Location: Diabetes @ 2c3451dfbd0a / BondGraph / BG.cellml

Author:
Soroush <ssaf006@aucklanduni.ac.nz>
Date:
2018-06-07 18:16:45+12:00
Desc:
add
Permanent Source URI:
https://models.cellml.org/workspace/483/rawfile/2c3451dfbd0a114efbabe7f43d40c8172c5915f4/BondGraph/BG.cellml

<?xml version='1.0'?>
<model name="main1" xmlns="http://www.cellml.org/cellml/1.1#" xmlns:cellml="http://www.cellml.org/cellml/1.1#" xmlns:xlink="http://www.w3.org/1999/xlink">
    <import xlink:href="Units.cellml">
        <units name="mmol_per_s" units_ref="mmol_per_s"/>
        <units name="mol_per_s" units_ref="mol_per_s"/>
        <units name="per_s" units_ref="per_s"/>
        <units name="m3_per_s" units_ref="m3_per_s"/>
        <units name="per_mol" units_ref="per_mol"/>
        <units name="kg_per_mol" units_ref="kg_per_mol"/>
        <units name="mM" units_ref="mM"/>
        <units name="pM" units_ref="pM"/>
        <units name="pmol" units_ref="pmol"/>
        <units name="mmol" units_ref="mmol"/>
        <units name="mM_per_s" units_ref="mM_per_s"/>
        <units name="mM_per_mol" units_ref="mM_per_mol"/>
        <units name="m3" units_ref="m3"/>
        <units name="g_per_s" units_ref="g_per_s"/>
        <units name="l_per_kg" units_ref="l_per_kg"/>
        <units name="s_per_pmol" units_ref="s_per_pmol"/>
        <units name="g_per_l" units_ref="g_per_l"/>
        <units name="g_per_s_pM" units_ref="g_per_s_pM"/>
        <units name="g_per_s_pmol" units_ref="g_per_s_pmol"/>
        <units name="pmol_per_s" units_ref="pmol_per_s"/>
        <units name="mmol_per_s_kg" units_ref="mmol_per_s_kg"/>
        <units name="pM_per_s" units_ref="pM_per_s"/>
        <units name="pmol_l_per_g_s" units_ref="pmol_l_per_g_s"/>
        <units name="pmol_l_per_g" units_ref="pmol_l_per_g"/>
        <units name="per_g" units_ref="per_g"/>
        <units name="mmol_per_g" units_ref="mmol_per_g"/>
        <units name="per_mM_s" units_ref="per_mM_s"/>
        <units name="per_mM" units_ref="per_mM"/>
    </import>
    <component name="environment">
        <variable name="time" public_interface="out" units="second"/>
    </component>
    <component name="state">
        <variable name="t" public_interface="in" units="second"/>
        <!-- State variable-->
        <!-- q_G_pl: blood glucose
 q_I_pl: plasma insulin
 q_I_pe: peripheral insulin
 k_gre: kidney extraction
 k_cns: central nervous system uptake
 k_is: insulin sensitivity
 k_egp: endogenous glucose production
 k_ra: glucose exogenous input
 k_gsat: saturation of insulin mediated glucose uptake parameter
 k_hs: hepatic secretion of insulin
 k_bl: rate constant of insulin clearance through blood
 k_isat: hepatic clearance parameter
 k_ire: kidney clearance of insulin
 k_diff: insulin diffusion between plasma and periphery
 k_cell: insulin degradation by cell rate constant
 k_end: insulin secretion
 k_exo: delivered insulin exogenously
 V_G_pl: volume of distribution of glucose in plasma
 V_I_pl: blood plasma volume - distribution of plasma insulin
 V_I_pe: interstitial fluid volume - distribution of peripheral insulin-->
        <variable initial_value="0.0" name="q_G_pl" public_interface="out" units="mM"/>
        <variable initial_value="0.0" name="q_I_pl" public_interface="out" units="mM"/>
        <variable initial_value="0.0" name="q_I_pe" public_interface="out" units="mM"/>
        <variable initial_value="78" name="q_G_sto1" public_interface="out" units="gram"/>
        <variable initial_value="0.0" name="q_G_sto2" public_interface="out" units="gram"/>
        <variable initial_value="0.0" name="q_G_gut" public_interface="out" units="gram"/>
        <variable name="v_G_RE" public_interface="out" units="mM_per_s"/>
        <variable name="v_G_EGP" public_interface="out" units="mM_per_s"/>
        <variable name="v_G_RA" public_interface="out" units="mM_per_s"/>
        <!--var v_G_RA1: mM_per_s {pub: out};-->
        <variable name="v_G_abs" public_interface="out" units="g_per_s"/>
        <variable name="v_G_empt" public_interface="out" units="g_per_s"/>
        <variable name="v_G_gri" public_interface="out" units="g_per_s"/>
        <variable name="v_G_CNS" public_interface="out" units="mM_per_s"/>
        <variable name="v_G_idu" public_interface="out" units="mM_per_s"/>
        <variable name="v_I_PE" public_interface="out" units="mM_per_s"/>
        <variable name="v_I_DEG" public_interface="out" units="mM_per_s"/>
        <variable name="v_I_END" public_interface="out" units="mM_per_s"/>
        <variable name="v_I_EXO" public_interface="out" units="mM_per_s"/>
        <variable name="v_I_RE" public_interface="out" units="mM_per_s"/>
        <variable name="v_I_HE" public_interface="out" units="mM_per_s"/>
        <variable initial_value="0.75" name="m_body" public_interface="out" units="kilogram"/>
        <variable name="m_brain" units="kilogram"/>
        <variable initial_value="0.045" name="V_I_pl" public_interface="out" units="l_per_kg"/>
        <variable initial_value="0.289" name="V_I_pe" public_interface="out" units="l_per_kg"/>
        <variable initial_value="0.56" name="V_G_pl" public_interface="out" units="l_per_kg"/>
        <variable initial_value="0.00005" name="k_gre" public_interface="out" units="per_s"/>
        <variable initial_value="0.00055" name="k_egp" public_interface="out" units="mmol_per_s_kg"/>
        <variable initial_value="0.0001733" name="k_ra" public_interface="out" units="mmol_per_s"/>
        <variable initial_value="0.001467" name="k_cns" public_interface="out" units="mmol_per_s_kg"/>
        <variable initial_value="0.67" name="k_hs" public_interface="out" units="dimensionless"/>
        <variable initial_value="0.01667e-7" name="k_is" public_interface="out" units="per_mM_s"/>
        <variable initial_value="0.00043" name="k_cell" public_interface="out" units="per_s"/>
        <variable initial_value="0.0005667" name="k_ire" public_interface="out" units="per_s"/>
        <variable initial_value="0.0004167" name="k_diff" public_interface="out" units="per_s"/>
        <variable initial_value="0.0065" name="k_bl" public_interface="out" units="per_s"/>
        <variable initial_value="0.0" name="k_gsat" public_interface="out" units="per_mM"/>
        <variable initial_value="0.0017" name="k_isat" public_interface="out" units="per_mM"/>
        <variable initial_value="0.0" name="k_EXO" public_interface="out" units="mmol_per_s"/>
        <variable name="k_END" units="mM_per_s"/>
        <variable name="a" public_interface="out" units="per_g"/>
        <variable name="c" public_interface="out" units="per_g"/>
        <variable initial_value="0.00093" name="k_max" public_interface="out" units="per_s"/>
        <variable initial_value="0.00013" name="k_min" public_interface="out" units="per_s"/>
        <variable initial_value="0.00095" name="k_abs" public_interface="out" units="per_s"/>
        <variable initial_value="0.00093" name="k_gri" public_interface="out" units="per_s"/>
        <variable initial_value="0.9" name="f" public_interface="out" units="dimensionless"/>
        <variable initial_value="0.82" name="b" public_interface="out" units="dimensionless"/>
        <variable initial_value="0.01" name="d" public_interface="out" units="dimensionless"/>
        <variable initial_value="78" name="BW" public_interface="out" units="kilogram"/>
        <variable name="k_empt" public_interface="out" units="per_s"/>
        <variable initial_value="78" name="D" public_interface="out" units="gram"/>
        <variable initial_value="5.551" name="mol_gram" units="mmol_per_g"/>
        <math xmlns="http://www.w3.org/1998/Math/MathML">
            <apply>
                <eq/>
                <ci>m_brain</ci>
                <apply>
                    <times/>
                    <cn cellml:units="dimensionless">0.14</cn>
                    <ci>m_body</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>k_END</ci>
                <piecewise>
                    <piece>
                        <apply>
                            <plus/>
                            <apply>
                                <minus/>
                                <cn cellml:units="mM_per_s">0.025</cn>
                            </apply>
                            <apply>
                                <times/>
                                <cn cellml:units="per_s">0.0317</cn>
                                <ci>q_G_pl</ci>
                            </apply>
                        </apply>
                        <apply>
                            <gt/>
                            <apply>
                                <plus/>
                                <apply>
                                    <minus/>
                                    <cn cellml:units="mM_per_s">0.025</cn>
                                </apply>
                                <apply>
                                    <times/>
                                    <cn cellml:units="per_s">0.0317</cn>
                                    <ci>q_G_pl</ci>
                                </apply>
                            </apply>
                            <cn cellml:units="mM_per_s">0.07</cn>
                        </apply>
                    </piece>
                    <piece>
                        <cn cellml:units="mM_per_s">0.07</cn>
                        <apply>
                            <leq/>
                            <apply>
                                <plus/>
                                <apply>
                                    <minus/>
                                    <cn cellml:units="mM_per_s">0.025</cn>
                                </apply>
                                <apply>
                                    <times/>
                                    <cn cellml:units="per_s">0.0317</cn>
                                    <ci>q_G_pl</ci>
                                </apply>
                            </apply>
                            <cn cellml:units="mM_per_s">0.07</cn>
                        </apply>
                    </piece>
                </piecewise>
            </apply>
            <!-- Glucose Kinetics-->
            <apply>
                <eq/>
                <apply>
                    <diff/>
                    <bvar>
                        <ci>t</ci>
                    </bvar>
                    <ci>q_G_pl</ci>
                </apply>
                <apply>
                    <minus/>
                    <apply>
                        <minus/>
                        <apply>
                            <minus/>
                            <apply>
                                <plus/>
                                <ci>v_G_RA</ci>
                                <ci>v_G_EGP</ci>
                            </apply>
                            <ci>v_G_RE</ci>
                        </apply>
                        <ci>v_G_CNS</ci>
                    </apply>
                    <ci>v_G_idu</ci>
                </apply>
            </apply>
            <!-- Glucose Rate of Appearance-->
            <apply>
                <eq/>
                <apply>
                    <diff/>
                    <bvar>
                        <ci>t</ci>
                    </bvar>
                    <ci>q_G_sto1</ci>
                </apply>
                <apply>
                    <minus/>
                    <ci>v_G_gri</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <apply>
                    <diff/>
                    <bvar>
                        <ci>t</ci>
                    </bvar>
                    <ci>q_G_sto2</ci>
                </apply>
                <apply>
                    <minus/>
                    <ci>v_G_gri</ci>
                    <ci>v_G_empt</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <apply>
                    <diff/>
                    <bvar>
                        <ci>t</ci>
                    </bvar>
                    <ci>q_G_gut</ci>
                </apply>
                <apply>
                    <minus/>
                    <ci>v_G_empt</ci>
                    <ci>v_G_abs</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>a</ci>
                <apply>
                    <divide/>
                    <cn cellml:units="dimensionless">2.5</cn>
                    <apply>
                        <times/>
                        <apply>
                            <minus/>
                            <cn cellml:units="dimensionless">1</cn>
                            <ci>b</ci>
                        </apply>
                        <ci>D</ci>
                    </apply>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>c</ci>
                <apply>
                    <divide/>
                    <cn cellml:units="dimensionless">2.5</cn>
                    <apply>
                        <times/>
                        <ci>d</ci>
                        <ci>D</ci>
                    </apply>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>k_empt</ci>
                <apply>
                    <plus/>
                    <ci>k_min</ci>
                    <apply>
                        <times/>
                        <apply>
                            <divide/>
                            <apply>
                                <minus/>
                                <ci>k_max</ci>
                                <ci>k_min</ci>
                            </apply>
                            <cn cellml:units="dimensionless">2</cn>
                        </apply>
                        <apply>
                            <plus/>
                            <apply>
                                <minus/>
                                <apply>
                                    <tanh/>
                                    <apply>
                                        <times/>
                                        <ci>a</ci>
                                        <apply>
                                            <minus/>
                                            <apply>
                                                <plus/>
                                                <ci>q_G_sto1</ci>
                                                <ci>q_G_sto2</ci>
                                            </apply>
                                            <apply>
                                                <times/>
                                                <ci>b</ci>
                                                <ci>D</ci>
                                            </apply>
                                        </apply>
                                    </apply>
                                </apply>
                                <apply>
                                    <tanh/>
                                    <apply>
                                        <times/>
                                        <ci>c</ci>
                                        <apply>
                                            <minus/>
                                            <apply>
                                                <plus/>
                                                <ci>q_G_sto1</ci>
                                                <ci>q_G_sto2</ci>
                                            </apply>
                                            <apply>
                                                <times/>
                                                <ci>d</ci>
                                                <ci>D</ci>
                                            </apply>
                                        </apply>
                                    </apply>
                                </apply>
                            </apply>
                            <cn cellml:units="dimensionless">2</cn>
                        </apply>
                    </apply>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_G_gri</ci>
                <apply>
                    <times/>
                    <ci>k_gri</ci>
                    <ci>q_G_sto1</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_G_empt</ci>
                <apply>
                    <times/>
                    <ci>k_empt</ci>
                    <ci>q_G_sto2</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_G_abs</ci>
                <apply>
                    <times/>
                    <ci>k_abs</ci>
                    <ci>q_G_gut</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_G_RA</ci>
                <apply>
                    <times/>
                    <apply>
                        <divide/>
                        <ci>v_G_abs</ci>
                        <apply>
                            <times/>
                            <ci>V_G_pl</ci>
                            <ci>m_body</ci>
                        </apply>
                    </apply>
                    <ci>f</ci>
                    <ci>mol_gram</ci>
                </apply>
            </apply>
            <!-- Endogenous Glucose Production-->
            <apply>
                <eq/>
                <ci>v_G_EGP</ci>
                <apply>
                    <divide/>
                    <ci>k_egp</ci>
                    <ci>V_G_pl</ci>
                </apply>
            </apply>
            <!-- Glucose Uptake-->
            <apply>
                <eq/>
                <ci>v_G_RE</ci>
                <apply>
                    <times/>
                    <ci>k_gre</ci>
                    <ci>q_G_pl</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_G_CNS</ci>
                <apply>
                    <divide/>
                    <apply>
                        <times/>
                        <ci>k_cns</ci>
                        <ci>m_brain</ci>
                    </apply>
                    <apply>
                        <times/>
                        <ci>V_G_pl</ci>
                        <ci>m_body</ci>
                    </apply>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_G_idu</ci>
                <apply>
                    <divide/>
                    <apply>
                        <times/>
                        <ci>k_is</ci>
                        <ci>q_G_pl</ci>
                        <ci>q_I_pe</ci>
                    </apply>
                    <apply>
                        <plus/>
                        <cn cellml:units="dimensionless">1</cn>
                        <apply>
                            <times/>
                            <ci>k_gsat</ci>
                            <ci>q_I_pe</ci>
                        </apply>
                    </apply>
                </apply>
            </apply>
            <!-- Insulin Kinetics-->
            <apply>
                <eq/>
                <apply>
                    <diff/>
                    <bvar>
                        <ci>t</ci>
                    </bvar>
                    <ci>q_I_pl</ci>
                </apply>
                <apply>
                    <minus/>
                    <apply>
                        <minus/>
                        <apply>
                            <minus/>
                            <apply>
                                <plus/>
                                <ci>v_I_END</ci>
                                <ci>v_I_EXG</ci>
                            </apply>
                            <ci>v_I_HE</ci>
                        </apply>
                        <ci>v_I_RE</ci>
                    </apply>
                    <ci>v_I_PE</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <apply>
                    <diff/>
                    <bvar>
                        <ci>t</ci>
                    </bvar>
                    <ci>q_I_pe</ci>
                </apply>
                <apply>
                    <minus/>
                    <apply>
                        <divide/>
                        <apply>
                            <times/>
                            <ci>v_I_PE</ci>
                            <ci>V_I_pl</ci>
                        </apply>
                        <ci>V_I_pe</ci>
                    </apply>
                    <ci>v_I_DEG</ci>
                </apply>
            </apply>
            <!-- Insulin Secretion-->
            <apply>
                <eq/>
                <ci>v_I_END</ci>
                <apply>
                    <times/>
                    <apply>
                        <minus/>
                        <cn cellml:units="dimensionless">1</cn>
                        <ci>k_hs</ci>
                    </apply>
                    <ci>k_END</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_I_EXO</ci>
                <apply>
                    <divide/>
                    <ci>k_EXO</ci>
                    <apply>
                        <times/>
                        <ci>V_I_pl</ci>
                        <ci>m_body</ci>
                    </apply>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_I_PE</ci>
                <apply>
                    <times/>
                    <ci>k_diff</ci>
                    <apply>
                        <minus/>
                        <ci>q_I_pl</ci>
                        <ci>q_I_pe</ci>
                    </apply>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_I_RE</ci>
                <apply>
                    <times/>
                    <ci>k_ire</ci>
                    <ci>q_I_pl</ci>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_I_HE</ci>
                <apply>
                    <divide/>
                    <apply>
                        <times/>
                        <ci>k_bl</ci>
                        <ci>q_I_pl</ci>
                    </apply>
                    <apply>
                        <plus/>
                        <cn cellml:units="dimensionless">1</cn>
                        <apply>
                            <times/>
                            <ci>k_isat</ci>
                            <ci>q_I_pl</ci>
                        </apply>
                    </apply>
                </apply>
            </apply>
            <apply>
                <eq/>
                <ci>v_I_DEG</ci>
                <apply>
                    <divide/>
                    <apply>
                        <times/>
                        <ci>k_cell</ci>
                        <ci>q_I_pe</ci>
                    </apply>
                    <apply>
                        <plus/>
                        <cn cellml:units="dimensionless">1</cn>
                        <apply>
                            <times/>
                            <ci>k_gsat</ci>
                            <ci>q_I_pe</ci>
                        </apply>
                    </apply>
                </apply>
            </apply>
        </math>
    </component>
    <connection>
        <map_components component_1="environment" component_2="state"/>
        <map_variables variable_1="time" variable_2="t"/>
    </connection>
</model>