A. Appendix

The following mathematical descriptions use elementary mathematics and a minimum set of assumptions, similar to the landmark article of [37]. These equations could be regarded as an extension of the work of [37], with my main points being that the fat-burning fraction can be calculated from serial fat and weight changes, producing the same result as 24 h indirect calorimetry. Importantly, the equations allow the clinician to determine the nonprotein respiratory quotient with serial weight and fat weight measurement, avoiding the necessity for gas exchange analysis. An important advantage of this mathematical method is that it can be used anywhere outside of a metabolic laboratory.

The R-ratio for modeling of the insulin resistance is defined in our analysis as the ratio of lean body mass change velocity ΔLk (lean mass change in 24 h) and fat mass change velocity ΔFk (fat mass change in 24 h) of day k as in Eq. (1).

$$R\_k = \frac{\Delta L\_k}{\Delta F\_k}.\tag{1}$$

noteworthy that this calculation avoids the division by zero for cases when there is

Here alpha α<sup>k</sup> is the first-order term coefficient in the Taylor series expansion

α ¼ 10:4 is used [38] if mass is measured in kilograms. Though intuitively it is felt that this may not be the case for everybody every time, the stability assumption for α over prolonged time is made by multiple authors [19, 38, 39]. Obviously,

Now, the daily weight change ΔWk can be connected to the daily fat change ΔFk using the first-order term coefficient in the Taylor series expansion similar

Obviously, finding the individual applicable value of the semi-stable daily lean mass change-related alpha αk, weight-related alpha αwk, and ϱWk is needed. For this purpose we want to take advantage of the principle of "least action" or "stationary action," which is assumed to hold true at steady state of an energy system. The same principle is widely used in Lagrangian or Hamiltonian mechanical systems. We want to extend this variational principle to the thermodynamic system of the human energy metabolism. Briefly stated, the time integral of a thermodynamic energy functional (Lagrangian functional) of the observed energy system under stationary assumption will assume a minimum value. The justification for our approach is that the first and second laws of thermodynamics (Hess's law) are fully applicable for indirect calorimetry as well as thermic energy calculations [37, 40]. The use of the principle of "least action/stationary action" will predict that the energy metabolism works with the minimum consumption of fuel and would not waste energy unnecessarily. Here we introduce our thermodynamic Lagrangian functional where the time integral is replaced by summation of energies for each

<sup>2</sup> <sup>þ</sup> λαwk � <sup>Δ</sup>Wk � <sup>α</sup>wk � ð Þ ln Fk � ln Fk�<sup>1</sup> ½ �

The minimum solution of L is sought for very slow changing semi-stable αwk and ϱWk for known ΔFk, ΔWk, and EBk. This solution could be obtained with numerical methods to minimize the Lagrangian functional L. The Lagrange multipliers λαwk and λϱWk are non-zero variables and are part of the minimization procedure, and they multiply the constraints for conservation of mass and energy, respectively. Metabolic studies suggest that a new steady state of equilibrium ensues

in 5–6 days [31] after a change of input variables occurs and equilibrium is reached. The parameters αwk and ϱWk can be considered stable. The Lagrangian functional L may also contain the parameter α<sup>k</sup> in a similar fashion to αwk if needed. Instead of using head-on numerical minimization methods to find the semi-stable parameters αwk and ϱWk, I prefer using the recursive least square method (RLS) of the general form yk ¼ ^z � xk where the time-dependent variables yk and xk are known and estimate for parameter ^z is sought. RLS has the advantage that the

<sup>≈</sup> <sup>α</sup>wk Fk

Rwk <sup>¼</sup> <sup>Δ</sup>Wk ΔFk

<sup>≈</sup> <sup>α</sup><sup>k</sup> Fk

: (8)

: (9)

(10)

Rk <sup>¼</sup> <sup>Δ</sup>Lk ΔFk

Cyber-Physical System for Management and Self-Management of Cardiometabolic Health

of the lean body-fat logarithmic functional relationship. For the value of

finding the individual applicable value of α<sup>k</sup> is desired [19].

no change of fat mass.

DOI: http://dx.doi.org/10.5772/intechopen.84262

to Eq. (8).

L ¼ ∑ k¼N k¼0

127

day from day k ¼ 1 to day k ¼ N:

ϱWk � Rwk þ ϱ<sup>F</sup> � <sup>Δ</sup>Fk

þ λϱWk � EBk � ϱWk � ΔWk � ϱ<sup>F</sup> � ΔFk

:

Likewise, Rw-ratio can be defined as the ratio of weight change velocity ΔWk (body weight change in 24 h) and fat mass change velocity ΔFk (fat mass change in 24 h) of day k as in Eq. (2).

$$Rw\_k = \frac{\Delta W\_k}{\Delta F\_k}.\tag{2}$$

We proposed the Rw-ratio for modeling of the insulin resistance as it is easier to measure change of weight than lean mass [26].

The total energy balance for the day k can be expressed as in Eq. (3):

$$
\rho\_{Wk} \cdot \Delta W\_k + \varrho\_F \cdot \Delta F\_k = MEI\_k - TEE\_k. \tag{3}
$$

The same energy balance as in (3) can be expressed also using Rw-ratio or Rwk as in Eq. (4):

$$\left(\varrho\_{Wk} \cdot Rw\_k + \varrho\_F\right) \cdot \Delta F\_k = MEI\_k - TEE\_k = EB\_k. \tag{4}$$

According to (3) and (4), the total energy balance (metabolically utilized energy intake MEIk minus total energy expenditure TEEk) is connected to changes of weight ΔWk and body fat mass change ΔFk at the end of day k where the energy distribution is governed by the energy density parameter for weight ϱWk and fat ϱF. In the case of positive energy balance, ΔLk, ΔWk, and ΔFk will have a positive sign, otherwise negative. ϱ<sup>F</sup> is the daily energy density of the fat mass change which is estimated to be ϱ<sup>F</sup> ≈9:4 Kcal/g. Rwk and ϱWk need to be estimated as direct measurement is not possible. The main idea and proposition here are to estimate Rwk from serial weight and fat weight measurement. ϱWk is estimated here from serial measurement of weight and energy balance EBk. Accordingly, the input to our models is going to be known measured values of daily weight Wk and fat weight Fk. The daily energy balance EBk is indirectly measured or calculated. If no calorie counting and total energy expenditure measurements are done, then the option exists to use (5):

$$EB\_k \approx (\varrho\_L \cdot R\_k + \varrho\_F) \cdot \Delta F\_k. \tag{5}$$

Here the energy density value of lean mass change ϱ<sup>L</sup> is used, which is assumed to be around ϱ<sup>L</sup> ≈1:8 Kcal/g and is a semi-stable value [19]. Now the estimation of Rk and Rwk is needed. Here we exploit the observation that there is a logarithmic relationship between lean mass and fat mass according to Forbes [38]:

$$L\_k = a\_k \cdot \ln\left(F\_k\right). \tag{6}$$

The same assumption can be used for weight and fat weight interrelationship:

$$\mathcal{W}\_k = a\nu\_k \cdot \ln \left( F\_k \right). \tag{7}$$

Now the daily lean mass change ΔLk can be connected to the daily fat change ΔFk using the first-order term coefficient in the Taylor series expansion. It is

Cyber-Physical System for Management and Self-Management of Cardiometabolic Health DOI: http://dx.doi.org/10.5772/intechopen.84262

noteworthy that this calculation avoids the division by zero for cases when there is no change of fat mass.

$$R\_k = \frac{\Delta L\_k}{\Delta F\_k} \approx \frac{a\_k}{F\_k}.\tag{8}$$

Here alpha α<sup>k</sup> is the first-order term coefficient in the Taylor series expansion of the lean body-fat logarithmic functional relationship. For the value of α ¼ 10:4 is used [38] if mass is measured in kilograms. Though intuitively it is felt that this may not be the case for everybody every time, the stability assumption for α over prolonged time is made by multiple authors [19, 38, 39]. Obviously, finding the individual applicable value of α<sup>k</sup> is desired [19].

Now, the daily weight change ΔWk can be connected to the daily fat change ΔFk using the first-order term coefficient in the Taylor series expansion similar to Eq. (8).

$$Rw\_k = \frac{\Delta W\_k}{\Delta F\_k} \approx \frac{aw\_k}{F\_k} \,. \tag{9}$$

Obviously, finding the individual applicable value of the semi-stable daily lean mass change-related alpha αk, weight-related alpha αwk, and ϱWk is needed. For this purpose we want to take advantage of the principle of "least action" or "stationary action," which is assumed to hold true at steady state of an energy system. The same principle is widely used in Lagrangian or Hamiltonian mechanical systems. We want to extend this variational principle to the thermodynamic system of the human energy metabolism. Briefly stated, the time integral of a thermodynamic energy functional (Lagrangian functional) of the observed energy system under stationary assumption will assume a minimum value. The justification for our approach is that the first and second laws of thermodynamics (Hess's law) are fully applicable for indirect calorimetry as well as thermic energy calculations [37, 40]. The use of the principle of "least action/stationary action" will predict that the energy metabolism works with the minimum consumption of fuel and would not waste energy unnecessarily. Here we introduce our thermodynamic Lagrangian functional where the time integral is replaced by summation of energies for each day from day k ¼ 1 to day k ¼ N:

$$\begin{split} L &= \sum\_{k=0}^{k=N} \left[ \left( \varrho\_{Wk} \cdot R\boldsymbol{\nu}\_{k} + \varrho\_{\mathcal{F}} \right) \cdot \Delta \boldsymbol{F}\_{k} \right]^{2} + \lambda a \boldsymbol{\nu}\_{k} \cdot \left[ \Delta \boldsymbol{W}\_{k} - a \boldsymbol{\nu}\_{k} \cdot \left( \ln \boldsymbol{F}\_{k} - \ln \boldsymbol{F}\_{k-1} \right) \right] \\ &+ \lambda \boldsymbol{\varrho}\_{Wk} \cdot \left[ \boldsymbol{E} \boldsymbol{B}\_{k} - \varrho\_{\mathcal{W}k} \cdot \Delta \boldsymbol{W}\_{k} - \varrho\_{\mathcal{F}} \cdot \Delta \boldsymbol{F}\_{k} \right]. \end{split} \tag{10}$$

The minimum solution of L is sought for very slow changing semi-stable αwk and ϱWk for known ΔFk, ΔWk, and EBk. This solution could be obtained with numerical methods to minimize the Lagrangian functional L. The Lagrange multipliers λαwk and λϱWk are non-zero variables and are part of the minimization procedure, and they multiply the constraints for conservation of mass and energy, respectively. Metabolic studies suggest that a new steady state of equilibrium ensues in 5–6 days [31] after a change of input variables occurs and equilibrium is reached. The parameters αwk and ϱWk can be considered stable. The Lagrangian functional L may also contain the parameter α<sup>k</sup> in a similar fashion to αwk if needed. Instead of using head-on numerical minimization methods to find the semi-stable parameters αwk and ϱWk, I prefer using the recursive least square method (RLS) of the general form yk ¼ ^z � xk where the time-dependent variables yk and xk are known and estimate for parameter ^z is sought. RLS has the advantage that the

The R-ratio for modeling of the insulin resistance is defined in our analysis as the ratio of lean body mass change velocity ΔLk (lean mass change in 24 h) and fat mass

> Rk <sup>¼</sup> <sup>Δ</sup>Lk ΔFk

Likewise, Rw-ratio can be defined as the ratio of weight change velocity ΔWk (body weight change in 24 h) and fat mass change velocity ΔFk (fat mass change in

> Rwk <sup>¼</sup> <sup>Δ</sup>Wk ΔFk

The total energy balance for the day k can be expressed as in Eq. (3):

We proposed the Rw-ratio for modeling of the insulin resistance as it is easier to

The same energy balance as in (3) can be expressed also using Rw-ratio or Rwk as

According to (3) and (4), the total energy balance (metabolically utilized energy

Here the energy density value of lean mass change ϱ<sup>L</sup> is used, which is assumed to be around ϱ<sup>L</sup> ≈1:8 Kcal/g and is a semi-stable value [19]. Now the estimation of Rk and Rwk is needed. Here we exploit the observation that there is a logarithmic

The same assumption can be used for weight and fat weight interrelationship:

Now the daily lean mass change ΔLk can be connected to the daily fat change ΔFk using the first-order term coefficient in the Taylor series expansion. It is

relationship between lean mass and fat mass according to Forbes [38]:

intake MEIk minus total energy expenditure TEEk) is connected to changes of weight ΔWk and body fat mass change ΔFk at the end of day k where the energy distribution is governed by the energy density parameter for weight ϱWk and fat ϱF. In the case of positive energy balance, ΔLk, ΔWk, and ΔFk will have a positive sign, otherwise negative. ϱ<sup>F</sup> is the daily energy density of the fat mass change which is estimated to be ϱ<sup>F</sup> ≈9:4 Kcal/g. Rwk and ϱWk need to be estimated as direct measurement is not possible. The main idea and proposition here are to estimate Rwk from serial weight and fat weight measurement. ϱWk is estimated here from serial measurement of weight and energy balance EBk. Accordingly, the input to our models is going to be known measured values of daily weight Wk and fat weight Fk. The daily energy balance EBk is indirectly measured or calculated. If no calorie counting and total energy expenditure measurements are done, then the option

ϱWk � ΔWk þ ϱ<sup>F</sup> � ΔFk ¼ MEIk � TEEk: (3)

� <sup>Δ</sup>Fk <sup>¼</sup> MEIk � TEEk <sup>¼</sup> EBk: (4)

EBk ≈ ϱ<sup>L</sup> � Rk þ ϱ<sup>F</sup> ð Þ� ΔFk: (5)

Lk ¼ α<sup>k</sup> � ln ð Þ Fk : (6)

Wk ¼ αwk � ln ð Þ Fk : (7)

: (1)

: (2)

change velocity ΔFk (fat mass change in 24 h) of day k as in Eq. (1).

Type 2 Diabetes - From Pathophysiology to Modern Management

24 h) of day k as in Eq. (2).

in Eq. (4):

exists to use (5):

126

measure change of weight than lean mass [26].

ϱWk � Rwk þ ϱ<sup>F</sup>

estimate of ^zk�<sup>1</sup> at time k � 1 can be updated at the arrival of the new measured variables yk and xk. This method allows us to estimate α^wk when ΔWk, ΔFk, and Fk are available. Similarly, ϱ^ <sup>W</sup> <sup>k</sup> can be estimated when a new set of ΔWk, ΔFk, and EBk are available.

Once all parameters of the energy balance Eq. (4) are known, the nonfat energy balance and fat energy balance can be calculated as in Eqs. (11) and (12), respectively:

$$
\rho\_{Wk} \cdot \Delta W\_k = (\mathbf{1} - \rho\_k) \cdot \text{MEI}\_k - (\mathbf{1} - \chi\_k) \cdot \text{TEE}\_k,\tag{11}
$$

$$
\varrho\_F \cdot \Delta F\_k = \varrho\_k \cdot \mathrm{MEI}\_k - \chi\_k \cdot \mathrm{TEE}\_k. \tag{12}
$$

Here φ<sup>k</sup> designates fat intake fraction as defined in Eq. (13), and χ<sup>k</sup> denotes the fat-burning fraction as in Eq. (14).

$$
\rho\_k = \frac{FI\_k}{MEI\_k},
\tag{13}
$$

Further, according to Elia and Livesey [37] during nonprotein energy production, the nonprotein respiratory quotient Rnpk can be calculated from the fatburning fraction χ<sup>k</sup> using stoichiometry under the assumption that mainly

Cyber-Physical System for Management and Self-Management of Cardiometabolic Health

dioleylpalmityltriglyceride and glucose are used as fuels for oxidation as in Eq. (19)

Rnpk <sup>¼</sup> <sup>a</sup> � <sup>χ</sup><sup>k</sup> � <sup>a</sup> <sup>þ</sup> <sup>χ</sup><sup>k</sup> � <sup>b</sup> � <sup>c</sup>

All calculations from Eqs. (1)–(19) use the same assumption as Elia and Livesey

The somewhat arbitrary looking choice of definitions Eqs. (17) and (18) can be justified with our experience that increasing insulin resistance would lead to more sugar burning and less fat burning. Further it allows for the calculated burning fraction χ<sup>k</sup> in Eq. (18) to be used as an input variable to calculate the nonprotein respiratory quotient Rnpk as in Eq. (19). The result of this choice is also that an increasing (or decreasing) burning fraction χ<sup>k</sup> would translate into a decreasing (or increasing) nonprotein respiratory quotient Rnpk as demonstrated in Figure 2a and b

The constant values in [37] are a ¼ 19:502, b ¼ 21:120, and c ¼ 0:7097.

[37] for their formulas, which remain in keeping and coincide with traditional

indirect calorimetry calculation as introduced by Lusk [37].

We calculate the total energy expenditure as in Eq. (20):

Ori Diagnostic Instruments, LLC, Durham, NC, USA

\*Address all correspondence to: zsolt.ori56@gmail.com

provided the original work is properly cited.

© 2019 The Author(s). Licensee IntechOpen. This chapter is distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/ by/3.0), which permits unrestricted use, distribution, and reproduction in any medium,

<sup>a</sup> � <sup>χ</sup><sup>k</sup> � <sup>a</sup> <sup>þ</sup> <sup>χ</sup><sup>k</sup> � <sup>b</sup> : (19)

TEEk ¼ PAEk þ BMRk: (20)

adopted from Elia [37].

DOI: http://dx.doi.org/10.5772/intechopen.84262

and 3a and b.

Author details

Zsolt Peter Ori

129

and

$$\chi\_k = \frac{FO\_k}{TEE\_k}.\tag{14}$$

In Eq. (13), FIk represents fat intake, and in Eq. (14), FOk stands for oxidized fat calories of day k:

We made an important observation in [2, 3, 26] that the R-ratio Rk strongly and negatively correlates with HOMA-IR. Building on this observation and using Rwratio Rwk, we introduce here a possible modeling of the connection between insulin resistance and substrate fractionation. At assumed steady state, the fat-burning fraction χ<sup>k</sup> approximates food fraction φ<sup>k</sup> according to [31], and they become quasi equal. Under this condition the nonfat and fat energy balance can be written in a simplified form as in Eqs. (15) and (16):

$$
\varrho\_{Wk} \cdot \Delta W\_k = \frac{\varrho\_F}{\varrho\_{Wk} \cdot Rw\_k + \varrho\_F} \cdot (MEI\_k - TEE\_k), \tag{15}
$$

$$
\varrho\_F \cdot \Delta F\_k = \frac{\varrho\_{Wk} \cdot Rw\_k}{\varrho\_{Wk} \cdot Rw\_k + \varrho\_F} \cdot (MEI\_k - TEE\_k) . \tag{16}
$$

Accordingly, the carbohydrate burning fraction 1 � χ<sup>k</sup> and the fat-burning fraction χ<sup>k</sup> can be written as in Eqs. (17) and (18):

$$\mathbf{1} - \chi\_k = \frac{\varrho\_F}{\varrho\_{Wk} \cdot Rw\_k + \varrho\_F} = \frac{CO\_k}{CO\_k + FO\_k},\tag{17}$$

$$\chi\_k = \frac{\varrho\_{Wk} \cdot R w\_k}{\varrho\_{Wk} \cdot R w\_k + \varrho\_F} = \frac{F O\_k}{\text{CO}\_k + F O\_k}. \tag{18}$$

Important properties of Eqs. (15) and (16) are that they add up to the total energy balance equation as in Eq. (3). It can be seen in this pair of equations that with decreasing insulin resistance, i.e., decreasing HOMA-IR and concomitantly increasing Rw-ratio Rwk, the fat-burning fraction χ<sup>k</sup> increases, and the carbohydrate burning fraction 1 � χ<sup>k</sup> would decrease. Similarly, with increasing insulin resistance, i.e., increasing HOMA-IR and concomitantly decreasing Rw-ratio Rwk, the fat-burning fraction χ<sup>k</sup> decreases, and carbohydrate burning fraction 1 � χ<sup>k</sup> would increase as demonstrated in Figure 2a and b.

Cyber-Physical System for Management and Self-Management of Cardiometabolic Health DOI: http://dx.doi.org/10.5772/intechopen.84262

Further, according to Elia and Livesey [37] during nonprotein energy production, the nonprotein respiratory quotient Rnpk can be calculated from the fatburning fraction χ<sup>k</sup> using stoichiometry under the assumption that mainly dioleylpalmityltriglyceride and glucose are used as fuels for oxidation as in Eq. (19) adopted from Elia [37].

$$Rnp\_k = \frac{a - \chi\_k \cdot a + \chi\_k \cdot b \cdot c}{a - \chi\_k \cdot a + \chi\_k \cdot b}. \tag{19}$$

The constant values in [37] are a ¼ 19:502, b ¼ 21:120, and c ¼ 0:7097.

All calculations from Eqs. (1)–(19) use the same assumption as Elia and Livesey [37] for their formulas, which remain in keeping and coincide with traditional indirect calorimetry calculation as introduced by Lusk [37].

The somewhat arbitrary looking choice of definitions Eqs. (17) and (18) can be justified with our experience that increasing insulin resistance would lead to more sugar burning and less fat burning. Further it allows for the calculated burning fraction χ<sup>k</sup> in Eq. (18) to be used as an input variable to calculate the nonprotein respiratory quotient Rnpk as in Eq. (19). The result of this choice is also that an increasing (or decreasing) burning fraction χ<sup>k</sup> would translate into a decreasing (or increasing) nonprotein respiratory quotient Rnpk as demonstrated in Figure 2a and b and 3a and b.

We calculate the total energy expenditure as in Eq. (20):

$$TEE\_k = PAE\_k + BMR\_k.\tag{20}$$
