/* There are a total of 71 entries in the algebraic variable array. There are a total of 26 entries in each of the rate and state variable arrays. There are a total of 107 entries in the constant variable array. */ /* * VOI is time in component environment (second). * STATES[0] is V in component membrane (millivolt). * CONSTANTS[0] is R in component membrane (joule_per_kilomole_kelvin). * CONSTANTS[1] is T in component membrane (kelvin). * CONSTANTS[2] is F in component membrane (coulomb_per_mole). * CONSTANTS[3] is Cm in component membrane (microF). * ALGEBRAIC[37] is i_K1 in component time_independent_potassium_current (nanoA). * ALGEBRAIC[53] is i_to in component transient_outward_current (nanoA). * ALGEBRAIC[39] is i_Kr in component rapid_delayed_rectifier_potassium_current (nanoA). * ALGEBRAIC[40] is i_Ks in component slow_delayed_rectifier_potassium_current (nanoA). * ALGEBRAIC[41] is i_K_ATP in component ATP_dependent_potassium_current (nanoA). * ALGEBRAIC[54] is i_K_ACh in component ACh_dependent_potassium_current (nanoA). * ALGEBRAIC[46] is i_Ca_L_K_cyt in component L_type_Ca_channel (nanoA). * ALGEBRAIC[49] is i_Ca_L_K_ds in component L_type_Ca_channel (nanoA). * ALGEBRAIC[55] is i_NaK in component sodium_potassium_pump (nanoA). * ALGEBRAIC[42] is i_Na in component fast_sodium_current (nanoA). * ALGEBRAIC[44] is i_b_Na in component sodium_background_current (nanoA). * ALGEBRAIC[43] is i_p_Na in component persistent_sodium_current (nanoA). * ALGEBRAIC[47] is i_Ca_L_Na_cyt in component L_type_Ca_channel (nanoA). * ALGEBRAIC[50] is i_Ca_L_Na_ds in component L_type_Ca_channel (nanoA). * ALGEBRAIC[56] is i_NaCa_cyt in component sodium_calcium_exchanger (nanoA). * ALGEBRAIC[57] is i_NaCa_ds in component sodium_calcium_exchanger (nanoA). * ALGEBRAIC[45] is i_Ca_L_Ca_cyt in component L_type_Ca_channel (nanoA). * ALGEBRAIC[48] is i_Ca_L_Ca_ds in component L_type_Ca_channel (nanoA). * ALGEBRAIC[52] is i_b_Ca in component calcium_background_current (nanoA). * ALGEBRAIC[70] is i_stretch in component stretch_current (nanoA). * ALGEBRAIC[9] is i_Stim in component membrane (nanoA). * CONSTANTS[4] is stim_start in component membrane (second). * CONSTANTS[5] is stim_end in component membrane (second). * CONSTANTS[6] is stim_period in component membrane (second). * CONSTANTS[7] is stim_duration in component membrane (second). * CONSTANTS[8] is stim_amplitude in component membrane (nanoA). * ALGEBRAIC[21] is E_Na in component reversal_potentials (millivolt). * ALGEBRAIC[28] is E_K in component reversal_potentials (millivolt). * ALGEBRAIC[31] is E_Ks in component reversal_potentials (millivolt). * ALGEBRAIC[33] is E_Ca in component reversal_potentials (millivolt). * ALGEBRAIC[35] is E_mh in component reversal_potentials (millivolt). * CONSTANTS[9] is P_kna in component reversal_potentials (dimensionless). * CONSTANTS[10] is K_o in component extracellular_potassium_concentration (millimolar). * CONSTANTS[11] is Na_o in component extracellular_sodium_concentration (millimolar). * STATES[1] is K_i in component intracellular_potassium_concentration (millimolar). * STATES[2] is Na_i in component intracellular_sodium_concentration (millimolar). * CONSTANTS[12] is Ca_o in component extracellular_calcium_concentration (millimolar). * STATES[3] is Ca_i in component intracellular_calcium_concentration (millimolar). * CONSTANTS[13] is K_mk1 in component time_independent_potassium_current (millimolar). * CONSTANTS[14] is g_K1 in component time_independent_potassium_current (microS). * CONSTANTS[15] is g_Kr1 in component rapid_delayed_rectifier_potassium_current (microS). * CONSTANTS[16] is g_Kr2 in component rapid_delayed_rectifier_potassium_current (microS). * STATES[4] is xr1 in component rapid_delayed_rectifier_potassium_current_xr1_gate (dimensionless). * STATES[5] is xr2 in component rapid_delayed_rectifier_potassium_current_xr2_gate (dimensionless). * ALGEBRAIC[0] is alpha_xr1 in component rapid_delayed_rectifier_potassium_current_xr1_gate (per_second). * ALGEBRAIC[12] is beta_xr1 in component rapid_delayed_rectifier_potassium_current_xr1_gate (per_second). * ALGEBRAIC[1] is alpha_xr2 in component rapid_delayed_rectifier_potassium_current_xr2_gate (per_second). * ALGEBRAIC[13] is beta_xr2 in component rapid_delayed_rectifier_potassium_current_xr2_gate (per_second). * CONSTANTS[17] is g_Ks in component slow_delayed_rectifier_potassium_current (microS). * STATES[6] is xs in component slow_delayed_rectifier_potassium_current_xs_gate (dimensionless). * ALGEBRAIC[2] is alpha_xs in component slow_delayed_rectifier_potassium_current_xs_gate (per_second). * ALGEBRAIC[14] is beta_xs in component slow_delayed_rectifier_potassium_current_xs_gate (per_second). * CONSTANTS[18] is g_K_ATP in component ATP_dependent_potassium_current (microS). * CONSTANTS[19] is K_ATP in component ATP_dependent_potassium_current (millimolar). * CONSTANTS[20] is ATP in component ATP_dependent_potassium_current (millimolar). * ALGEBRAIC[29] is i_KNa in component sodium_activated_potassium_current (nanoA). * CONSTANTS[21] is g_K_Na in component sodium_activated_potassium_current (microS). * CONSTANTS[22] is K_kna in component sodium_activated_potassium_current (millimolar). * CONSTANTS[23] is g_Na in component fast_sodium_current (microS). * STATES[7] is m in component fast_sodium_current_m_gate (dimensionless). * STATES[8] is h in component fast_sodium_current_h_gate (dimensionless). * ALGEBRAIC[15] is alpha_m in component fast_sodium_current_m_gate (per_second). * ALGEBRAIC[24] is beta_m in component fast_sodium_current_m_gate (per_second). * CONSTANTS[24] is delta_m in component fast_sodium_current_m_gate (millivolt). * ALGEBRAIC[3] is E0_m in component fast_sodium_current_m_gate (millivolt). * ALGEBRAIC[4] is alpha_h in component fast_sodium_current_h_gate (per_second). * ALGEBRAIC[16] is beta_h in component fast_sodium_current_h_gate (per_second). * CONSTANTS[25] is g_pna in component persistent_sodium_current (microS). * CONSTANTS[26] is g_bna in component sodium_background_current (microS). * ALGEBRAIC[51] is i_Ca_L in component L_type_Ca_channel (nanoA). * CONSTANTS[27] is P_Ca_L in component L_type_Ca_channel (nanoA_per_millimolar). * CONSTANTS[28] is P_CaK in component L_type_Ca_channel (dimensionless). * CONSTANTS[29] is P_CaNa in component L_type_Ca_channel (dimensionless). * STATES[9] is Ca_ds in component intracellular_calcium_concentration (millimolar). * STATES[10] is d in component L_type_Ca_channel_d_gate (dimensionless). * STATES[11] is f in component L_type_Ca_channel_f_gate (dimensionless). * STATES[12] is f2 in component L_type_Ca_channel_f2_gate (dimensionless). * STATES[13] is f2ds in component L_type_Ca_channel_f2ds_gate (dimensionless). * CONSTANTS[30] is Km_f2 in component L_type_Ca_channel (millimolar). * CONSTANTS[31] is Km_f2ds in component L_type_Ca_channel (millimolar). * CONSTANTS[32] is R_decay in component L_type_Ca_channel (per_second). * CONSTANTS[33] is FrICa in component L_type_Ca_channel (dimensionless). * ALGEBRAIC[17] is alpha_d in component L_type_Ca_channel_d_gate (per_second). * ALGEBRAIC[25] is beta_d in component L_type_Ca_channel_d_gate (per_second). * ALGEBRAIC[5] is E0_d in component L_type_Ca_channel_d_gate (millivolt). * CONSTANTS[34] is speed_d in component L_type_Ca_channel_d_gate (dimensionless). * ALGEBRAIC[18] is alpha_f in component L_type_Ca_channel_f_gate (per_second). * ALGEBRAIC[26] is beta_f in component L_type_Ca_channel_f_gate (per_second). * CONSTANTS[35] is speed_f in component L_type_Ca_channel_f_gate (dimensionless). * CONSTANTS[36] is delta_f in component L_type_Ca_channel_f_gate (millivolt). * ALGEBRAIC[6] is E0_f in component L_type_Ca_channel_f_gate (millivolt). * CONSTANTS[37] is g_bca in component calcium_background_current (microS). * CONSTANTS[38] is g_to in component transient_outward_current (microS). * CONSTANTS[39] is g_tos in component transient_outward_current (dimensionless). * STATES[14] is s in component transient_outward_current_s_gate (dimensionless). * STATES[15] is r in component transient_outward_current_r_gate (dimensionless). * ALGEBRAIC[7] is alpha_s in component transient_outward_current_s_gate (per_second). * ALGEBRAIC[19] is beta_s in component transient_outward_current_s_gate (per_second). * CONSTANTS[40] is g_KACh in component ACh_dependent_potassium_current (microS). * CONSTANTS[41] is ACh in component ACh_dependent_potassium_current (millimolar). * CONSTANTS[42] is K_D in component ACh_dependent_potassium_current (millimolar). * STATES[16] is x_ACh in component ACh_dependent_potassium_current_xACh_gate (dimensionless). * CONSTANTS[43] is alpha_ACh in component ACh_dependent_potassium_current_xACh_gate (per_second). * CONSTANTS[44] is beta_ACh in component ACh_dependent_potassium_current_xACh_gate (per_second). * CONSTANTS[45] is i_NaK_max in component sodium_potassium_pump (nanoA). * CONSTANTS[46] is K_mK in component sodium_potassium_pump (millimolar). * CONSTANTS[47] is K_mNa in component sodium_potassium_pump (millimolar). * ALGEBRAIC[58] is i_NaCa in component sodium_calcium_exchanger (nanoA). * CONSTANTS[48] is k_NaCa in component sodium_calcium_exchanger (nanoA). * CONSTANTS[49] is n_NaCa in component sodium_calcium_exchanger (dimensionless). * CONSTANTS[50] is d_NaCa in component sodium_calcium_exchanger (dimensionless). * CONSTANTS[51] is gamma in component sodium_calcium_exchanger (dimensionless). * CONSTANTS[52] is FRiNaCa in component sodium_calcium_exchanger (dimensionless). * ALGEBRAIC[60] is i_up in component sarcoplasmic_reticulum_calcium_pump (millimolar_per_second). * CONSTANTS[99] is K_1 in component sarcoplasmic_reticulum_calcium_pump (dimensionless). * ALGEBRAIC[59] is K_2 in component sarcoplasmic_reticulum_calcium_pump (millimolar). * CONSTANTS[53] is K_cyca in component sarcoplasmic_reticulum_calcium_pump (millimolar). * CONSTANTS[54] is K_xcs in component sarcoplasmic_reticulum_calcium_pump (dimensionless). * CONSTANTS[55] is K_srca in component sarcoplasmic_reticulum_calcium_pump (millimolar). * CONSTANTS[56] is alpha_up in component sarcoplasmic_reticulum_calcium_pump (millimolar_per_second). * CONSTANTS[57] is beta_up in component sarcoplasmic_reticulum_calcium_pump (millimolar_per_second). * STATES[17] is Ca_up in component intracellular_calcium_concentration (millimolar). * ALGEBRAIC[61] is i_trans in component calcium_translocation (millimolar_per_second). * STATES[18] is Ca_rel in component intracellular_calcium_concentration (millimolar). * ALGEBRAIC[66] is i_rel in component calcium_release (millimolar_per_second). * ALGEBRAIC[8] is VoltDep in component calcium_release (dimensionless). * ALGEBRAIC[30] is RegBindSite in component calcium_release (dimensionless). * ALGEBRAIC[20] is CaiReg in component calcium_release (dimensionless). * ALGEBRAIC[27] is CadsReg in component calcium_release (dimensionless). * ALGEBRAIC[32] is ActRate in component calcium_release (per_second). * ALGEBRAIC[34] is InactRate in component calcium_release (per_second). * CONSTANTS[58] is K_leak_rate in component calcium_release (per_second). * ALGEBRAIC[63] is SRLeak in component calcium_release (per_second). * CONSTANTS[59] is K_m_rel in component calcium_release (per_second). * CONSTANTS[60] is K_m_Ca_cyt in component calcium_release (millimolar). * CONSTANTS[61] is K_m_Ca_ds in component calcium_release (millimolar). * ALGEBRAIC[38] is PrecFrac in component calcium_release (dimensionless). * STATES[19] is ActFrac in component calcium_release (dimensionless). * STATES[20] is ProdFrac in component calcium_release (dimensionless). * ALGEBRAIC[36] is SpeedRel in component calcium_release (dimensionless). * CONSTANTS[62] is gama_SR_SL in component calcium_release (per_micrometre). * CONSTANTS[63] is gama_SR_IT in component calcium_release (dimensionless). * ALGEBRAIC[62] is isometric_tension in component contraction (dimensionless). * CONSTANTS[64] is sarcomere_length in component contraction (micrometre). * CONSTANTS[105] is V_i in component intracellular_calcium_concentration (micrometre3). * STATES[21] is Ca_Calmod in component intracellular_calcium_concentration (millimolar). * STATES[22] is Ca_Trop in component intracellular_calcium_concentration (millimolar). * CONSTANTS[65] is Calmod in component intracellular_calcium_concentration (millimolar). * CONSTANTS[66] is Trop in component intracellular_calcium_concentration (millimolar). * CONSTANTS[67] is alpha_Calmod in component intracellular_calcium_concentration (per_millimolar_second). * CONSTANTS[68] is beta_Calmod in component intracellular_calcium_concentration (per_second). * CONSTANTS[100] is alpha_Trop in component intracellular_calcium_concentration (per_millimolar_second). * CONSTANTS[69] is beta_Trop in component intracellular_calcium_concentration (per_second). * CONSTANTS[70] is gama_Trop_SL in component intracellular_calcium_concentration (per_micrometre). * CONSTANTS[71] is KTrop in component intracellular_calcium_concentration (per_millimolar_second). * CONSTANTS[72] is radius in component intracellular_calcium_concentration (micrometre). * CONSTANTS[73] is length in component intracellular_calcium_concentration (micrometre). * CONSTANTS[98] is V_Cell in component intracellular_calcium_concentration (micrometre3). * CONSTANTS[103] is V_i_ratio in component intracellular_calcium_concentration (dimensionless). * CONSTANTS[74] is V_ds_ratio in component intracellular_calcium_concentration (dimensionless). * CONSTANTS[75] is V_rel_ratio in component intracellular_calcium_concentration (dimensionless). * CONSTANTS[76] is V_e_ratio in component intracellular_calcium_concentration (dimensionless). * CONSTANTS[77] is V_up_ratio in component intracellular_calcium_concentration (dimensionless). * CONSTANTS[78] is Kdecay in component intracellular_calcium_concentration (per_second). * STATES[23] is light_chain in component contraction (dimensionless). * STATES[24] is cross_bridge in component contraction (dimensionless). * CONSTANTS[79] is KCont1 in component contraction (per_second). * ALGEBRAIC[10] is XCont2 in component contraction (dimensionless). * ALGEBRAIC[22] is XCont1 in component contraction (dimensionless). * CONSTANTS[80] is KCont2 in component contraction (per_second). * CONSTANTS[81] is KCont3 in component contraction (per_second). * CONSTANTS[82] is KCont4 in component contraction (per_second). * CONSTANTS[83] is cross_bridge_density in component contraction (per_micrometre). * CONSTANTS[101] is tension_rest in component contraction (dimensionless). * CONSTANTS[102] is tension_active in component contraction (dimensionless). * CONSTANTS[104] is overlap in component contraction (micrometre). * CONSTANTS[106] is cross_bridge_availability in component contraction (dimensionless). * ALGEBRAIC[65] is i_Ca_stretch in component stretch_current (nanoA). * ALGEBRAIC[68] is i_K_stretch in component stretch_current (nanoA). * ALGEBRAIC[67] is i_Na_stretch in component stretch_current (nanoA). * ALGEBRAIC[69] is i_An_stretch in component stretch_current (nanoA). * CONSTANTS[84] is gama_SAC_SL in component stretch_current (per_micrometre). * CONSTANTS[85] is gama_SAC_IT in component stretch_current (dimensionless). * CONSTANTS[86] is SLHST in component stretch_current (micrometre). * CONSTANTS[87] is ITHST in component stretch_current (dimensionless). * CONSTANTS[88] is g_Ca_stretch in component stretch_current (microS). * CONSTANTS[89] is g_K_stretch in component stretch_current (microS). * CONSTANTS[90] is g_Na_stretch in component stretch_current (microS). * CONSTANTS[91] is g_An_stretch in component stretch_current (microS). * CONSTANTS[92] is E_An_stretch in component stretch_current (millivolt). * ALGEBRAIC[64] is f_stretch in component stretch_current (dimensionless). * CONSTANTS[93] is g_fibro_junct in component fibroblast (microS). * CONSTANTS[94] is g_fibro in component fibroblast (microS). * CONSTANTS[95] is c_fibro in component fibroblast (microF). * CONSTANTS[96] is g_fibro_stretch in component fibroblast (microS). * CONSTANTS[97] is E_fibro_stretch in component fibroblast (millivolt). * STATES[25] is V_fibro in component fibroblast (millivolt). * ALGEBRAIC[11] is i_fibro in component fibroblast (nanoA). * ALGEBRAIC[23] is i_fibro_junct in component fibroblast (nanoA). * RATES[0] is d/dt V in component membrane (millivolt). * RATES[4] is d/dt xr1 in component rapid_delayed_rectifier_potassium_current_xr1_gate (dimensionless). * RATES[5] is d/dt xr2 in component rapid_delayed_rectifier_potassium_current_xr2_gate (dimensionless). * RATES[6] is d/dt xs in component slow_delayed_rectifier_potassium_current_xs_gate (dimensionless). * RATES[7] is d/dt m in component fast_sodium_current_m_gate (dimensionless). * RATES[8] is d/dt h in component fast_sodium_current_h_gate (dimensionless). * RATES[10] is d/dt d in component L_type_Ca_channel_d_gate (dimensionless). * RATES[11] is d/dt f in component L_type_Ca_channel_f_gate (dimensionless). * RATES[12] is d/dt f2 in component L_type_Ca_channel_f2_gate (dimensionless). * RATES[13] is d/dt f2ds in component L_type_Ca_channel_f2ds_gate (dimensionless). * RATES[14] is d/dt s in component transient_outward_current_s_gate (dimensionless). * RATES[15] is d/dt r in component transient_outward_current_r_gate (dimensionless). * RATES[16] is d/dt x_ACh in component ACh_dependent_potassium_current_xACh_gate (dimensionless). * RATES[19] is d/dt ActFrac in component calcium_release (dimensionless). * RATES[20] is d/dt ProdFrac in component calcium_release (dimensionless). * RATES[2] is d/dt Na_i in component intracellular_sodium_concentration (millimolar). * RATES[1] is d/dt K_i in component intracellular_potassium_concentration (millimolar). * RATES[3] is d/dt Ca_i in component intracellular_calcium_concentration (millimolar). * RATES[21] is d/dt Ca_Calmod in component intracellular_calcium_concentration (millimolar). * RATES[22] is d/dt Ca_Trop in component intracellular_calcium_concentration (millimolar). * RATES[9] is d/dt Ca_ds in component intracellular_calcium_concentration (millimolar). * RATES[17] is d/dt Ca_up in component intracellular_calcium_concentration (millimolar). * RATES[18] is d/dt Ca_rel in component intracellular_calcium_concentration (millimolar). * RATES[23] is d/dt light_chain in component contraction (dimensionless). * RATES[24] is d/dt cross_bridge in component contraction (dimensionless). * RATES[25] is d/dt V_fibro in component fibroblast (millivolt). */ void initConsts(double* CONSTANTS, double* RATES, double *STATES) { STATES[0] = -92.849333; CONSTANTS[0] = 8314.472; CONSTANTS[1] = 310; CONSTANTS[2] = 96485.3415; CONSTANTS[3] = 9.5e-5; CONSTANTS[4] = 0.1; CONSTANTS[5] = 10000; CONSTANTS[6] = 1; CONSTANTS[7] = 0.003; CONSTANTS[8] = -3; CONSTANTS[9] = 0.03; CONSTANTS[10] = 4; CONSTANTS[11] = 140; STATES[1] = 136.5644281; STATES[2] = 7.3321223; CONSTANTS[12] = 2; STATES[3] = 1.4e-5; CONSTANTS[13] = 10; CONSTANTS[14] = 0.5; CONSTANTS[15] = 0.0021; CONSTANTS[16] = 0.0013; STATES[4] = 1.03e-5; STATES[5] = 2e-7; CONSTANTS[17] = 0.0026; STATES[6] = 0.001302; CONSTANTS[18] = 0; CONSTANTS[19] = 0.1; CONSTANTS[20] = 0; CONSTANTS[21] = 0; CONSTANTS[22] = 20; CONSTANTS[23] = 2.5; STATES[7] = 0.0016203; STATES[8] = 0.9944036; CONSTANTS[24] = 1e-5; CONSTANTS[25] = 0.004; CONSTANTS[26] = 0.0006; CONSTANTS[27] = 0.1; CONSTANTS[28] = 0.002; CONSTANTS[29] = 0.01; STATES[9] = 1.88e-5; STATES[10] = 0; STATES[11] = 1; STATES[12] = 0.9349197; STATES[13] = 0.9651958; CONSTANTS[30] = 100000; CONSTANTS[31] = 0.001; CONSTANTS[32] = 20; CONSTANTS[33] = 1; CONSTANTS[34] = 3; CONSTANTS[35] = 0.3; CONSTANTS[36] = 0.0001; CONSTANTS[37] = 0.00025; CONSTANTS[38] = 0.005; CONSTANTS[39] = 0; STATES[14] = 0.9948645; STATES[15] = 0; CONSTANTS[40] = 0; CONSTANTS[41] = 5; CONSTANTS[42] = 0.00013; STATES[16] = 0; CONSTANTS[43] = 0.5; CONSTANTS[44] = 0.5; CONSTANTS[45] = 0.7; CONSTANTS[46] = 1; CONSTANTS[47] = 40; CONSTANTS[48] = 0.0005; CONSTANTS[49] = 3; CONSTANTS[50] = 0; CONSTANTS[51] = 0.5; CONSTANTS[52] = 0.001; CONSTANTS[53] = 0.0003; CONSTANTS[54] = 0.4; CONSTANTS[55] = 0.5; CONSTANTS[56] = 0.4; CONSTANTS[57] = 0.03; STATES[17] = 0.4531889; STATES[18] = 0.4481927; CONSTANTS[58] = 0.005; CONSTANTS[59] = 250; CONSTANTS[60] = 0.0005; CONSTANTS[61] = 0.01; STATES[19] = 0.001914; STATES[20] = 0.2854569; CONSTANTS[62] = 2.5; CONSTANTS[63] = 2.5; CONSTANTS[64] = 2; STATES[21] = 0.0005555; STATES[22] = 0.0002; CONSTANTS[65] = 0.02; CONSTANTS[66] = 0.05; CONSTANTS[67] = 100000; CONSTANTS[68] = 50; CONSTANTS[69] = 200; CONSTANTS[70] = 1.5; CONSTANTS[71] = 5000; CONSTANTS[72] = 12; CONSTANTS[73] = 74; CONSTANTS[74] = 0.1; CONSTANTS[75] = 0.1; CONSTANTS[76] = 0.4; CONSTANTS[77] = 0.01; CONSTANTS[78] = 10; STATES[23] = 3.32e-5; STATES[24] = 8.09e-5; CONSTANTS[79] = 12000; CONSTANTS[80] = 100; CONSTANTS[81] = 60; CONSTANTS[82] = 25; CONSTANTS[83] = 0.05; CONSTANTS[84] = 2.5; CONSTANTS[85] = 2.5; CONSTANTS[86] = 2; CONSTANTS[87] = 1; CONSTANTS[88] = 0.01; CONSTANTS[89] = 0.01; CONSTANTS[90] = 0.01; CONSTANTS[91] = 0.01; CONSTANTS[92] = -20; CONSTANTS[93] = 2.9e-4; CONSTANTS[94] = 2e-4; CONSTANTS[95] = 1e-5; CONSTANTS[96] = 0; CONSTANTS[97] = 0; STATES[25] = -20; CONSTANTS[98] = ( 3.14159*pow(CONSTANTS[72]/1000.00, 2.00000)*CONSTANTS[73])/1000.00; CONSTANTS[99] = ( CONSTANTS[53]*CONSTANTS[54])/CONSTANTS[55]; CONSTANTS[100] = CONSTANTS[71]*exp( CONSTANTS[70]*CONSTANTS[64]); CONSTANTS[101] = 0.000200000*exp( 2.00000*CONSTANTS[64]); CONSTANTS[102] = (CONSTANTS[64]>1.00000 ? 1.00000 - exp( - 3.00000*(CONSTANTS[64] - 1.00000)) : 0.00000); CONSTANTS[103] = ((1.00000 - CONSTANTS[76]) - CONSTANTS[77]) - CONSTANTS[75]; CONSTANTS[104] = (CONSTANTS[64]>2.00000 ? 1.00000 - 0.625000*(CONSTANTS[64] - 2.00000) : 1.00000); CONSTANTS[105] = CONSTANTS[98]*CONSTANTS[103]; CONSTANTS[106] = CONSTANTS[102]*CONSTANTS[104]*CONSTANTS[83]; } void computeRates(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC) { RATES[12] = 1.00000 - 1.00000*(STATES[3]/(CONSTANTS[30]+STATES[3])+STATES[12]); RATES[13] = CONSTANTS[32]*(1.00000 - (STATES[9]/(CONSTANTS[31]+STATES[9])+STATES[13])); RATES[15] = 333.000*(1.00000/(1.00000+exp(- (STATES[0]+4.00000)/5.00000)) - STATES[15]); RATES[16] = CONSTANTS[43]*(1.00000 - STATES[16]) - CONSTANTS[44]*STATES[16]; RATES[24] = CONSTANTS[81]*STATES[23]*(1.00000 - STATES[24]) - CONSTANTS[82]*STATES[24]; ALGEBRAIC[0] = 50.0000/(1.00000+exp(- (STATES[0] - 5.00000)/9.00000)); ALGEBRAIC[12] = 0.0500000*exp(- (STATES[0] - 20.0000)/15.0000); RATES[4] = ALGEBRAIC[0]*(1.00000 - STATES[4]) - ALGEBRAIC[12]*STATES[4]; ALGEBRAIC[1] = 50.0000/(1.00000+exp(- (STATES[0] - 5.00000)/9.00000)); ALGEBRAIC[13] = 0.400000*exp(- pow((STATES[0]+30.0000)/30.0000, 3.00000)); RATES[5] = ALGEBRAIC[1]*(1.00000 - STATES[5]) - ALGEBRAIC[13]*STATES[5]; ALGEBRAIC[2] = 14.0000/(1.00000+exp(- (STATES[0] - 40.0000)/9.00000)); ALGEBRAIC[14] = 1.00000*exp(- STATES[0]/45.0000); RATES[6] = ALGEBRAIC[2]*(1.00000 - STATES[6]) - ALGEBRAIC[14]*STATES[6]; ALGEBRAIC[4] = 20.0000*exp( - 0.125000*(STATES[0]+75.0000)); ALGEBRAIC[16] = 2000.00/(1.00000+ 320.000*exp( - 0.100000*(STATES[0]+75.0000))); RATES[8] = ALGEBRAIC[4]*(1.00000 - STATES[8]) - ALGEBRAIC[16]*STATES[8]; ALGEBRAIC[7] = 0.0330000*exp(- STATES[0]/17.0000); ALGEBRAIC[19] = 33.0000/(1.00000+exp( - 0.125000*(STATES[0]+10.0000))); RATES[14] = ALGEBRAIC[7]*(1.00000 - STATES[14]) - ALGEBRAIC[19]*STATES[14]; ALGEBRAIC[10] = STATES[21]/CONSTANTS[65]; ALGEBRAIC[22] = STATES[22]/CONSTANTS[66]; RATES[23] = CONSTANTS[79]*pow(ALGEBRAIC[22], 2.00000)*ALGEBRAIC[10]*(1.00000 - STATES[23]) - CONSTANTS[80]*STATES[23]; ALGEBRAIC[11] = CONSTANTS[94]*(STATES[25]+20.0000)+ CONSTANTS[96]*(STATES[25] - CONSTANTS[97]); ALGEBRAIC[23] = - CONSTANTS[93]*(STATES[0] - STATES[25]); RATES[25] = - (ALGEBRAIC[11]+ALGEBRAIC[23])/CONSTANTS[95]; ALGEBRAIC[3] = STATES[0]+41.0000; ALGEBRAIC[15] = (fabs(ALGEBRAIC[3])0.00000 ? CONSTANTS[58]*exp( CONSTANTS[63]*ALGEBRAIC[62]) : CONSTANTS[58]*exp( CONSTANTS[62]*CONSTANTS[64])); ALGEBRAIC[66] = ( pow(STATES[19]/(STATES[19]+0.250000), 2.00000)*CONSTANTS[59]+ALGEBRAIC[63])*STATES[18]; RATES[3] = ((( (- 1.00000/( 2.00000*1.00000*CONSTANTS[105]*CONSTANTS[2]))*(((ALGEBRAIC[45]+ALGEBRAIC[52]) - 2.00000*ALGEBRAIC[56]) - 2.00000*ALGEBRAIC[57])+ STATES[9]*CONSTANTS[74]*CONSTANTS[78]+( ALGEBRAIC[66]*CONSTANTS[75])/CONSTANTS[103]) - RATES[21]) - RATES[22]) - ALGEBRAIC[60]; RATES[18] = (CONSTANTS[77]/CONSTANTS[75])*ALGEBRAIC[61] - ALGEBRAIC[66]; ALGEBRAIC[41] = ( CONSTANTS[18]*(STATES[0]+80.0000))/(1.00000+pow(CONSTANTS[20]/CONSTANTS[19], 2.00000)); ALGEBRAIC[54] = ( CONSTANTS[40]*(CONSTANTS[10]/(CONSTANTS[10]+CONSTANTS[13]))*STATES[16]*(1.00000/(1.00000+pow(CONSTANTS[42]/CONSTANTS[41], 2.00000)))*(STATES[0] - ALGEBRAIC[28]))/(1.00000+exp(( 2.00000*CONSTANTS[2]*(STATES[0] - (ALGEBRAIC[28]+10.0000)))/( CONSTANTS[0]*CONSTANTS[1]))); ALGEBRAIC[64] = (ALGEBRAIC[62]>0.00000 ? 1.00000/(1.00000+exp( - 2.00000*CONSTANTS[85]*(ALGEBRAIC[62] - CONSTANTS[87]))) : 1.00000/(1.00000+exp( - 2.00000*CONSTANTS[84]*(CONSTANTS[64] - CONSTANTS[86])))); ALGEBRAIC[65] = CONSTANTS[88]*ALGEBRAIC[64]*(STATES[0] - ALGEBRAIC[33]); ALGEBRAIC[68] = CONSTANTS[89]*ALGEBRAIC[64]*(STATES[0] - ALGEBRAIC[28]); ALGEBRAIC[67] = CONSTANTS[90]*ALGEBRAIC[64]*(STATES[0] - ALGEBRAIC[21]); ALGEBRAIC[69] = CONSTANTS[91]*ALGEBRAIC[64]*(STATES[0] - CONSTANTS[92]); ALGEBRAIC[70] = ALGEBRAIC[65]+ALGEBRAIC[67]+ALGEBRAIC[68]+ALGEBRAIC[69]; ALGEBRAIC[9] = (VOI>=CONSTANTS[4]&&VOI<=CONSTANTS[5]&&(VOI - CONSTANTS[4]) - floor((VOI - CONSTANTS[4])/CONSTANTS[6])*CONSTANTS[6]<=CONSTANTS[7] ? CONSTANTS[8] : 0.00000); RATES[0] = (- 1.00000/CONSTANTS[3])*(ALGEBRAIC[9]+ALGEBRAIC[37]+ALGEBRAIC[53]+ALGEBRAIC[39]+ALGEBRAIC[40]+ALGEBRAIC[41]+ALGEBRAIC[54]+ALGEBRAIC[55]+ALGEBRAIC[42]+ALGEBRAIC[44]+ALGEBRAIC[43]+ALGEBRAIC[47]+ALGEBRAIC[50]+ALGEBRAIC[56]+ALGEBRAIC[57]+ALGEBRAIC[45]+ALGEBRAIC[48]+ALGEBRAIC[46]+ALGEBRAIC[49]+ALGEBRAIC[52]+ALGEBRAIC[70]); } void computeVariables(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC) { ALGEBRAIC[0] = 50.0000/(1.00000+exp(- (STATES[0] - 5.00000)/9.00000)); ALGEBRAIC[12] = 0.0500000*exp(- (STATES[0] - 20.0000)/15.0000); ALGEBRAIC[1] = 50.0000/(1.00000+exp(- (STATES[0] - 5.00000)/9.00000)); ALGEBRAIC[13] = 0.400000*exp(- pow((STATES[0]+30.0000)/30.0000, 3.00000)); ALGEBRAIC[2] = 14.0000/(1.00000+exp(- (STATES[0] - 40.0000)/9.00000)); ALGEBRAIC[14] = 1.00000*exp(- STATES[0]/45.0000); ALGEBRAIC[4] = 20.0000*exp( - 0.125000*(STATES[0]+75.0000)); ALGEBRAIC[16] = 2000.00/(1.00000+ 320.000*exp( - 0.100000*(STATES[0]+75.0000))); ALGEBRAIC[7] = 0.0330000*exp(- STATES[0]/17.0000); ALGEBRAIC[19] = 33.0000/(1.00000+exp( - 0.125000*(STATES[0]+10.0000))); ALGEBRAIC[10] = STATES[21]/CONSTANTS[65]; ALGEBRAIC[22] = STATES[22]/CONSTANTS[66]; ALGEBRAIC[11] = CONSTANTS[94]*(STATES[25]+20.0000)+ CONSTANTS[96]*(STATES[25] - CONSTANTS[97]); ALGEBRAIC[23] = - CONSTANTS[93]*(STATES[0] - STATES[25]); ALGEBRAIC[3] = STATES[0]+41.0000; ALGEBRAIC[15] = (fabs(ALGEBRAIC[3])0.00000 ? CONSTANTS[58]*exp( CONSTANTS[63]*ALGEBRAIC[62]) : CONSTANTS[58]*exp( CONSTANTS[62]*CONSTANTS[64])); ALGEBRAIC[66] = ( pow(STATES[19]/(STATES[19]+0.250000), 2.00000)*CONSTANTS[59]+ALGEBRAIC[63])*STATES[18]; ALGEBRAIC[41] = ( CONSTANTS[18]*(STATES[0]+80.0000))/(1.00000+pow(CONSTANTS[20]/CONSTANTS[19], 2.00000)); ALGEBRAIC[54] = ( CONSTANTS[40]*(CONSTANTS[10]/(CONSTANTS[10]+CONSTANTS[13]))*STATES[16]*(1.00000/(1.00000+pow(CONSTANTS[42]/CONSTANTS[41], 2.00000)))*(STATES[0] - ALGEBRAIC[28]))/(1.00000+exp(( 2.00000*CONSTANTS[2]*(STATES[0] - (ALGEBRAIC[28]+10.0000)))/( CONSTANTS[0]*CONSTANTS[1]))); ALGEBRAIC[64] = (ALGEBRAIC[62]>0.00000 ? 1.00000/(1.00000+exp( - 2.00000*CONSTANTS[85]*(ALGEBRAIC[62] - CONSTANTS[87]))) : 1.00000/(1.00000+exp( - 2.00000*CONSTANTS[84]*(CONSTANTS[64] - CONSTANTS[86])))); ALGEBRAIC[65] = CONSTANTS[88]*ALGEBRAIC[64]*(STATES[0] - ALGEBRAIC[33]); ALGEBRAIC[68] = CONSTANTS[89]*ALGEBRAIC[64]*(STATES[0] - ALGEBRAIC[28]); ALGEBRAIC[67] = CONSTANTS[90]*ALGEBRAIC[64]*(STATES[0] - ALGEBRAIC[21]); ALGEBRAIC[69] = CONSTANTS[91]*ALGEBRAIC[64]*(STATES[0] - CONSTANTS[92]); ALGEBRAIC[70] = ALGEBRAIC[65]+ALGEBRAIC[67]+ALGEBRAIC[68]+ALGEBRAIC[69]; ALGEBRAIC[9] = (VOI>=CONSTANTS[4]&&VOI<=CONSTANTS[5]&&(VOI - CONSTANTS[4]) - floor((VOI - CONSTANTS[4])/CONSTANTS[6])*CONSTANTS[6]<=CONSTANTS[7] ? CONSTANTS[8] : 0.00000); ALGEBRAIC[29] = (( CONSTANTS[21]*STATES[2])/(STATES[2]+CONSTANTS[22]))*(STATES[0] - ALGEBRAIC[28]); ALGEBRAIC[51] = ALGEBRAIC[45]+ALGEBRAIC[46]+ALGEBRAIC[47]+ALGEBRAIC[48]+ALGEBRAIC[49]+ALGEBRAIC[50]; ALGEBRAIC[58] = ALGEBRAIC[56]+ALGEBRAIC[57]; }