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 52 entries in the algebraic variable array.
   There are a total of 15 entries in each of the rate and state variable arrays.
   There are a total of 133 entries in the constant variable array.
 */
/*
 * VOI is time in component environment (second).
 * CONSTANTS[0] is Version in component membrane (dimensionless).
 * CONSTANTS[1] is dCell in component membrane (dimensionless).
 * CONSTANTS[2] is FCellConstant in component membrane (dimensionless).
 * CONSTANTS[110] is FCell in component membrane (dimensionless).
 * STATES[0] is V in component membrane (millivolt).
 * CONSTANTS[3] is R in component membrane (millijoule_per_mole_kelvin).
 * CONSTANTS[4] is T in component membrane (kelvin).
 * CONSTANTS[5] is F in component membrane (coulomb_per_mole).
 * CONSTANTS[116] is Cm in component membrane (microF).
 * CONSTANTS[6] is CmCentre in component membrane (microF).
 * CONSTANTS[7] is CmPeriphery in component membrane (microF).
 * ALGEBRAIC[50] is i_Na in component sodium_current (nanoA).
 * ALGEBRAIC[8] is i_Ca_L in component L_type_Ca_channel (nanoA).
 * ALGEBRAIC[17] is i_Ca_T in component T_type_Ca_channel (nanoA).
 * ALGEBRAIC[26] is i_to in component four_AP_sensitive_currents (nanoA).
 * ALGEBRAIC[27] is i_sus in component four_AP_sensitive_currents (nanoA).
 * ALGEBRAIC[51] is i_K_r in component rapid_delayed_rectifying_potassium_current (nanoA).
 * ALGEBRAIC[38] is i_K_s in component slow_delayed_rectifying_potassium_current (nanoA).
 * ALGEBRAIC[41] is i_f_Na in component hyperpolarisation_activated_current (nanoA).
 * ALGEBRAIC[42] is i_f_K in component hyperpolarisation_activated_current (nanoA).
 * ALGEBRAIC[45] is i_b_Na in component sodium_background_current (nanoA).
 * ALGEBRAIC[47] is i_b_Ca in component calcium_background_current (nanoA).
 * ALGEBRAIC[46] is i_b_K in component potassium_background_current (nanoA).
 * ALGEBRAIC[48] is i_NaCa in component sodium_calcium_exchanger (nanoA).
 * ALGEBRAIC[49] is i_p in component sodium_potassium_pump (nanoA).
 * CONSTANTS[132] is i_Ca_p in component persistent_calcium_current (nanoA).
 * CONSTANTS[117] is g_Na in component sodium_current (microlitre_per_second).
 * CONSTANTS[8] is g_Na_Centre_Published in component sodium_current (microlitre_per_second).
 * CONSTANTS[9] is g_Na_Centre_0DCapable in component sodium_current (microlitre_per_second).
 * CONSTANTS[10] is g_Na_Centre_1DCapable in component sodium_current (microlitre_per_second).
 * CONSTANTS[11] is g_Na_Periphery_Published in component sodium_current (microlitre_per_second).
 * CONSTANTS[12] is g_Na_Periphery_0DCapable in component sodium_current (microlitre_per_second).
 * CONSTANTS[13] is g_Na_Periphery_1DCapable in component sodium_current (microlitre_per_second).
 * CONSTANTS[111] is E_Na in component reversal_and_equilibrium_potentials (millivolt).
 * CONSTANTS[14] is Na_o in component ionic_concentrations (millimolar).
 * STATES[1] is m in component sodium_current_m_gate (dimensionless).
 * ALGEBRAIC[3] is h in component sodium_current_h_gate (dimensionless).
 * ALGEBRAIC[0] is m_infinity in component sodium_current_m_gate (dimensionless).
 * ALGEBRAIC[1] is tau_m in component sodium_current_m_gate (second).
 * ALGEBRAIC[2] is F_Na in component sodium_current_h_gate (dimensionless).
 * STATES[2] is h1 in component sodium_current_h_gate (dimensionless).
 * STATES[3] is h2 in component sodium_current_h_gate (dimensionless).
 * ALGEBRAIC[4] is h1_infinity in component sodium_current_h_gate (dimensionless).
 * ALGEBRAIC[5] is h2_infinity in component sodium_current_h_gate (dimensionless).
 * ALGEBRAIC[6] is tau_h1 in component sodium_current_h_gate (second).
 * ALGEBRAIC[7] is tau_h2 in component sodium_current_h_gate (second).
 * CONSTANTS[15] is g_Ca_L_Centre_Published in component L_type_Ca_channel (microS).
 * CONSTANTS[16] is g_Ca_L_Centre_0DCapable in component L_type_Ca_channel (microS).
 * CONSTANTS[17] is g_Ca_L_Centre_1DCapable in component L_type_Ca_channel (microS).
 * CONSTANTS[18] is g_Ca_L_Periphery_Published in component L_type_Ca_channel (microS).
 * CONSTANTS[19] is g_Ca_L_Periphery_0DCapable in component L_type_Ca_channel (microS).
 * CONSTANTS[20] is g_Ca_L_Periphery_1DCapable in component L_type_Ca_channel (microS).
 * CONSTANTS[118] is g_Ca_L in component L_type_Ca_channel (microS).
 * CONSTANTS[21] is E_Ca_L in component L_type_Ca_channel (millivolt).
 * STATES[4] is d_L in component L_type_Ca_channel_d_gate (dimensionless).
 * STATES[5] is f_L in component L_type_Ca_channel_f_gate (dimensionless).
 * ALGEBRAIC[9] is alpha_d_L in component L_type_Ca_channel_d_gate (per_second).
 * ALGEBRAIC[10] is beta_d_L in component L_type_Ca_channel_d_gate (per_second).
 * ALGEBRAIC[12] is d_L_infinity in component L_type_Ca_channel_d_gate (dimensionless).
 * ALGEBRAIC[11] is tau_d_L in component L_type_Ca_channel_d_gate (second).
 * ALGEBRAIC[13] is alpha_f_L in component L_type_Ca_channel_f_gate (per_second).
 * ALGEBRAIC[14] is beta_f_L in component L_type_Ca_channel_f_gate (per_second).
 * ALGEBRAIC[16] is f_L_infinity in component L_type_Ca_channel_f_gate (dimensionless).
 * ALGEBRAIC[15] is tau_f_L in component L_type_Ca_channel_f_gate (second).
 * CONSTANTS[22] is g_Ca_T_Centre_Published in component T_type_Ca_channel (microS).
 * CONSTANTS[23] is g_Ca_T_Centre_0DCapable in component T_type_Ca_channel (microS).
 * CONSTANTS[24] is g_Ca_T_Centre_1DCapable in component T_type_Ca_channel (microS).
 * CONSTANTS[25] is g_Ca_T_Periphery_Published in component T_type_Ca_channel (microS).
 * CONSTANTS[26] is g_Ca_T_Periphery_0DCapable in component T_type_Ca_channel (microS).
 * CONSTANTS[27] is g_Ca_T_Periphery_1DCapable in component T_type_Ca_channel (microS).
 * CONSTANTS[119] is g_Ca_T in component T_type_Ca_channel (microS).
 * CONSTANTS[28] is E_Ca_T in component T_type_Ca_channel (millivolt).
 * STATES[6] is d_T in component T_type_Ca_channel_d_gate (dimensionless).
 * STATES[7] is f_T in component T_type_Ca_channel_f_gate (dimensionless).
 * ALGEBRAIC[18] is alpha_d_T in component T_type_Ca_channel_d_gate (per_second).
 * ALGEBRAIC[19] is beta_d_T in component T_type_Ca_channel_d_gate (per_second).
 * ALGEBRAIC[21] is d_T_infinity in component T_type_Ca_channel_d_gate (dimensionless).
 * ALGEBRAIC[20] is tau_d_T in component T_type_Ca_channel_d_gate (second).
 * ALGEBRAIC[22] is alpha_f_T in component T_type_Ca_channel_f_gate (per_second).
 * ALGEBRAIC[23] is beta_f_T in component T_type_Ca_channel_f_gate (per_second).
 * ALGEBRAIC[25] is f_T_infinity in component T_type_Ca_channel_f_gate (dimensionless).
 * ALGEBRAIC[24] is tau_f_T in component T_type_Ca_channel_f_gate (second).
 * CONSTANTS[29] is g_to_Centre_Published in component four_AP_sensitive_currents (microS).
 * CONSTANTS[30] is g_to_Centre_0DCapable in component four_AP_sensitive_currents (microS).
 * CONSTANTS[31] is g_to_Centre_1DCapable in component four_AP_sensitive_currents (microS).
 * CONSTANTS[32] is g_to_Periphery_Published in component four_AP_sensitive_currents (microS).
 * CONSTANTS[33] is g_to_Periphery_0DCapable in component four_AP_sensitive_currents (microS).
 * CONSTANTS[34] is g_to_Periphery_1DCapable in component four_AP_sensitive_currents (microS).
 * CONSTANTS[120] is g_to in component four_AP_sensitive_currents (microS).
 * CONSTANTS[35] is g_sus_Centre_Published in component four_AP_sensitive_currents (microS).
 * CONSTANTS[36] is g_sus_Centre_0DCapable in component four_AP_sensitive_currents (microS).
 * CONSTANTS[37] is g_sus_Centre_1DCapable in component four_AP_sensitive_currents (microS).
 * CONSTANTS[38] is g_sus_Periphery_Published in component four_AP_sensitive_currents (microS).
 * CONSTANTS[39] is g_sus_Periphery_0DCapable in component four_AP_sensitive_currents (microS).
 * CONSTANTS[40] is g_sus_Periphery_1DCapable in component four_AP_sensitive_currents (microS).
 * CONSTANTS[121] is g_sus in component four_AP_sensitive_currents (microS).
 * CONSTANTS[112] is E_K in component reversal_and_equilibrium_potentials (millivolt).
 * STATES[8] is q in component four_AP_sensitive_currents_q_gate (dimensionless).
 * STATES[9] is r in component four_AP_sensitive_currents_r_gate (dimensionless).
 * ALGEBRAIC[28] is q_infinity in component four_AP_sensitive_currents_q_gate (dimensionless).
 * ALGEBRAIC[29] is tau_q in component four_AP_sensitive_currents_q_gate (second).
 * ALGEBRAIC[30] is r_infinity in component four_AP_sensitive_currents_r_gate (dimensionless).
 * ALGEBRAIC[31] is tau_r in component four_AP_sensitive_currents_r_gate (second).
 * CONSTANTS[41] is g_K_r_Centre_Published in component rapid_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[42] is g_K_r_Centre_0DCapable in component rapid_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[43] is g_K_r_Centre_1DCapable in component rapid_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[44] is g_K_r_Periphery_Published in component rapid_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[45] is g_K_r_Periphery_0DCapable in component rapid_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[46] is g_K_r_Periphery_1DCapable in component rapid_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[122] is g_K_r in component rapid_delayed_rectifying_potassium_current (microS).
 * ALGEBRAIC[32] is P_a in component rapid_delayed_rectifying_potassium_current (dimensionless).
 * STATES[10] is P_af in component rapid_delayed_rectifying_potassium_current_P_af_gate (dimensionless).
 * STATES[11] is P_as in component rapid_delayed_rectifying_potassium_current_P_as_gate (dimensionless).
 * STATES[12] is P_i in component rapid_delayed_rectifying_potassium_current_P_i_gate (dimensionless).
 * ALGEBRAIC[33] is P_af_infinity in component rapid_delayed_rectifying_potassium_current_P_af_gate (dimensionless).
 * ALGEBRAIC[34] is tau_P_af in component rapid_delayed_rectifying_potassium_current_P_af_gate (second).
 * ALGEBRAIC[35] is P_as_infinity in component rapid_delayed_rectifying_potassium_current_P_as_gate (dimensionless).
 * ALGEBRAIC[36] is tau_P_as in component rapid_delayed_rectifying_potassium_current_P_as_gate (second).
 * ALGEBRAIC[37] is P_i_infinity in component rapid_delayed_rectifying_potassium_current_P_i_gate (dimensionless).
 * CONSTANTS[113] is tau_P_i in component rapid_delayed_rectifying_potassium_current_P_i_gate (second).
 * CONSTANTS[47] is g_K_s_Centre_Published in component slow_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[48] is g_K_s_Centre_0DCapable in component slow_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[49] is g_K_s_Centre_1DCapable in component slow_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[50] is g_K_s_Periphery_Published in component slow_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[51] is g_K_s_Periphery_0DCapable in component slow_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[52] is g_K_s_Periphery_1DCapable in component slow_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[123] is g_K_s in component slow_delayed_rectifying_potassium_current (microS).
 * CONSTANTS[114] is E_K_s in component reversal_and_equilibrium_potentials (millivolt).
 * STATES[13] is xs in component slow_delayed_rectifying_potassium_current_xs_gate (dimensionless).
 * ALGEBRAIC[39] is alpha_xs in component slow_delayed_rectifying_potassium_current_xs_gate (per_second).
 * ALGEBRAIC[40] is beta_xs in component slow_delayed_rectifying_potassium_current_xs_gate (per_second).
 * CONSTANTS[53] is g_f_Na_Centre_Published in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[54] is g_f_Na_Centre_0DCapable in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[55] is g_f_Na_Centre_1DCapable in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[56] is g_f_Na_Periphery_Published in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[57] is g_f_Na_Periphery_0DCapable in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[58] is g_f_Na_Periphery_1DCapable in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[124] is g_f_Na in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[59] is g_f_K_Centre_Published in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[60] is g_f_K_Centre_0DCapable in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[61] is g_f_K_Centre_1DCapable in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[62] is g_f_K_Periphery_Published in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[63] is g_f_K_Periphery_0DCapable in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[64] is g_f_K_Periphery_1DCapable in component hyperpolarisation_activated_current (microS).
 * CONSTANTS[125] is g_f_K in component hyperpolarisation_activated_current (microS).
 * STATES[14] is y in component hyperpolarisation_activated_current_y_gate (dimensionless).
 * ALGEBRAIC[43] is alpha_y in component hyperpolarisation_activated_current_y_gate (per_second).
 * ALGEBRAIC[44] is beta_y in component hyperpolarisation_activated_current_y_gate (per_second).
 * CONSTANTS[65] is g_b_Na_Centre_Published in component sodium_background_current (microS).
 * CONSTANTS[66] is g_b_Na_Centre_0DCapable in component sodium_background_current (microS).
 * CONSTANTS[67] is g_b_Na_Centre_1DCapable in component sodium_background_current (microS).
 * CONSTANTS[68] is g_b_Na_Periphery_Published in component sodium_background_current (microS).
 * CONSTANTS[69] is g_b_Na_Periphery_0DCapable in component sodium_background_current (microS).
 * CONSTANTS[70] is g_b_Na_Periphery_1DCapable in component sodium_background_current (microS).
 * CONSTANTS[126] is g_b_Na in component sodium_background_current (microS).
 * CONSTANTS[71] is g_b_K_Centre_Published in component potassium_background_current (microS).
 * CONSTANTS[72] is g_b_K_Centre_0DCapable in component potassium_background_current (microS).
 * CONSTANTS[73] is g_b_K_Centre_1DCapable in component potassium_background_current (microS).
 * CONSTANTS[74] is g_b_K_Periphery_Published in component potassium_background_current (microS).
 * CONSTANTS[75] is g_b_K_Periphery_0DCapable in component potassium_background_current (microS).
 * CONSTANTS[76] is g_b_K_Periphery_1DCapable in component potassium_background_current (microS).
 * CONSTANTS[127] is g_b_K in component potassium_background_current (microS).
 * CONSTANTS[77] is g_b_Ca_Centre_Published in component calcium_background_current (microS).
 * CONSTANTS[78] is g_b_Ca_Centre_0DCapable in component calcium_background_current (microS).
 * CONSTANTS[79] is g_b_Ca_Centre_1DCapable in component calcium_background_current (microS).
 * CONSTANTS[80] is g_b_Ca_Periphery_Published in component calcium_background_current (microS).
 * CONSTANTS[81] is g_b_Ca_Periphery_0DCapable in component calcium_background_current (microS).
 * CONSTANTS[82] is g_b_Ca_Periphery_1DCapable in component calcium_background_current (microS).
 * CONSTANTS[128] is g_b_Ca in component calcium_background_current (microS).
 * CONSTANTS[115] is E_Ca in component reversal_and_equilibrium_potentials (millivolt).
 * CONSTANTS[83] is k_NaCa_Centre_Published in component sodium_calcium_exchanger (nanoA).
 * CONSTANTS[84] is k_NaCa_Centre_0DCapable in component sodium_calcium_exchanger (nanoA).
 * CONSTANTS[85] is k_NaCa_Centre_1DCapable in component sodium_calcium_exchanger (nanoA).
 * CONSTANTS[86] is k_NaCa_Periphery_Published in component sodium_calcium_exchanger (nanoA).
 * CONSTANTS[87] is k_NaCa_Periphery_0DCapable in component sodium_calcium_exchanger (nanoA).
 * CONSTANTS[88] is k_NaCa_Periphery_1DCapable in component sodium_calcium_exchanger (nanoA).
 * CONSTANTS[129] is k_NaCa in component sodium_calcium_exchanger (nanoA).
 * CONSTANTS[89] is d_NaCa in component sodium_calcium_exchanger (dimensionless).
 * CONSTANTS[90] is gamma_NaCa in component sodium_calcium_exchanger (dimensionless).
 * CONSTANTS[91] is Na_i in component ionic_concentrations (millimolar).
 * CONSTANTS[92] is Ca_i in component ionic_concentrations (millimolar).
 * CONSTANTS[93] is Ca_o in component ionic_concentrations (millimolar).
 * CONSTANTS[94] is K_m_Na in component sodium_potassium_pump (millimolar).
 * CONSTANTS[95] is K_m_K in component sodium_potassium_pump (millimolar).
 * CONSTANTS[96] is i_p_max_Centre_Published in component sodium_potassium_pump (nanoA).
 * CONSTANTS[97] is i_p_max_Centre_0DCapable in component sodium_potassium_pump (nanoA).
 * CONSTANTS[98] is i_p_max_Centre_1DCapable in component sodium_potassium_pump (nanoA).
 * CONSTANTS[99] is i_p_max_Periphery_Published in component sodium_potassium_pump (nanoA).
 * CONSTANTS[100] is i_p_max_Periphery_0DCapable in component sodium_potassium_pump (nanoA).
 * CONSTANTS[101] is i_p_max_Periphery_1DCapable in component sodium_potassium_pump (nanoA).
 * CONSTANTS[130] is i_p_max in component sodium_potassium_pump (nanoA).
 * CONSTANTS[102] is K_o in component ionic_concentrations (millimolar).
 * CONSTANTS[103] is i_Ca_p_max_Centre_Published in component persistent_calcium_current (nanoA).
 * CONSTANTS[104] is i_Ca_p_max_Centre_0DCapable in component persistent_calcium_current (nanoA).
 * CONSTANTS[105] is i_Ca_p_max_Centre_1DCapable in component persistent_calcium_current (nanoA).
 * CONSTANTS[106] is i_Ca_p_max_Periphery_Published in component persistent_calcium_current (nanoA).
 * CONSTANTS[107] is i_Ca_p_max_Periphery_0DCapable in component persistent_calcium_current (nanoA).
 * CONSTANTS[108] is i_Ca_p_max_Periphery_1DCapable in component persistent_calcium_current (nanoA).
 * CONSTANTS[131] is i_Ca_p_max in component persistent_calcium_current (nanoA).
 * CONSTANTS[109] is K_i in component ionic_concentrations (millimolar).
 * RATES[0] is d/dt V in component membrane (millivolt).
 * RATES[1] is d/dt m in component sodium_current_m_gate (dimensionless).
 * RATES[2] is d/dt h1 in component sodium_current_h_gate (dimensionless).
 * RATES[3] is d/dt h2 in component sodium_current_h_gate (dimensionless).
 * RATES[4] is d/dt d_L in component L_type_Ca_channel_d_gate (dimensionless).
 * RATES[5] is d/dt f_L in component L_type_Ca_channel_f_gate (dimensionless).
 * RATES[6] is d/dt d_T in component T_type_Ca_channel_d_gate (dimensionless).
 * RATES[7] is d/dt f_T in component T_type_Ca_channel_f_gate (dimensionless).
 * RATES[8] is d/dt q in component four_AP_sensitive_currents_q_gate (dimensionless).
 * RATES[9] is d/dt r in component four_AP_sensitive_currents_r_gate (dimensionless).
 * RATES[10] is d/dt P_af in component rapid_delayed_rectifying_potassium_current_P_af_gate (dimensionless).
 * RATES[11] is d/dt P_as in component rapid_delayed_rectifying_potassium_current_P_as_gate (dimensionless).
 * RATES[12] is d/dt P_i in component rapid_delayed_rectifying_potassium_current_P_i_gate (dimensionless).
 * RATES[13] is d/dt xs in component slow_delayed_rectifying_potassium_current_xs_gate (dimensionless).
 * RATES[14] is d/dt y in component hyperpolarisation_activated_current_y_gate (dimensionless).
 * There are a total of 0 condition variables.
 */
void
initConsts(double* CONSTANTS, double* RATES, double *STATES)
{
CONSTANTS[0] = 1;
CONSTANTS[1] = 0;
CONSTANTS[2] = 1.0309347;
STATES[0] = -39.013558536;
CONSTANTS[3] = 8314;
CONSTANTS[4] = 310;
CONSTANTS[5] = 96845;
CONSTANTS[6] = 2e-5;
CONSTANTS[7] = 6.5e-5;
CONSTANTS[8] = 0;
CONSTANTS[9] = 0;
CONSTANTS[10] = 0;
CONSTANTS[11] = 1.2e-6;
CONSTANTS[12] = 1.204e-6;
CONSTANTS[13] = 3.7e-7;
CONSTANTS[14] = 140;
STATES[1] = 0.092361701692;
STATES[2] = 0.015905380261;
STATES[3] = 0.01445216109;
CONSTANTS[15] = 0.0058;
CONSTANTS[16] = 0.0057938;
CONSTANTS[17] = 0.0082;
CONSTANTS[18] = 0.0659;
CONSTANTS[19] = 0.06588648;
CONSTANTS[20] = 0.0659;
CONSTANTS[21] = 46.4;
STATES[4] = 0.04804900895;
STATES[5] = 0.48779845203;
CONSTANTS[22] = 0.0043;
CONSTANTS[23] = 0.00427806;
CONSTANTS[24] = 0.0021;
CONSTANTS[25] = 0.0139;
CONSTANTS[26] = 0.0138823;
CONSTANTS[27] = 0.00694;
CONSTANTS[28] = 45;
STATES[6] = 0.42074047435;
STATES[7] = 0.038968420558;
CONSTANTS[29] = 0.00491;
CONSTANTS[30] = 0.004905;
CONSTANTS[31] = 0.004905;
CONSTANTS[32] = 0.03649;
CONSTANTS[33] = 0.036495;
CONSTANTS[34] = 0.0365;
CONSTANTS[35] = 6.65e-5;
CONSTANTS[36] = 6.645504e-5;
CONSTANTS[37] = 0.000266;
CONSTANTS[38] = 0.0114;
CONSTANTS[39] = 0.01138376;
CONSTANTS[40] = 0.0114;
STATES[8] = 0.29760539675;
STATES[9] = 0.064402950262;
CONSTANTS[41] = 0.000797;
CONSTANTS[42] = 0.00079704;
CONSTANTS[43] = 0.000738;
CONSTANTS[44] = 0.016;
CONSTANTS[45] = 0.016;
CONSTANTS[46] = 0.0208;
STATES[10] = 0.13034201158;
STATES[11] = 0.46960956028;
STATES[12] = 0.87993375273;
CONSTANTS[47] = 0.000518;
CONSTANTS[48] = 0.0003445;
CONSTANTS[49] = 0.000345;
CONSTANTS[50] = 0.0104;
CONSTANTS[51] = 0.0104;
CONSTANTS[52] = 0.0104;
STATES[13] = 0.082293827208;
CONSTANTS[53] = 0.000548;
CONSTANTS[54] = 0.0005465;
CONSTANTS[55] = 0.000437;
CONSTANTS[56] = 0.0069;
CONSTANTS[57] = 0.006875;
CONSTANTS[58] = 0.0055;
CONSTANTS[59] = 0.000548;
CONSTANTS[60] = 0.0005465;
CONSTANTS[61] = 0.000437;
CONSTANTS[62] = 0.0069;
CONSTANTS[63] = 0.006875;
CONSTANTS[64] = 0.0055;
STATES[14] = 0.03889291759;
CONSTANTS[65] = 5.8e-5;
CONSTANTS[66] = 5.81818e-5;
CONSTANTS[67] = 5.8e-5;
CONSTANTS[68] = 0.000189;
CONSTANTS[69] = 0.0001888;
CONSTANTS[70] = 0.000189;
CONSTANTS[71] = 2.52e-5;
CONSTANTS[72] = 2.523636e-5;
CONSTANTS[73] = 2.52e-5;
CONSTANTS[74] = 8.19e-5;
CONSTANTS[75] = 8.1892e-5;
CONSTANTS[76] = 8.19e-5;
CONSTANTS[77] = 1.32e-5;
CONSTANTS[78] = 1.3236e-5;
CONSTANTS[79] = 1.323e-5;
CONSTANTS[80] = 4.3e-5;
CONSTANTS[81] = 4.2952e-5;
CONSTANTS[82] = 4.29e-5;
CONSTANTS[83] = 2.7e-6;
CONSTANTS[84] = 2.7229e-6;
CONSTANTS[85] = 2.8e-6;
CONSTANTS[86] = 8.8e-6;
CONSTANTS[87] = 8.83584e-6;
CONSTANTS[88] = 8.8e-6;
CONSTANTS[89] = 0.0001;
CONSTANTS[90] = 0.5;
CONSTANTS[91] = 8;
CONSTANTS[92] = 0.0001;
CONSTANTS[93] = 2;
CONSTANTS[94] = 5.64;
CONSTANTS[95] = 0.621;
CONSTANTS[96] = 0.0478;
CONSTANTS[97] = 0.04782545;
CONSTANTS[98] = 0.0478;
CONSTANTS[99] = 0.16;
CONSTANTS[100] = 0.1551936;
CONSTANTS[101] = 0.16;
CONSTANTS[102] = 5.4;
CONSTANTS[103] = 0;
CONSTANTS[104] = 0;
CONSTANTS[105] = 0.0042;
CONSTANTS[106] = 0;
CONSTANTS[107] = 0;
CONSTANTS[108] = 0.03339;
CONSTANTS[109] = 140;
CONSTANTS[110] = (CONSTANTS[0]==0.00000 ? ( 1.07000*( 3.00000*CONSTANTS[1] - 0.100000))/( 3.00000*(1.00000+ 0.774500*exp(- ( 3.00000*CONSTANTS[1] - 2.05000)/0.295000))) : CONSTANTS[0]==1.00000 ? ( CONSTANTS[2]*CONSTANTS[1])/(1.00000+ 0.774500*exp(- ( 3.00000*CONSTANTS[1] - 2.05000)/0.295000)) : ( 1.07000*29.0000*CONSTANTS[1])/( 30.0000*(1.00000+ 0.774500*exp(- ( 29.0000*CONSTANTS[1] - 24.5000)/1.95000))));
CONSTANTS[111] =  (( CONSTANTS[3]*CONSTANTS[4])/CONSTANTS[5])*log(CONSTANTS[14]/CONSTANTS[91]);
CONSTANTS[112] =  (( CONSTANTS[3]*CONSTANTS[4])/CONSTANTS[5])*log(CONSTANTS[102]/CONSTANTS[109]);
CONSTANTS[113] = (CONSTANTS[0]==0.00000 ? 0.00200000 : CONSTANTS[0]==1.00000 ? 0.00200000 : 0.00600000);
CONSTANTS[114] = (CONSTANTS[0]==0.00000 ?  (( CONSTANTS[3]*CONSTANTS[4])/CONSTANTS[5])*log((CONSTANTS[102]+ 0.120000*CONSTANTS[14])/(CONSTANTS[109]+ 0.120000*CONSTANTS[91])) :  (( CONSTANTS[3]*CONSTANTS[4])/CONSTANTS[5])*log((CONSTANTS[102]+ 0.0300000*CONSTANTS[14])/(CONSTANTS[109]+ 0.0300000*CONSTANTS[91])));
CONSTANTS[115] =  (( CONSTANTS[3]*CONSTANTS[4])/( 2.00000*CONSTANTS[5]))*log(CONSTANTS[93]/CONSTANTS[92]);
CONSTANTS[116] = CONSTANTS[6]+ CONSTANTS[110]*(CONSTANTS[7] - CONSTANTS[6]);
CONSTANTS[117] = (CONSTANTS[0]==0.00000 ? CONSTANTS[8]+ CONSTANTS[110]*(CONSTANTS[11] - CONSTANTS[8]) : CONSTANTS[0]==1.00000 ? CONSTANTS[9]+ CONSTANTS[110]*(CONSTANTS[12] - CONSTANTS[9]) : CONSTANTS[10]+ CONSTANTS[110]*(CONSTANTS[13] - CONSTANTS[10]));
CONSTANTS[118] = (CONSTANTS[0]==0.00000 ? CONSTANTS[15]+ CONSTANTS[110]*(CONSTANTS[18] - CONSTANTS[15]) : CONSTANTS[0]==1.00000 ? CONSTANTS[16]+ CONSTANTS[110]*(CONSTANTS[19] - CONSTANTS[16]) : CONSTANTS[17]+ CONSTANTS[110]*(CONSTANTS[20] - CONSTANTS[17]));
CONSTANTS[119] = (CONSTANTS[0]==0.00000 ? CONSTANTS[22]+ CONSTANTS[110]*(CONSTANTS[25] - CONSTANTS[22]) : CONSTANTS[0]==1.00000 ? CONSTANTS[23]+ CONSTANTS[110]*(CONSTANTS[26] - CONSTANTS[23]) : CONSTANTS[24]+ CONSTANTS[110]*(CONSTANTS[27] - CONSTANTS[24]));
CONSTANTS[120] = (CONSTANTS[0]==0.00000 ? CONSTANTS[29]+ CONSTANTS[110]*(CONSTANTS[32] - CONSTANTS[29]) : CONSTANTS[0]==1.00000 ? CONSTANTS[30]+ CONSTANTS[110]*(CONSTANTS[33] - CONSTANTS[30]) : CONSTANTS[31]+ CONSTANTS[110]*(CONSTANTS[34] - CONSTANTS[31]));
CONSTANTS[121] = (CONSTANTS[0]==0.00000 ? CONSTANTS[35]+ CONSTANTS[110]*(CONSTANTS[38] - CONSTANTS[35]) : CONSTANTS[0]==1.00000 ? CONSTANTS[36]+ CONSTANTS[110]*(CONSTANTS[39] - CONSTANTS[36]) : CONSTANTS[37]+ CONSTANTS[110]*(CONSTANTS[40] - CONSTANTS[37]));
CONSTANTS[122] = (CONSTANTS[0]==0.00000 ? CONSTANTS[41]+ CONSTANTS[110]*(CONSTANTS[44] - CONSTANTS[41]) : CONSTANTS[0]==1.00000 ? CONSTANTS[42]+ CONSTANTS[110]*(CONSTANTS[45] - CONSTANTS[42]) : CONSTANTS[43]+ CONSTANTS[110]*(CONSTANTS[46] - CONSTANTS[43]));
CONSTANTS[123] = (CONSTANTS[0]==0.00000 ? CONSTANTS[47]+ CONSTANTS[110]*(CONSTANTS[50] - CONSTANTS[47]) : CONSTANTS[0]==1.00000 ? CONSTANTS[48]+ CONSTANTS[110]*(CONSTANTS[51] - CONSTANTS[48]) : CONSTANTS[49]+ CONSTANTS[110]*(CONSTANTS[52] - CONSTANTS[49]));
CONSTANTS[124] = (CONSTANTS[0]==0.00000 ? CONSTANTS[53]+ CONSTANTS[110]*(CONSTANTS[56] - CONSTANTS[53]) : CONSTANTS[0]==1.00000 ? CONSTANTS[54]+ CONSTANTS[110]*(CONSTANTS[57] - CONSTANTS[54]) : CONSTANTS[55]+ CONSTANTS[110]*(CONSTANTS[58] - CONSTANTS[55]));
CONSTANTS[125] = (CONSTANTS[0]==0.00000 ? CONSTANTS[59]+ CONSTANTS[110]*(CONSTANTS[62] - CONSTANTS[59]) : CONSTANTS[0]==1.00000 ? CONSTANTS[60]+ CONSTANTS[110]*(CONSTANTS[63] - CONSTANTS[60]) : CONSTANTS[61]+ CONSTANTS[110]*(CONSTANTS[64] - CONSTANTS[61]));
CONSTANTS[126] = (CONSTANTS[0]==0.00000 ? CONSTANTS[65]+ CONSTANTS[110]*(CONSTANTS[68] - CONSTANTS[65]) : CONSTANTS[0]==1.00000 ? CONSTANTS[66]+ CONSTANTS[110]*(CONSTANTS[69] - CONSTANTS[66]) : CONSTANTS[67]+ CONSTANTS[110]*(CONSTANTS[70] - CONSTANTS[67]));
CONSTANTS[127] = (CONSTANTS[0]==0.00000 ? CONSTANTS[71]+ CONSTANTS[110]*(CONSTANTS[74] - CONSTANTS[71]) : CONSTANTS[0]==1.00000 ? CONSTANTS[72]+ CONSTANTS[110]*(CONSTANTS[75] - CONSTANTS[72]) : CONSTANTS[73]+ CONSTANTS[110]*(CONSTANTS[76] - CONSTANTS[73]));
CONSTANTS[128] = (CONSTANTS[0]==0.00000 ? CONSTANTS[77]+ CONSTANTS[110]*(CONSTANTS[80] - CONSTANTS[77]) : CONSTANTS[0]==1.00000 ? CONSTANTS[78]+ CONSTANTS[110]*(CONSTANTS[81] - CONSTANTS[78]) : CONSTANTS[79]+ CONSTANTS[110]*(CONSTANTS[82] - CONSTANTS[79]));
CONSTANTS[129] = (CONSTANTS[0]==0.00000 ? CONSTANTS[83]+ CONSTANTS[110]*(CONSTANTS[86] - CONSTANTS[83]) : CONSTANTS[0]==1.00000 ? CONSTANTS[84]+ CONSTANTS[110]*(CONSTANTS[87] - CONSTANTS[84]) : CONSTANTS[85]+ CONSTANTS[110]*(CONSTANTS[88] - CONSTANTS[85]));
CONSTANTS[130] = (CONSTANTS[0]==0.00000 ? CONSTANTS[96]+ CONSTANTS[110]*(CONSTANTS[99] - CONSTANTS[96]) : CONSTANTS[0]==1.00000 ? CONSTANTS[97]+ CONSTANTS[110]*(CONSTANTS[100] - CONSTANTS[97]) : CONSTANTS[98]+ CONSTANTS[110]*(CONSTANTS[101] - CONSTANTS[98]));
CONSTANTS[131] = (CONSTANTS[0]==0.00000 ? CONSTANTS[103]+ CONSTANTS[110]*(CONSTANTS[106] - CONSTANTS[103]) : CONSTANTS[0]==1.00000 ? CONSTANTS[104]+ CONSTANTS[110]*(CONSTANTS[107] - CONSTANTS[104]) : CONSTANTS[105]+ CONSTANTS[110]*(CONSTANTS[108] - CONSTANTS[105]));
CONSTANTS[132] = ( CONSTANTS[131]*CONSTANTS[92])/(CONSTANTS[92]+0.000400000);
RATES[0] = 0.1001;
RATES[1] = 0.1001;
RATES[2] = 0.1001;
RATES[3] = 0.1001;
RATES[4] = 0.1001;
RATES[5] = 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[12] = 0.1001;
RATES[13] = 0.1001;
RATES[14] = 0.1001;
}
void
computeResiduals(double VOI, double* CONSTANTS, double* RATES, double* OLDRATES, double* STATES,
                 double* OLDSTATES, double* ALGEBRAIC, double* CONDVARS)
{
resid[0] = RATES[0] -  (- 1.00000/CONSTANTS[116])*(ALGEBRAIC[50]+ALGEBRAIC[8]+ALGEBRAIC[17]+ALGEBRAIC[26]+ALGEBRAIC[27]+ALGEBRAIC[51]+ALGEBRAIC[38]+ALGEBRAIC[41]+ALGEBRAIC[42]+ALGEBRAIC[45]+ALGEBRAIC[47]+ALGEBRAIC[46]+ALGEBRAIC[48]+ALGEBRAIC[49]+CONSTANTS[132]);
resid[1] = RATES[1] - (ALGEBRAIC[0] - STATES[1])/ALGEBRAIC[1];
resid[2] = RATES[2] - (ALGEBRAIC[4] - STATES[2])/ALGEBRAIC[6];
resid[3] = RATES[3] - (ALGEBRAIC[5] - STATES[3])/ALGEBRAIC[7];
resid[4] = RATES[4] - (ALGEBRAIC[12] - STATES[4])/ALGEBRAIC[11];
resid[5] = RATES[5] - (ALGEBRAIC[16] - STATES[5])/ALGEBRAIC[15];
resid[6] = RATES[6] - (ALGEBRAIC[21] - STATES[6])/ALGEBRAIC[20];
resid[7] = RATES[7] - (ALGEBRAIC[25] - STATES[7])/ALGEBRAIC[24];
resid[8] = RATES[8] - (ALGEBRAIC[28] - STATES[8])/ALGEBRAIC[29];
resid[9] = RATES[9] - (ALGEBRAIC[30] - STATES[9])/ALGEBRAIC[31];
resid[10] = RATES[10] - (ALGEBRAIC[33] - STATES[10])/ALGEBRAIC[34];
resid[11] = RATES[11] - (ALGEBRAIC[35] - STATES[11])/ALGEBRAIC[36];
resid[12] = RATES[12] - (ALGEBRAIC[37] - STATES[12])/CONSTANTS[113];
resid[13] = RATES[13] -  ALGEBRAIC[39]*(1.00000 - STATES[13]) -  ALGEBRAIC[40]*STATES[13];
resid[14] = RATES[14] -  ALGEBRAIC[43]*(1.00000 - STATES[14]) -  ALGEBRAIC[44]*STATES[14];
}
void
computeVariables(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC)
{
}
void
computeEssentialVariables(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC)
{
ALGEBRAIC[0] = (CONSTANTS[0]==0.00000 ? pow(1.00000/(1.00000+exp(- STATES[0]/5.46000)), 1.00000/3.00000) : pow(1.00000/(1.00000+exp(- (STATES[0]+30.3200)/5.46000)), 1.00000/3.00000));
ALGEBRAIC[1] = (CONSTANTS[0]==0.00000 ? 0.000624700/( 0.832000*exp( - 0.335000*(STATES[0]+56.7000))+ 0.627000*exp( 0.0820000*(STATES[0]+65.0100)))+4.00000e-05 : 0.000624700/( 0.832217*exp( - 0.335660*(STATES[0]+56.7062))+ 0.627400*exp( 0.0823000*(STATES[0]+65.0131)))+4.56900e-05);
ALGEBRAIC[4] = 1.00000/(1.00000+exp((STATES[0]+66.1000)/6.40000));
ALGEBRAIC[5] = ALGEBRAIC[4];
ALGEBRAIC[6] = ( 3.71700e-06*exp( - 0.281500*(STATES[0]+17.1100)))/(1.00000+ 0.00373200*exp( - 0.342600*(STATES[0]+37.7600)))+0.000597700;
ALGEBRAIC[7] = ( 3.18600e-08*exp( - 0.621900*(STATES[0]+18.8000)))/(1.00000+ 7.18900e-05*exp( - 0.668300*(STATES[0]+34.0700)))+0.00355600;
ALGEBRAIC[8] =  CONSTANTS[118]*( STATES[5]*STATES[4]+0.00600000/(1.00000+exp(- (STATES[0]+14.1000)/6.00000)))*(STATES[0] - CONSTANTS[21]);
ALGEBRAIC[9] = (CONSTANTS[0]==0.00000 ? ( - 28.3800*(STATES[0]+35.0000))/(exp(- (STATES[0]+35.0000)/2.50000) - 1.00000) - ( 84.9000*STATES[0])/(exp( - 0.208000*STATES[0]) - 1.00000) : CONSTANTS[0]==1.00000 ? ( - 28.3900*(STATES[0]+35.0000))/(exp(- (STATES[0]+35.0000)/2.50000) - 1.00000) - ( 84.9000*STATES[0])/(exp( - 0.208000*STATES[0]) - 1.00000) : ( - 28.4000*(STATES[0]+35.0000))/(exp(- (STATES[0]+35.0000)/2.50000) - 1.00000) - ( 84.9000*STATES[0])/(exp( - 0.208000*STATES[0]) - 1.00000));
ALGEBRAIC[10] = (CONSTANTS[0]==1.00000 ? ( 11.4300*(STATES[0] - 5.00000))/(exp( 0.400000*(STATES[0] - 5.00000)) - 1.00000) : ( 11.4200*(STATES[0] - 5.00000))/(exp( 0.400000*(STATES[0] - 5.00000)) - 1.00000));
ALGEBRAIC[11] = 2.00000/(ALGEBRAIC[9]+ALGEBRAIC[10]);
ALGEBRAIC[12] = (CONSTANTS[0]==0.00000 ? 1.00000/(1.00000+exp(- (STATES[0]+23.1000)/6.00000)) : CONSTANTS[0]==1.00000 ? 1.00000/(1.00000+exp(- (STATES[0]+22.3000+ 0.800000*CONSTANTS[110])/6.00000)) : 1.00000/(1.00000+exp(- (STATES[0]+22.2000)/6.00000)));
ALGEBRAIC[13] = (CONSTANTS[0]==1.00000 ? ( 3.75000*(STATES[0]+28.0000))/(exp((STATES[0]+28.0000)/4.00000) - 1.00000) : ( 3.12000*(STATES[0]+28.0000))/(exp((STATES[0]+28.0000)/4.00000) - 1.00000));
ALGEBRAIC[14] = (CONSTANTS[0]==1.00000 ? 30.0000/(1.00000+exp(- (STATES[0]+28.0000)/4.00000)) : 25.0000/(1.00000+exp(- (STATES[0]+28.0000)/4.00000)));
ALGEBRAIC[15] = (CONSTANTS[0]==1.00000 ? (1.20000 -  0.200000*CONSTANTS[110])/(ALGEBRAIC[13]+ALGEBRAIC[14]) : 1.00000/(ALGEBRAIC[13]+ALGEBRAIC[14]));
ALGEBRAIC[16] = 1.00000/(1.00000+exp((STATES[0]+45.0000)/5.00000));
ALGEBRAIC[17] =  CONSTANTS[119]*STATES[6]*STATES[7]*(STATES[0] - CONSTANTS[28]);
ALGEBRAIC[18] =  1068.00*exp((STATES[0]+26.3000)/30.0000);
ALGEBRAIC[19] =  1068.00*exp(- (STATES[0]+26.3000)/30.0000);
ALGEBRAIC[20] = 1.00000/(ALGEBRAIC[18]+ALGEBRAIC[19]);
ALGEBRAIC[21] = 1.00000/(1.00000+exp(- (STATES[0]+37.0000)/6.80000));
ALGEBRAIC[22] = (CONSTANTS[0]==1.00000 ?  15.3000*exp(- (STATES[0]+71.0000+ 0.700000*CONSTANTS[110])/83.3000) :  15.3000*exp(- (STATES[0]+71.7000)/83.3000));
ALGEBRAIC[23] = (CONSTANTS[0]==1.00000 ?  15.0000*exp((STATES[0]+71.0000)/15.3800) :  15.0000*exp((STATES[0]+71.7000)/15.3800));
ALGEBRAIC[24] = 1.00000/(ALGEBRAIC[22]+ALGEBRAIC[23]);
ALGEBRAIC[25] = 1.00000/(1.00000+exp((STATES[0]+71.0000)/9.00000));
ALGEBRAIC[26] =  CONSTANTS[120]*STATES[8]*STATES[9]*(STATES[0] - CONSTANTS[112]);
ALGEBRAIC[27] =  CONSTANTS[121]*STATES[9]*(STATES[0] - CONSTANTS[112]);
ALGEBRAIC[28] = 1.00000/(1.00000+exp((STATES[0]+59.3700)/13.1000));
ALGEBRAIC[29] = (CONSTANTS[0]==0.00000 ? 0.0101000+0.0651700/( 0.570000*exp( - 0.0800000*(STATES[0]+49.0000)))+ 2.40000e-05*exp( 0.100000*(STATES[0]+50.9300)) : CONSTANTS[0]==1.00000 ?  (0.00100000/3.00000)*(30.3100+195.500/( 0.568600*exp( - 0.0816100*(STATES[0]+39.0000+ 10.0000*CONSTANTS[110]))+ 0.717400*exp( (0.271900 -  0.171900*CONSTANTS[110])*1.00000*(STATES[0]+40.9300+ 10.0000*CONSTANTS[110])))) : 0.0101000+0.0651700/( 0.568600*exp( - 0.0816100*(STATES[0]+39.0000))+ 0.717400*exp( 0.271900*(STATES[0]+40.9300))));
ALGEBRAIC[30] = 1.00000/(1.00000+exp(- (STATES[0] - 10.9300)/19.7000));
ALGEBRAIC[31] = (CONSTANTS[0]==0.00000 ?  0.00100000*(2.98000+15.5900/( 1.03700*exp( 0.0900000*(STATES[0]+30.6100))+ 0.369000*exp( - 0.120000*(STATES[0]+23.8400)))) : CONSTANTS[0]==1.00000 ?  0.00250000*(1.19100+7.83800/( 1.03700*exp( 0.0901200*(STATES[0]+30.6100))+ 0.369000*exp( - 0.119000*(STATES[0]+23.8400)))) :  0.00100000*(2.98000+19.5900/( 1.03700*exp( 0.0901200*(STATES[0]+30.6100))+ 0.369000*exp( - 0.119000*(STATES[0]+23.8400)))));
ALGEBRAIC[33] = (CONSTANTS[0] != 2.00000 ? 1.00000/(1.00000+exp(- (STATES[0]+14.2000)/10.6000)) : 1.00000/(1.00000+exp(- (STATES[0]+13.2000)/10.6000)));
ALGEBRAIC[34] = (CONSTANTS[0] != 2.00000 ? 1.00000/( 37.2000*exp((STATES[0] - 9.00000)/15.9000)+ 0.960000*exp(- (STATES[0] - 9.00000)/22.5000)) : 1.00000/( 37.2000*exp((STATES[0] - 10.0000)/15.9000)+ 0.960000*exp(- (STATES[0] - 10.0000)/22.5000)));
ALGEBRAIC[35] = ALGEBRAIC[33];
ALGEBRAIC[36] = (CONSTANTS[0] != 2.00000 ? 1.00000/( 4.20000*exp((STATES[0] - 9.00000)/17.0000)+ 0.150000*exp(- (STATES[0] - 9.00000)/21.6000)) : 1.00000/( 4.20000*exp((STATES[0] - 10.0000)/17.0000)+ 0.150000*exp(- (STATES[0] - 10.0000)/21.6000)));
ALGEBRAIC[37] = 1.00000/(1.00000+exp((STATES[0]+18.6000)/10.1000));
ALGEBRAIC[38] =  CONSTANTS[123]*pow(STATES[13], 2.00000)*(STATES[0] - CONSTANTS[114]);
ALGEBRAIC[39] = 14.0000/(1.00000+exp(- (STATES[0] - 40.0000)/9.00000));
ALGEBRAIC[40] =  1.00000*exp(- STATES[0]/45.0000);
ALGEBRAIC[41] = (CONSTANTS[0] != 2.00000 ?  CONSTANTS[124]*STATES[14]*(STATES[0] - CONSTANTS[111]) :  CONSTANTS[124]*STATES[14]*(STATES[0] - 77.6000));
ALGEBRAIC[42] = (CONSTANTS[0] != 2.00000 ?  CONSTANTS[125]*STATES[14]*(STATES[0] - CONSTANTS[112]) :  CONSTANTS[125]*STATES[14]*(STATES[0]+102.000));
ALGEBRAIC[43] = (CONSTANTS[0]==0.00000 ?  1.00000*exp(- (STATES[0]+78.9100)/26.6200) :  1.00000*exp(- (STATES[0]+78.9100)/26.6300));
ALGEBRAIC[44] =  1.00000*exp((STATES[0]+75.1300)/21.2500);
ALGEBRAIC[45] =  CONSTANTS[126]*(STATES[0] - CONSTANTS[111]);
ALGEBRAIC[46] =  CONSTANTS[127]*(STATES[0] - CONSTANTS[112]);
ALGEBRAIC[47] =  CONSTANTS[128]*(STATES[0] - CONSTANTS[115]);
ALGEBRAIC[48] = (CONSTANTS[0]==0.00000 ? ( CONSTANTS[129]*( pow(CONSTANTS[91], 3.00000)*CONSTANTS[93]*exp( 0.0374300*STATES[0]*CONSTANTS[90]) -  pow(CONSTANTS[14], 3.00000)*CONSTANTS[92]*exp( 0.0374000*STATES[0]*(CONSTANTS[90] - 1.00000))))/(1.00000+ CONSTANTS[89]*( CONSTANTS[92]*pow(CONSTANTS[14], 3.00000)+ CONSTANTS[93]*pow(CONSTANTS[91], 3.00000))) : ( CONSTANTS[129]*( pow(CONSTANTS[91], 3.00000)*CONSTANTS[93]*exp( 0.0374300*STATES[0]*CONSTANTS[90]) -  pow(CONSTANTS[14], 3.00000)*CONSTANTS[92]*exp( 0.0374300*STATES[0]*(CONSTANTS[90] - 1.00000))))/(1.00000+ CONSTANTS[89]*( CONSTANTS[92]*pow(CONSTANTS[14], 3.00000)+ CONSTANTS[93]*pow(CONSTANTS[91], 3.00000))));
ALGEBRAIC[49] = ( CONSTANTS[130]*pow(CONSTANTS[91]/(CONSTANTS[94]+CONSTANTS[91]), 3.00000)*pow(CONSTANTS[102]/(CONSTANTS[95]+CONSTANTS[102]), 2.00000)*1.60000)/(1.50000+exp(- (STATES[0]+60.0000)/40.0000));
ALGEBRAIC[2] = (CONSTANTS[0]==0.00000 ? ( 0.0952000*exp( - 0.0630000*(STATES[0]+34.4000)))/(1.00000+ 1.66000*exp( - 0.225000*(STATES[0]+63.7000)))+0.0869000 : ( 0.0951800*exp( - 0.0630600*(STATES[0]+34.4000)))/(1.00000+ 1.66200*exp( - 0.225100*(STATES[0]+63.7000)))+0.0869300);
ALGEBRAIC[3] =  (1.00000 - ALGEBRAIC[2])*STATES[2]+ ALGEBRAIC[2]*STATES[3];
ALGEBRAIC[50] =  (( (( CONSTANTS[117]*pow(STATES[1], 3.00000)*ALGEBRAIC[3]*CONSTANTS[14]*pow(CONSTANTS[5], 2.00000))/( CONSTANTS[3]*CONSTANTS[4]))*(exp(( (STATES[0] - CONSTANTS[111])*CONSTANTS[5])/( CONSTANTS[3]*CONSTANTS[4])) - 1.00000))/(exp(( STATES[0]*CONSTANTS[5])/( CONSTANTS[3]*CONSTANTS[4])) - 1.00000))*STATES[0];
ALGEBRAIC[32] =  0.600000*STATES[10]+ 0.400000*STATES[11];
ALGEBRAIC[51] =  CONSTANTS[122]*ALGEBRAIC[32]*STATES[12]*(STATES[0] - CONSTANTS[112]);
}
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;
}
void
computeRoots(double VOI, double* CONSTANTS, double* RATES, double* OLDRATES, double* STATES,
             double* OLDSTATES, double* ALGEBRAIC, double* CONDVARS)
{
}