Generated Code
The following is c_ida code generated by the CellML API from this CellML file. (Back to language selection)
The raw code is available.
/* There are a total of 143 entries in the algebraic variable array. There are a total of 44 entries in each of the rate and state variable arrays. There are a total of 99 entries in the constant variable array. */ /* * VOI is time in component environment (millisecond). * STATES[0] is Vm in component membrane (millivolt). * CONSTANTS[0] is R in component membrane (coulomb_millivolt_per_kelvin_millimole). * CONSTANTS[1] is T in component membrane (kelvin). * CONSTANTS[2] is F in component membrane (coulomb_per_millimole). * CONSTANTS[3] is Cm in component membrane (picoF). * ALGEBRAIC[142] is i_tot in component membrane (picoA). * ALGEBRAIC[139] is i_I in component membrane (picoA). * ALGEBRAIC[109] is i_Na in component sodium_current (picoA). * ALGEBRAIC[135] is i_Ca_L in component L_type_Ca_channel (picoA). * ALGEBRAIC[36] is i_Ca_T in component T_type_Ca_channel (picoA). * ALGEBRAIC[136] is i_K1 in component time_independent_potassium_current (picoA). * ALGEBRAIC[60] is i_Kr in component rapid_time_dependent_potassium_current (picoA). * ALGEBRAIC[113] is i_st in component st_channel (picoA). * ALGEBRAIC[114] is i_ha in component ha_channel (picoA). * ALGEBRAIC[67] is i_KACh in component ACh_dependent_potassium_current (picoA). * ALGEBRAIC[138] is i_NaK in component sodium_potassium_pump (picoA). * ALGEBRAIC[125] is i_NaCa in component sodium_calcium_exchanger (picoA). * ALGEBRAIC[121] is i_bNSC in component background_NSC_current (picoA). * ALGEBRAIC[74] is i_Cab in component background_Cab_current (picoA). * ALGEBRAIC[71] is i_Kpl in component background_Kpl_current (picoA). * ALGEBRAIC[137] is i_lCa in component background_lCa_current (picoA). * ALGEBRAIC[124] is i_KATP in component background_KATP_current (picoA). * CONSTANTS[4] is Nao in component external_ion_concentrations (millimolar). * CONSTANTS[5] is Cao in component external_ion_concentrations (millimolar). * CONSTANTS[6] is Ko in component external_ion_concentrations (millimolar). * STATES[1] is Nai in component internal_ion_concentrations (millimolar). * ALGEBRAIC[2] is Cai in component internal_ion_concentrations (millimolar). * STATES[2] is Ki in component internal_ion_concentrations (millimolar). * CONSTANTS[7] is Vi in component internal_ion_concentrations (micrometre3). * ALGEBRAIC[140] is i_net_Na in component internal_ion_concentrations (picoA). * ALGEBRAIC[141] is i_net_K in component internal_ion_concentrations (picoA). * ALGEBRAIC[134] is i_net_Ca in component internal_ion_concentrations (picoA). * ALGEBRAIC[6] is i_Na_Na in component sodium_current (picoA). * ALGEBRAIC[111] is i_CaL_Na in component L_type_Ca_channel (picoA). * ALGEBRAIC[41] is i_st_Na in component st_channel (picoA). * ALGEBRAIC[49] is i_ha_Na in component ha_channel (picoA). * ALGEBRAIC[70] is i_bNSC_Na in component background_NSC_current (picoA). * ALGEBRAIC[123] is i_lCa_Na in component background_lCa_current (picoA). * ALGEBRAIC[7] is i_Na_K in component sodium_current (picoA). * ALGEBRAIC[112] is i_CaL_K in component L_type_Ca_channel (picoA). * ALGEBRAIC[42] is i_st_K in component st_channel (picoA). * ALGEBRAIC[50] is i_ha_K in component ha_channel (picoA). * ALGEBRAIC[69] is i_bNSC_K in component background_NSC_current (picoA). * ALGEBRAIC[122] is i_lCa_K in component background_lCa_current (picoA). * ALGEBRAIC[110] is i_CaL_Ca in component L_type_Ca_channel (picoA). * ALGEBRAIC[130] is i_RyR in component RyR_channel (picoA). * ALGEBRAIC[129] is i_SR_U in component SR_calcium_pump (picoA). * ALGEBRAIC[94] is i_SR_L in component SR_L_current (picoA). * STATES[41] is dCaidt in component NL_model (millimolar_per_millisecond). * CONSTANTS[8] is CMDN_max in component internal_ion_concentrations (millimolar). * CONSTANTS[9] is K_mCMDN in component internal_ion_concentrations (millimolar). * STATES[3] is Ca_Total in component internal_ion_concentrations (millimolar). * ALGEBRAIC[0] is b1 in component internal_ion_concentrations (millimolar). * ALGEBRAIC[1] is c1 in component internal_ion_concentrations (millimolar2). * ALGEBRAIC[3] is CF_Na in component constant_field_equations (millimolar). * ALGEBRAIC[4] is CF_Ca in component constant_field_equations (millimolar). * ALGEBRAIC[5] is CF_K in component constant_field_equations (millimolar). * STATES[4] is ATPi in component ATP_production (millimolar). * ALGEBRAIC[104] is dATPdt in component NL_model (millimolar_per_millisecond). * CONSTANTS[10] is ProducingRate_Max in component ATP_production (per_millisecond). * CONSTANTS[11] is Adenosine_Total in component ATP_production (millimolar). * CONSTANTS[12] is P_Na in component sodium_current (picoA_per_millimolar). * STATES[5] is p_AP_Na in component sodium_current_voltage_dependent_gate (dimensionless). * STATES[6] is y in component sodium_current_ultra_slow_gate (dimensionless). * ALGEBRAIC[8] is p_RI_Na in component sodium_current_voltage_dependent_gate (dimensionless). * STATES[7] is p_RP_Na in component sodium_current_voltage_dependent_gate (dimensionless). * STATES[8] is p_AI_Na in component sodium_current_voltage_dependent_gate (dimensionless). * ALGEBRAIC[9] is k_RP_AP in component sodium_current_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[10] is k_AP_RP in component sodium_current_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[13] is k_RI_AI in component sodium_current_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[12] is k_AI_RI in component sodium_current_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[11] is k_AP_AI in component sodium_current_voltage_dependent_gate (per_millisecond). * CONSTANTS[13] is k_AI_AP in component sodium_current_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[14] is k_RP_RI in component sodium_current_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[15] is k_RI_RP in component sodium_current_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[16] is alpha_y in component sodium_current_ultra_slow_gate (per_millisecond). * ALGEBRAIC[17] is beta_y in component sodium_current_ultra_slow_gate (per_millisecond). * ALGEBRAIC[18] is p_open_CaL in component L_type_Ca_channel (dimensionless). * ALGEBRAIC[27] is CaDiadic in component L_type_Ca_channel_Ca_dependent_gate (picoA). * CONSTANTS[14] is P_CaL in component L_type_Ca_channel (picoA_per_millimolar). * STATES[9] is p_AP_CaL in component L_type_Ca_channel_voltage_dependent_gate (dimensionless). * STATES[10] is p_U in component L_type_Ca_channel_Ca_dependent_gate (dimensionless). * STATES[11] is p_UCa in component L_type_Ca_channel_Ca_dependent_gate (dimensionless). * STATES[12] is y in component L_type_Ca_channel_ultra_slow_gate (dimensionless). * ALGEBRAIC[19] is p_RI_CaL in component L_type_Ca_channel_voltage_dependent_gate (dimensionless). * STATES[13] is p_RP_CaL in component L_type_Ca_channel_voltage_dependent_gate (dimensionless). * STATES[14] is p_AI_CaL in component L_type_Ca_channel_voltage_dependent_gate (dimensionless). * ALGEBRAIC[20] is k_RP_AP in component L_type_Ca_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[21] is k_AP_RP in component L_type_Ca_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[22] is k_RI_AI in component L_type_Ca_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[23] is k_AI_RI in component L_type_Ca_channel_voltage_dependent_gate (per_millisecond). * CONSTANTS[15] is k_AP_AI in component L_type_Ca_channel_voltage_dependent_gate (per_millisecond). * CONSTANTS[16] is k_AI_AP in component L_type_Ca_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[24] is k_RP_RI in component L_type_Ca_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[25] is k_RI_RP in component L_type_Ca_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[26] is iCaL in component L_type_Ca_channel_Ca_dependent_gate (picoA). * ALGEBRAIC[28] is Cacm in component L_type_Ca_channel_Ca_dependent_gate (millimolar). * ALGEBRAIC[33] is p_CCa in component L_type_Ca_channel_Ca_dependent_gate (dimensionless). * STATES[15] is p_C in component L_type_Ca_channel_Ca_dependent_gate (dimensionless). * CONSTANTS[17] is k_CCa_UCa in component L_type_Ca_channel_Ca_dependent_gate (per_millisecond). * CONSTANTS[18] is k_UCa_CCa in component L_type_Ca_channel_Ca_dependent_gate (per_millisecond). * CONSTANTS[19] is k_C_U in component L_type_Ca_channel_Ca_dependent_gate (per_millisecond). * CONSTANTS[20] is k_U_C in component L_type_Ca_channel_Ca_dependent_gate (per_millisecond). * CONSTANTS[89] is k_UCa_U in component L_type_Ca_channel_Ca_dependent_gate (per_millisecond). * CONSTANTS[21] is k_U_UCa in component L_type_Ca_channel_Ca_dependent_gate (per_millimolar_millisecond). * CONSTANTS[22] is k_CCa_C in component L_type_Ca_channel_Ca_dependent_gate (per_millisecond). * CONSTANTS[23] is k_C_CCa in component L_type_Ca_channel_Ca_dependent_gate (per_millimolar_millisecond). * ALGEBRAIC[29] is CaEffC in component L_type_Ca_channel_Ca_dependent_gate (millimolar). * ALGEBRAIC[30] is CaEffU in component L_type_Ca_channel_Ca_dependent_gate (millimolar). * ALGEBRAIC[31] is k_UUCa_Ca in component L_type_Ca_channel_Ca_dependent_gate (per_millisecond). * ALGEBRAIC[32] is k_CCCa_Ca in component L_type_Ca_channel_Ca_dependent_gate (per_millisecond). * ALGEBRAIC[34] is alpha_y in component L_type_Ca_channel_ultra_slow_gate (per_millisecond). * ALGEBRAIC[35] is beta_y in component L_type_Ca_channel_ultra_slow_gate (per_millisecond). * CONSTANTS[24] is P_CaT in component T_type_Ca_channel (picoA_per_millimolar). * STATES[16] is y1 in component T_type_Ca_channel_y1_gate (dimensionless). * STATES[17] is y2 in component T_type_Ca_channel_y2_gate (dimensionless). * ALGEBRAIC[37] is alpha_y1 in component T_type_Ca_channel_y1_gate (per_millisecond). * ALGEBRAIC[38] is beta_y1 in component T_type_Ca_channel_y1_gate (per_millisecond). * ALGEBRAIC[39] is alpha_y2 in component T_type_Ca_channel_y2_gate (per_millisecond). * ALGEBRAIC[40] is beta_y2 in component T_type_Ca_channel_y2_gate (per_millisecond). * STATES[18] is y1 in component st_channel_y1_gate (dimensionless). * STATES[19] is y2 in component st_channel_y2_gate (dimensionless). * STATES[20] is y3 in component st_channel_y3_gate (dimensionless). * CONSTANTS[25] is P_st_Na in component st_channel (picoA_per_millimolar). * CONSTANTS[26] is P_st_K in component st_channel (picoA_per_millimolar). * ALGEBRAIC[43] is alpha_y1 in component st_channel_y1_gate (per_millisecond). * ALGEBRAIC[44] is beta_y1 in component st_channel_y1_gate (per_millisecond). * ALGEBRAIC[45] is alpha_y2 in component st_channel_y2_gate (per_millisecond). * ALGEBRAIC[46] is beta_y2 in component st_channel_y2_gate (per_millisecond). * ALGEBRAIC[47] is alpha_y3 in component st_channel_y3_gate (per_millisecond). * ALGEBRAIC[48] is beta_y3 in component st_channel_y3_gate (per_millisecond). * STATES[21] is C1 in component ha_channel_voltage_dependent_gate (dimensionless). * STATES[22] is C2 in component ha_channel_voltage_dependent_gate (dimensionless). * CONSTANTS[27] is P_ha_Na in component ha_channel (picoA_per_millimolar). * CONSTANTS[28] is P_ha_K in component ha_channel (picoA_per_millimolar). * STATES[23] is O1 in component ha_channel_voltage_dependent_gate (dimensionless). * STATES[24] is O2 in component ha_channel_voltage_dependent_gate (dimensionless). * ALGEBRAIC[51] is O3 in component ha_channel_voltage_dependent_gate (dimensionless). * ALGEBRAIC[52] is alpha in component ha_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[53] is beta in component ha_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[54] is mu in component ha_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[55] is lambda in component ha_channel_voltage_dependent_gate (per_millisecond). * ALGEBRAIC[56] is E_K in component time_independent_potassium_current (millivolt). * CONSTANTS[90] is g_K1 in component time_independent_potassium_current (nanoS). * CONSTANTS[29] is P_K1_0 in component time_independent_potassium_current (nanoS_per_picoF). * ALGEBRAIC[116] is fO in component time_independent_potassium_current (dimensionless). * ALGEBRAIC[117] is fO2 in component time_independent_potassium_current (dimensionless). * ALGEBRAIC[118] is fO3 in component time_independent_potassium_current (dimensionless). * ALGEBRAIC[119] is fO4 in component time_independent_potassium_current (dimensionless). * ALGEBRAIC[115] is fB in component time_independent_potassium_current (dimensionless). * ALGEBRAIC[57] is mu in component time_independent_potassium_current (per_millisecond). * ALGEBRAIC[58] is lambda in component time_independent_potassium_current (per_millisecond). * STATES[25] is y in component time_independent_potassium_current_y_gate (dimensionless). * ALGEBRAIC[59] is alpha_y in component time_independent_potassium_current_y_gate (per_millisecond). * ALGEBRAIC[120] is beta_y in component time_independent_potassium_current_y_gate (per_millisecond). * CONSTANTS[91] is g_Kr in component rapid_time_dependent_potassium_current (nanoS). * CONSTANTS[30] is P_Kr in component rapid_time_dependent_potassium_current (nanoS_per_picoF). * STATES[26] is y1 in component rapid_time_dependent_potassium_current_y1_gate (dimensionless). * STATES[27] is y2 in component rapid_time_dependent_potassium_current_y2_gate (dimensionless). * STATES[28] is y3 in component rapid_time_dependent_potassium_current_y3_gate (dimensionless). * ALGEBRAIC[61] is alpha_y1 in component rapid_time_dependent_potassium_current_y1_gate (per_millisecond). * ALGEBRAIC[62] is beta_y1 in component rapid_time_dependent_potassium_current_y1_gate (per_millisecond). * ALGEBRAIC[63] is alpha_y2 in component rapid_time_dependent_potassium_current_y2_gate (per_millisecond). * ALGEBRAIC[64] is beta_y2 in component rapid_time_dependent_potassium_current_y2_gate (per_millisecond). * ALGEBRAIC[65] is alpha_y3 in component rapid_time_dependent_potassium_current_y3_gate (per_millisecond). * ALGEBRAIC[66] is beta_y3 in component rapid_time_dependent_potassium_current_y3_gate (per_millisecond). * STATES[29] is y in component ACh_dependent_potassium_current_y_gate (dimensionless). * CONSTANTS[31] is g_ACh in component ACh_dependent_potassium_current (nanoS). * CONSTANTS[92] is alpha_y in component ACh_dependent_potassium_current_y_gate (per_millisecond). * ALGEBRAIC[68] is beta_y in component ACh_dependent_potassium_current_y_gate (per_millisecond). * CONSTANTS[32] is ACh in component ACh_dependent_potassium_current_y_gate (millimolar). * CONSTANTS[33] is Km_ACh in component ACh_dependent_potassium_current_y_gate (millimolar). * CONSTANTS[34] is P_bNSC in component background_NSC_current (picoA_per_millimolar). * CONSTANTS[93] is P_Kpl in component background_Kpl_current (nanoS_per_millimolar). * CONSTANTS[35] is P_lCa in component background_lCa_current (picoA_per_millimolar). * ALGEBRAIC[72] is p_open in component background_lCa_current (dimensionless). * ALGEBRAIC[73] is p_open in component background_KATP_current (dimensionless). * CONSTANTS[94] is gamma in component background_KATP_current (nanoS). * CONSTANTS[36] is P_KATP in component background_KATP_current (nanoS_per_picoF). * CONSTANTS[37] is N in component background_KATP_current (picoF). * CONSTANTS[38] is P_Cab in component background_Cab_current (picoA_per_millimolar). * CONSTANTS[95] is p_E2Na in component sodium_calcium_exchanger (dimensionless). * ALGEBRAIC[75] is p_E1Na in component sodium_calcium_exchanger (dimensionless). * ALGEBRAIC[76] is p_E1Ca in component sodium_calcium_exchanger (dimensionless). * CONSTANTS[98] is p_E2Ca in component sodium_calcium_exchanger (dimensionless). * ALGEBRAIC[77] is k1 in component sodium_calcium_exchanger (per_millisecond). * ALGEBRAIC[78] is k2 in component sodium_calcium_exchanger (per_millisecond). * CONSTANTS[39] is k3 in component sodium_calcium_exchanger (per_millisecond). * CONSTANTS[40] is k4 in component sodium_calcium_exchanger (per_millisecond). * CONSTANTS[41] is Km_Nai in component sodium_calcium_exchanger (millimolar). * CONSTANTS[42] is Km_Nao in component sodium_calcium_exchanger (millimolar). * CONSTANTS[43] is Km_Cai in component sodium_calcium_exchanger (millimolar). * CONSTANTS[44] is Km_Cao in component sodium_calcium_exchanger (millimolar). * STATES[30] is y in component sodium_calcium_exchanger_y_gate (dimensionless). * CONSTANTS[45] is P_NaCa in component sodium_calcium_exchanger (picoA_per_picoF). * CONSTANTS[46] is Partition in component sodium_calcium_exchanger (dimensionless). * ALGEBRAIC[79] is alpha_y in component sodium_calcium_exchanger_y_gate (per_millisecond). * ALGEBRAIC[80] is beta_y in component sodium_calcium_exchanger_y_gate (per_millisecond). * ALGEBRAIC[126] is p_E2Na in component sodium_potassium_pump (dimensionless). * ALGEBRAIC[81] is p_E1Na in component sodium_potassium_pump (dimensionless). * ALGEBRAIC[82] is p_E1K in component sodium_potassium_pump (dimensionless). * ALGEBRAIC[127] is p_E2K in component sodium_potassium_pump (dimensionless). * ALGEBRAIC[83] is k1 in component sodium_potassium_pump (per_millisecond). * CONSTANTS[47] is k2 in component sodium_potassium_pump (per_millisecond). * CONSTANTS[48] is k3 in component sodium_potassium_pump (per_millisecond). * CONSTANTS[49] is k4 in component sodium_potassium_pump (per_millisecond). * CONSTANTS[50] is Km_Nai in component sodium_potassium_pump (millimolar). * CONSTANTS[51] is Km_Nao in component sodium_potassium_pump (millimolar). * CONSTANTS[52] is Km_Ki in component sodium_potassium_pump (millimolar). * CONSTANTS[53] is Km_Ko in component sodium_potassium_pump (millimolar). * CONSTANTS[54] is Km_ATP in component sodium_potassium_pump (millimolar). * ALGEBRAIC[84] is Nao_Eff in component sodium_potassium_pump (millimolar). * STATES[31] is y in component sodium_potassium_pump_y_gate (dimensionless). * CONSTANTS[55] is P_NaK in component sodium_potassium_pump (picoA_per_picoF). * ALGEBRAIC[128] is alpha_y in component sodium_potassium_pump_y_gate (per_millisecond). * ALGEBRAIC[85] is beta_y in component sodium_potassium_pump_y_gate (per_millisecond). * ALGEBRAIC[87] is p_E2Ca in component SR_calcium_pump (dimensionless). * ALGEBRAIC[86] is p_E1Ca in component SR_calcium_pump (dimensionless). * ALGEBRAIC[88] is p_E1 in component SR_calcium_pump (dimensionless). * ALGEBRAIC[89] is p_E2 in component SR_calcium_pump (dimensionless). * CONSTANTS[56] is k1 in component SR_calcium_pump (per_millisecond). * ALGEBRAIC[90] is k2 in component SR_calcium_pump (per_millisecond). * CONSTANTS[57] is k3 in component SR_calcium_pump (per_millisecond). * CONSTANTS[58] is k4 in component SR_calcium_pump (per_millisecond). * CONSTANTS[59] is Km_CaSR in component SR_calcium_pump (millimolar). * CONSTANTS[60] is Km_CaCyto in component SR_calcium_pump (millimolar). * CONSTANTS[61] is Km_ATP in component SR_calcium_pump (millimolar). * CONSTANTS[62] is i_max in component SR_calcium_pump (picoA). * STATES[32] is Caup in component Ca_concentrations_in_SR (millimolar). * STATES[33] is y in component SR_calcium_pump_y_gate (dimensionless). * ALGEBRAIC[91] is alpha_y in component SR_calcium_pump_y_gate (per_millisecond). * ALGEBRAIC[92] is beta_y in component SR_calcium_pump_y_gate (per_millisecond). * CONSTANTS[63] is P_RyR in component RyR_channel (picoA_per_millimolar). * ALGEBRAIC[93] is k1 in component RyR_channel (per_millisecond). * ALGEBRAIC[131] is k2 in component RyR_channel (per_millisecond). * ALGEBRAIC[132] is k3 in component RyR_channel (per_millisecond). * CONSTANTS[64] is k4 in component RyR_channel (per_millisecond). * STATES[34] is p_open_RyR in component RyR_channel (dimensionless). * STATES[35] is p_close_RyR in component RyR_channel (dimensionless). * ALGEBRAIC[97] is Carel in component Ca_concentrations_in_SR (millimolar). * CONSTANTS[65] is Diadid_Factor in component RyR_channel (per_picoA_millisecond). * ALGEBRAIC[133] is i_SR_T in component SR_T_current (picoA). * CONSTANTS[66] is P_SR_T in component SR_T_current (picoA_per_millimolar). * CONSTANTS[67] is P_SR_L in component SR_L_current (picoA_per_millimolar). * STATES[36] is Ca_Total in component Ca_concentrations_in_SR (millimolar). * CONSTANTS[68] is V_rel in component Ca_concentrations_in_SR (micrometre3). * CONSTANTS[69] is V_up in component Ca_concentrations_in_SR (micrometre3). * CONSTANTS[70] is CSQN_max in component Ca_concentrations_in_SR (millimolar). * CONSTANTS[71] is K_mCSQN in component Ca_concentrations_in_SR (millimolar). * ALGEBRAIC[95] is b1 in component Ca_concentrations_in_SR (millimolar). * ALGEBRAIC[96] is c1 in component Ca_concentrations_in_SR (millimolar2). * CONSTANTS[96] is EffFraction in component NL_model (dimensionless). * STATES[37] is pCa in component NL_model (dimensionless). * STATES[38] is pCaCB in component NL_model (dimensionless). * STATES[39] is pCB in component NL_model (dimensionless). * ALGEBRAIC[99] is p in component NL_model (dimensionless). * CONSTANTS[72] is T_t in component NL_model (millimolar). * ALGEBRAIC[101] is Q_a in component NL_model (per_millisecond). * ALGEBRAIC[100] is Q_b in component NL_model (per_millisecond). * ALGEBRAIC[102] is Q_r in component NL_model (per_millisecond). * ALGEBRAIC[103] is Q_d in component NL_model (per_millisecond). * STATES[42] is Q_d1 in component NL_model (per_millisecond). * STATES[43] is Q_d2 in component NL_model (per_millisecond). * CONSTANTS[73] is Y_1 in component NL_model (per_millimolar_millisecond). * CONSTANTS[74] is Y_2 in component NL_model (per_millisecond). * CONSTANTS[75] is Y_3 in component NL_model (per_millisecond). * CONSTANTS[76] is Y_4 in component NL_model (per_millisecond). * CONSTANTS[77] is Y_d in component NL_model (millisecond_per_micrometre2). * CONSTANTS[78] is Z_1 in component NL_model (per_millisecond). * CONSTANTS[79] is Z_2 in component NL_model (per_millisecond). * CONSTANTS[80] is Z_3 in component NL_model (per_millimolar_millisecond). * ALGEBRAIC[98] is h in component NL_model (micrometre). * CONSTANTS[81] is L_a in component NL_model (micrometre). * CONSTANTS[82] is L in component NL_model (micrometre). * ALGEBRAIC[107] is ForceCB in component NL_model (mN_per_mm2). * STATES[40] is X in component NL_model (micrometre). * ALGEBRAIC[106] is NewCBF in component NL_model (mN_per_mm2_micrometre). * ALGEBRAIC[105] is CBBound in component NL_model (millimolar). * CONSTANTS[83] is KForceEC in component NL_model (mN_per_mm2_micrometre5). * CONSTANTS[84] is ZeroForceEL in component NL_model (micrometre). * CONSTANTS[85] is KForceLinearEc in component NL_model (mN_per_mm2_micrometre). * CONSTANTS[86] is ForceFactor in component NL_model (mN_per_mm2_micrometre_millimolar). * CONSTANTS[97] is ForceEcomp in component NL_model (mN_per_mm2). * CONSTANTS[87] is B in component NL_model (per_millisecond). * CONSTANTS[88] is h_c in component NL_model (micrometre). * ALGEBRAIC[108] is ForceExt in component NL_model (mN_per_mm2). * RATES[0] is d/dt Vm in component membrane (millivolt). * RATES[1] is d/dt Nai in component internal_ion_concentrations (millimolar). * RATES[2] is d/dt Ki in component internal_ion_concentrations (millimolar). * RATES[3] is d/dt Ca_Total in component internal_ion_concentrations (millimolar). * RATES[4] is d/dt ATPi in component ATP_production (millimolar). * RATES[7] is d/dt p_RP_Na in component sodium_current_voltage_dependent_gate (dimensionless). * RATES[5] is d/dt p_AP_Na in component sodium_current_voltage_dependent_gate (dimensionless). * RATES[8] is d/dt p_AI_Na in component sodium_current_voltage_dependent_gate (dimensionless). * RATES[6] is d/dt y in component sodium_current_ultra_slow_gate (dimensionless). * RATES[13] is d/dt p_RP_CaL in component L_type_Ca_channel_voltage_dependent_gate (dimensionless). * RATES[9] is d/dt p_AP_CaL in component L_type_Ca_channel_voltage_dependent_gate (dimensionless). * RATES[14] is d/dt p_AI_CaL in component L_type_Ca_channel_voltage_dependent_gate (dimensionless). * RATES[10] is d/dt p_U in component L_type_Ca_channel_Ca_dependent_gate (dimensionless). * RATES[11] is d/dt p_UCa in component L_type_Ca_channel_Ca_dependent_gate (dimensionless). * RATES[15] is d/dt p_C in component L_type_Ca_channel_Ca_dependent_gate (dimensionless). * RATES[12] is d/dt y in component L_type_Ca_channel_ultra_slow_gate (dimensionless). * RATES[16] is d/dt y1 in component T_type_Ca_channel_y1_gate (dimensionless). * RATES[17] is d/dt y2 in component T_type_Ca_channel_y2_gate (dimensionless). * RATES[18] is d/dt y1 in component st_channel_y1_gate (dimensionless). * RATES[19] is d/dt y2 in component st_channel_y2_gate (dimensionless). * RATES[20] is d/dt y3 in component st_channel_y3_gate (dimensionless). * RATES[23] is d/dt O1 in component ha_channel_voltage_dependent_gate (dimensionless). * RATES[24] is d/dt O2 in component ha_channel_voltage_dependent_gate (dimensionless). * RATES[21] is d/dt C1 in component ha_channel_voltage_dependent_gate (dimensionless). * RATES[22] is d/dt C2 in component ha_channel_voltage_dependent_gate (dimensionless). * RATES[25] is d/dt y in component time_independent_potassium_current_y_gate (dimensionless). * RATES[26] is d/dt y1 in component rapid_time_dependent_potassium_current_y1_gate (dimensionless). * RATES[27] is d/dt y2 in component rapid_time_dependent_potassium_current_y2_gate (dimensionless). * RATES[28] is d/dt y3 in component rapid_time_dependent_potassium_current_y3_gate (dimensionless). * RATES[29] is d/dt y in component ACh_dependent_potassium_current_y_gate (dimensionless). * RATES[30] is d/dt y in component sodium_calcium_exchanger_y_gate (dimensionless). * RATES[31] is d/dt y in component sodium_potassium_pump_y_gate (dimensionless). * RATES[33] is d/dt y in component SR_calcium_pump_y_gate (dimensionless). * RATES[34] is d/dt p_open_RyR in component RyR_channel (dimensionless). * RATES[35] is d/dt p_close_RyR in component RyR_channel (dimensionless). * RATES[36] is d/dt Ca_Total in component Ca_concentrations_in_SR (millimolar). * RATES[32] is d/dt Caup in component Ca_concentrations_in_SR (millimolar). * RATES[40] is d/dt X in component NL_model (micrometre). * RATES[37] is d/dt pCa in component NL_model (dimensionless). * RATES[38] is d/dt pCaCB in component NL_model (dimensionless). * RATES[39] is d/dt pCB in component NL_model (dimensionless). * There are a total of 0 condition variables. */ void initConsts(double* CONSTANTS, double* RATES, double *STATES) { STATES[0] = -42.987671350068005; CONSTANTS[0] = 8.3143; CONSTANTS[1] = 310; CONSTANTS[2] = 96.4867; CONSTANTS[3] = 32; CONSTANTS[4] = 139.99977217549068; CONSTANTS[5] = 1.7999668787634697; CONSTANTS[6] = 5.399964171929831; STATES[1] = 4.6808027298969925; STATES[2] = 139.22099524072777; CONSTANTS[7] = 2513.25; CONSTANTS[8] = 0.05; CONSTANTS[9] = 0.00238; STATES[3] = 0.003834100516470642; STATES[4] = 4.929308214702568; CONSTANTS[10] = 0.003; CONSTANTS[11] = 5; CONSTANTS[12] = 12; STATES[5] = 5.9898633533987405e-5; STATES[6] = 0.02691630436856424; STATES[7] = 2.2262336890623873e-4; STATES[8] = 0.9715915109181413; CONSTANTS[13] = 8.75e-5; CONSTANTS[14] = 2112; STATES[9] = 0.010773205742759775; STATES[10] = 0.018412749759150325; STATES[11] = 2.0870506374005444e-4; STATES[12] = 0.8256168329801671; STATES[13] = 0.42833044151885075; STATES[14] = 0.5607106503080197; CONSTANTS[15] = 0.004; CONSTANTS[16] = 0.001; STATES[15] = 0.05040310692927668; CONSTANTS[17] = 0.0003; CONSTANTS[18] = 0.35; CONSTANTS[19] = 0.143; CONSTANTS[20] = 0.35; CONSTANTS[21] = 6.954; CONSTANTS[22] = 0.0042; CONSTANTS[23] = 6.954; CONSTANTS[24] = 612; STATES[16] = 0.04679297803939428; STATES[17] = 0.004220636800632867; STATES[18] = 0.5375825176280309; STATES[19] = 0.3404904569858008; STATES[20] = 0.5596860236041188; CONSTANTS[25] = 0.236; CONSTANTS[26] = 0.138; STATES[21] = 0.9999616586460943; STATES[22] = 3.757612529902994e-5; CONSTANTS[27] = 1.821; CONSTANTS[28] = 7.7286; STATES[23] = 7.531035735927369e-7; STATES[24] = 1.1957124194086763e-8; CONSTANTS[29] = 0.003125; STATES[25] = 0.54434573606543; CONSTANTS[30] = 0.1045; STATES[26] = 0.7520936568166604; STATES[27] = 0.6128486629679218; STATES[28] = 0.6786243213825371; STATES[29] = 0.018249236601344903; CONSTANTS[31] = 4.32; CONSTANTS[32] = 0; CONSTANTS[33] = 0.0042; CONSTANTS[34] = 0.152; CONSTANTS[35] = 0.44; CONSTANTS[36] = 0.0236; CONSTANTS[37] = 1000; CONSTANTS[38] = 0.008; CONSTANTS[39] = 1; CONSTANTS[40] = 1; CONSTANTS[41] = 8.75; CONSTANTS[42] = 87.5; CONSTANTS[43] = 0.00138; CONSTANTS[44] = 1.38; STATES[30] = 0.9218642754061908; CONSTANTS[45] = 6.81; CONSTANTS[46] = 0.32; CONSTANTS[47] = 0.04; CONSTANTS[48] = 0.01; CONSTANTS[49] = 0.165; CONSTANTS[50] = 4.05; CONSTANTS[51] = 69.8; CONSTANTS[52] = 32.88; CONSTANTS[53] = 0.258; CONSTANTS[54] = 0.094; STATES[31] = 0.6755031143352256; CONSTANTS[55] = 21; CONSTANTS[56] = 0.01; CONSTANTS[57] = 1; CONSTANTS[58] = 0.01; CONSTANTS[59] = 0.08; CONSTANTS[60] = 0.0008; CONSTANTS[61] = 0.1; CONSTANTS[62] = 4875; STATES[32] = 3.539652240305415; STATES[33] = 0.8709732600283433; CONSTANTS[63] = 1860; CONSTANTS[64] = 0.000849; STATES[34] = 0.011424172905335395; STATES[35] = 0.007354039651246729; CONSTANTS[65] = -3; CONSTANTS[66] = 11.58; CONSTANTS[67] = 13.77; STATES[36] = 5.185011336959393; CONSTANTS[68] = 1.50795; CONSTANTS[69] = 3.769875; CONSTANTS[70] = 10; CONSTANTS[71] = 0.8; STATES[37] = 0.24298053499618683; STATES[38] = 0.02896443650702234; STATES[39] = 0.0020275353474589783; CONSTANTS[72] = 0.007; CONSTANTS[73] = 39; CONSTANTS[74] = 0.0039; CONSTANTS[75] = 0.03; CONSTANTS[76] = 0.12; CONSTANTS[77] = 0.027; CONSTANTS[78] = 0.03; CONSTANTS[79] = 0.0039; CONSTANTS[80] = 1560; CONSTANTS[81] = 1.17; CONSTANTS[82] = 0.9602399999150041; STATES[40] = 0.9552449999150041; CONSTANTS[83] = 140000; CONSTANTS[84] = 0.97; CONSTANTS[85] = 200; CONSTANTS[86] = 1800000; CONSTANTS[87] = 1.2; CONSTANTS[88] = 0.005; CONSTANTS[89] = ( CONSTANTS[22]*CONSTANTS[19]*CONSTANTS[21]*CONSTANTS[18])/( CONSTANTS[20]*CONSTANTS[23]*CONSTANTS[17]); CONSTANTS[90] = CONSTANTS[29]*CONSTANTS[3]*pow(CONSTANTS[6]/5.40000, 0.400000); CONSTANTS[91] = CONSTANTS[30]*CONSTANTS[3]*pow(CONSTANTS[6]/5.40000, 0.200000); CONSTANTS[92] = (CONSTANTS[32]==0.00000 ? 0.000247500 : 0.0123200/(1.00000+CONSTANTS[33]/CONSTANTS[32])+0.000247500); CONSTANTS[93] = 0.00700000*pow(CONSTANTS[6]/5.40000, 0.160000); CONSTANTS[94] = CONSTANTS[36]*CONSTANTS[37]*pow(CONSTANTS[6]/1.00000, 0.240000); CONSTANTS[95] = 1.00000/(1.00000+ pow(CONSTANTS[42]/CONSTANTS[4], 3.00000)*(1.00000+CONSTANTS[5]/CONSTANTS[44])); CONSTANTS[96] = exp( - 20.0000*pow(CONSTANTS[82] - CONSTANTS[81], 2.00000)); CONSTANTS[97] = CONSTANTS[83]*pow(CONSTANTS[84] - CONSTANTS[82], 5.00000)+ CONSTANTS[85]*(CONSTANTS[84] - CONSTANTS[82]); CONSTANTS[98] = 1.00000/(1.00000+ (CONSTANTS[44]/CONSTANTS[5])*(1.00000+pow(CONSTANTS[4]/CONSTANTS[42], 3.00000))); STATES[41] = 0.1001; STATES[42] = 0.1001; STATES[43] = 0.1001; RATES[0] = 0.1001; RATES[1] = 0.1001; RATES[2] = 0.1001; RATES[3] = 0.1001; RATES[4] = 0.1001; RATES[7] = 0.1001; RATES[5] = 0.1001; RATES[8] = 0.1001; RATES[6] = 0.1001; RATES[13] = 0.1001; RATES[9] = 0.1001; RATES[14] = 0.1001; RATES[10] = 0.1001; RATES[11] = 0.1001; RATES[15] = 0.1001; RATES[12] = 0.1001; RATES[16] = 0.1001; RATES[17] = 0.1001; RATES[18] = 0.1001; RATES[19] = 0.1001; RATES[20] = 0.1001; RATES[23] = 0.1001; RATES[24] = 0.1001; RATES[21] = 0.1001; RATES[22] = 0.1001; RATES[25] = 0.1001; RATES[26] = 0.1001; RATES[27] = 0.1001; RATES[28] = 0.1001; RATES[29] = 0.1001; RATES[30] = 0.1001; RATES[31] = 0.1001; RATES[33] = 0.1001; RATES[34] = 0.1001; RATES[35] = 0.1001; RATES[36] = 0.1001; RATES[32] = 0.1001; RATES[40] = 0.1001; RATES[37] = 0.1001; RATES[38] = 0.1001; RATES[39] = 0.1001; } void computeResiduals(double VOI, double* CONSTANTS, double* RATES, double* OLDRATES, double* STATES, double* OLDSTATES, double* ALGEBRAIC, double* CONDVARS) { resid[0] = RATES[0] - - ALGEBRAIC[142]/CONSTANTS[3]; resid[1] = RATES[1] - - ALGEBRAIC[140]/( CONSTANTS[2]*CONSTANTS[7]); resid[2] = RATES[2] - - ALGEBRAIC[141]/( CONSTANTS[2]*CONSTANTS[7]); resid[3] = RATES[3] - - (((ALGEBRAIC[134] - ALGEBRAIC[129]) - ALGEBRAIC[130]) - ALGEBRAIC[94])/( 2.00000*CONSTANTS[2]*CONSTANTS[7])+STATES[41]; resid[4] = RATES[4] - (( CONSTANTS[10]*(CONSTANTS[11] - STATES[4])+ALGEBRAIC[104]) - ALGEBRAIC[138]/( CONSTANTS[2]*CONSTANTS[7]))+ALGEBRAIC[129]/( 4.00000*CONSTANTS[2]*CONSTANTS[7]); resid[5] = RATES[7] - ( STATES[5]*ALGEBRAIC[10]+ ALGEBRAIC[8]*ALGEBRAIC[15]) - STATES[7]*(ALGEBRAIC[14]+ALGEBRAIC[9]); resid[6] = RATES[5] - ( STATES[7]*ALGEBRAIC[9]+ STATES[8]*CONSTANTS[13]) - STATES[5]*(ALGEBRAIC[10]+ALGEBRAIC[11]); resid[7] = RATES[8] - ( ALGEBRAIC[8]*ALGEBRAIC[13]+ STATES[5]*ALGEBRAIC[11]) - STATES[8]*(ALGEBRAIC[12]+CONSTANTS[13]); resid[8] = RATES[6] - ALGEBRAIC[16]*(1.00000 - STATES[6]) - ALGEBRAIC[17]*STATES[6]; resid[9] = RATES[13] - ( STATES[9]*ALGEBRAIC[21]+ ALGEBRAIC[19]*ALGEBRAIC[25]) - STATES[13]*(ALGEBRAIC[24]+ALGEBRAIC[20]); resid[10] = RATES[9] - ( STATES[13]*ALGEBRAIC[20]+ STATES[14]*CONSTANTS[16]) - STATES[9]*(ALGEBRAIC[21]+CONSTANTS[15]); resid[11] = RATES[14] - ( ALGEBRAIC[19]*ALGEBRAIC[22]+ STATES[9]*CONSTANTS[15]) - STATES[14]*(ALGEBRAIC[23]+CONSTANTS[16]); resid[12] = RATES[10] - ( STATES[15]*CONSTANTS[19]+ STATES[11]*CONSTANTS[89]) - STATES[10]*(ALGEBRAIC[31]+CONSTANTS[20]); resid[13] = RATES[11] - ( STATES[10]*ALGEBRAIC[31]+ ALGEBRAIC[33]*CONSTANTS[17]) - STATES[11]*(CONSTANTS[18]+CONSTANTS[89]); resid[14] = RATES[15] - ( ALGEBRAIC[33]*CONSTANTS[22]+ STATES[10]*CONSTANTS[20]) - STATES[15]*(CONSTANTS[19]+ CONSTANTS[23]*ALGEBRAIC[28]*STATES[9]); resid[15] = RATES[12] - ALGEBRAIC[34]*(1.00000 - STATES[12]) - ALGEBRAIC[35]*STATES[12]; resid[16] = RATES[16] - ALGEBRAIC[37]*(1.00000 - STATES[16]) - ALGEBRAIC[38]*STATES[16]; resid[17] = RATES[17] - ALGEBRAIC[39]*(1.00000 - STATES[17]) - ALGEBRAIC[40]*STATES[17]; resid[18] = RATES[18] - ALGEBRAIC[43]*(1.00000 - STATES[18]) - ALGEBRAIC[44]*STATES[18]; resid[19] = RATES[19] - ALGEBRAIC[45]*(1.00000 - STATES[19]) - ALGEBRAIC[46]*STATES[19]; resid[20] = RATES[20] - ALGEBRAIC[47]*(1.00000 - STATES[20]) - ALGEBRAIC[48]*STATES[20]; resid[21] = RATES[23] - ( ALGEBRAIC[52]*STATES[22]+ ALGEBRAIC[53]*STATES[24]) - (ALGEBRAIC[52]+ALGEBRAIC[53])*STATES[23]; resid[22] = RATES[24] - ( ALGEBRAIC[52]*STATES[23]+ ALGEBRAIC[53]*ALGEBRAIC[51]) - (ALGEBRAIC[52]+ALGEBRAIC[53])*STATES[24]; resid[23] = RATES[21] - ALGEBRAIC[55]*STATES[22] - ALGEBRAIC[54]*STATES[21]; resid[24] = RATES[22] - ( ALGEBRAIC[54]*STATES[21]+ ALGEBRAIC[53]*STATES[23]) - (ALGEBRAIC[52]+ALGEBRAIC[55])*STATES[22]; resid[25] = RATES[25] - ALGEBRAIC[59]*(1.00000 - STATES[25]) - ALGEBRAIC[120]*STATES[25]; resid[26] = RATES[26] - ALGEBRAIC[61]*(1.00000 - STATES[26]) - ALGEBRAIC[62]*STATES[26]; resid[27] = RATES[27] - ALGEBRAIC[63]*(1.00000 - STATES[27]) - ALGEBRAIC[64]*STATES[27]; resid[28] = RATES[28] - ALGEBRAIC[65]*(1.00000 - STATES[28]) - ALGEBRAIC[66]*STATES[28]; resid[29] = RATES[29] - CONSTANTS[92]*(1.00000 - STATES[29]) - ALGEBRAIC[68]*STATES[29]; resid[30] = RATES[30] - ALGEBRAIC[79]*(1.00000 - STATES[30]) - ALGEBRAIC[80]*STATES[30]; resid[31] = RATES[31] - ALGEBRAIC[128]*(1.00000 - STATES[31]) - ALGEBRAIC[85]*STATES[31]; resid[32] = RATES[33] - ALGEBRAIC[91]*(1.00000 - STATES[33]) - ALGEBRAIC[92]*STATES[33]; resid[33] = RATES[34] - STATES[35]*ALGEBRAIC[93] - STATES[34]*ALGEBRAIC[131]; resid[34] = RATES[35] - ALGEBRAIC[132]*(1.00000 - (STATES[34]+STATES[35])) - (ALGEBRAIC[93]+CONSTANTS[64])*STATES[35]; resid[35] = RATES[36] - (ALGEBRAIC[133] - ALGEBRAIC[130])/( 2.00000*CONSTANTS[2]*CONSTANTS[68]); resid[36] = RATES[32] - ((- ALGEBRAIC[129] - ALGEBRAIC[133]) - ALGEBRAIC[94])/( 2.00000*CONSTANTS[2]*CONSTANTS[69]); resid[37] = STATES[42] - CONSTANTS[77]*pow(RATES[40], 2.00000)*STATES[39]; resid[38] = STATES[43] - CONSTANTS[77]*pow(RATES[40], 2.00000)*STATES[38]; resid[39] = RATES[37] - ALGEBRAIC[100] - ALGEBRAIC[101]; resid[40] = RATES[38] - (ALGEBRAIC[101] - ALGEBRAIC[102]) - STATES[43]; resid[41] = RATES[39] - (ALGEBRAIC[102] - ALGEBRAIC[103]) - STATES[42]; resid[42] = STATES[41] - CONSTANTS[72]*((STATES[43]+ALGEBRAIC[102]) - ALGEBRAIC[100]); resid[43] = RATES[40] - CONSTANTS[87]*(ALGEBRAIC[98] - CONSTANTS[88]); } void computeVariables(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC) { ALGEBRAIC[32] = CONSTANTS[23]*ALGEBRAIC[29]; ALGEBRAIC[105] = CONSTANTS[72]*(STATES[38]+STATES[39]); ALGEBRAIC[106] = CONSTANTS[86]*ALGEBRAIC[105]; ALGEBRAIC[107] = ALGEBRAIC[106]*ALGEBRAIC[98]; ALGEBRAIC[108] = - CONSTANTS[97]+ALGEBRAIC[107]; } void computeEssentialVariables(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC) { ALGEBRAIC[8] = ((1.00000 - STATES[7]) - STATES[5]) - STATES[8]; ALGEBRAIC[9] = 1.00000/( 0.102700*exp(- STATES[0]/8.00000)+ 0.250000*exp(- STATES[0]/50.0000)); ALGEBRAIC[10] = 1.00000/( 26.0000*exp(STATES[0]/17.0000)+ 0.0200000*exp(STATES[0]/800.000)); ALGEBRAIC[11] = 1.00000/( 0.800000*exp(- STATES[0]/400.000)); ALGEBRAIC[12] = 1.00000/( 1300.00*exp(STATES[0]/20.0000)+ 0.0400000*exp(STATES[0]/800.000)); ALGEBRAIC[13] = 1.00000/( 0.000102700*exp(- STATES[0]/8.00000)+ 5.00000*exp(- STATES[0]/400.000)); ALGEBRAIC[14] = 0.0100000/(1.00000+( CONSTANTS[13]*ALGEBRAIC[10]*ALGEBRAIC[13])/( ALGEBRAIC[11]*ALGEBRAIC[9]*ALGEBRAIC[12])); ALGEBRAIC[15] = 0.0100000 - ALGEBRAIC[14]; ALGEBRAIC[16] = 1.00000/( 9.00000e+09*exp(STATES[0]/5.00000)+ 8000.00*exp(STATES[0]/100.000)); ALGEBRAIC[17] = 1.00000/( 0.0140000*exp(- STATES[0]/5.00000)+ 4000.00*exp(- STATES[0]/100.000)); ALGEBRAIC[19] = ((1.00000 - STATES[9]) - STATES[13]) - STATES[14]; ALGEBRAIC[20] = 1.00000/( 0.270000*exp(- STATES[0]/5.90000)+ 1.50000*exp(- STATES[0]/65.0000)); ALGEBRAIC[21] = 1.00000/( 480.000*exp(STATES[0]/7.00000)+ 2.20000*exp(STATES[0]/65.0000)); ALGEBRAIC[22] = 1.00000/( 0.00180000*exp(- STATES[0]/7.40000)+ 2.00000*exp(- STATES[0]/100.000)); ALGEBRAIC[23] = 1.00000/( 2.20000e+06*exp(STATES[0]/7.40000)+ 11.0000*exp(STATES[0]/100.000)); ALGEBRAIC[24] = 0.0400000/(1.00000+( CONSTANTS[16]*ALGEBRAIC[21]*ALGEBRAIC[22])/( CONSTANTS[15]*ALGEBRAIC[20]*ALGEBRAIC[23])); ALGEBRAIC[25] = 0.0400000 - ALGEBRAIC[24]; ALGEBRAIC[0] = (CONSTANTS[8] - STATES[3])+CONSTANTS[9]; ALGEBRAIC[1] = CONSTANTS[9]*STATES[3]; ALGEBRAIC[2] = ( pow((pow(ALGEBRAIC[0], 2.00000)+ 4.00000*ALGEBRAIC[1]), 1.0 / 2) - ALGEBRAIC[0])/2.00000; ALGEBRAIC[4] = (STATES[0]==0.00000 ? - CONSTANTS[5] : ( (( 2.00000*CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1]))*(ALGEBRAIC[2] - CONSTANTS[5]*exp(( - 2.00000*CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1]))))/(1.00000 - exp(( - 2.00000*CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1])))); ALGEBRAIC[26] = 0.0676000*ALGEBRAIC[4]; ALGEBRAIC[28] = ALGEBRAIC[2] - 0.300000*ALGEBRAIC[26]; ALGEBRAIC[29] = ALGEBRAIC[28]*STATES[9]; ALGEBRAIC[30] = ALGEBRAIC[29]+ ALGEBRAIC[2]*(1.00000 - STATES[9]); ALGEBRAIC[31] = CONSTANTS[21]*ALGEBRAIC[30]; ALGEBRAIC[33] = ((1.00000 - STATES[15]) - STATES[10]) - STATES[11]; ALGEBRAIC[34] = 1.00000/( 250000.*exp(STATES[0]/9.00000)+ 58.0000*exp(STATES[0]/65.0000)); ALGEBRAIC[35] = 1.00000/( 1800.00*exp(- STATES[0]/14.0000)+ 66.0000*exp(- STATES[0]/65.0000)); ALGEBRAIC[37] = 1.00000/( 0.0190000*exp(- STATES[0]/5.60000)+ 0.820000*exp(- STATES[0]/250.000)); ALGEBRAIC[38] = 1.00000/( 40.0000*exp(STATES[0]/6.30000)+ 1.50000*exp(STATES[0]/10000.0)); ALGEBRAIC[39] = 1.00000/( 62000.0*exp(STATES[0]/10.1000)+ 30.0000*exp(STATES[0]/3000.00)); ALGEBRAIC[40] = 1.00000/( 0.000600000*exp(- STATES[0]/6.70000)+ 1.20000*exp(- STATES[0]/25.0000)); ALGEBRAIC[43] = 1.00000/( 0.150000*exp(- STATES[0]/11.0000)+ 0.200000*exp(- STATES[0]/700.000)); ALGEBRAIC[44] = 1.00000/( 16.0000*exp(STATES[0]/8.00000)+ 15.0000*exp(STATES[0]/50.0000)); ALGEBRAIC[45] = 1.00000/( 3100.00*exp(STATES[0]/13.0000)+ 700.000*exp(STATES[0]/70.0000)); ALGEBRAIC[46] = 1.00000/( 95.0000*exp(- STATES[0]/10.0000)+ 50.0000*exp(- STATES[0]/700.000))+( ALGEBRAIC[2]*2.50000)/(1.00000+exp(- STATES[0]/5.00000)); ALGEBRAIC[47] = 1.00000/( 400000.*exp(STATES[0]/9.00000)+ 60.0000*exp(STATES[0]/65.0000)); ALGEBRAIC[48] = 1.00000/( 700.000*exp(- STATES[0]/14.0000)+ 60.0000*exp(- STATES[0]/65.0000)); ALGEBRAIC[51] = (((1.00000 - STATES[21]) - STATES[22]) - STATES[23]) - STATES[24]; ALGEBRAIC[52] = 1.00000/( 3500.00*exp(STATES[0]/16.8000)+ 0.300000*exp(STATES[0]/400.000)); ALGEBRAIC[53] = 1.00000/( 4.00000*exp(- STATES[0]/14.0000)+ 2.00000*exp(- STATES[0]/400.000)); ALGEBRAIC[54] = 1.00000/( 4.50000e+07*exp(STATES[0]/8.00000)+ 500.000*exp(STATES[0]/200.000)); ALGEBRAIC[55] = 1.00000/( 10.5000*exp(- STATES[0]/16.4000)+ 0.400000*exp(- STATES[0]/400.000)); ALGEBRAIC[56] = (( CONSTANTS[0]*CONSTANTS[1])/CONSTANTS[2])*log(CONSTANTS[6]/STATES[2]); ALGEBRAIC[59] = 1.00000/( 8000.00*exp(((STATES[0] - ALGEBRAIC[56]) - 97.0000)/8.50000)+ 7.00000*exp(((STATES[0] - ALGEBRAIC[56]) - 97.0000)/300.000)); ALGEBRAIC[61] = 1.00000/( 20.0000*exp(- STATES[0]/11.5000)+ 5.00000*exp(- STATES[0]/300.000)); ALGEBRAIC[62] = 1.00000/( 160.000*exp(STATES[0]/28.0000)+ 200.000*exp(STATES[0]/1000.00))+1.00000/( 2500.00*exp(STATES[0]/20.0000)); ALGEBRAIC[63] = 1.00000/( 200.000*exp(- STATES[0]/13.0000)+ 20.0000*exp(- STATES[0]/300.000)); ALGEBRAIC[64] = 1.00000/( 1600.00*exp(STATES[0]/28.0000)+ 2000.00*exp(STATES[0]/1000.00))+1.00000/( 10000.0*exp(STATES[0]/20.0000)); ALGEBRAIC[65] = 1.00000/( 10.0000*exp(STATES[0]/17.0000)+ 2.50000*exp(STATES[0]/300.000)); ALGEBRAIC[66] = 1.00000/( 0.350000*exp(- STATES[0]/17.0000)+ 2.00000*exp(- STATES[0]/150.000)); ALGEBRAIC[68] = 0.0100000*exp( 0.0133000*(STATES[0]+40.0000)); ALGEBRAIC[78] = 1.00000*exp(( (CONSTANTS[46] - 1.00000)*CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1])); ALGEBRAIC[79] = ALGEBRAIC[78]*CONSTANTS[95]+ CONSTANTS[40]*CONSTANTS[98]; ALGEBRAIC[75] = 1.00000/(1.00000+ pow(CONSTANTS[41]/STATES[1], 3.00000)*(1.00000+ALGEBRAIC[2]/CONSTANTS[43])); ALGEBRAIC[76] = 1.00000/(1.00000+ (CONSTANTS[43]/ALGEBRAIC[2])*(1.00000+pow(STATES[1]/CONSTANTS[41], 3.00000))); ALGEBRAIC[77] = 1.00000*exp(( CONSTANTS[46]*CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1])); ALGEBRAIC[80] = ALGEBRAIC[77]*ALGEBRAIC[75]+ CONSTANTS[39]*ALGEBRAIC[76]; ALGEBRAIC[81] = 1.00000/(1.00000+ pow(CONSTANTS[50]/STATES[1], 1.06000)*(1.00000+pow(STATES[2]/CONSTANTS[52], 1.12000))); ALGEBRAIC[82] = 1.00000/(1.00000+ pow(CONSTANTS[52]/STATES[2], 1.12000)*(1.00000+pow(STATES[1]/CONSTANTS[50], 1.06000))); ALGEBRAIC[83] = 0.370000/(1.00000+CONSTANTS[54]/STATES[4]); ALGEBRAIC[85] = ALGEBRAIC[83]*ALGEBRAIC[81]+ CONSTANTS[48]*ALGEBRAIC[82]; ALGEBRAIC[87] = 1.00000/(1.00000+CONSTANTS[60]/ALGEBRAIC[2]); ALGEBRAIC[89] = 1.00000 - ALGEBRAIC[87]; ALGEBRAIC[90] = 1.00000/(1.00000+CONSTANTS[61]/STATES[4]); ALGEBRAIC[91] = ALGEBRAIC[90]*ALGEBRAIC[87]+ CONSTANTS[58]*ALGEBRAIC[89]; ALGEBRAIC[86] = 1.00000/(1.00000+CONSTANTS[59]/STATES[32]); ALGEBRAIC[88] = 1.00000 - ALGEBRAIC[86]; ALGEBRAIC[92] = CONSTANTS[56]*ALGEBRAIC[86]+ CONSTANTS[57]*ALGEBRAIC[88]; ALGEBRAIC[18] = ( STATES[9]*(STATES[10]+STATES[11])*STATES[12])/(1.00000+pow(1.40000/STATES[4], 3.00000)); ALGEBRAIC[27] = ALGEBRAIC[26]*ALGEBRAIC[18]; ALGEBRAIC[93] = 280000.*pow(ALGEBRAIC[2]/1.00000, 2.00000)+ CONSTANTS[65]*ALGEBRAIC[27]; ALGEBRAIC[94] = CONSTANTS[67]*(STATES[32] - ALGEBRAIC[2]); ALGEBRAIC[98] = CONSTANTS[82] - STATES[40]; ALGEBRAIC[99] = ((1.00000 - STATES[37]) - STATES[38]) - STATES[39]; ALGEBRAIC[100] = CONSTANTS[73]*ALGEBRAIC[2]*ALGEBRAIC[99] - CONSTANTS[78]*STATES[37]; ALGEBRAIC[101] = CONSTANTS[74]*STATES[37]*CONSTANTS[96] - CONSTANTS[79]*STATES[38]; ALGEBRAIC[102] = CONSTANTS[75]*STATES[38] - CONSTANTS[80]*STATES[39]*ALGEBRAIC[2]; ALGEBRAIC[103] = CONSTANTS[76]*STATES[39]; ALGEBRAIC[104] = - 0.400000*STATES[38]*CONSTANTS[72]; ALGEBRAIC[57] = ( 0.750000*exp( 0.0350000*((STATES[0] - ALGEBRAIC[56]) - 10.0000)))/(1.00000+exp( 0.0150000*((STATES[0] - ALGEBRAIC[56]) - 140.000))); ALGEBRAIC[58] = ( 3.00000*exp( - 0.0480000*((STATES[0] - ALGEBRAIC[56]) - 10.0000))*(1.00000+exp( 0.0640000*((STATES[0] - ALGEBRAIC[56]) - 38.0000))))/(1.00000+exp( 0.0300000*((STATES[0] - ALGEBRAIC[56]) - 70.0000))); ALGEBRAIC[116] = ALGEBRAIC[58]/(ALGEBRAIC[57]+ALGEBRAIC[58]); ALGEBRAIC[120] = ( pow(ALGEBRAIC[116], 4.00000)*1.00000)/( 0.000140000*exp(- ((STATES[0] - ALGEBRAIC[56]) - 97.0000)/9.10000)+ 0.200000*exp(- ((STATES[0] - ALGEBRAIC[56]) - 97.0000)/500.000)); ALGEBRAIC[84] = CONSTANTS[4]*exp(( - 0.820000*CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1])); ALGEBRAIC[126] = 1.00000/(1.00000+ pow(CONSTANTS[51]/ALGEBRAIC[84], 1.06000)*(1.00000+pow(CONSTANTS[6]/CONSTANTS[53], 1.12000))); ALGEBRAIC[127] = 1.00000/(1.00000+ pow(CONSTANTS[53]/CONSTANTS[6], 1.12000)*(1.00000+pow(ALGEBRAIC[84]/CONSTANTS[51], 1.06000))); ALGEBRAIC[128] = CONSTANTS[47]*ALGEBRAIC[126]+ CONSTANTS[49]*ALGEBRAIC[127]; ALGEBRAIC[129] = CONSTANTS[62]*1.00000*( CONSTANTS[56]*ALGEBRAIC[86]*STATES[33] - ALGEBRAIC[90]*ALGEBRAIC[87]*(1.00000 - STATES[33])); ALGEBRAIC[95] = (CONSTANTS[70] - STATES[36])+CONSTANTS[71]; ALGEBRAIC[96] = CONSTANTS[71]*STATES[36]; ALGEBRAIC[97] = ( pow((pow(ALGEBRAIC[95], 2.00000)+ 4.00000*ALGEBRAIC[96]), 1.0 / 2) - ALGEBRAIC[95])/2.00000; ALGEBRAIC[130] = CONSTANTS[63]*(ALGEBRAIC[97] - ALGEBRAIC[2])*STATES[34]; ALGEBRAIC[131] = 0.0800000/(1.00000+0.360000/ALGEBRAIC[97]); ALGEBRAIC[132] = 0.000377000*pow(ALGEBRAIC[97]/1.00000, 2.00000); ALGEBRAIC[133] = CONSTANTS[66]*(STATES[32] - ALGEBRAIC[97]); ALGEBRAIC[36] = CONSTANTS[24]*ALGEBRAIC[4]*STATES[16]*STATES[17]; ALGEBRAIC[125] = CONSTANTS[45]*CONSTANTS[3]*1.00000*( ALGEBRAIC[77]*ALGEBRAIC[75]*STATES[30] - ALGEBRAIC[78]*CONSTANTS[95]*(1.00000 - STATES[30])); ALGEBRAIC[74] = CONSTANTS[38]*ALGEBRAIC[4]; ALGEBRAIC[110] = CONSTANTS[14]*ALGEBRAIC[4]*ALGEBRAIC[18]; ALGEBRAIC[134] = (ALGEBRAIC[110]+ALGEBRAIC[36]+ALGEBRAIC[74]) - 2.00000*ALGEBRAIC[125]; ALGEBRAIC[138] = CONSTANTS[55]*CONSTANTS[3]*1.00000*( ALGEBRAIC[83]*ALGEBRAIC[81]*STATES[31] - CONSTANTS[47]*ALGEBRAIC[126]*(1.00000 - STATES[31])); ALGEBRAIC[3] = (STATES[0]==0.00000 ? - CONSTANTS[4] : ( (( CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1]))*(STATES[1] - CONSTANTS[4]*exp(( - CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1]))))/(1.00000 - exp(( - CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1])))); ALGEBRAIC[6] = CONSTANTS[12]*ALGEBRAIC[3]*STATES[5]*STATES[6]; ALGEBRAIC[111] = 1.85000e-05*CONSTANTS[14]*ALGEBRAIC[3]*ALGEBRAIC[18]; ALGEBRAIC[41] = CONSTANTS[25]*ALGEBRAIC[3]*STATES[18]*STATES[19]*STATES[20]; ALGEBRAIC[49] = CONSTANTS[27]*ALGEBRAIC[3]*((1.00000 - STATES[21]) - STATES[22]); ALGEBRAIC[70] = CONSTANTS[34]*ALGEBRAIC[3]; ALGEBRAIC[72] = 1.00000/(1.00000+pow(0.00120000/ALGEBRAIC[2], 3.00000)); ALGEBRAIC[123] = CONSTANTS[35]*ALGEBRAIC[3]*ALGEBRAIC[72]; ALGEBRAIC[140] = ALGEBRAIC[6]+ALGEBRAIC[111]+ALGEBRAIC[41]+ALGEBRAIC[49]+ALGEBRAIC[70]+ALGEBRAIC[123]+ 3.00000*ALGEBRAIC[138]+ 3.00000*ALGEBRAIC[125]; ALGEBRAIC[115] = ALGEBRAIC[57]/(ALGEBRAIC[57]+ALGEBRAIC[58]); ALGEBRAIC[117] = 2.00000*pow(ALGEBRAIC[116], 2.00000)*pow(ALGEBRAIC[115], 2.00000); ALGEBRAIC[118] = (8.00000/3.00000)*pow(ALGEBRAIC[116], 3.00000)*ALGEBRAIC[115]; ALGEBRAIC[119] = pow(ALGEBRAIC[116], 4.00000); ALGEBRAIC[136] = CONSTANTS[90]*(STATES[0] - ALGEBRAIC[56])*(ALGEBRAIC[119]+ALGEBRAIC[118]+ALGEBRAIC[117])*STATES[25]; ALGEBRAIC[60] = CONSTANTS[91]*(STATES[0] - ALGEBRAIC[56])*( 0.600000*STATES[26]+ 0.400000*STATES[27])*STATES[28]; ALGEBRAIC[67] = (( CONSTANTS[31]*(STATES[0] - ALGEBRAIC[56]))/(1.00000+exp((STATES[0]+20.0000)/20.0000)))*STATES[29]; ALGEBRAIC[5] = (STATES[0]==0.00000 ? STATES[2] : ( (( CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1]))*(STATES[2] - CONSTANTS[6]*exp(( - CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1]))))/(1.00000 - exp(( - CONSTANTS[2]*STATES[0])/( CONSTANTS[0]*CONSTANTS[1])))); ALGEBRAIC[71] = (STATES[0]==- 3.00000 ? CONSTANTS[93]*ALGEBRAIC[5]*13.0077 : ( CONSTANTS[93]*ALGEBRAIC[5]*(STATES[0]+3.00000))/(1.00000 - exp(- (STATES[0]+3.00000)/13.0000))); ALGEBRAIC[73] = 0.800000/(1.00000+pow(STATES[4]/0.100000, 2.00000)); ALGEBRAIC[124] = CONSTANTS[94]*(STATES[0] - ALGEBRAIC[56])*ALGEBRAIC[73]; ALGEBRAIC[7] = 0.100000*CONSTANTS[12]*ALGEBRAIC[5]*STATES[5]*STATES[6]; ALGEBRAIC[112] = 0.000365000*CONSTANTS[14]*ALGEBRAIC[5]*ALGEBRAIC[18]; ALGEBRAIC[42] = CONSTANTS[26]*ALGEBRAIC[5]*STATES[18]*STATES[19]*STATES[20]; ALGEBRAIC[50] = CONSTANTS[28]*ALGEBRAIC[5]*((1.00000 - STATES[21]) - STATES[22]); ALGEBRAIC[69] = 0.400000*CONSTANTS[34]*ALGEBRAIC[5]; ALGEBRAIC[122] = CONSTANTS[35]*ALGEBRAIC[5]*ALGEBRAIC[72]; ALGEBRAIC[141] = (ALGEBRAIC[136]+ALGEBRAIC[60]+ALGEBRAIC[124]+ALGEBRAIC[67]+ALGEBRAIC[7]+ALGEBRAIC[112]+ALGEBRAIC[42]+ALGEBRAIC[50]+ALGEBRAIC[69]+ALGEBRAIC[122]+ALGEBRAIC[71]) - 2.00000*ALGEBRAIC[138]; ALGEBRAIC[121] = ALGEBRAIC[69]+ALGEBRAIC[70]; ALGEBRAIC[137] = ALGEBRAIC[122]+ALGEBRAIC[123]; ALGEBRAIC[139] = ALGEBRAIC[121]+ALGEBRAIC[74]+ALGEBRAIC[71]+ALGEBRAIC[137]+ALGEBRAIC[124]; ALGEBRAIC[109] = ALGEBRAIC[6]+ALGEBRAIC[7]; ALGEBRAIC[135] = ALGEBRAIC[111]+ALGEBRAIC[110]+ALGEBRAIC[112]; ALGEBRAIC[113] = ALGEBRAIC[41]+ALGEBRAIC[42]; ALGEBRAIC[114] = ALGEBRAIC[49]+ALGEBRAIC[50]; ALGEBRAIC[142] = ALGEBRAIC[109]+ALGEBRAIC[135]+ALGEBRAIC[36]+ALGEBRAIC[136]+ALGEBRAIC[60]+ALGEBRAIC[139]+ALGEBRAIC[138]+ALGEBRAIC[125]+ALGEBRAIC[113]+ALGEBRAIC[114]+ALGEBRAIC[67]; } void getStateInformation(double* SI) { SI[0] = 1.0; SI[1] = 1.0; SI[2] = 1.0; SI[41] = 0.0; SI[3] = 1.0; SI[4] = 1.0; SI[5] = 1.0; SI[6] = 1.0; SI[7] = 1.0; SI[8] = 1.0; SI[9] = 1.0; SI[10] = 1.0; SI[11] = 1.0; SI[12] = 1.0; SI[13] = 1.0; SI[14] = 1.0; SI[15] = 1.0; SI[16] = 1.0; SI[17] = 1.0; SI[18] = 1.0; SI[19] = 1.0; SI[20] = 1.0; SI[21] = 1.0; SI[22] = 1.0; SI[23] = 1.0; SI[24] = 1.0; SI[25] = 1.0; SI[26] = 1.0; SI[27] = 1.0; SI[28] = 1.0; SI[29] = 1.0; SI[30] = 1.0; SI[31] = 1.0; SI[32] = 1.0; SI[33] = 1.0; SI[34] = 1.0; SI[35] = 1.0; SI[36] = 1.0; SI[37] = 1.0; SI[38] = 1.0; SI[39] = 1.0; SI[42] = 0.0; SI[43] = 0.0; SI[40] = 1.0; } void computeRoots(double VOI, double* CONSTANTS, double* RATES, double* OLDRATES, double* STATES, double* OLDSTATES, double* ALGEBRAIC, double* CONDVARS) { }