/* There are a total of 115 entries in the algebraic variable array. There are a total of 42 entries in each of the rate and state variable arrays. There are a total of 111 entries in the constant variable array. */ /* * VOI is t in component environment (millisecond). * STATES[0] is V in component membrane (millivolt). * CONSTANTS[0] is R in component membrane (joule_per_kmole_kelvin). * CONSTANTS[1] is T in component membrane (kelvin). * CONSTANTS[2] is Frdy in component membrane (coulomb_per_mole). * CONSTANTS[95] is FoRT in component membrane (per_milliV). * CONSTANTS[3] is C_mem in component membrane (farad). * ALGEBRAIC[107] is I_Na_tot_junc in component Sodium_Concentrations (picoA_per_picoF). * ALGEBRAIC[108] is I_Na_tot_sl in component Sodium_Concentrations (picoA_per_picoF). * ALGEBRAIC[38] is I_ClCa in component Ca_Activated_Cl_Current (picoA_per_picoF). * ALGEBRAIC[39] is I_Cl_Bk in component Background_Cl_Current (picoA_per_picoF). * ALGEBRAIC[110] is I_Ca_tot_junc in component Calcium_Concentrations (picoA_per_picoF). * ALGEBRAIC[111] is I_Ca_tot_sl in component Calcium_Concentrations (picoA_per_picoF). * ALGEBRAIC[109] is I_K_tot in component Potassium_Concentrations (picoA_per_picoF). * ALGEBRAIC[112] is I_Na_tot in component membrane (picoA_per_picoF). * ALGEBRAIC[94] is I_Cl_tot in component membrane (picoA_per_picoF). * ALGEBRAIC[113] is I_Ca_tot in component membrane (picoA_per_picoF). * ALGEBRAIC[114] is I_tot in component membrane (picoA_per_picoF). * ALGEBRAIC[0] is I_Stim in component membrane (picoA_per_picoF). * CONSTANTS[4] is I_Stim_Start in component membrane (millisecond). * CONSTANTS[5] is I_Stim_End in component membrane (millisecond). * CONSTANTS[6] is I_Stim_Amplitude in component membrane (picoA_per_picoF). * CONSTANTS[7] is I_Stim_Period in component membrane (millisecond). * CONSTANTS[8] is I_Stim_PulseDuration in component membrane (millisecond). * CONSTANTS[9] is F_junc in component membrane (dimensionless). * CONSTANTS[96] is F_sl in component membrane (dimensionless). * CONSTANTS[10] is F_junc_Ca_L in component membrane (dimensionless). * CONSTANTS[97] is F_sl_Ca_L in component membrane (dimensionless). * CONSTANTS[98] is V_cell in component membrane (litre). * CONSTANTS[11] is Length_cell in component membrane (decimetre). * CONSTANTS[12] is Radius_cell in component membrane (decimetre). * CONSTANTS[100] is V_myo in component membrane (litre). * CONSTANTS[103] is V_sl in component membrane (litre). * CONSTANTS[104] is V_sr in component membrane (litre). * CONSTANTS[105] is V_junc in component membrane (litre). * CONSTANTS[13] is J_Ca_juncsl in component membrane (L_per_millis). * CONSTANTS[14] is J_Ca_slmyo in component membrane (L_per_millis). * CONSTANTS[15] is J_Na_juncsl in component membrane (L_per_millis). * CONSTANTS[16] is J_Na_slmyo in component membrane (L_per_millis). * ALGEBRAIC[95] is I_Na_junc in component Fast_Na_Current (picoA_per_picoF). * ALGEBRAIC[96] is I_Na_sl in component Fast_Na_Current (picoA_per_picoF). * ALGEBRAIC[97] is I_Na in component Fast_Na_Current (picoA_per_picoF). * ALGEBRAIC[90] is E_Na_sl in component Nerst_Potentials (millivolt). * ALGEBRAIC[89] is E_Na_junc in component Nerst_Potentials (millivolt). * CONSTANTS[17] is G_Na in component Fast_Na_Current (milliS_per_microF). * STATES[1] is m in component Fast_Na_Current (dimensionless). * ALGEBRAIC[1] is m_ss in component Fast_Na_Current (dimensionless). * ALGEBRAIC[2] is tau_m in component Fast_Na_Current (millisecond). * ALGEBRAIC[3] is a_h in component Fast_Na_Current (dimensionless). * ALGEBRAIC[4] is b_h in component Fast_Na_Current (dimensionless). * ALGEBRAIC[7] is tau_h in component Fast_Na_Current (millisecond). * STATES[2] is h in component Fast_Na_Current (dimensionless). * ALGEBRAIC[8] is h_ss in component Fast_Na_Current (dimensionless). * ALGEBRAIC[5] is a_j in component Fast_Na_Current (dimensionless). * ALGEBRAIC[6] is b_j in component Fast_Na_Current (dimensionless). * ALGEBRAIC[9] is tau_j in component Fast_Na_Current (millisecond). * STATES[3] is j in component Fast_Na_Current (dimensionless). * ALGEBRAIC[10] is j_ss in component Fast_Na_Current (dimensionless). * ALGEBRAIC[98] is I_Na_Bk_junc in component Background_Na_Current (picoA_per_picoF). * ALGEBRAIC[99] is I_Na_Bk_sl in component Background_Na_Current (picoA_per_picoF). * ALGEBRAIC[100] is I_Na_Bk in component Background_Na_Current (picoA_per_picoF). * CONSTANTS[18] is G_Na_B in component Background_Na_Current (milliS_per_microF). * CONSTANTS[19] is Na_o in component Sodium_Concentrations (millimolar). * CONSTANTS[99] is sigma in component Na_K_Pump_Current (dimensionless). * ALGEBRAIC[11] is f_NaK in component Na_K_Pump_Current (dimensionless). * ALGEBRAIC[12] is I_NaK_junc in component Na_K_Pump_Current (picoA_per_picoF). * ALGEBRAIC[13] is I_NaK_sl in component Na_K_Pump_Current (picoA_per_picoF). * ALGEBRAIC[14] is I_NaK in component Na_K_Pump_Current (picoA_per_picoF). * CONSTANTS[20] is Ibar_NaK in component Na_K_Pump_Current (picoA_per_picoF). * CONSTANTS[21] is K_o in component Potassium_Concentrations (millimolar). * STATES[4] is Na_j in component Sodium_Concentrations (millimolar). * STATES[5] is Na_sl in component Sodium_Concentrations (millimolar). * CONSTANTS[22] is Km_Ko in component Na_K_Pump_Current (millimolar). * CONSTANTS[23] is Km_Naip in component Na_K_Pump_Current (millimolar). * ALGEBRAIC[15] is x_r_ss in component Rapidly_Activating_K_Current (dimensionless). * STATES[6] is x_Kr in component Rapidly_Activating_K_Current (dimensionless). * ALGEBRAIC[17] is r_Kr in component Rapidly_Activating_K_Current (dimensionless). * CONSTANTS[101] is E_K in component Nerst_Potentials (millivolt). * CONSTANTS[24] is G_Kr in component Rapidly_Activating_K_Current (milliS_per_microF). * ALGEBRAIC[16] is tau_xr in component Rapidly_Activating_K_Current (millisecond). * ALGEBRAIC[18] is I_Kr in component Rapidly_Activating_K_Current (picoA_per_picoF). * ALGEBRAIC[19] is x_s_ss in component Slowly_Activating_K_Current (dimensionless). * ALGEBRAIC[20] is tau_xs in component Slowly_Activating_K_Current (millisecond). * STATES[7] is x_Ks in component Slowly_Activating_K_Current (dimensionless). * ALGEBRAIC[91] is E_Ks in component Nerst_Potentials (millivolt). * CONSTANTS[25] is G_Ks_junc in component Slowly_Activating_K_Current (milliS_per_microF). * CONSTANTS[26] is G_Ks_sl in component Slowly_Activating_K_Current (milliS_per_microF). * ALGEBRAIC[101] is I_Ks_junc in component Slowly_Activating_K_Current (picoA_per_picoF). * ALGEBRAIC[102] is I_Ks_sl in component Slowly_Activating_K_Current (picoA_per_picoF). * ALGEBRAIC[103] is I_Ks in component Slowly_Activating_K_Current (picoA_per_picoF). * ALGEBRAIC[21] is kp_Kp in component Plateau_K_Current (dimensionless). * CONSTANTS[27] is G_Kp in component Plateau_K_Current (milliS_per_microF). * ALGEBRAIC[22] is I_Kp in component Plateau_K_Current (picoA_per_picoF). * ALGEBRAIC[23] is x_to_ss in component Transient_Outward_K_Current (dimensionless). * ALGEBRAIC[24] is y_to_ss in component Transient_Outward_K_Current (dimensionless). * ALGEBRAIC[25] is tau_x_tos in component Transient_Outward_K_Current (millisecond). * ALGEBRAIC[26] is tau_y_tos in component Transient_Outward_K_Current (millisecond). * ALGEBRAIC[27] is tau_x_tof in component Transient_Outward_K_Current (millisecond). * ALGEBRAIC[28] is tau_y_tof in component Transient_Outward_K_Current (millisecond). * STATES[8] is x_to_s in component Transient_Outward_K_Current (dimensionless). * STATES[9] is y_to_s in component Transient_Outward_K_Current (dimensionless). * STATES[10] is x_to_f in component Transient_Outward_K_Current (dimensionless). * STATES[11] is y_to_f in component Transient_Outward_K_Current (dimensionless). * CONSTANTS[28] is G_to_s in component Transient_Outward_K_Current (milliS_per_microF). * CONSTANTS[29] is G_to_f in component Transient_Outward_K_Current (milliS_per_microF). * ALGEBRAIC[29] is I_to_s in component Transient_Outward_K_Current (picoA_per_picoF). * ALGEBRAIC[30] is I_to_f in component Transient_Outward_K_Current (picoA_per_picoF). * ALGEBRAIC[31] is I_to in component Transient_Outward_K_Current (picoA_per_picoF). * ALGEBRAIC[32] is a_K1 in component Inward_Rectifier_K_Current (dimensionless). * ALGEBRAIC[33] is b_K1 in component Inward_Rectifier_K_Current (dimensionless). * ALGEBRAIC[34] is K1_ss in component Inward_Rectifier_K_Current (dimensionless). * ALGEBRAIC[35] is I_K1 in component Inward_Rectifier_K_Current (picoA_per_picoF). * CONSTANTS[30] is G_K1 in component Inward_Rectifier_K_Current (milliS_per_microF). * ALGEBRAIC[36] is I_ClCa_junc in component Ca_Activated_Cl_Current (picoA_per_picoF). * ALGEBRAIC[37] is I_ClCa_sl in component Ca_Activated_Cl_Current (picoA_per_picoF). * STATES[12] is Ca_j in component Calcium_Concentrations (millimolar). * STATES[13] is Ca_sl in component Calcium_Concentrations (millimolar). * CONSTANTS[102] is E_Cl in component Nerst_Potentials (millivolt). * CONSTANTS[31] is G_ClCa in component Ca_Activated_Cl_Current (milliS_per_microF). * CONSTANTS[32] is Kd_ClCa in component Ca_Activated_Cl_Current (millimolar). * CONSTANTS[33] is G_Cl_B in component Background_Cl_Current (milliS_per_microF). * ALGEBRAIC[40] is d_ss in component L_Type_Calcium_Current (dimensionless). * ALGEBRAIC[41] is alpha_d in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[42] is beta_d in component L_Type_Calcium_Current (dimensionless). * ALGEBRAIC[43] is gamma_d in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[44] is tau_d in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[45] is f_ss in component L_Type_Calcium_Current (dimensionless). * ALGEBRAIC[46] is alpha_f in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[47] is beta_f in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[48] is gamma_f in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[49] is tau_f in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[50] is f_2_ss in component L_Type_Calcium_Current (dimensionless). * ALGEBRAIC[51] is alpha_f_2 in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[52] is beta_f_2 in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[53] is gamma_f_2 in component L_Type_Calcium_Current (millisecond). * ALGEBRAIC[54] is tau_f_2 in component L_Type_Calcium_Current (millisecond). * STATES[14] is d in component L_Type_Calcium_Current (dimensionless). * STATES[15] is f in component L_Type_Calcium_Current (dimensionless). * STATES[16] is f_2 in component L_Type_Calcium_Current (dimensionless). * STATES[17] is f_Ca_B_j in component L_Type_Calcium_Current (dimensionless). * STATES[18] is f_Ca_B_sl in component L_Type_Calcium_Current (dimensionless). * CONSTANTS[34] is K_i in component Potassium_Concentrations (millimolar). * CONSTANTS[35] is Ca_o in component Calcium_Concentrations (millimolar). * ALGEBRAIC[55] is Ibar_Ca_j in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[56] is Ibar_Ca_sl in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[57] is Ibar_K in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[58] is Ibar_Na_j in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[59] is Ibar_Na_sl in component L_Type_Calcium_Current (picoA_per_picoF). * CONSTANTS[36] is p_Ca in component L_Type_Calcium_Current (litre_per_farad_millisecond). * CONSTANTS[37] is p_Na in component L_Type_Calcium_Current (litre_per_farad_millisecond). * CONSTANTS[38] is p_K in component L_Type_Calcium_Current (litre_per_farad_millisecond). * ALGEBRAIC[60] is I_Ca_junc in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[61] is I_Ca_sl in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[62] is I_Ca in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[64] is I_Ca_Na_junc in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[65] is I_Ca_Na_sl in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[66] is I_Ca_Na in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[63] is I_Ca_K in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[67] is I_Ca_L in component L_Type_Calcium_Current (picoA_per_picoF). * ALGEBRAIC[68] is Ka_junc in component Na_Ca_Exchanger_Current (dimensionless). * ALGEBRAIC[69] is Ka_sl in component Na_Ca_Exchanger_Current (dimensionless). * CONSTANTS[39] is Kd_act in component Na_Ca_Exchanger_Current (millimolar). * CONSTANTS[40] is Km_Ca_i in component Na_Ca_Exchanger_Current (millimolar). * CONSTANTS[41] is Km_Ca_o in component Na_Ca_Exchanger_Current (millimolar). * CONSTANTS[42] is Km_Na_i in component Na_Ca_Exchanger_Current (millimolar). * CONSTANTS[43] is Km_Na_o in component Na_Ca_Exchanger_Current (millimolar). * CONSTANTS[44] is k_sat in component Na_Ca_Exchanger_Current (dimensionless). * CONSTANTS[45] is nu in component Na_Ca_Exchanger_Current (dimensionless). * ALGEBRAIC[70] is s1_junc in component Na_Ca_Exchanger_Current (millimolar4). * ALGEBRAIC[72] is s2_junc in component Na_Ca_Exchanger_Current (millimolar4). * ALGEBRAIC[74] is s3_junc in component Na_Ca_Exchanger_Current (millimolar4). * ALGEBRAIC[71] is s1_sl in component Na_Ca_Exchanger_Current (millimolar4). * ALGEBRAIC[73] is s2_sl in component Na_Ca_Exchanger_Current (millimolar4). * ALGEBRAIC[75] is s3_sl in component Na_Ca_Exchanger_Current (millimolar4). * CONSTANTS[46] is Ibar_NCX in component Na_Ca_Exchanger_Current (picoA_per_picoF). * ALGEBRAIC[77] is I_ncx_sl in component Na_Ca_Exchanger_Current (picoA_per_picoF). * ALGEBRAIC[76] is I_ncx_junc in component Na_Ca_Exchanger_Current (picoA_per_picoF). * ALGEBRAIC[78] is I_ncx in component Na_Ca_Exchanger_Current (picoA_per_picoF). * CONSTANTS[47] is Km_P_Ca in component Sarcolemmal_Ca_Pump_Current (millimolar). * CONSTANTS[48] is Ibar_PMCA in component Sarcolemmal_Ca_Pump_Current (picoA_per_picoF). * ALGEBRAIC[79] is I_pCa_junc in component Sarcolemmal_Ca_Pump_Current (picoA_per_picoF). * ALGEBRAIC[80] is I_pCa_sl in component Sarcolemmal_Ca_Pump_Current (picoA_per_picoF). * ALGEBRAIC[81] is I_pCa in component Sarcolemmal_Ca_Pump_Current (picoA_per_picoF). * ALGEBRAIC[93] is E_Ca_sl in component Nerst_Potentials (millivolt). * ALGEBRAIC[92] is E_Ca_junc in component Nerst_Potentials (millivolt). * CONSTANTS[49] is G_Ca_B in component Background_Ca_Current (milliS_per_microF). * ALGEBRAIC[105] is I_Ca_Bk_sl in component Background_Ca_Current (picoA_per_picoF). * ALGEBRAIC[104] is I_Ca_Bk_junc in component Background_Ca_Current (picoA_per_picoF). * ALGEBRAIC[106] is I_Ca_Bk in component Background_Ca_Current (picoA_per_picoF). * CONSTANTS[50] is Max_SR in component SR_Fluxes (dimensionless). * CONSTANTS[51] is Min_SR in component SR_Fluxes (dimensionless). * STATES[19] is Ca_SR in component Calcium_Concentrations (millimolar). * CONSTANTS[52] is ec50_SR in component SR_Fluxes (millimolar). * ALGEBRAIC[82] is k_Ca_SR in component SR_Fluxes (dimensionless). * CONSTANTS[53] is ko_Ca in component SR_Fluxes (per_milliM2_per_millis). * ALGEBRAIC[83] is ko_SR_Ca in component SR_Fluxes (per_milliM2_per_millis). * CONSTANTS[54] is ki_Ca in component SR_Fluxes (per_milliM_per_millis). * ALGEBRAIC[84] is ki_SR_Ca in component SR_Fluxes (per_milliM_per_millis). * CONSTANTS[55] is ki_m in component SR_Fluxes (per_millis). * CONSTANTS[56] is ko_m in component SR_Fluxes (per_millis). * CONSTANTS[57] is ks in component SR_Fluxes (per_millis). * CONSTANTS[58] is Km_f in component SR_Fluxes (millimolar). * CONSTANTS[59] is Km_r in component SR_Fluxes (millimolar). * ALGEBRAIC[86] is J_SR_Ca_rel in component SR_Fluxes (milliM_per_millis). * ALGEBRAIC[88] is J_SR_leak in component SR_Fluxes (milliM_per_millis). * ALGEBRAIC[87] is J_ser_Ca in component SR_Fluxes (milliM_per_millis). * ALGEBRAIC[85] is RI in component SR_Fluxes (dimensionless). * STATES[20] is Ry_Rr in component SR_Fluxes (dimensionless). * STATES[21] is Ry_Ro in component SR_Fluxes (dimensionless). * STATES[22] is Ry_Ri in component SR_Fluxes (dimensionless). * STATES[23] is Ca_i in component Calcium_Concentrations (millimolar). * CONSTANTS[60] is V_max_SR_CaP in component SR_Fluxes (milliM_per_millis). * CONSTANTS[61] is hill_SR_CaP in component SR_Fluxes (dimensionless). * CONSTANTS[62] is Mg_i in component Magnesium_Concentrations (millimolar). * STATES[24] is TnC_l in component Cytosolic_Ca_Buffers (millimolar). * STATES[25] is TnC_h_c in component Cytosolic_Ca_Buffers (millimolar). * STATES[26] is TnC_h_m in component Cytosolic_Ca_Buffers (millimolar). * STATES[27] is CaM in component Cytosolic_Ca_Buffers (millimolar). * STATES[28] is Myo_c in component Cytosolic_Ca_Buffers (millimolar). * STATES[29] is Myo_m in component Cytosolic_Ca_Buffers (millimolar). * STATES[30] is SRB in component Cytosolic_Ca_Buffers (millimolar). * CONSTANTS[63] is k_off_TnC_l in component Cytosolic_Ca_Buffers (per_millis). * CONSTANTS[64] is k_off_TnC_h_Ca in component Cytosolic_Ca_Buffers (per_millis). * CONSTANTS[65] is k_off_TnC_h_Mg in component Cytosolic_Ca_Buffers (per_millis). * CONSTANTS[66] is k_off_CaM in component Cytosolic_Ca_Buffers (per_millis). * CONSTANTS[67] is k_off_myo_Ca in component Cytosolic_Ca_Buffers (per_millis). * CONSTANTS[68] is k_off_myo_Mg in component Cytosolic_Ca_Buffers (per_millis). * CONSTANTS[69] is k_off_SR in component Cytosolic_Ca_Buffers (per_millis). * CONSTANTS[70] is k_on_TnC_l in component Cytosolic_Ca_Buffers (per_milliM_per_millis). * CONSTANTS[71] is k_on_TnC_h_Ca in component Cytosolic_Ca_Buffers (per_milliM_per_millis). * CONSTANTS[72] is k_on_TnC_h_Mg in component Cytosolic_Ca_Buffers (per_milliM_per_millis). * CONSTANTS[73] is k_on_CaM in component Cytosolic_Ca_Buffers (per_milliM_per_millis). * CONSTANTS[74] is k_on_myo_Ca in component Cytosolic_Ca_Buffers (per_milliM_per_millis). * CONSTANTS[75] is k_on_myo_Mg in component Cytosolic_Ca_Buffers (per_milliM_per_millis). * CONSTANTS[76] is k_on_SR in component Cytosolic_Ca_Buffers (per_milliM_per_millis). * CONSTANTS[77] is B_max_TnC_low in component Cytosolic_Ca_Buffers (millimolar). * CONSTANTS[78] is B_max_TnC_high in component Cytosolic_Ca_Buffers (millimolar). * CONSTANTS[79] is B_max_CaM in component Cytosolic_Ca_Buffers (millimolar). * CONSTANTS[80] is B_max_myosin in component Cytosolic_Ca_Buffers (millimolar). * CONSTANTS[81] is B_max_SR in component Cytosolic_Ca_Buffers (millimolar). * STATES[39] is J_Ca_B_cytosol in component Cytosolic_Ca_Buffers (milliM_per_millis). * CONSTANTS[106] is B_max_SL_low_j in component Junctional_and_SL_Ca_Buffers (millimolar). * CONSTANTS[107] is B_max_SL_low_sl in component Junctional_and_SL_Ca_Buffers (millimolar). * CONSTANTS[108] is B_max_SL_high_j in component Junctional_and_SL_Ca_Buffers (millimolar). * CONSTANTS[109] is B_max_SL_high_sl in component Junctional_and_SL_Ca_Buffers (millimolar). * CONSTANTS[82] is k_off_sl_l in component Junctional_and_SL_Ca_Buffers (per_millis). * CONSTANTS[83] is k_off_sl_h in component Junctional_and_SL_Ca_Buffers (per_millis). * CONSTANTS[84] is k_on_sl_l in component Junctional_and_SL_Ca_Buffers (per_milliM_per_millis). * CONSTANTS[85] is k_on_sl_h in component Junctional_and_SL_Ca_Buffers (per_milliM_per_millis). * STATES[31] is SLL_j in component Junctional_and_SL_Ca_Buffers (millimolar). * STATES[32] is SLL_sl in component Junctional_and_SL_Ca_Buffers (millimolar). * STATES[33] is SLH_j in component Junctional_and_SL_Ca_Buffers (millimolar). * STATES[34] is SLH_sl in component Junctional_and_SL_Ca_Buffers (millimolar). * STATES[40] is J_Ca_B_junction in component Junctional_and_SL_Ca_Buffers (milliM_per_millis). * STATES[41] is J_Ca_B_sl in component Junctional_and_SL_Ca_Buffers (milliM_per_millis). * CONSTANTS[86] is B_max_Na_j in component Sodium_Concentrations (millimolar). * CONSTANTS[87] is B_max_Na_sl in component Sodium_Concentrations (millimolar). * CONSTANTS[88] is k_off_Na in component Sodium_Concentrations (per_millis). * CONSTANTS[89] is k_on_Na in component Sodium_Concentrations (per_milliM_per_millis). * STATES[35] is Na_i in component Sodium_Concentrations (millimolar). * STATES[36] is Na_B_j in component Sodium_Concentrations (millimolar). * STATES[37] is Na_B_sl in component Sodium_Concentrations (millimolar). * CONSTANTS[110] is B_max_csqn in component Calcium_Concentrations (millimolar). * STATES[38] is Csqn_b in component Calcium_Concentrations (millimolar). * CONSTANTS[90] is k_off_csqn in component Calcium_Concentrations (per_millis). * CONSTANTS[91] is k_on_csqn in component Calcium_Concentrations (per_milliM_per_millis). * CONSTANTS[92] is Cl_i in component Chlorine_Concentrations (millimolar). * CONSTANTS[93] is Cl_o in component Chlorine_Concentrations (millimolar). * CONSTANTS[94] is p_Na_K in component Nerst_Potentials (dimensionless). * RATES[0] is d/dt V in component membrane (millivolt). * RATES[1] is d/dt m in component Fast_Na_Current (dimensionless). * RATES[2] is d/dt h in component Fast_Na_Current (dimensionless). * RATES[3] is d/dt j in component Fast_Na_Current (dimensionless). * RATES[6] is d/dt x_Kr in component Rapidly_Activating_K_Current (dimensionless). * RATES[7] is d/dt x_Ks in component Slowly_Activating_K_Current (dimensionless). * RATES[8] is d/dt x_to_s in component Transient_Outward_K_Current (dimensionless). * RATES[9] is d/dt y_to_s in component Transient_Outward_K_Current (dimensionless). * RATES[10] is d/dt x_to_f in component Transient_Outward_K_Current (dimensionless). * RATES[11] is d/dt y_to_f in component Transient_Outward_K_Current (dimensionless). * RATES[14] is d/dt d in component L_Type_Calcium_Current (dimensionless). * RATES[15] is d/dt f in component L_Type_Calcium_Current (dimensionless). * RATES[16] is d/dt f_2 in component L_Type_Calcium_Current (dimensionless). * RATES[17] is d/dt f_Ca_B_j in component L_Type_Calcium_Current (dimensionless). * RATES[18] is d/dt f_Ca_B_sl in component L_Type_Calcium_Current (dimensionless). * RATES[20] is d/dt Ry_Rr in component SR_Fluxes (dimensionless). * RATES[21] is d/dt Ry_Ro in component SR_Fluxes (dimensionless). * RATES[22] is d/dt Ry_Ri in component SR_Fluxes (dimensionless). * RATES[24] is d/dt TnC_l in component Cytosolic_Ca_Buffers (millimolar). * RATES[25] is d/dt TnC_h_c in component Cytosolic_Ca_Buffers (millimolar). * RATES[26] is d/dt TnC_h_m in component Cytosolic_Ca_Buffers (millimolar). * RATES[27] is d/dt CaM in component Cytosolic_Ca_Buffers (millimolar). * RATES[28] is d/dt Myo_c in component Cytosolic_Ca_Buffers (millimolar). * RATES[29] is d/dt Myo_m in component Cytosolic_Ca_Buffers (millimolar). * RATES[30] is d/dt SRB in component Cytosolic_Ca_Buffers (millimolar). * RATES[31] is d/dt SLL_j in component Junctional_and_SL_Ca_Buffers (millimolar). * RATES[32] is d/dt SLL_sl in component Junctional_and_SL_Ca_Buffers (millimolar). * RATES[33] is d/dt SLH_j in component Junctional_and_SL_Ca_Buffers (millimolar). * RATES[34] is d/dt SLH_sl in component Junctional_and_SL_Ca_Buffers (millimolar). * RATES[4] is d/dt Na_j in component Sodium_Concentrations (millimolar). * RATES[36] is d/dt Na_B_j in component Sodium_Concentrations (millimolar). * RATES[5] is d/dt Na_sl in component Sodium_Concentrations (millimolar). * RATES[37] is d/dt Na_B_sl in component Sodium_Concentrations (millimolar). * RATES[35] is d/dt Na_i in component Sodium_Concentrations (millimolar). * RATES[38] is d/dt Csqn_b in component Calcium_Concentrations (millimolar). * RATES[12] is d/dt Ca_j in component Calcium_Concentrations (millimolar). * RATES[13] is d/dt Ca_sl in component Calcium_Concentrations (millimolar). * RATES[23] is d/dt Ca_i in component Calcium_Concentrations (millimolar). * RATES[19] is d/dt Ca_SR in component Calcium_Concentrations (millimolar). * There are a total of 7 condition variables. */ void initConsts(double* CONSTANTS, double* RATES, double *STATES) { STATES[0] = -8.410546e1; CONSTANTS[0] = 8314; CONSTANTS[1] = 310; CONSTANTS[2] = 96485; CONSTANTS[3] = 1.381e-10; CONSTANTS[4] = 0; CONSTANTS[5] = 100000; CONSTANTS[6] = 40; CONSTANTS[7] = 1000; CONSTANTS[8] = 1; CONSTANTS[9] = 0.11; CONSTANTS[10] = 0.9; CONSTANTS[11] = 100e-5; CONSTANTS[12] = 10.25e-5; CONSTANTS[13] = 8.2413e-13; CONSTANTS[14] = 3.7243e-12; CONSTANTS[15] = 1.8313e-14; CONSTANTS[16] = 1.6386e-12; CONSTANTS[17] = 18.86; STATES[1] = 2.176608e-3; STATES[2] = 7.126555e-1; STATES[3] = 7.119893e-1; CONSTANTS[18] = 0.597e-3; CONSTANTS[19] = 140; CONSTANTS[20] = 0.99; CONSTANTS[21] = 5.4; STATES[4] = 1.00211e1; STATES[5] = 1.001974e1; CONSTANTS[22] = 1.5; CONSTANTS[23] = 11; STATES[6] = 1.896559e-2; CONSTANTS[24] = 0.035; STATES[7] = 3.55636e-3; CONSTANTS[25] = 0.0035; CONSTANTS[26] = 0.0035; CONSTANTS[27] = 0.002; STATES[8] = 3.592503e-4; STATES[9] = 8.161309e-1; STATES[10] = 3.592405e-4; STATES[11] = 9.999976e-1; CONSTANTS[28] = 3.7596e-2; CONSTANTS[29] = 1.404e-3; CONSTANTS[30] = 0.57153; STATES[12] = 2.048633e-4; STATES[13] = 1.188246e-4; CONSTANTS[31] = 0.054813; CONSTANTS[32] = 100e-3; CONSTANTS[33] = 9e-3; STATES[14] = 1.879996e-6; STATES[15] = 9.789409e-1; STATES[16] = 9.993986e-1; STATES[17] = 2.861794e-2; STATES[18] = 1.69833e-2; CONSTANTS[34] = 138; CONSTANTS[35] = 1.8; CONSTANTS[36] = 1.9887e-4; CONSTANTS[37] = 3.0375e-9; CONSTANTS[38] = 5.4675e-8; CONSTANTS[39] = 0.15e-3; CONSTANTS[40] = 3.59e-3; CONSTANTS[41] = 1.3; CONSTANTS[42] = 12.29; CONSTANTS[43] = 87.5; CONSTANTS[44] = 0.32; CONSTANTS[45] = 0.27; CONSTANTS[46] = 4.5; CONSTANTS[47] = 0.5e-3; CONSTANTS[48] = 0.0673; CONSTANTS[49] = 5.513e-4; CONSTANTS[50] = 15; CONSTANTS[51] = 1; STATES[19] = 6.138856e-1; CONSTANTS[52] = 0.45; CONSTANTS[53] = 10; CONSTANTS[54] = 0.5; CONSTANTS[55] = 0.005; CONSTANTS[56] = 0.06; CONSTANTS[57] = 25; CONSTANTS[58] = 0.246e-3; CONSTANTS[59] = 1.7; STATES[20] = 8.888214e-1; STATES[21] = 1.149876e-6; STATES[22] = 1.43831e-7; STATES[23] = 9.719632e-5; CONSTANTS[60] = 5.3114e-3; CONSTANTS[61] = 1.787; CONSTANTS[62] = 1; STATES[24] = 9.811535e-3; STATES[25] = 1.225802e-1; STATES[26] = 8.128604e-3; STATES[27] = 3.288063e-4; STATES[28] = 2.522168e-3; STATES[29] = 1.369514e-1; STATES[30] = 2.38683e-3; CONSTANTS[63] = 19.6e-3; CONSTANTS[64] = 0.032e-3; CONSTANTS[65] = 3.33e-3; CONSTANTS[66] = 238e-3; CONSTANTS[67] = 0.46e-3; CONSTANTS[68] = 0.057e-3; CONSTANTS[69] = 60e-3; CONSTANTS[70] = 32.7; CONSTANTS[71] = 2.37; CONSTANTS[72] = 3e-3; CONSTANTS[73] = 34; CONSTANTS[74] = 13.8; CONSTANTS[75] = 0.0157; CONSTANTS[76] = 100; CONSTANTS[77] = 70e-3; CONSTANTS[78] = 140e-3; CONSTANTS[79] = 24e-3; CONSTANTS[80] = 140e-3; CONSTANTS[81] = 17.1e-3; CONSTANTS[82] = 1.3; CONSTANTS[83] = 30e-3; CONSTANTS[84] = 100; CONSTANTS[85] = 100; STATES[31] = 8.606485e-3; STATES[32] = 1.101044e-2; STATES[33] = 8.078504e-2; STATES[34] = 1.238366e-1; CONSTANTS[86] = 7.561; CONSTANTS[87] = 1.65; CONSTANTS[88] = 1e-3; CONSTANTS[89] = 0.1e-3; STATES[35] = 1.001989e1; STATES[36] = 3.785209e0; STATES[37] = 8.259271e-1; STATES[38] = 1.262853; CONSTANTS[90] = 65; CONSTANTS[91] = 100; CONSTANTS[92] = 15; CONSTANTS[93] = 150; CONSTANTS[94] = 0.01833; CONSTANTS[95] = CONSTANTS[2]/( CONSTANTS[0]*CONSTANTS[1]); CONSTANTS[96] = 1.00000 - CONSTANTS[9]; CONSTANTS[97] = 1.00000 - CONSTANTS[10]; CONSTANTS[98] = 3.14159265358979*pow(CONSTANTS[12], 2.00000)*CONSTANTS[11]; CONSTANTS[99] = (exp(CONSTANTS[19]/67.3000) - 1.00000)/7.00000; CONSTANTS[100] = 0.650000*CONSTANTS[98]; CONSTANTS[101] = (1.00000/CONSTANTS[95])*log(CONSTANTS[21]/CONSTANTS[34]); CONSTANTS[102] = (1.00000/CONSTANTS[95])*log(CONSTANTS[92]/CONSTANTS[93]); CONSTANTS[103] = 0.0200000*CONSTANTS[98]; CONSTANTS[104] = 0.0350000*CONSTANTS[98]; CONSTANTS[105] = 0.000539000*CONSTANTS[98]; CONSTANTS[106] = ( 0.000460000*CONSTANTS[100])/CONSTANTS[105]; CONSTANTS[107] = ( 0.0374000*CONSTANTS[100])/CONSTANTS[103]; CONSTANTS[108] = ( 0.000165000*CONSTANTS[100])/CONSTANTS[105]; CONSTANTS[109] = ( 0.0134000*CONSTANTS[100])/CONSTANTS[103]; CONSTANTS[110] = ( 0.140000*CONSTANTS[100])/CONSTANTS[104]; STATES[39] = 0.1001; STATES[40] = 0.1001; STATES[41] = 0.1001; RATES[0] = 0.1001; RATES[1] = 0.1001; RATES[2] = 0.1001; RATES[3] = 0.1001; RATES[6] = 0.1001; RATES[7] = 0.1001; RATES[8] = 0.1001; RATES[9] = 0.1001; RATES[10] = 0.1001; RATES[11] = 0.1001; RATES[14] = 0.1001; RATES[15] = 0.1001; RATES[16] = 0.1001; RATES[17] = 0.1001; RATES[18] = 0.1001; RATES[20] = 0.1001; RATES[21] = 0.1001; RATES[22] = 0.1001; RATES[24] = 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[32] = 0.1001; RATES[33] = 0.1001; RATES[34] = 0.1001; RATES[4] = 0.1001; RATES[36] = 0.1001; RATES[5] = 0.1001; RATES[37] = 0.1001; RATES[35] = 0.1001; RATES[38] = 0.1001; RATES[12] = 0.1001; RATES[13] = 0.1001; RATES[23] = 0.1001; RATES[19] = 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[114] - ALGEBRAIC[0]); resid[1] = RATES[1] - (ALGEBRAIC[1] - STATES[1])/ALGEBRAIC[2]; resid[2] = RATES[2] - (ALGEBRAIC[8] - STATES[2])/ALGEBRAIC[7]; resid[3] = RATES[3] - (ALGEBRAIC[10] - STATES[3])/ALGEBRAIC[9]; resid[4] = RATES[6] - (ALGEBRAIC[15] - STATES[6])/ALGEBRAIC[16]; resid[5] = RATES[7] - (ALGEBRAIC[19] - STATES[7])/ALGEBRAIC[20]; resid[6] = RATES[8] - (ALGEBRAIC[23] - STATES[8])/ALGEBRAIC[25]; resid[7] = RATES[9] - (ALGEBRAIC[24] - STATES[9])/ALGEBRAIC[26]; resid[8] = RATES[10] - (ALGEBRAIC[23] - STATES[10])/ALGEBRAIC[27]; resid[9] = RATES[11] - (ALGEBRAIC[24] - STATES[11])/ALGEBRAIC[28]; resid[10] = RATES[14] - (ALGEBRAIC[40] - STATES[14])/ALGEBRAIC[44]; resid[11] = RATES[15] - (ALGEBRAIC[45] - STATES[15])/ALGEBRAIC[49]; resid[12] = RATES[16] - (ALGEBRAIC[50] - STATES[16])/ALGEBRAIC[54]; resid[13] = RATES[17] - 1.70000*STATES[12]*(1.00000 - STATES[17]) - 0.0119000*STATES[17]; resid[14] = RATES[18] - 1.70000*STATES[13]*(1.00000 - STATES[18]) - 0.0119000*STATES[18]; resid[15] = RATES[20] - ( CONSTANTS[55]*ALGEBRAIC[85] - ALGEBRAIC[84]*STATES[12]*STATES[20]) - ( ALGEBRAIC[83]*pow(STATES[12], 2.00000)*STATES[20] - CONSTANTS[56]*STATES[21]); resid[16] = RATES[21] - ( ALGEBRAIC[83]*pow(STATES[12], 2.00000)*STATES[20] - CONSTANTS[56]*STATES[21]) - ( ALGEBRAIC[84]*STATES[12]*STATES[21] - CONSTANTS[55]*STATES[22]); resid[17] = RATES[22] - ( ALGEBRAIC[84]*STATES[12]*STATES[21] - CONSTANTS[55]*STATES[22]) - ( CONSTANTS[56]*STATES[22] - ALGEBRAIC[83]*pow(STATES[12], 2.00000)*ALGEBRAIC[85]); resid[18] = RATES[24] - CONSTANTS[70]*STATES[23]*(CONSTANTS[77] - STATES[24]) - CONSTANTS[63]*STATES[24]; resid[19] = RATES[25] - CONSTANTS[71]*STATES[23]*((CONSTANTS[78] - STATES[25]) - STATES[26]) - CONSTANTS[64]*STATES[25]; resid[20] = RATES[26] - CONSTANTS[72]*CONSTANTS[62]*((CONSTANTS[78] - STATES[25]) - STATES[26]) - CONSTANTS[65]*STATES[26]; resid[21] = RATES[27] - CONSTANTS[73]*STATES[23]*(CONSTANTS[79] - STATES[27]) - CONSTANTS[66]*STATES[27]; resid[22] = RATES[28] - CONSTANTS[74]*STATES[23]*((CONSTANTS[80] - STATES[28]) - STATES[29]) - CONSTANTS[67]*STATES[28]; resid[23] = RATES[29] - CONSTANTS[75]*CONSTANTS[62]*((CONSTANTS[80] - STATES[28]) - STATES[29]) - CONSTANTS[68]*STATES[29]; resid[24] = RATES[30] - CONSTANTS[76]*STATES[23]*(CONSTANTS[81] - STATES[30]) - CONSTANTS[69]*STATES[30]; resid[25] = STATES[39] - RATES[24]+RATES[25]+RATES[26]+RATES[27]+RATES[28]+RATES[29]+RATES[30]; resid[26] = RATES[31] - CONSTANTS[84]*STATES[12]*(CONSTANTS[106] - STATES[31]) - CONSTANTS[82]*STATES[31]; resid[27] = RATES[32] - CONSTANTS[84]*STATES[13]*(CONSTANTS[107] - STATES[32]) - CONSTANTS[82]*STATES[32]; resid[28] = RATES[33] - CONSTANTS[85]*STATES[12]*(CONSTANTS[108] - STATES[33]) - CONSTANTS[83]*STATES[33]; resid[29] = RATES[34] - CONSTANTS[85]*STATES[13]*(CONSTANTS[109] - STATES[34]) - CONSTANTS[83]*STATES[34]; resid[30] = STATES[40] - RATES[31]+RATES[33]; resid[31] = STATES[41] - RATES[32]+RATES[34]; resid[32] = RATES[4] - (( - ALGEBRAIC[107]*CONSTANTS[3])/( CONSTANTS[105]*CONSTANTS[2])+ (CONSTANTS[15]/CONSTANTS[105])*(STATES[5] - STATES[4])) - RATES[36]; resid[33] = RATES[5] - (( - ALGEBRAIC[108]*CONSTANTS[3])/( CONSTANTS[103]*CONSTANTS[2])+ (CONSTANTS[15]/CONSTANTS[103])*(STATES[4] - STATES[5])+ (CONSTANTS[16]/CONSTANTS[103])*(STATES[35] - STATES[5])) - RATES[37]; resid[34] = RATES[35] - (CONSTANTS[16]/CONSTANTS[100])*(STATES[5] - STATES[35]); resid[35] = RATES[36] - CONSTANTS[89]*STATES[4]*(CONSTANTS[86] - STATES[36]) - CONSTANTS[88]*STATES[36]; resid[36] = RATES[37] - CONSTANTS[89]*STATES[5]*(CONSTANTS[87] - STATES[37]) - CONSTANTS[88]*STATES[37]; resid[37] = RATES[38] - CONSTANTS[91]*STATES[19]*(CONSTANTS[110] - STATES[38]) - CONSTANTS[90]*STATES[38]; resid[38] = RATES[12] - ((( - ALGEBRAIC[110]*CONSTANTS[3])/( CONSTANTS[105]*2.00000*CONSTANTS[2])+ (CONSTANTS[13]/CONSTANTS[105])*(STATES[13] - STATES[12])) - STATES[40])+( ALGEBRAIC[86]*CONSTANTS[104])/CONSTANTS[105]+( ALGEBRAIC[88]*CONSTANTS[100])/CONSTANTS[105]; resid[39] = RATES[13] - (( - ALGEBRAIC[111]*CONSTANTS[3])/( CONSTANTS[103]*2.00000*CONSTANTS[2])+ (CONSTANTS[13]/CONSTANTS[103])*(STATES[12] - STATES[13])+ (CONSTANTS[14]/CONSTANTS[103])*(STATES[23] - STATES[13])) - STATES[41]; resid[40] = RATES[23] - (( - ALGEBRAIC[87]*CONSTANTS[104])/CONSTANTS[100] - STATES[39])+ (CONSTANTS[14]/CONSTANTS[100])*(STATES[13] - STATES[23]); resid[41] = RATES[19] - (ALGEBRAIC[87] - (( ALGEBRAIC[88]*CONSTANTS[100])/CONSTANTS[104]+ALGEBRAIC[86])) - RATES[38]; } void computeVariables(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC) { ALGEBRAIC[62] = ALGEBRAIC[60]+ALGEBRAIC[61]; ALGEBRAIC[66] = ALGEBRAIC[64]+ALGEBRAIC[65]; ALGEBRAIC[67] = ALGEBRAIC[62]+ALGEBRAIC[63]+ALGEBRAIC[66]; ALGEBRAIC[78] = ALGEBRAIC[76]+ALGEBRAIC[77]; ALGEBRAIC[81] = ALGEBRAIC[79]+ALGEBRAIC[80]; ALGEBRAIC[97] = ALGEBRAIC[95]+ALGEBRAIC[96]; ALGEBRAIC[100] = ALGEBRAIC[98]+ALGEBRAIC[99]; ALGEBRAIC[106] = ALGEBRAIC[104]+ALGEBRAIC[105]; } void computeEssentialVariables(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC) { ALGEBRAIC[0] = (CONDVAR[0]>=0.00000&&CONDVAR[1]<=0.00000&&CONDVAR[2]<=0.00000 ? CONSTANTS[6] : 0.00000); ALGEBRAIC[1] = 1.00000/pow(1.00000+exp(- (56.8600+STATES[0])/9.03000), 2.00000); ALGEBRAIC[2] = 0.129200*exp(- pow((STATES[0]+45.7900)/15.5400, 2.00000))+ 0.0648700*exp(- pow((STATES[0] - 4.82300)/51.1200, 2.00000)); ALGEBRAIC[3] = (CONDVAR[3]>=0.00000 ? 0.00000 : 0.0570000*exp(- (STATES[0]+80.0000)/6.80000)); ALGEBRAIC[4] = (CONDVAR[4]>=0.00000 ? 5.92310/(1.00000+exp(- (STATES[0]+10.6600)/11.1000)) : 2.70000*exp( 0.0790000*STATES[0])+ 310000.*exp( 0.348500*STATES[0])); ALGEBRAIC[7] = 1.00000/(ALGEBRAIC[3]+ALGEBRAIC[4]); ALGEBRAIC[8] = 1.00000/pow(1.00000+exp((STATES[0]+71.5500)/7.43000), 2.00000); ALGEBRAIC[5] = (CONDVAR[5]>=0.00000 ? 0.00000 : ( ( - 25428.0*exp( 0.244400*STATES[0]) - 6.94800e-06*exp( - 0.0439100*STATES[0]))*(STATES[0]+37.7800))/(1.00000+exp( 0.311000*(STATES[0]+79.2300)))); ALGEBRAIC[6] = (CONDVAR[6]>=0.00000 ? ( 0.600000*exp( 0.0570000*STATES[0]))/(1.00000+exp( - 0.100000*(STATES[0]+32.0000))) : ( 0.0242400*exp( - 0.0105200*STATES[0]))/(1.00000+exp( - 0.137800*(STATES[0]+40.1400)))); ALGEBRAIC[9] = 1.00000/(ALGEBRAIC[5]+ALGEBRAIC[6]); ALGEBRAIC[10] = 1.00000/pow(1.00000+exp((STATES[0]+71.5500)/7.43000), 2.00000); ALGEBRAIC[15] = 1.00000/(1.00000+exp(- (STATES[0]+10.0000)/5.00000)); ALGEBRAIC[16] = 3300.00/( (1.00000+exp((- 22.0000 - STATES[0])/9.00000))*(1.00000+exp((STATES[0]+11.0000)/9.00000)))+230.000/(1.00000+exp((STATES[0]+40.0000)/20.0000)); ALGEBRAIC[19] = 1.00000/(1.00000+exp(- (STATES[0]+3.80000)/14.2500)); ALGEBRAIC[20] = 990.100/(1.00000+exp(- (STATES[0]+2.43600)/14.1200)); ALGEBRAIC[23] = 1.00000/(1.00000+exp(- (STATES[0] - 19.0000)/13.0000)); ALGEBRAIC[24] = 1.00000/(1.00000+exp((STATES[0]+19.5000)/5.00000)); ALGEBRAIC[25] = 9.00000/(1.00000+exp((STATES[0]+3.00000)/15.0000))+0.500000; ALGEBRAIC[26] = 800.000/(1.00000+exp((STATES[0]+60.0000)/10.0000))+30.0000; ALGEBRAIC[27] = 8.50000*exp(- pow((STATES[0]+45.0000)/50.0000, 2.00000))+0.500000; ALGEBRAIC[28] = 85.0000*exp(- pow(STATES[0]+40.0000, 2.00000)/220.000)+7.00000; ALGEBRAIC[40] = 1.00000/(1.00000+exp(- (STATES[0]+5.00000)/6.00000)); ALGEBRAIC[41] = 1.40000/(1.00000+exp((- 35.0000 - STATES[0])/13.0000))+0.250000; ALGEBRAIC[42] = 1.40000/(1.00000+exp((STATES[0]+5.00000)/5.00000)); ALGEBRAIC[43] = 1.00000/(1.00000+exp((50.0000 - STATES[0])/20.0000)); ALGEBRAIC[44] = ALGEBRAIC[41]*ALGEBRAIC[42]+ALGEBRAIC[43]; ALGEBRAIC[45] = 1.00000/(1.00000+exp((STATES[0]+20.0000)/7.00000)); ALGEBRAIC[46] = 1102.50*exp(- pow((STATES[0]+27.0000)/15.0000, 2.00000)); ALGEBRAIC[47] = 200.000/(1.00000+exp((13.0000 - STATES[0])/10.0000)); ALGEBRAIC[48] = 180.000/(1.00000+exp((STATES[0]+30.0000)/10.0000))+20.0000; ALGEBRAIC[49] = ALGEBRAIC[46]+ALGEBRAIC[47]+ALGEBRAIC[48]; ALGEBRAIC[50] = 0.670000/(1.00000+exp((STATES[0]+35.0000)/7.00000))+0.330000; ALGEBRAIC[51] = 300.000*exp(- pow(STATES[0]+25.0000, 2.00000)/170.000); ALGEBRAIC[52] = 31.0000/(1.00000+exp((25.0000 - STATES[0])/10.0000)); ALGEBRAIC[53] = 16.0000/(1.00000+exp((STATES[0]+30.0000)/10.0000)); ALGEBRAIC[54] = ALGEBRAIC[51]+ALGEBRAIC[52]+ALGEBRAIC[53]; ALGEBRAIC[82] = CONSTANTS[50] - (CONSTANTS[50] - CONSTANTS[51])/(1.00000+pow(CONSTANTS[52]/STATES[19], 2.50000)); ALGEBRAIC[83] = CONSTANTS[53]/ALGEBRAIC[82]; ALGEBRAIC[84] = CONSTANTS[54]*ALGEBRAIC[82]; ALGEBRAIC[85] = ((1.00000 - STATES[20]) - STATES[21]) - STATES[22]; ALGEBRAIC[86] = CONSTANTS[57]*STATES[21]*(STATES[19] - STATES[12]); ALGEBRAIC[87] = ( CONSTANTS[60]*(pow(STATES[23]/CONSTANTS[58], CONSTANTS[61]) - pow(STATES[19]/CONSTANTS[59], CONSTANTS[61])))/(1.00000+pow(STATES[23]/CONSTANTS[58], CONSTANTS[61])+pow(STATES[19]/CONSTANTS[59], CONSTANTS[61])); ALGEBRAIC[88] = 5.34800e-06*(STATES[19] - STATES[12]); ALGEBRAIC[89] = (1.00000/CONSTANTS[95])*log(CONSTANTS[19]/STATES[4]); ALGEBRAIC[95] = CONSTANTS[9]*CONSTANTS[17]*pow(STATES[1], 3.00000)*STATES[2]*STATES[3]*(STATES[0] - ALGEBRAIC[89]); ALGEBRAIC[98] = CONSTANTS[9]*CONSTANTS[18]*(STATES[0] - ALGEBRAIC[89]); ALGEBRAIC[11] = 1.00000/(1.00000+ 0.124500*exp( - 0.100000*STATES[0]*CONSTANTS[95])+ 0.0365000*CONSTANTS[99]*exp( - STATES[0]*CONSTANTS[95])); ALGEBRAIC[12] = ( CONSTANTS[9]*CONSTANTS[20]*ALGEBRAIC[11]*CONSTANTS[21])/( (1.00000+pow(CONSTANTS[23]/STATES[4], 4.00000))*(CONSTANTS[21]+CONSTANTS[22])); ALGEBRAIC[58] = ( CONSTANTS[37]*STATES[0]*CONSTANTS[2]*CONSTANTS[95]*( STATES[4]*exp( STATES[0]*CONSTANTS[95]) - CONSTANTS[19]))/(exp( STATES[0]*CONSTANTS[95]) - 1.00000); ALGEBRAIC[64] = CONSTANTS[10]*ALGEBRAIC[58]*STATES[14]*STATES[15]*STATES[16]*(1.00000 - STATES[17]); ALGEBRAIC[68] = 1.00000/(1.00000+pow(CONSTANTS[39]/STATES[12], 2.00000)); ALGEBRAIC[70] = exp( CONSTANTS[45]*STATES[0]*CONSTANTS[95])*pow(STATES[4], 3.00000)*CONSTANTS[35]; ALGEBRAIC[72] = exp( (CONSTANTS[45] - 1.00000)*STATES[0]*CONSTANTS[95])*pow(CONSTANTS[19], 3.00000)*STATES[12]; ALGEBRAIC[74] = CONSTANTS[40]*pow(CONSTANTS[19], 3.00000)*(1.00000+pow(STATES[4]/CONSTANTS[42], 3.00000))+ pow(CONSTANTS[43], 3.00000)*STATES[12]*(1.00000+STATES[12]/CONSTANTS[40])+ CONSTANTS[41]*pow(STATES[4], 3.00000)+ pow(STATES[4], 3.00000)*CONSTANTS[35]+ pow(CONSTANTS[19], 3.00000)*STATES[12]; ALGEBRAIC[76] = ( CONSTANTS[9]*CONSTANTS[46]*ALGEBRAIC[68]*(ALGEBRAIC[70] - ALGEBRAIC[72]))/( ALGEBRAIC[74]*(1.00000+ CONSTANTS[44]*exp( (CONSTANTS[45] - 1.00000)*STATES[0]*CONSTANTS[95]))); ALGEBRAIC[107] = ALGEBRAIC[95]+ALGEBRAIC[98]+ 3.00000*ALGEBRAIC[76]+ 3.00000*ALGEBRAIC[12]+ALGEBRAIC[64]; ALGEBRAIC[90] = (1.00000/CONSTANTS[95])*log(CONSTANTS[19]/STATES[5]); ALGEBRAIC[96] = CONSTANTS[96]*CONSTANTS[17]*pow(STATES[1], 3.00000)*STATES[2]*STATES[3]*(STATES[0] - ALGEBRAIC[90]); ALGEBRAIC[99] = CONSTANTS[96]*CONSTANTS[18]*(STATES[0] - ALGEBRAIC[90]); ALGEBRAIC[13] = ( CONSTANTS[96]*CONSTANTS[20]*ALGEBRAIC[11]*CONSTANTS[21])/( (1.00000+pow(CONSTANTS[23]/STATES[5], 4.00000))*(CONSTANTS[21]+CONSTANTS[22])); ALGEBRAIC[59] = ( CONSTANTS[37]*STATES[0]*CONSTANTS[2]*CONSTANTS[95]*( STATES[5]*exp( STATES[0]*CONSTANTS[95]) - CONSTANTS[19]))/(exp( STATES[0]*CONSTANTS[95]) - 1.00000); ALGEBRAIC[65] = CONSTANTS[97]*ALGEBRAIC[59]*STATES[14]*STATES[15]*STATES[16]*(1.00000 - STATES[18]); ALGEBRAIC[69] = 1.00000/(1.00000+pow(CONSTANTS[39]/STATES[13], 2.00000)); ALGEBRAIC[71] = exp( CONSTANTS[45]*STATES[0]*CONSTANTS[95])*pow(STATES[5], 3.00000)*CONSTANTS[35]; ALGEBRAIC[73] = exp( (CONSTANTS[45] - 1.00000)*STATES[0]*CONSTANTS[95])*pow(CONSTANTS[19], 3.00000)*STATES[13]; ALGEBRAIC[75] = CONSTANTS[40]*pow(CONSTANTS[19], 3.00000)*(1.00000+pow(STATES[5]/CONSTANTS[42], 3.00000))+ pow(CONSTANTS[43], 3.00000)*STATES[13]*(1.00000+STATES[13]/CONSTANTS[40])+ CONSTANTS[41]*pow(STATES[5], 3.00000)+ pow(STATES[5], 3.00000)*CONSTANTS[35]+ pow(CONSTANTS[19], 3.00000)*STATES[13]; ALGEBRAIC[77] = ( CONSTANTS[96]*CONSTANTS[46]*ALGEBRAIC[69]*(ALGEBRAIC[71] - ALGEBRAIC[73]))/( ALGEBRAIC[75]*(1.00000+ CONSTANTS[44]*exp( (CONSTANTS[45] - 1.00000)*STATES[0]*CONSTANTS[95]))); ALGEBRAIC[108] = ALGEBRAIC[96]+ALGEBRAIC[99]+ 3.00000*ALGEBRAIC[77]+ 3.00000*ALGEBRAIC[13]+ALGEBRAIC[65]; ALGEBRAIC[55] = ( CONSTANTS[36]*STATES[0]*CONSTANTS[2]*CONSTANTS[95]*( STATES[12]*exp( 2.00000*STATES[0]*CONSTANTS[95]) - CONSTANTS[35]))/(exp( 2.00000*STATES[0]*CONSTANTS[95]) - 1.00000); ALGEBRAIC[60] = CONSTANTS[10]*ALGEBRAIC[55]*STATES[14]*STATES[15]*STATES[16]*(1.00000 - STATES[17]); ALGEBRAIC[79] = ( CONSTANTS[9]*CONSTANTS[48]*pow(STATES[12], 1.60000))/(pow(CONSTANTS[47], 1.60000)+pow(STATES[12], 1.60000)); ALGEBRAIC[92] = (1.00000/( 2.00000*CONSTANTS[95]))*log(CONSTANTS[35]/STATES[12]); ALGEBRAIC[104] = CONSTANTS[9]*CONSTANTS[49]*(STATES[0] - ALGEBRAIC[92]); ALGEBRAIC[110] = (ALGEBRAIC[60]+ALGEBRAIC[104]+ALGEBRAIC[79]) - 2.00000*ALGEBRAIC[76]; ALGEBRAIC[56] = ( CONSTANTS[36]*STATES[0]*CONSTANTS[2]*CONSTANTS[95]*( STATES[13]*exp( 2.00000*STATES[0]*CONSTANTS[95]) - CONSTANTS[35]))/(exp( 2.00000*STATES[0]*CONSTANTS[95]) - 1.00000); ALGEBRAIC[61] = CONSTANTS[97]*ALGEBRAIC[56]*STATES[14]*STATES[15]*STATES[16]*(1.00000 - STATES[18]); ALGEBRAIC[80] = ( CONSTANTS[96]*CONSTANTS[48]*pow(STATES[13], 1.60000))/(pow(CONSTANTS[47], 1.60000)+pow(STATES[13], 1.60000)); ALGEBRAIC[93] = (1.00000/( 2.00000*CONSTANTS[95]))*log(CONSTANTS[35]/STATES[13]); ALGEBRAIC[105] = CONSTANTS[96]*CONSTANTS[49]*(STATES[0] - ALGEBRAIC[93]); ALGEBRAIC[111] = (ALGEBRAIC[61]+ALGEBRAIC[105]+ALGEBRAIC[80]) - 2.00000*ALGEBRAIC[77]; ALGEBRAIC[14] = ALGEBRAIC[12]+ALGEBRAIC[13]; ALGEBRAIC[17] = 1.00000/(1.00000+exp((STATES[0]+74.0000)/24.0000)); ALGEBRAIC[18] = CONSTANTS[24]* pow((CONSTANTS[21]/5.40000), 1.0 / 2)*STATES[6]*ALGEBRAIC[17]*(STATES[0] - CONSTANTS[101]); ALGEBRAIC[91] = (1.00000/CONSTANTS[95])*log((CONSTANTS[21]+ CONSTANTS[94]*CONSTANTS[19])/(CONSTANTS[34]+ CONSTANTS[94]*STATES[35])); ALGEBRAIC[101] = CONSTANTS[9]*CONSTANTS[25]*pow(STATES[7], 2.00000)*(STATES[0] - ALGEBRAIC[91]); ALGEBRAIC[102] = CONSTANTS[96]*CONSTANTS[26]*pow(STATES[7], 2.00000)*(STATES[0] - ALGEBRAIC[91]); ALGEBRAIC[103] = ALGEBRAIC[101]+ALGEBRAIC[102]; ALGEBRAIC[21] = 1.00000/(1.00000+exp(7.48800 - STATES[0]/5.98000)); ALGEBRAIC[22] = CONSTANTS[27]*ALGEBRAIC[21]*(STATES[0] - CONSTANTS[101]); ALGEBRAIC[29] = CONSTANTS[28]*STATES[8]*STATES[9]*(STATES[0] - CONSTANTS[101]); ALGEBRAIC[30] = CONSTANTS[29]*STATES[10]*STATES[11]*(STATES[0] - CONSTANTS[101]); ALGEBRAIC[31] = ALGEBRAIC[29]+ALGEBRAIC[30]; ALGEBRAIC[32] = 4.09380/(1.00000+exp( 0.121650*((STATES[0] - CONSTANTS[101]) - 49.9344))); ALGEBRAIC[33] = ( 15.7197*exp( 0.0673900*((STATES[0] - CONSTANTS[101]) - 3.25710))+exp( 0.0617500*((STATES[0] - CONSTANTS[101]) - 594.310)))/(1.00000+exp( - 0.162850*((STATES[0] - CONSTANTS[101])+14.2067))); ALGEBRAIC[34] = ALGEBRAIC[32]/(ALGEBRAIC[32]+ALGEBRAIC[33]); ALGEBRAIC[35] = CONSTANTS[30]* pow((CONSTANTS[21]/5.40000), 1.0 / 2)*ALGEBRAIC[34]*(STATES[0] - CONSTANTS[101]); ALGEBRAIC[57] = ( CONSTANTS[38]*STATES[0]*CONSTANTS[2]*CONSTANTS[95]*( CONSTANTS[34]*exp( STATES[0]*CONSTANTS[95]) - CONSTANTS[21]))/(exp( STATES[0]*CONSTANTS[95]) - 1.00000); ALGEBRAIC[63] = ALGEBRAIC[57]*STATES[14]*STATES[15]*STATES[16]*( CONSTANTS[10]*(1.00000 - STATES[17])+ CONSTANTS[97]*(1.00000 - STATES[18])); ALGEBRAIC[109] = ((ALGEBRAIC[31]+ALGEBRAIC[18]+ALGEBRAIC[103]+ALGEBRAIC[35]) - 2.00000*ALGEBRAIC[14])+ALGEBRAIC[63]+ALGEBRAIC[22]; ALGEBRAIC[112] = ALGEBRAIC[107]+ALGEBRAIC[108]; ALGEBRAIC[36] = (( CONSTANTS[9]*CONSTANTS[31])/(1.00000+CONSTANTS[32]/STATES[12]))*(STATES[0] - CONSTANTS[102]); ALGEBRAIC[37] = (( CONSTANTS[96]*CONSTANTS[31])/(1.00000+CONSTANTS[32]/STATES[13]))*(STATES[0] - CONSTANTS[102]); ALGEBRAIC[38] = ALGEBRAIC[36]+ALGEBRAIC[37]; ALGEBRAIC[39] = CONSTANTS[33]*(STATES[0] - CONSTANTS[102]); ALGEBRAIC[94] = ALGEBRAIC[38]+ALGEBRAIC[39]; ALGEBRAIC[113] = ALGEBRAIC[110]+ALGEBRAIC[111]; ALGEBRAIC[114] = ALGEBRAIC[112]+ALGEBRAIC[94]+ALGEBRAIC[113]+ALGEBRAIC[109]; } void getStateInformation(double* SI) { SI[0] = 1.0; SI[1] = 1.0; SI[2] = 1.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[39] = 0.0; SI[31] = 1.0; SI[32] = 1.0; SI[33] = 1.0; SI[34] = 1.0; SI[40] = 0.0; SI[41] = 0.0; SI[35] = 1.0; SI[36] = 1.0; SI[37] = 1.0; SI[38] = 1.0; } void computeRoots(double VOI, double* CONSTANTS, double* RATES, double* OLDRATES, double* STATES, double* OLDSTATES, double* ALGEBRAIC, double* CONDVARS) { CONDVAR[0] = VOI - CONSTANTS[4]; CONDVAR[1] = VOI - CONSTANTS[5]; CONDVAR[2] = ((VOI - CONSTANTS[4]) - floor((VOI - CONSTANTS[4])/CONSTANTS[7])*CONSTANTS[7]) - CONSTANTS[8]; CONDVAR[3] = STATES[0] - - 40.0000; CONDVAR[4] = STATES[0] - - 40.0000; CONDVAR[5] = STATES[0] - - 40.0000; CONDVAR[6] = STATES[0] - - 40.0000; }