Skip Navigation

Nutrition Sim

Eating healthy

April 30, 2022 · Alex Ulbrich

Food on table
Table of Contents

In this project, the goal is for an individual to easily access nutrition information and how to meet the recommended nutrient values.

Nutrients are substances used by an organism to survive, grow, and reproduce. One classification for nutrients divides then into macronutrients and micronutrients.

Macronutrients and Calories

Macronutrients are primarily used to generate energy and to grow or repair tissues.

The SI unit for energy is the Joule, denoted by J. In nutrition, another unit, the calorie (denoted by cal) is often used. It might be written Calorie, Cal, or kcal. It is defined as the amount of heat needed to raise the temperature of one kilogram of water (one liter) by one degree Celsius (or one kelvin). One calorie is generally assumed to be 4184 J.

The macronutrients described below have an approximate energy content per gram.

Carbohydrates (excl. dietary fibers)417
Dietary Fibers28

A more detailed breakdown is available from Regulation (EU) No 1169/2011, Annex XIV.

This can be used to approximate the energy intake (i.e., calories or joules collected by ingesting food). In turn, this intake can be compared to the energy going out.


Carbohydrates are composed of hydrogen, oxygen, and carbon molecules. They are a major source of energy. They can be separated in simple (“sugars”) and complex carbohydrates.

Simple carbohydrates include monosaccharides (e.g., glucose, fructose, galactose) and disaccharides (e.g., maltose, sucrose, lactose). Disaccharides are a combination of two monosaccharides (e.g., sucrose is composed of one glucose and one fructose). Monosaccharides and disaccharides are commonly referred to as “sugar” but not all of them have a sweet taste.

Monosaccharides can be directly absorbed in the bloodstream to provide energy. They don’t require digestion. Disaccharides require digestion (the process is called hydrolysis) to be broken down to their individual monosaccharides.

Complex carbohydrates are composed of three or more monosaccharides. Among complex carbohydrates are starches (e.g., potato, rice, wheat). Starches are how plants store glucose. Some starches are digestible by humans and are a common source of energy. Glycogen is another type of complex carbohydrates. It is the animal equivalent of starches. Humans can store glucose in the body by producing glycogen.

Dietary fibers are another classification for some types of non-digestible complex carbohydrates (e.g., resistant starches). Hence, fibers cannot be used for energy, but provide many health benefits.

Carbohydrates can also be separated into available and unavailable. Available carbohydrates are those absorbed by the small intestine. Unavailable ones (e.g., dietary fibers) are subject to fermentation in the large intestine.

Nutrition labels do not define carbohydrate content the same way. For instance,

  • in the US, the carbohydrate content is obtained by subtracting all other constituents from the total (water, protein, fat, alcohol, and minerals),
  • in Europe, carbohydrate content is defined as “available carbohydrate,” and hence, the energy content is split for different types of carbohydrates (e.g., polyols, fibers).

Unfortunately, in the US, the calories calculated use the basic 4 cal/g or 17 kJ/g energy content. Foods rich in dietary fibers or polyols should have a lower energy content that advertised on the label.

There are many more carbohydrates subtypes than described here (such as polyols), but they were not required to understand how carbohydrates work.




Reference Intakes

In this example, you see the reference energy intake for 18-29 years old individuals. The range varies depending on gender and activity level.

Energy or macronutrientsReference Intake (RI)
Energy7.9-14 MJ
Total Lipids20-35 E%
Total Carbohydrates45-60 E%
Protein0.83 g/kg


Micronutrients are needed in smaller amounts (milligrams or micrograms). They have more subtle roles in cellular processes.

Allergens and Restrictions


Physical Activity Levels

Physical Activity Level

Human Energy Requirements

Total energy expenditure (TEE) and physical activity levels (PAL) in adults

Benefits of a Good Nutrition

Health Indicators

Heart rate variability

find papers on heart rate / variability

Average Rest Heart Rate

Average Sleep Heart Rate

Surface-based Body Shape Index (SBSI)

no recommendation

Body Mass Index (BMI)

Body Volume Index (BVI)

Waist Circumference


Intake of macro- and micronutrients in Danish vegans

EPIC-Oxford: lifestyle characteristics and nutrient intakes in a cohort of 33 883 meat-eaters and 31 546 non meat-eaters in the UK

The energy and nutrient intakes of different types of vegetarian: a case for supplements?

Comparative metabolomics in vegans and omnivores reveal constraints on diet-dependent gut microbiota metabolite production

Nutrient intakes and eating behavior scores of vegetarian and nonvegetarian women

Comparison of Nutritional Quality of the Vegan, Vegetarian, Semi-Vegetarian, Pesco-Vegetarian and Omnivorous Diet

Dietary intake and biochemical, hematologic, and immune status of vegans compared with nonvegetarians