diff --git a/RELEASE.md b/RELEASE.md index a71dd9ca..31f665d2 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -1,5 +1,9 @@ # Release 0.9.6 +- This release fixes a bug printing large integers, in some environments: Large numbers such as 8.034023767017109e+27 whch were actually ints would be printed as an the int 8034023767017108950029959168 and then the C++ compiler would complain as that's more than the maximum int value. This has been fixed by only printing ints as ints if they are `MIN_INT < number < MAX_INT` else we print them as a float (and we get the sceintific notation). + +# Release 0.9.6 (yanked) - Fixed tests to pass with sympy 1.10 and required latest cellmlmanip, which also workes with sympy1.10. Updated sympy requirement to be >=1.9, < 1.11 +- This release was yanked due to a bug printing large integers # Release 0.9.5 - Corrected a type in the generated output for `--rush-larsen-c` diff --git a/chaste_codegen/_chaste_printer.py b/chaste_codegen/_chaste_printer.py index a6693067..74ca9c51 100644 --- a/chaste_codegen/_chaste_printer.py +++ b/chaste_codegen/_chaste_printer.py @@ -12,6 +12,10 @@ from sympy.printing.precedence import precedence +C_MAX_INT = 2147483647 +C_MIN_INT = -2147483647 + + class ChastePrinter(Printer): """ Converts Sympy expressions to strings for use in Chaste code generation. @@ -141,18 +145,19 @@ def _print_ternary(self, cond, expr): return parts def _print_IntegerConstant(self, expr): - return cxxcode(int(expr), standard='C++11') + return self._print_int(float(expr)) def _print_float(self, expr): """ Handles ``float``s. """ - if expr.is_integer(): + # print integers as int if they are between min & max int in c++ + if expr.is_integer() and C_MIN_INT < expr < C_MAX_INT: return cxxcode(int(expr), standard='C++11') else: - return cxxcode(expr, standard='C++11') + return cxxcode(float(expr), standard='C++11') def _print_int(self, expr): """ Handles ``ints``s. """ - return cxxcode(int(expr), standard='C++11') + return self._print_float(float(expr)) def _print_ITE(self, expr): """ Handles ITE (if then else) objects by rewriting them as Piecewise """ diff --git a/chaste_codegen/data/tests/chaste_reference_models/BE/dynamic_courtemanche_ramirez_nattel_1998.cpp b/chaste_codegen/data/tests/chaste_reference_models/BE/dynamic_courtemanche_ramirez_nattel_1998.cpp index 636da0c4..a0cef475 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/BE/dynamic_courtemanche_ramirez_nattel_1998.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/BE/dynamic_courtemanche_ramirez_nattel_1998.cpp @@ -256,9 +256,9 @@ bool Dynamiccourtemanche_ramirez_nattel_1998FromCellMLBackwardEuler::registered const double var_background_currents__i_B_Ca = (-var_background_currents__E_Ca + var_chaste_interface__membrane__V) * var_background_currents__g_B_Ca * mParameters[9]; // picoA const double var_Na_Ca_exchanger_current__i_NaCa = (pow(var_chaste_interface__intracellular_ion_concentrations__Na_i, 3) * mParameters[4] * exp(var_Na_Ca_exchanger_current__gamma * var_membrane__F * var_chaste_interface__membrane__V / (var_membrane__R * var_membrane__T)) - pow(mParameters[6], 3) * var_chaste_interface__intracellular_ion_concentrations__Ca_i * exp((-1 + var_Na_Ca_exchanger_current__gamma) * var_membrane__F * var_chaste_interface__membrane__V / (var_membrane__R * var_membrane__T))) * mParameters[16] * mParameters[9] / ((1 + var_Na_Ca_exchanger_current__K_sat * exp((-1 + var_Na_Ca_exchanger_current__gamma) * var_membrane__F * var_chaste_interface__membrane__V / (var_membrane__R * var_membrane__T))) * (pow(var_Na_Ca_exchanger_current__K_mNa, 3) + pow(mParameters[6], 3)) * (var_Na_Ca_exchanger_current__K_mCa + mParameters[4])); // picoA const double var_Ca_release_current_from_JSR__Fn = 9.9999999999999998e-13 * var_Ca_release_current_from_JSR__i_rel * var_intracellular_ion_concentrations__V_rel - 4.9999999999999999e-13 * (0.5 * var_L_type_Ca_channel__i_Ca_L - 0.20000000000000001 * var_Na_Ca_exchanger_current__i_NaCa) / var_membrane__F; // dimensionless - const double var_Ca_release_current_from_JSR_u_gate__u_infinity = 1 / (1 + exp(250 - 731528895391368 * var_Ca_release_current_from_JSR__Fn)); // dimensionless - const double var_Ca_release_current_from_JSR_v_gate__tau_v = 1.9099999999999999 + 2.0899999999999999 / (1 + exp(250 - 731528895391368 * var_Ca_release_current_from_JSR__Fn)); // millisecond - const double var_Ca_release_current_from_JSR_v_gate__v_infinity = 1 - 1 / (1 + exp(50 - 731528895391368 * var_Ca_release_current_from_JSR__Fn)); // dimensionless + const double var_Ca_release_current_from_JSR_u_gate__u_infinity = 1 / (1 + exp(250 - 731528895391368.0 * var_Ca_release_current_from_JSR__Fn)); // dimensionless + const double var_Ca_release_current_from_JSR_v_gate__tau_v = 1.9099999999999999 + 2.0899999999999999 / (1 + exp(250 - 731528895391368.0 * var_Ca_release_current_from_JSR__Fn)); // millisecond + const double var_Ca_release_current_from_JSR_v_gate__v_infinity = 1 - 1 / (1 + exp(50 - 731528895391368.0 * var_Ca_release_current_from_JSR__Fn)); // dimensionless const double d_dt_chaste_interface_var_Ca_release_current_from_JSR_u_gate__u = (-var_chaste_interface__Ca_release_current_from_JSR_u_gate__u + var_Ca_release_current_from_JSR_u_gate__u_infinity) / var_Ca_release_current_from_JSR_u_gate__tau_u; // 1 / millisecond const double d_dt_chaste_interface_var_Ca_release_current_from_JSR_v_gate__v = (-var_chaste_interface__Ca_release_current_from_JSR_v_gate__v + var_Ca_release_current_from_JSR_v_gate__v_infinity) / var_Ca_release_current_from_JSR_v_gate__tau_v; // 1 / millisecond const double var_fast_sodium_current__E_Na = var_membrane__R * var_membrane__T * log(mParameters[6] / var_chaste_interface__intracellular_ion_concentrations__Na_i) / var_membrane__F; // millivolt diff --git a/chaste_codegen/data/tests/chaste_reference_models/BE/dynamic_courtemanche_ramirez_nattel_1998.cpp_alt b/chaste_codegen/data/tests/chaste_reference_models/BE/dynamic_courtemanche_ramirez_nattel_1998.cpp_alt index e80aca4c..b83c8a7b 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/BE/dynamic_courtemanche_ramirez_nattel_1998.cpp_alt +++ b/chaste_codegen/data/tests/chaste_reference_models/BE/dynamic_courtemanche_ramirez_nattel_1998.cpp_alt @@ -256,9 +256,9 @@ bool Dynamiccourtemanche_ramirez_nattel_1998FromCellMLBackwardEuler::registered const double var_background_currents__i_B_Ca = (-var_background_currents__E_Ca + var_chaste_interface__membrane__V) * var_background_currents__g_B_Ca * mParameters[9]; // picoA const double var_Na_Ca_exchanger_current__i_NaCa = (pow(var_chaste_interface__intracellular_ion_concentrations__Na_i, 3) * mParameters[4] * exp(var_Na_Ca_exchanger_current__gamma * var_membrane__F * var_chaste_interface__membrane__V / (var_membrane__R * var_membrane__T)) - pow(mParameters[6], 3) * var_chaste_interface__intracellular_ion_concentrations__Ca_i * exp((-1 + var_Na_Ca_exchanger_current__gamma) * var_membrane__F * var_chaste_interface__membrane__V / (var_membrane__R * var_membrane__T))) * mParameters[16] * mParameters[9] / ((1 + var_Na_Ca_exchanger_current__K_sat * exp((-1 + var_Na_Ca_exchanger_current__gamma) * var_membrane__F * var_chaste_interface__membrane__V / (var_membrane__R * var_membrane__T))) * (pow(var_Na_Ca_exchanger_current__K_mNa, 3) + pow(mParameters[6], 3)) * (var_Na_Ca_exchanger_current__K_mCa + mParameters[4])); // picoA const double var_Ca_release_current_from_JSR__Fn = 9.9999999999999998e-13 * var_Ca_release_current_from_JSR__i_rel * var_intracellular_ion_concentrations__V_rel - 4.9999999999999999e-13 * (0.5 * var_L_type_Ca_channel__i_Ca_L - 0.20000000000000001 * var_Na_Ca_exchanger_current__i_NaCa) / var_membrane__F; // dimensionless - const double var_Ca_release_current_from_JSR_u_gate__u_infinity = 1 / (1 + exp(250 - 731528895391368 * var_Ca_release_current_from_JSR__Fn)); // dimensionless - const double var_Ca_release_current_from_JSR_v_gate__tau_v = 1.9099999999999999 + 2.0899999999999999 / (1 + exp(250 - 731528895391368 * var_Ca_release_current_from_JSR__Fn)); // millisecond - const double var_Ca_release_current_from_JSR_v_gate__v_infinity = 1 - 1 / (1 + exp(50 - 731528895391368 * var_Ca_release_current_from_JSR__Fn)); // dimensionless + const double var_Ca_release_current_from_JSR_u_gate__u_infinity = 1 / (1 + exp(250 - 731528895391368.0 * var_Ca_release_current_from_JSR__Fn)); // dimensionless + const double var_Ca_release_current_from_JSR_v_gate__tau_v = 1.9099999999999999 + 2.0899999999999999 / (1 + exp(250 - 731528895391368.0 * var_Ca_release_current_from_JSR__Fn)); // millisecond + const double var_Ca_release_current_from_JSR_v_gate__v_infinity = 1 - 1 / (1 + exp(50 - 731528895391368.0 * var_Ca_release_current_from_JSR__Fn)); // dimensionless const double d_dt_chaste_interface_var_Ca_release_current_from_JSR_u_gate__u = (-var_chaste_interface__Ca_release_current_from_JSR_u_gate__u + var_Ca_release_current_from_JSR_u_gate__u_infinity) / var_Ca_release_current_from_JSR_u_gate__tau_u; // 1 / millisecond const double d_dt_chaste_interface_var_Ca_release_current_from_JSR_v_gate__v = (-var_chaste_interface__Ca_release_current_from_JSR_v_gate__v + var_Ca_release_current_from_JSR_v_gate__v_infinity) / var_Ca_release_current_from_JSR_v_gate__tau_v; // 1 / millisecond const double var_fast_sodium_current__E_Na = var_membrane__R * var_membrane__T * log(mParameters[6] / var_chaste_interface__intracellular_ion_concentrations__Na_i) / var_membrane__F; // millivolt diff --git a/chaste_codegen/data/tests/chaste_reference_models/BE/li_mouse_2010.cpp b/chaste_codegen/data/tests/chaste_reference_models/BE/li_mouse_2010.cpp index b1d77bbb..e2d5b2a4 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/BE/li_mouse_2010.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/BE/li_mouse_2010.cpp @@ -293,7 +293,7 @@ const double var_cell__VNSR = 2.3099999999999999e-7; // microlitre const double var_cell__Vmyo = 2.1999999999999999e-5; // microlitre const double var_cell__Vss = 2.1999999999999998e-8; // microlitre - const double var_cell__prepulses_number = 10000000000; // dimensionless + const double var_cell__prepulses_number = 10000000000.0; // dimensionless const double var_chaste_interface__cell__stim_period = 333.33300000000003; // millisecond const double var_calcium_fluxes__J_leak = ((var_chaste_interface__environment__time < var_cell__prepulses_number * var_chaste_interface__cell__stim_period) ? ((-var_calcium_concentration__Cai + var_chaste_interface__calcium_concentration__CaNSR) * var_calcium_fluxes__v2) : ((-var_calcium_concentration__Cai + var_chaste_interface__calcium_concentration__CaNSR) * var_calcium_fluxes__v2_caff)); // micromolar_per_millisecond const double d_dt_chaste_interface_var_calcium_concentration__CaNSR = (-var_calcium_fluxes__J_leak + var_calcium_fluxes__J_serca) * var_cell__Vmyo / var_cell__VNSR - var_calcium_fluxes__J_tr * var_cell__VJSR / var_cell__VNSR; // micromolar / millisecond @@ -508,13 +508,13 @@ const double var_x56 = var_x51 * (1 + 5.7870370370370368e-13 * var_x53); const double var_x57 = 1000 * var_x51; const double var_x58 = var_x57 * var_chaste_interface__calcium_concentration__Cai_converted; - const double var_x59 = 1 / (var_x54 + var_x58 + 1400 * var_x53 + 1728000000000 * var_x55 + 3.6000000000000001 * var_x56 + 681472000000000000 * var_chaste_interface__calcium_concentration__Cai_converted); + const double var_x59 = 1 / (var_x54 + var_x58 + 1400 * var_x53 + 1728000000000.0 * var_x55 + 3.6000000000000001 * var_x56 + 6.81472e+17 * var_chaste_interface__calcium_concentration__Cai_converted); const double var_x60 = var_x52 * var_x59 * mParameters[11]; const double var_x61 = var_x50 * var_x51 * var_x60; const double var_x62 = pow((2.0543764087152516e-15 * var_x53 + 5.282682193839219e-18 * var_x56 + 2.535687453042825e-6 * var_x55 + 1.4674117205108941e-18 * var_x54 + 1.4674117205108941e-15 * var_x51 * var_chaste_interface__calcium_concentration__Cai_converted + var_chaste_interface__calcium_concentration__Cai_converted), (-2)); const double var_x63 = exp(0.013189690992192795 * var_chaste_interface__cell__V); const double var_x64 = -var_x50 * var_x58 + var_x53 * var_x63 * mParameters[1]; - const double var_x65 = -681472000000000000 - var_x57 - 480000000000000 * mParameters[1]; + const double var_x65 = -6.81472e+17 - var_x57 - 480000000000000.0 * mParameters[1]; const double var_x66 = var_x31 * var_x35; const double var_x67 = var_x52 * var_x64 * mParameters[11]; const double var_x68 = pow(var_chaste_interface__sodium_concentration__Nai, 2); @@ -1498,7 +1498,7 @@ const double var_cell__T = 308; // kelvin const double var_L_type_calcium_current__i_CaL = (((var_chaste_interface__cell__V >= -1.3267937823834197e-6) && (var_chaste_interface__cell__V <= 1.3267937823834197e-6)) ? (376848.31406265136 * (1.3267937823834197e-6 + var_chaste_interface__cell__V) * (-3.0621664503101105e-9 * (-var_chaste_interface__calcium_concentration__Cass + mParameters[1] * exp(9.9999999999999995e-8)) * var_chaste_interface__L_type_calcium_current__O * mParameters[4] * var_chaste_interface__L_type_calcium_current__y_gate / ((1 - exp(9.9999999999999995e-8)) * mParameters[5]) - 3.0621664503101105e-9 * (-var_chaste_interface__calcium_concentration__Cass + mParameters[1] * exp(-9.9999999999999995e-8)) * var_chaste_interface__L_type_calcium_current__O * mParameters[4] * var_chaste_interface__L_type_calcium_current__y_gate / ((1 - exp(-9.9999999999999995e-8)) * mParameters[5])) + 3.0621664503101105e-9 * (-var_chaste_interface__calcium_concentration__Cass + mParameters[1] * exp(9.9999999999999995e-8)) * var_chaste_interface__L_type_calcium_current__O * mParameters[4] * var_chaste_interface__L_type_calcium_current__y_gate / ((1 - exp(9.9999999999999995e-8)) * mParameters[5])) : (-0.0023079445283571576 * (-var_chaste_interface__calcium_concentration__Cass + mParameters[1] * exp(-0.075369662812530269 * var_chaste_interface__cell__V)) * var_chaste_interface__L_type_calcium_current__O * mParameters[4] * var_chaste_interface__L_type_calcium_current__y_gate * var_chaste_interface__cell__V / ((1 - exp(-0.075369662812530269 * var_chaste_interface__cell__V)) * mParameters[5]))); // picoA_per_picoF const double var_L_type_calcium_current__i_CaL_converted = HeartConfig::Instance()->GetCapacitance() * var_L_type_calcium_current__i_CaL; // uA_per_cm2 - const double var_cell__prepulses_number = 10000000000; // dimensionless + const double var_cell__prepulses_number = 10000000000.0; // dimensionless const double var_chaste_interface__cell__stim_period = 333.33300000000003; // millisecond const double var_cell__i_Stim_converted = GetIntracellularAreaStimulus(var_chaste_interface__environment__time); // uA_per_cm2 const double var_fast_transient_outward_K_I__E_K = var_cell__R * var_cell__T * log(mParameters[2] / var_chaste_interface__potassium_concentration__Ki) / var_cell__F; // millivolt diff --git a/chaste_codegen/data/tests/chaste_reference_models/BE/li_mouse_2010.cpp_alt b/chaste_codegen/data/tests/chaste_reference_models/BE/li_mouse_2010.cpp_alt index 9ab044cd..4113ad61 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/BE/li_mouse_2010.cpp_alt +++ b/chaste_codegen/data/tests/chaste_reference_models/BE/li_mouse_2010.cpp_alt @@ -293,7 +293,7 @@ const double var_cell__VNSR = 2.3099999999999999e-7; // microlitre const double var_cell__Vmyo = 2.1999999999999999e-5; // microlitre const double var_cell__Vss = 2.1999999999999998e-8; // microlitre - const double var_cell__prepulses_number = 10000000000; // dimensionless + const double var_cell__prepulses_number = 10000000000.0; // dimensionless const double var_chaste_interface__cell__stim_period = 333.33300000000003; // millisecond const double var_calcium_fluxes__J_leak = ((var_chaste_interface__environment__time < var_cell__prepulses_number * var_chaste_interface__cell__stim_period) ? ((-var_calcium_concentration__Cai + var_chaste_interface__calcium_concentration__CaNSR) * var_calcium_fluxes__v2) : ((-var_calcium_concentration__Cai + var_chaste_interface__calcium_concentration__CaNSR) * var_calcium_fluxes__v2_caff)); // micromolar_per_millisecond const double d_dt_chaste_interface_var_calcium_concentration__CaNSR = (-var_calcium_fluxes__J_leak + var_calcium_fluxes__J_serca) * var_cell__Vmyo / var_cell__VNSR - var_calcium_fluxes__J_tr * var_cell__VJSR / var_cell__VNSR; // micromolar / millisecond @@ -505,7 +505,7 @@ const double var_x53 = 1 / (0.083232249999999994 + var_x25); const double var_x54 = pow(mParameters[3], 3); const double var_x55 = 1000 * var_x54; - const double var_x56 = -681472000000000000 - var_x55 - 480000000000000 * mParameters[1]; + const double var_x56 = -6.81472e+17 - var_x55 - 480000000000000.0 * mParameters[1]; const double var_x57 = pow(var_chaste_interface__sodium_concentration__Nai, 3); const double var_x58 = var_x54 * (1 + 5.7870370370370368e-13 * var_x57); const double var_x59 = (1 + 277.77777777777777 * var_chaste_interface__calcium_concentration__Cai_converted) * mParameters[1]; @@ -517,7 +517,7 @@ const double var_x65 = var_x62 * (var_x60 * var_x63 - var_x61 * var_x64) * mParameters[11]; const double var_x66 = var_x65 / pow((2.0543764087152516e-15 * var_x57 + 5.282682193839219e-18 * var_x58 + 2.535687453042825e-6 * var_x59 + 1.4674117205108941e-18 * var_x60 + 1.4674117205108941e-15 * var_x54 * var_chaste_interface__calcium_concentration__Cai_converted + var_chaste_interface__calcium_concentration__Cai_converted), 2); const double var_x67 = 1.4063880539705308e-37 * var_x66; - const double var_x68 = 1 / (var_x60 + var_x64 + 1400 * var_x57 + 1728000000000 * var_x59 + 3.6000000000000001 * var_x58 + 681472000000000000 * var_chaste_interface__calcium_concentration__Cai_converted); + const double var_x68 = 1 / (var_x60 + var_x64 + 1400 * var_x57 + 1728000000000.0 * var_x59 + 3.6000000000000001 * var_x58 + 6.81472e+17 * var_chaste_interface__calcium_concentration__Cai_converted); const double var_x69 = var_x62 * var_x68 * mParameters[11]; const double var_x70 = var_x54 * var_x61 * var_x69; const double var_x71 = pow(var_chaste_interface__sodium_concentration__Nai, 2); @@ -1504,7 +1504,7 @@ const double var_cell__T = 308; // kelvin const double var_L_type_calcium_current__i_CaL = (((var_chaste_interface__cell__V >= -1.3267937823834197e-6) && (var_chaste_interface__cell__V <= 1.3267937823834197e-6)) ? (376848.31406265136 * (1.3267937823834197e-6 + var_chaste_interface__cell__V) * (-3.0621664503101105e-9 * (-var_chaste_interface__calcium_concentration__Cass + mParameters[1] * exp(9.9999999999999995e-8)) * var_chaste_interface__L_type_calcium_current__O * mParameters[4] * var_chaste_interface__L_type_calcium_current__y_gate / ((1 - exp(9.9999999999999995e-8)) * mParameters[5]) - 3.0621664503101105e-9 * (-var_chaste_interface__calcium_concentration__Cass + mParameters[1] * exp(-9.9999999999999995e-8)) * var_chaste_interface__L_type_calcium_current__O * mParameters[4] * var_chaste_interface__L_type_calcium_current__y_gate / ((1 - exp(-9.9999999999999995e-8)) * mParameters[5])) + 3.0621664503101105e-9 * (-var_chaste_interface__calcium_concentration__Cass + mParameters[1] * exp(9.9999999999999995e-8)) * var_chaste_interface__L_type_calcium_current__O * mParameters[4] * var_chaste_interface__L_type_calcium_current__y_gate / ((1 - exp(9.9999999999999995e-8)) * mParameters[5])) : (-0.0023079445283571576 * (-var_chaste_interface__calcium_concentration__Cass + mParameters[1] * exp(-0.075369662812530269 * var_chaste_interface__cell__V)) * var_chaste_interface__L_type_calcium_current__O * mParameters[4] * var_chaste_interface__L_type_calcium_current__y_gate * var_chaste_interface__cell__V / ((1 - exp(-0.075369662812530269 * var_chaste_interface__cell__V)) * mParameters[5]))); // picoA_per_picoF const double var_L_type_calcium_current__i_CaL_converted = HeartConfig::Instance()->GetCapacitance() * var_L_type_calcium_current__i_CaL; // uA_per_cm2 - const double var_cell__prepulses_number = 10000000000; // dimensionless + const double var_cell__prepulses_number = 10000000000.0; // dimensionless const double var_chaste_interface__cell__stim_period = 333.33300000000003; // millisecond const double var_cell__i_Stim_converted = GetIntracellularAreaStimulus(var_chaste_interface__environment__time); // uA_per_cm2 const double var_fast_transient_outward_K_I__E_K = var_cell__R * var_cell__T * log(mParameters[2] / var_chaste_interface__potassium_concentration__Ki) / var_cell__F; // millivolt diff --git a/chaste_codegen/data/tests/chaste_reference_models/BEopt/bondarenko_szigeti_bett_kim_rasmusson_2004_apical.cpp b/chaste_codegen/data/tests/chaste_reference_models/BEopt/bondarenko_szigeti_bett_kim_rasmusson_2004_apical.cpp index c0acab59..0bffba1c 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/BEopt/bondarenko_szigeti_bett_kim_rasmusson_2004_apical.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/BEopt/bondarenko_szigeti_bett_kim_rasmusson_2004_apical.cpp @@ -808,7 +808,7 @@ std::shared_ptrGetCapacitance() * var_chaste_interface__fast_sodium_current__O_Na * mParameters[9]; // uA_per_cm2 const double var_rapid_delayed_rectifier_potassium_current__i_Kr_converted = (-25.674321243523316 * log((mParameters[5] + 0.020408163265306124 * mParameters[6]) / (var_chaste_interface__potassium_concentration__Ki + 0.020408163265306124 * var_chaste_interface__sodium_concentration__Nai)) + var_chaste_interface__membrane__V) * HeartConfig::Instance()->GetCapacitance() * var_chaste_interface__rapid_delayed_rectifier_potassium_current__O_K * mParameters[13]; // uA_per_cm2 const double var_sodium_background_current__i_Nab = 0.0025999999999999999 * var_chaste_interface__membrane__V - 0.0025999999999999999 * var_fast_sodium_current__E_Na; // picoA_per_picoF - const double var_sodium_calcium_exchange_current__i_NaCa_converted = (pow(var_chaste_interface__sodium_concentration__Nai, 3) * mParameters[4] * _lt_0_row[1] - pow(mParameters[6], 3) * var_calcium_concentration__Cai * _lt_0_row[2]) * HeartConfig::Instance()->GetCapacitance() * mParameters[15] / ((_lt_0_row[3]) * (1380 + mParameters[4]) * (669921875000000 + pow(mParameters[6], 3))); // uA_per_cm2 + const double var_sodium_calcium_exchange_current__i_NaCa_converted = (pow(var_chaste_interface__sodium_concentration__Nai, 3) * mParameters[4] * _lt_0_row[1] - pow(mParameters[6], 3) * var_calcium_concentration__Cai * _lt_0_row[2]) * HeartConfig::Instance()->GetCapacitance() * mParameters[15] / ((_lt_0_row[3]) * (1380 + mParameters[4]) * (669921875000000.0 + pow(mParameters[6], 3))); // uA_per_cm2 const double var_sodium_potassium_pump_current__i_NaK = 0.88 * mParameters[5] / ((1 + 3043189.1166997822 * pow((1 / var_chaste_interface__sodium_concentration__Nai), 1.5)) * (1500 + mParameters[5]) * (1 + _lt_0_row[5] + 0.036499999999999998 * (-0.14285714285714285 + 0.14285714285714285 * exp(1.4858841010401188e-5 * mParameters[6])) * _lt_0_row[4])); // picoA_per_picoF const double var_time_independent_potassium_current__i_K1_converted = (-var_fast_transient_outward_potassium_current__E_K + var_chaste_interface__membrane__V) * HeartConfig::Instance()->GetCapacitance() * mParameters[5] * mParameters[11] / ((1 + exp(0.089599999999999999 * var_chaste_interface__membrane__V - 0.089599999999999999 * var_fast_transient_outward_potassium_current__E_K)) * (210 + mParameters[5])); // uA_per_cm2 const double var_ultra_rapidly_activating_delayed_rectifier_potassium_current__i_Kur = 0.16 * (-var_fast_transient_outward_potassium_current__E_K + var_chaste_interface__membrane__V) * var_chaste_interface__ultra_rapidly_activating_delayed_rectifier_potassium_current__aur * var_chaste_interface__ultra_rapidly_activating_delayed_rectifier_potassium_current__iur; // picoA_per_picoF @@ -950,7 +950,7 @@ std::shared_ptrGetCapacitance() * var_chaste_interface__fast_sodium_current__O_Na * mParameters[9]; // uA_per_cm2 const double var_rapid_delayed_rectifier_potassium_current__i_Kr_converted = (-25.674321243523316 * log((mParameters[5] + 0.020408163265306124 * mParameters[6]) / (var_chaste_interface__potassium_concentration__Ki + 0.020408163265306124 * var_chaste_interface__sodium_concentration__Nai)) + var_chaste_interface__membrane__V) * HeartConfig::Instance()->GetCapacitance() * var_chaste_interface__rapid_delayed_rectifier_potassium_current__O_K * mParameters[13]; // uA_per_cm2 const double var_sodium_background_current__i_Nab = 0.0025999999999999999 * var_chaste_interface__membrane__V - 0.0025999999999999999 * var_fast_sodium_current__E_Na; // picoA_per_picoF - const double var_sodium_calcium_exchange_current__i_NaCa_converted = (pow(var_chaste_interface__sodium_concentration__Nai, 3) * mParameters[4] * _lt_0_row[1] - pow(mParameters[6], 3) * var_calcium_concentration__Cai * _lt_0_row[2]) * HeartConfig::Instance()->GetCapacitance() * mParameters[15] / ((_lt_0_row[3]) * (1380 + mParameters[4]) * (669921875000000 + pow(mParameters[6], 3))); // uA_per_cm2 + const double var_sodium_calcium_exchange_current__i_NaCa_converted = (pow(var_chaste_interface__sodium_concentration__Nai, 3) * mParameters[4] * _lt_0_row[1] - pow(mParameters[6], 3) * var_calcium_concentration__Cai * _lt_0_row[2]) * HeartConfig::Instance()->GetCapacitance() * mParameters[15] / ((_lt_0_row[3]) * (1380 + mParameters[4]) * (669921875000000.0 + pow(mParameters[6], 3))); // uA_per_cm2 const double var_sodium_potassium_pump_current__i_NaK = 0.88 * mParameters[5] / ((1 + 3043189.1166997822 * pow((1 / var_chaste_interface__sodium_concentration__Nai), 1.5)) * (1500 + mParameters[5]) * (1 + _lt_0_row[5] + 0.036499999999999998 * (-0.14285714285714285 + 0.14285714285714285 * exp(1.4858841010401188e-5 * mParameters[6])) * _lt_0_row[4])); // picoA_per_picoF const double var_time_independent_potassium_current__i_K1_converted = (-var_fast_transient_outward_potassium_current__E_K + var_chaste_interface__membrane__V) * HeartConfig::Instance()->GetCapacitance() * mParameters[5] * mParameters[11] / ((1 + exp(0.089599999999999999 * var_chaste_interface__membrane__V - 0.089599999999999999 * var_fast_transient_outward_potassium_current__E_K)) * (210 + mParameters[5])); // uA_per_cm2 const double var_ultra_rapidly_activating_delayed_rectifier_potassium_current__i_Kur = 0.16 * (-var_fast_transient_outward_potassium_current__E_K + var_chaste_interface__membrane__V) * var_chaste_interface__ultra_rapidly_activating_delayed_rectifier_potassium_current__aur * var_chaste_interface__ultra_rapidly_activating_delayed_rectifier_potassium_current__iur; // picoA_per_picoF @@ -950,7 +950,7 @@ std::shared_ptr -0.059999999999999998) && (var_chaste_interface__calcium_dynamics__g < var_calcium_dynamics__g_inf)) ? (0) : (1)); // dimensionless const double var_calcium_dynamics__i_leak = (-var_chaste_interface__calcium_dynamics__Cai + var_chaste_interface__calcium_dynamics__Ca_SR) * var_calcium_dynamics__V_leak; // millimolar_per_second const double var_calcium_dynamics__i_up = var_calcium_dynamics__VmaxUp / (1 + pow(var_calcium_dynamics__Kup, 2) / pow(var_chaste_interface__calcium_dynamics__Cai, 2)); // millimolar_per_second @@ -287,7 +287,7 @@ const double var_i_CaL_f2_gate__tau_f2 = 0.001 * (16 / (1 + exp(3 + 100 * var_Membrane__Vm)) + 31 / (1 + exp(2.5 - 100 * var_Membrane__Vm)) + 600 * exp(-5882.3529411764703 * pow((0.025000000000000001 + var_Membrane__Vm), 2))) * var_i_CaL_f2_gate__constf2; // second const double var_i_CaL_f2_gate__f2_orig_deriv = (-var_chaste_interface__i_CaL_f2_gate__f2 + var_i_CaL_f2_gate__f2_inf) / var_i_CaL_f2_gate__tau_f2; // 1 / second const double d_dt_chaste_interface_var_i_CaL_f2_gate__f2 = 0.001 * var_i_CaL_f2_gate__f2_orig_deriv; // 1 / millisecond - const double var_i_CaL_fCa_gate__alpha_fCa = 1 / (1 + 59537418076512766132224000 * pow(var_chaste_interface__calcium_dynamics__Cai, 8)); // dimensionless + const double var_i_CaL_fCa_gate__alpha_fCa = 1 / (1 + 5.9537418076512766e+25 * pow(var_chaste_interface__calcium_dynamics__Cai, 8)); // dimensionless const double var_i_CaL_fCa_gate__beta_fCa = 0.10000000000000001 / (1 + exp(-9 + 10000 * var_chaste_interface__calcium_dynamics__Cai)); // dimensionless const double var_i_CaL_fCa_gate__gamma_fCa = 0.29999999999999999 / (1 + exp(-0.9375 + 1250 * var_chaste_interface__calcium_dynamics__Cai)); // dimensionless const double var_i_CaL_fCa_gate__fCa_inf = 0.76010945576162958 * var_i_CaL_fCa_gate__alpha_fCa + 0.76010945576162958 * var_i_CaL_fCa_gate__beta_fCa + 0.76010945576162958 * var_i_CaL_fCa_gate__gamma_fCa; // dimensionless @@ -373,11 +373,11 @@ const double var_electric_potentials__E_Na = var_model_parameters__R * NV_Ith_S(mParameters, 12) * log(NV_Ith_S(mParameters, 3) / var_chaste_interface__sodium_dynamics__Nai) / var_model_parameters__F; // volt const double var_i_Na__i_Na = pow(var_chaste_interface__i_Na_m_gate__m, 3) * (-var_electric_potentials__E_Na + var_Membrane__Vm) * var_i_Na__TTX_coeff * NV_Ith_S(mParameters, 5) * var_chaste_interface__i_Na_h_gate__h * var_chaste_interface__i_Na_j_gate__j; // A_per_F const double var_i_NaCa__i_NaCa = (pow(var_chaste_interface__sodium_dynamics__Nai, 3) * NV_Ith_S(mParameters, 1) * exp(var_Membrane__Vm * var_i_NaCa__gamma * var_model_parameters__F / (var_model_parameters__R * NV_Ith_S(mParameters, 12))) - pow(NV_Ith_S(mParameters, 3), 3) * var_chaste_interface__calcium_dynamics__Cai * var_i_NaCa__alpha * exp((-1 + var_i_NaCa__gamma) * var_Membrane__Vm * var_model_parameters__F / (var_model_parameters__R * NV_Ith_S(mParameters, 12)))) * var_i_NaCa__kNaCa / ((1 + var_i_NaCa__Ksat * exp((-1 + var_i_NaCa__gamma) * var_Membrane__Vm * var_model_parameters__F / (var_model_parameters__R * NV_Ith_S(mParameters, 12)))) * (pow(var_i_NaCa__KmNai, 3) + pow(NV_Ith_S(mParameters, 3), 3)) * (var_i_NaCa__KmCa + NV_Ith_S(mParameters, 1))); // A_per_F - const double var_calcium_dynamics__Cai_orig_deriv = (-var_calcium_dynamics__i_up - 499999999999999936 * (-2 * var_i_NaCa__i_NaCa + var_i_CaL__i_CaL + var_i_PCa__i_PCa + var_i_b_Ca__i_b_Ca) * NV_Ith_S(mParameters, 11) / (var_model_parameters__F * var_model_parameters__Vc) + var_calcium_dynamics__i_leak + var_calcium_dynamics__i_rel) * var_calcium_dynamics__Cai_bufc; // millimolar / second + const double var_calcium_dynamics__Cai_orig_deriv = (-var_calcium_dynamics__i_up - 4.9999999999999994e+17 * (-2 * var_i_NaCa__i_NaCa + var_i_CaL__i_CaL + var_i_PCa__i_PCa + var_i_b_Ca__i_b_Ca) * NV_Ith_S(mParameters, 11) / (var_model_parameters__F * var_model_parameters__Vc) + var_calcium_dynamics__i_leak + var_calcium_dynamics__i_rel) * var_calcium_dynamics__Cai_bufc; // millimolar / second const double d_dt_chaste_interface_var_calcium_dynamics__Cai = 0.001 * var_calcium_dynamics__Cai_orig_deriv; // millimolar / millisecond const double var_i_NaK__i_NaK = var_i_NaK__PNaK * NV_Ith_S(mParameters, 2) * var_chaste_interface__sodium_dynamics__Nai / ((var_i_NaK__Km_K + NV_Ith_S(mParameters, 2)) * (var_i_NaK__Km_Na + var_chaste_interface__sodium_dynamics__Nai) * (1 + 0.035299999999999998 * exp(-var_Membrane__Vm * var_model_parameters__F / (var_model_parameters__R * NV_Ith_S(mParameters, 12))) + 0.1245 * exp(-0.10000000000000001 * var_Membrane__Vm * var_model_parameters__F / (var_model_parameters__R * NV_Ith_S(mParameters, 12))))); // A_per_F const double var_i_b_Na__i_b_Na = (-var_electric_potentials__E_Na + var_Membrane__Vm) * var_i_b_Na__g_b_Na; // A_per_F - const double var_sodium_dynamics__Nai_orig_deriv = -999999999999999872 * (3 * var_i_NaCa__i_NaCa + 3 * var_i_NaK__i_NaK + var_i_Na__i_Na + var_i_b_Na__i_b_Na) * NV_Ith_S(mParameters, 11) / (var_model_parameters__F * var_model_parameters__Vc); // millimolar / second + const double var_sodium_dynamics__Nai_orig_deriv = -9.9999999999999987e+17 * (3 * var_i_NaCa__i_NaCa + 3 * var_i_NaK__i_NaK + var_i_Na__i_Na + var_i_b_Na__i_b_Na) * NV_Ith_S(mParameters, 11) / (var_model_parameters__F * var_model_parameters__Vc); // millimolar / second const double d_dt_chaste_interface_var_sodium_dynamics__Nai = 0.001 * var_sodium_dynamics__Nai_orig_deriv; // millimolar / millisecond if (mSetVoltageDerivativeToZero) diff --git a/chaste_codegen/data/tests/chaste_reference_models/Cvode_opt_with_jacobian/dynamic_Shannon2004.cpp b/chaste_codegen/data/tests/chaste_reference_models/Cvode_opt_with_jacobian/dynamic_Shannon2004.cpp index 6cda4fa3..335cb8e3 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/Cvode_opt_with_jacobian/dynamic_Shannon2004.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/Cvode_opt_with_jacobian/dynamic_Shannon2004.cpp @@ -16,21 +16,28 @@ #include #include #include "Exception.hpp" -#include "Warnings.hpp" #include "OdeSystemInformation.hpp" #include "RegularStimulus.hpp" #include "HeartConfig.hpp" #include "IsNan.hpp" #include "MathsCustomFunctions.hpp" +#include "ModelFactory.hpp" + +AbstractCvodeCell* Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::CreateMethod(boost::shared_ptr p_solver, boost::shared_ptr p_stimulus) { + return new Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode(p_solver, p_stimulus); +} + +bool Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::registered = ModelFactory::Register("dynamic_Shannon2004", "AnalyticCvode", (ModelFactory::TCreateMethod)Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::CreateMethod); + - boost::shared_ptr DynamicShannon2004FromCellMLCvode::UseCellMLDefaultStimulus() + boost::shared_ptr Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::UseCellMLDefaultStimulus() { // Use the default stimulus specified by CellML metadata const double var_chaste_interface__cell__stim_amplitude_converted = -9.5 * HeartConfig::Instance()->GetCapacitance(); // uA_per_cm2 - const double var_chaste_interface__cell__stim_duration = 5.0; // millisecond - const double var_chaste_interface__cell__stim_period = 1000.0; // millisecond - const double var_chaste_interface__cell__stim_start = 100.0; // millisecond + const double var_chaste_interface__cell__stim_duration = 5; // millisecond + const double var_chaste_interface__cell__stim_period = 1000; // millisecond + const double var_chaste_interface__cell__stim_start = 100; // millisecond boost::shared_ptr p_cellml_stim(new RegularStimulus( -fabs(var_chaste_interface__cell__stim_amplitude_converted), var_chaste_interface__cell__stim_duration, @@ -41,12 +48,12 @@ return p_cellml_stim; } - double DynamicShannon2004FromCellMLCvode::GetIntracellularCalciumConcentration() + double Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::GetIntracellularCalciumConcentration() { return NV_Ith_S(mStateVariables, 1); } - DynamicShannon2004FromCellMLCvode::DynamicShannon2004FromCellMLCvode(boost::shared_ptr pOdeSolver /* unused; should be empty */, boost::shared_ptr pIntracellularStimulus) + Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode(boost::shared_ptr pOdeSolver /* unused; should be empty */, boost::shared_ptr pIntracellularStimulus) : AbstractCvodeCell( pOdeSolver, 45, @@ -55,7 +62,7 @@ { // Time units: millisecond // - this->mpSystemInfo = OdeSystemInformation::Instance(); + this->mpSystemInfo = OdeSystemInformation::Instance(); Init(); // We have a default stimulus specified in the CellML file metadata @@ -64,20 +71,20 @@ mHasAnalyticJacobian = true; NV_Ith_S(this->mParameters, 0) = 5.3480000000000003e-6; // (var_Jleak_SR__KSRleak) [per_millisecond] - NV_Ith_S(this->mParameters, 1) = 25.0; // (var_Jrel_SR__ks) [per_millisecond] + NV_Ith_S(this->mParameters, 1) = 25; // (var_Jrel_SR__ks) [per_millisecond] NV_Ith_S(this->mParameters, 2) = 0.00028600000000000001; // (var_Jpump_SR__V_max) [millimolar_per_millisecond] - NV_Ith_S(this->mParameters, 3) = 1.0; // (var_Na_buffer__conc_clamp) [dimensionless] - NV_Ith_S(this->mParameters, 4) = 15.0; // (var_model_parameters__Cli) [millimolar] - NV_Ith_S(this->mParameters, 5) = 135.0; // (var_model_parameters__Ki) [millimolar] + NV_Ith_S(this->mParameters, 3) = 1; // (var_Na_buffer__conc_clamp) [dimensionless] + NV_Ith_S(this->mParameters, 4) = 15; // (var_model_parameters__Cli) [millimolar] + NV_Ith_S(this->mParameters, 5) = 135; // (var_model_parameters__Ki) [millimolar] NV_Ith_S(this->mParameters, 6) = 1.8; // (var_model_parameters__Cao) [millimolar] - NV_Ith_S(this->mParameters, 7) = 150.0; // (var_model_parameters__Clo) [millimolar] + NV_Ith_S(this->mParameters, 7) = 150; // (var_model_parameters__Clo) [millimolar] NV_Ith_S(this->mParameters, 8) = 5.4000000000000004; // (var_model_parameters__Ko) [millimolar] - NV_Ith_S(this->mParameters, 9) = 140.0; // (var_model_parameters__Nao) [millimolar] + NV_Ith_S(this->mParameters, 9) = 140; // (var_model_parameters__Nao) [millimolar] NV_Ith_S(this->mParameters, 10) = 96486.699999999997; // (var_model_parameters__F) [coulomb_per_mole] NV_Ith_S(this->mParameters, 11) = 8314.2999999999993; // (var_model_parameters__R) [joule_per_kilomole_kelvin] NV_Ith_S(this->mParameters, 12) = 0.00054000000000000001; // (var_ICaL__PCa) [litre_per_farad_millisecond] NV_Ith_S(this->mParameters, 13) = 0.0089999999999999993; // (var_IClb__G_ClBk) [milliS_per_microF] - NV_Ith_S(this->mParameters, 14) = 16.0; // (var_INa__G_INa) [milliS_per_microF] + NV_Ith_S(this->mParameters, 14) = 16; // (var_INa__G_INa) [milliS_per_microF] NV_Ith_S(this->mParameters, 15) = 0; // (var_INa__perc_reduced_inact_for_IpNa) [dimensionless] NV_Ith_S(this->mParameters, 16) = 0; // (var_INa__shift_INa_inact) [millivolt] NV_Ith_S(this->mParameters, 17) = 0.02; // (var_Itof__G_tof) [milliS_per_microF] @@ -85,16 +92,16 @@ NV_Ith_S(this->mParameters, 19) = 0.029999999999999999; // (var_IKr__G_IKr_const) [milliS_per_microF] NV_Ith_S(this->mParameters, 20) = 0.070000000000000007; // (var_IKs__G_Ks_max) [milliS_per_microF] NV_Ith_S(this->mParameters, 21) = 0.059999999999999998; // (var_Itos__G_tos) [milliS_per_microF] - NV_Ith_S(this->mParameters, 22) = 9.0; // (var_INaCa__V_max) [microA_per_microF] - NV_Ith_S(this->mParameters, 23) = 310.0; // (var_model_parameters__T) [kelvin] + NV_Ith_S(this->mParameters, 22) = 9; // (var_INaCa__V_max) [microA_per_microF] + NV_Ith_S(this->mParameters, 23) = 310; // (var_model_parameters__T) [kelvin] } - DynamicShannon2004FromCellMLCvode::~DynamicShannon2004FromCellMLCvode() + Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::~Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode() { } - double DynamicShannon2004FromCellMLCvode::GetIIonic(const std::vector* pStateVariables) + double Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::GetIIonic(const std::vector* pStateVariables) { // For state variable interpolation (SVI) we read in interpolated state variables, // otherwise for ionic current interpolation (ICI) we use the state variables of this model (node). @@ -161,8 +168,8 @@ const double var_ICaL__gamma_Ko = 0.75; // dimensionless const double var_ICaL__gamma_Nai = 0.75; // dimensionless const double var_ICaL__gamma_Nao = 0.75; // dimensionless - const double var_ICaL_fCa_gate__fCa_SL = 1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL; // dimensionless - const double var_ICaL_fCa_gate__fCa_jct = 1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct; // dimensionless + const double var_ICaL_fCa_gate__fCa_SL = 1 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL; // dimensionless + const double var_ICaL_fCa_gate__fCa_jct = 1 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct; // dimensionless const double var_ICab__Fx_CaBk_SL = 0.89000000000000001; // dimensionless const double var_ICab__Fx_CaBk_jct = 0.11; // dimensionless const double var_ICab__G_CaBk = 0.00025129999999999998; // milliS_per_microF @@ -178,54 +185,54 @@ const double var_ICl_Ca__Kd_ClCa = 0.10000000000000001; // millimolar const double var_IKs__Fx_Ks_SL = 0.89000000000000001; // dimensionless const double var_IKs__Fx_Ks_jct = 0.11; // dimensionless - const double var_IKs__pCa_SL = 3.0 - log10(var_chaste_interface__Ca_buffer__Ca_SL); // dimensionless - const double var_IKs__G_Ks_SL = (0.057000000000000002 + 0.19 / (1.0 + exp(-12.0 + 1.6666666666666667 * var_IKs__pCa_SL))) * NV_Ith_S(mParameters, 20); // milliS_per_microF - const double var_IKs__pCa_jct = 3.0 - log10(var_chaste_interface__Ca_buffer__Ca_jct); // dimensionless - const double var_IKs__G_Ks_jct = (0.057000000000000002 + 0.19 / (1.0 + exp(-12.0 + 1.6666666666666667 * var_IKs__pCa_jct))) * NV_Ith_S(mParameters, 20); // milliS_per_microF + const double var_IKs__pCa_SL = 3 - log10(var_chaste_interface__Ca_buffer__Ca_SL); // dimensionless + const double var_IKs__G_Ks_SL = (0.057000000000000002 + 0.19 / (1 + exp(-12 + 1.6666666666666667 * var_IKs__pCa_SL))) * NV_Ith_S(mParameters, 20); // milliS_per_microF + const double var_IKs__pCa_jct = 3 - log10(var_chaste_interface__Ca_buffer__Ca_jct); // dimensionless + const double var_IKs__G_Ks_jct = (0.057000000000000002 + 0.19 / (1 + exp(-12 + 1.6666666666666667 * var_IKs__pCa_jct))) * NV_Ith_S(mParameters, 20); // milliS_per_microF const double var_IKs__pKNa = 0.018329999999999999; // dimensionless const double var_INa__Fx_Na_SL = 0.89000000000000001; // dimensionless const double var_INa__Fx_Na_jct = 0.11; // dimensionless const double var_INaCa__Fx_NCX_SL = 0.89000000000000001; // dimensionless const double var_INaCa__Fx_NCX_jct = 0.11; // dimensionless - const double var_INaCa__HNa = 3.0; // dimensionless + const double var_INaCa__HNa = 3; // dimensionless const double var_INaCa__K_mCai = 0.0035899999999999999; // millimolar const double var_INaCa__K_mCao = 1.3; // millimolar const double var_INaCa__K_mNai = 12.289999999999999; // millimolar const double var_INaCa__K_mNao = 87.5; // millimolar const double var_INaCa__Kd_act = 0.00025599999999999999; // millimolar - const double var_INaCa__Ka_SL = 1 / (1.0 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_SL, 3)); // dimensionless - const double var_INaCa__Ka_jct = 1 / (1.0 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_jct, 3)); // dimensionless + const double var_INaCa__Ka_SL = 1 / (1 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_SL, 3)); // dimensionless + const double var_INaCa__Ka_jct = 1 / (1 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_jct, 3)); // dimensionless const double var_INaCa__Q10_NCX = 1.5700000000000001; // dimensionless const double var_INaCa__eta = 0.34999999999999998; // dimensionless const double var_INaCa__ksat = 0.27000000000000002; // dimensionless const double var_INaK__Fx_NaK_SL = 0.89000000000000001; // dimensionless const double var_INaK__Fx_NaK_jct = 0.11; // dimensionless - const double var_INaK__H_NaK = 4.0; // dimensionless + const double var_INaK__H_NaK = 4; // dimensionless const double var_INaK__I_NaK_max = 1.9099999999999999; // microA_per_microF const double var_INaK__Km_Ko = 1.5; // millimolar - const double var_INaK__Km_Nai = 11.0; // millimolar + const double var_INaK__Km_Nai = 11; // millimolar const double var_INaK__Q10_Km_Nai = 1.49; // dimensionless const double var_INaK__Q10_NaK = 1.6299999999999999; // dimensionless const double var_INa__openProb = pow(var_chaste_interface__INa_m_gate__m, 3) * var_chaste_interface__INa_h_gate__h * var_chaste_interface__INa_j_gate__j; // dimensionless const double var_INab__Fx_NaBk_SL = 0.89000000000000001; // dimensionless const double var_INab__Fx_NaBk_jct = 0.11; // dimensionless const double var_INab__G_NaBk = 0.00029700000000000001; // milliS_per_microF - const double var_IKr_Rr_gate__Rr = 1 / (1.0 + exp(1.4732142857142858 + 0.044642857142857144 * var_chaste_interface__cell__V)); // dimensionless + const double var_IKr_Rr_gate__Rr = 1 / (1 + exp(1.4732142857142858 + 0.044642857142857144 * var_chaste_interface__cell__V)); // dimensionless const double var_IK1__G_K1 = 0.43033148291193518 * sqrt(NV_Ith_S(mParameters, 8)) * NV_Ith_S(mParameters, 18); // milliS_per_microF const double var_IKr__G_IKr = 0.43033148291193518 * sqrt(NV_Ith_S(mParameters, 8)) * NV_Ith_S(mParameters, 19); // milliS_per_microF const double var_INaK__sigma = -0.14285714285714285 + 0.14285714285714285 * exp(0.01485884101040119 * NV_Ith_S(mParameters, 9)); // dimensionless - const double var_ICaL__Q_CaL = pow(var_ICaL__Q10_CaL, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_ICaL__Q_CaL = pow(var_ICaL__Q10_CaL, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless const double var_ICaL__temp = 0.45000000000000001 * pow(NV_Ith_S(mParameters, 10), 2) * var_ICaL__Q_CaL * var_chaste_interface__ICaL_d_gate__d * var_chaste_interface__ICaL_f_gate__f * var_chaste_interface__cell__V / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)); // coulomb_per_mole - const double var_ICaL__i_CaL_Ca_SL = 4.0 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_SL * var_ICaL__gamma_Cai * exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1.0 + exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Ca_jct = 4.0 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_jct * var_ICaL__gamma_Cai * exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1.0 + exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_K = (var_ICaL__Fx_ICaL_SL * var_ICaL_fCa_gate__fCa_SL + var_ICaL__Fx_ICaL_jct * var_ICaL_fCa_gate__fCa_jct) * (-var_ICaL__gamma_Ko * NV_Ith_S(mParameters, 8) + var_ICaL__gamma_Ki * NV_Ith_S(mParameters, 5) * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__PK * var_ICaL__temp / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Na_SL = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_SL * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Na_jct = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_jct * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Ca_SL = 4 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_SL * var_ICaL__gamma_Cai * exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1 + exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Ca_jct = 4 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_jct * var_ICaL__gamma_Cai * exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1 + exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_K = (var_ICaL__Fx_ICaL_SL * var_ICaL_fCa_gate__fCa_SL + var_ICaL__Fx_ICaL_jct * var_ICaL_fCa_gate__fCa_jct) * (-var_ICaL__gamma_Ko * NV_Ith_S(mParameters, 8) + var_ICaL__gamma_Ki * NV_Ith_S(mParameters, 5) * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__PK * var_ICaL__temp / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Na_SL = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_SL * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Na_jct = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_jct * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF const double var_ICaL__i_CaL = var_ICaL__i_CaL_Ca_SL + var_ICaL__i_CaL_Ca_jct + var_ICaL__i_CaL_K + var_ICaL__i_CaL_Na_SL + var_ICaL__i_CaL_Na_jct; // microA_per_microF const double var_ICaL__i_CaL_converted = HeartConfig::Instance()->GetCapacitance() * var_ICaL__i_CaL; // uA_per_cm2 - const double var_ICap__Q_SLCaP = pow(var_ICap__Q10_SLCaP, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_ICap__i_Cap_SL = var_ICap__Fx_SLCaP_SL * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1.0 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_SL), var_ICap__H)); // microA_per_microF - const double var_ICap__i_Cap_jct = var_ICap__Fx_SLCaP_jct * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1.0 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_jct), var_ICap__H)); // microA_per_microF + const double var_ICap__Q_SLCaP = pow(var_ICap__Q10_SLCaP, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_ICap__i_Cap_SL = var_ICap__Fx_SLCaP_SL * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_SL), var_ICap__H)); // microA_per_microF + const double var_ICap__i_Cap_jct = var_ICap__Fx_SLCaP_jct * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_jct), var_ICap__H)); // microA_per_microF const double var_ICap__i_Cap = var_ICap__i_Cap_SL + var_ICap__i_Cap_jct; // microA_per_microF const double var_ICap__i_Cap_converted = HeartConfig::Instance()->GetCapacitance() * var_ICap__i_Cap; // uA_per_cm2 const double var_IKs__E_Ks = NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log((var_IKs__pKNa * NV_Ith_S(mParameters, 9) + NV_Ith_S(mParameters, 8)) / (var_IKs__pKNa * var_chaste_interface__Na_buffer__Nai + NV_Ith_S(mParameters, 5))) / NV_Ith_S(mParameters, 10); // millivolt @@ -233,18 +240,18 @@ const double var_IKs__i_Ks_jct = pow(var_chaste_interface__IKs_Xs_gate__Xs, 2) * (-var_IKs__E_Ks + var_chaste_interface__cell__V) * var_IKs__Fx_Ks_jct * var_IKs__G_Ks_jct; // microA_per_microF const double var_IKs__i_Ks = var_IKs__i_Ks_SL + var_IKs__i_Ks_jct; // microA_per_microF const double var_IKs__i_Ks_converted = HeartConfig::Instance()->GetCapacitance() * var_IKs__i_Ks; // uA_per_cm2 - const double var_INaCa__Q_NCX = pow(var_INaCa__Q10_NCX, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_INaCa__temp_SL = (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1.0 + var_INaCa__ksat * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 - const double var_INaCa__i_NaCa_SL = var_INaCa__Fx_NCX_SL * var_INaCa__Ka_SL * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_SL / (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1.0 + var_chaste_interface__Ca_buffer__Ca_SL / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_SL + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1.0 + pow((var_chaste_interface__Na_buffer__Na_SL / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF - const double var_INaCa__temp_jct = (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1.0 + var_INaCa__ksat * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 - const double var_INaCa__i_NaCa_jct = var_INaCa__Fx_NCX_jct * var_INaCa__Ka_jct * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_jct / (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1.0 + var_chaste_interface__Ca_buffer__Ca_jct / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_jct + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1.0 + pow((var_chaste_interface__Na_buffer__Na_jct / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF + const double var_INaCa__Q_NCX = pow(var_INaCa__Q10_NCX, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_INaCa__temp_SL = (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1 + var_INaCa__ksat * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 + const double var_INaCa__i_NaCa_SL = var_INaCa__Fx_NCX_SL * var_INaCa__Ka_SL * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_SL / (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1 + var_chaste_interface__Ca_buffer__Ca_SL / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_SL + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1 + pow((var_chaste_interface__Na_buffer__Na_SL / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF + const double var_INaCa__temp_jct = (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1 + var_INaCa__ksat * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 + const double var_INaCa__i_NaCa_jct = var_INaCa__Fx_NCX_jct * var_INaCa__Ka_jct * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_jct / (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1 + var_chaste_interface__Ca_buffer__Ca_jct / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_jct + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1 + pow((var_chaste_interface__Na_buffer__Na_jct / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF const double var_INaCa__i_NaCa = var_INaCa__i_NaCa_SL + var_INaCa__i_NaCa_jct; // microA_per_microF const double var_INaCa__i_NaCa_converted = HeartConfig::Instance()->GetCapacitance() * var_INaCa__i_NaCa; // uA_per_cm2 - const double var_INaK__Q_Km_Nai = pow(var_INaK__Q10_Km_Nai, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_INaK__Q_NaK = pow(var_INaK__Q10_NaK, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_INaK__f_NaK = 1 / (1.0 + 0.1245 * exp(-0.10000000000000001 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) + 0.036499999999999998 * var_INaK__sigma * exp(-var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // dimensionless - const double var_INaK__i_NaK_SL = var_INaK__Fx_NaK_SL * var_INaK__I_NaK_max * var_INaK__Q_NaK * var_INaK__f_NaK * NV_Ith_S(mParameters, 8) / ((1.0 + pow((var_INaK__Km_Nai * var_INaK__Q_Km_Nai / var_chaste_interface__Na_buffer__Na_SL), var_INaK__H_NaK)) * (var_INaK__Km_Ko + NV_Ith_S(mParameters, 8))); // microA_per_microF - const double var_INaK__i_NaK_jct = var_INaK__Fx_NaK_jct * var_INaK__I_NaK_max * var_INaK__Q_NaK * var_INaK__f_NaK * NV_Ith_S(mParameters, 8) / ((1.0 + pow((var_INaK__Km_Nai * var_INaK__Q_Km_Nai / var_chaste_interface__Na_buffer__Na_jct), var_INaK__H_NaK)) * (var_INaK__Km_Ko + NV_Ith_S(mParameters, 8))); // microA_per_microF + const double var_INaK__Q_Km_Nai = pow(var_INaK__Q10_Km_Nai, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_INaK__Q_NaK = pow(var_INaK__Q10_NaK, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_INaK__f_NaK = 1 / (1 + 0.1245 * exp(-0.10000000000000001 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) + 0.036499999999999998 * var_INaK__sigma * exp(-var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // dimensionless + const double var_INaK__i_NaK_SL = var_INaK__Fx_NaK_SL * var_INaK__I_NaK_max * var_INaK__Q_NaK * var_INaK__f_NaK * NV_Ith_S(mParameters, 8) / ((1 + pow((var_INaK__Km_Nai * var_INaK__Q_Km_Nai / var_chaste_interface__Na_buffer__Na_SL), var_INaK__H_NaK)) * (var_INaK__Km_Ko + NV_Ith_S(mParameters, 8))); // microA_per_microF + const double var_INaK__i_NaK_jct = var_INaK__Fx_NaK_jct * var_INaK__I_NaK_max * var_INaK__Q_NaK * var_INaK__f_NaK * NV_Ith_S(mParameters, 8) / ((1 + pow((var_INaK__Km_Nai * var_INaK__Q_Km_Nai / var_chaste_interface__Na_buffer__Na_jct), var_INaK__H_NaK)) * (var_INaK__Km_Ko + NV_Ith_S(mParameters, 8))); // microA_per_microF const double var_INaK__i_NaK = var_INaK__i_NaK_SL + var_INaK__i_NaK_jct; // microA_per_microF const double var_reversal_potentials__E_Ca_SL = 0.5 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 6) / var_chaste_interface__Ca_buffer__Ca_SL) / NV_Ith_S(mParameters, 10); // millivolt const double var_ICab__i_Cab_SL = (-var_reversal_potentials__E_Ca_SL + var_chaste_interface__cell__V) * var_ICab__Fx_CaBk_SL * var_ICab__G_CaBk; // microA_per_microF @@ -253,12 +260,12 @@ const double var_ICab__i_Cab = var_ICab__i_Cab_SL + var_ICab__i_Cab_jct; // microA_per_microF const double var_ICab__i_Cab_converted = HeartConfig::Instance()->GetCapacitance() * var_ICab__i_Cab; // uA_per_cm2 const double var_reversal_potentials__E_Cl = -NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 7) / NV_Ith_S(mParameters, 4)) / NV_Ith_S(mParameters, 10); // millivolt - const double var_ICl_Ca__i_Cl_Ca = (-var_reversal_potentials__E_Cl + var_chaste_interface__cell__V) * (var_ICl_Ca__Fx_Cl_SL / (1.0 + var_ICl_Ca__Kd_ClCa / var_chaste_interface__Ca_buffer__Ca_SL) + var_ICl_Ca__Fx_Cl_jct / (1.0 + var_ICl_Ca__Kd_ClCa / var_chaste_interface__Ca_buffer__Ca_jct)) * var_ICl_Ca__G_Cl; // microA_per_microF + const double var_ICl_Ca__i_Cl_Ca = (-var_reversal_potentials__E_Cl + var_chaste_interface__cell__V) * (var_ICl_Ca__Fx_Cl_SL / (1 + var_ICl_Ca__Kd_ClCa / var_chaste_interface__Ca_buffer__Ca_SL) + var_ICl_Ca__Fx_Cl_jct / (1 + var_ICl_Ca__Kd_ClCa / var_chaste_interface__Ca_buffer__Ca_jct)) * var_ICl_Ca__G_Cl; // microA_per_microF const double var_IClb__i_Clb = (-var_reversal_potentials__E_Cl + var_chaste_interface__cell__V) * NV_Ith_S(mParameters, 13); // microA_per_microF const double var_IClb__i_Clb_converted = HeartConfig::Instance()->GetCapacitance() * var_IClb__i_Clb; // uA_per_cm2 const double var_reversal_potentials__E_K = NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 8) / NV_Ith_S(mParameters, 5)) / NV_Ith_S(mParameters, 10); // millivolt - const double var_IK1_K1_gate__alpha_K1 = 1.02 / (1.0 + exp(-14.1227775 + 0.23849999999999999 * var_chaste_interface__cell__V - 0.23849999999999999 * var_reversal_potentials__E_K)); // per_millisecond - const double var_IK1_K1_gate__beta_K1 = (exp(-36.698642499999998 + 0.061749999999999999 * var_chaste_interface__cell__V - 0.061749999999999999 * var_reversal_potentials__E_K) + 0.49124000000000001 * exp(0.43983232 + 0.080320000000000003 * var_chaste_interface__cell__V - 0.080320000000000003 * var_reversal_potentials__E_K)) / (1.0 + exp(-2.4444678999999998 + 0.51429999999999998 * var_reversal_potentials__E_K - 0.51429999999999998 * var_chaste_interface__cell__V)); // per_millisecond + const double var_IK1_K1_gate__alpha_K1 = 1.02 / (1 + exp(-14.1227775 + 0.23849999999999999 * var_chaste_interface__cell__V - 0.23849999999999999 * var_reversal_potentials__E_K)); // per_millisecond + const double var_IK1_K1_gate__beta_K1 = (exp(-36.698642499999998 + 0.061749999999999999 * var_chaste_interface__cell__V - 0.061749999999999999 * var_reversal_potentials__E_K) + 0.49124000000000001 * exp(0.43983232 + 0.080320000000000003 * var_chaste_interface__cell__V - 0.080320000000000003 * var_reversal_potentials__E_K)) / (1 + exp(-2.4444678999999998 + 0.51429999999999998 * var_reversal_potentials__E_K - 0.51429999999999998 * var_chaste_interface__cell__V)); // per_millisecond const double var_IK1_K1_gate__K1_infinity = var_IK1_K1_gate__alpha_K1 / (var_IK1_K1_gate__alpha_K1 + var_IK1_K1_gate__beta_K1); // dimensionless const double var_IK1__i_K1 = (-var_reversal_potentials__E_K + var_chaste_interface__cell__V) * var_IK1__G_K1 * var_IK1_K1_gate__K1_infinity; // microA_per_microF const double var_IK1__i_K1_converted = HeartConfig::Instance()->GetCapacitance() * var_IK1__i_K1; // uA_per_cm2 @@ -289,7 +296,7 @@ return i_ionic; } - void DynamicShannon2004FromCellMLCvode::EvaluateYDerivatives(double var_chaste_interface__environment__time, const N_Vector rY, N_Vector rDY) + void Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::EvaluateYDerivatives(double var_chaste_interface__environment__time, const N_Vector rY, N_Vector rDY) { // Inputs: // Time units: millisecond @@ -391,11 +398,11 @@ const double var_Ca_buffer__Bmax_SLB_jct = 0.0045999999999999999; // millimolar const double var_Ca_buffer__Bmax_SLHigh_SL = 0.0134; // millimolar const double var_Ca_buffer__Bmax_SLHigh_jct = 0.00165; // millimolar - const double var_Ca_buffer__koff_Calsequestrin = 65.0; // per_millisecond + const double var_Ca_buffer__koff_Calsequestrin = 65; // per_millisecond const double var_Ca_buffer__koff_SLB = 1.3; // per_millisecond const double var_Ca_buffer__koff_SLHigh = 0.029999999999999999; // per_millisecond - const double var_Ca_buffer__kon_Calsequestrin = 100.0; // per_millimolar_per_millisecond - const double var_Ca_buffer__kon_SL = 100.0; // per_millimolar_per_millisecond + const double var_Ca_buffer__kon_Calsequestrin = 100; // per_millimolar_per_millisecond + const double var_Ca_buffer__kon_SL = 100; // per_millimolar_per_millisecond const double var_ICaL__Fx_ICaL_SL = 0.10000000000000001; // dimensionless const double var_ICaL__Fx_ICaL_jct = 0.90000000000000002; // dimensionless const double var_ICaL__PNa = 1.4999999999999999e-8; // litre_per_farad_millisecond @@ -404,10 +411,10 @@ const double var_ICaL__gamma_Cao = 0.34100000000000003; // dimensionless const double var_ICaL__gamma_Nai = 0.75; // dimensionless const double var_ICaL__gamma_Nao = 0.75; // dimensionless - const double d_dt_chaste_interface_var_ICaL_fCa_gate__fCaB_SL = -0.011900000000000001 * var_chaste_interface__ICaL_fCa_gate__fCaB_SL + 1.7 * (1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL) * var_chaste_interface__Ca_buffer__Ca_SL; // 1 / millisecond - const double d_dt_chaste_interface_var_ICaL_fCa_gate__fCaB_jct = -0.011900000000000001 * var_chaste_interface__ICaL_fCa_gate__fCaB_jct + 1.7 * (1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct) * var_chaste_interface__Ca_buffer__Ca_jct; // 1 / millisecond - const double var_ICaL_fCa_gate__fCa_SL = 1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL; // dimensionless - const double var_ICaL_fCa_gate__fCa_jct = 1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct; // dimensionless + const double d_dt_chaste_interface_var_ICaL_fCa_gate__fCaB_SL = -0.011900000000000001 * var_chaste_interface__ICaL_fCa_gate__fCaB_SL + 1.7 * (1 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL) * var_chaste_interface__Ca_buffer__Ca_SL; // 1 / millisecond + const double d_dt_chaste_interface_var_ICaL_fCa_gate__fCaB_jct = -0.011900000000000001 * var_chaste_interface__ICaL_fCa_gate__fCaB_jct + 1.7 * (1 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct) * var_chaste_interface__Ca_buffer__Ca_jct; // 1 / millisecond + const double var_ICaL_fCa_gate__fCa_SL = 1 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL; // dimensionless + const double var_ICaL_fCa_gate__fCa_jct = 1 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct; // dimensionless const double var_ICab__Fx_CaBk_SL = 0.89000000000000001; // dimensionless const double var_ICab__Fx_CaBk_jct = 0.11; // dimensionless const double var_ICab__G_CaBk = 0.00025129999999999998; // milliS_per_microF @@ -421,23 +428,23 @@ const double var_INa__Fx_Na_jct = 0.11; // dimensionless const double var_INaCa__Fx_NCX_SL = 0.89000000000000001; // dimensionless const double var_INaCa__Fx_NCX_jct = 0.11; // dimensionless - const double var_INaCa__HNa = 3.0; // dimensionless + const double var_INaCa__HNa = 3; // dimensionless const double var_INaCa__K_mCai = 0.0035899999999999999; // millimolar const double var_INaCa__K_mCao = 1.3; // millimolar const double var_INaCa__K_mNai = 12.289999999999999; // millimolar const double var_INaCa__K_mNao = 87.5; // millimolar const double var_INaCa__Kd_act = 0.00025599999999999999; // millimolar - const double var_INaCa__Ka_SL = 1 / (1.0 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_SL, 3)); // dimensionless - const double var_INaCa__Ka_jct = 1 / (1.0 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_jct, 3)); // dimensionless + const double var_INaCa__Ka_SL = 1 / (1 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_SL, 3)); // dimensionless + const double var_INaCa__Ka_jct = 1 / (1 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_jct, 3)); // dimensionless const double var_INaCa__Q10_NCX = 1.5700000000000001; // dimensionless const double var_INaCa__eta = 0.34999999999999998; // dimensionless const double var_INaCa__ksat = 0.27000000000000002; // dimensionless const double var_INaK__Fx_NaK_SL = 0.89000000000000001; // dimensionless const double var_INaK__Fx_NaK_jct = 0.11; // dimensionless - const double var_INaK__H_NaK = 4.0; // dimensionless + const double var_INaK__H_NaK = 4; // dimensionless const double var_INaK__I_NaK_max = 1.9099999999999999; // microA_per_microF const double var_INaK__Km_Ko = 1.5; // millimolar - const double var_INaK__Km_Nai = 11.0; // millimolar + const double var_INaK__Km_Nai = 11; // millimolar const double var_INaK__Q10_Km_Nai = 1.49; // dimensionless const double var_INaK__Q10_NaK = 1.6299999999999999; // dimensionless const double var_INa__openProb = pow(var_chaste_interface__INa_m_gate__m, 3) * var_chaste_interface__INa_h_gate__h * var_chaste_interface__INa_j_gate__j; // dimensionless @@ -451,14 +458,14 @@ const double var_Jpump_SR__Q10_SRCaP = 2.6000000000000001; // dimensionless const double var_Jrel_SR__EC50_SR = 0.45000000000000001; // millimolar const double var_Jrel_SR__HSR = 2.5; // dimensionless - const double var_Jrel_SR__Max_SR = 15.0; // dimensionless - const double var_Jrel_SR__Min_SR = 1.0; // dimensionless - const double var_Jrel_SR__RI = 1.0 - var_chaste_interface__Jrel_SR__I - var_chaste_interface__Jrel_SR__O - var_chaste_interface__Jrel_SR__R; // dimensionless - const double var_Jrel_SR__kCaSR = -(-var_Jrel_SR__Min_SR + var_Jrel_SR__Max_SR) / (1.0 + pow((var_Jrel_SR__EC50_SR / var_chaste_interface__Ca_buffer__Ca_SR), var_Jrel_SR__HSR)) + var_Jrel_SR__Max_SR; // dimensionless + const double var_Jrel_SR__Max_SR = 15; // dimensionless + const double var_Jrel_SR__Min_SR = 1; // dimensionless + const double var_Jrel_SR__RI = 1 - var_chaste_interface__Jrel_SR__I - var_chaste_interface__Jrel_SR__O - var_chaste_interface__Jrel_SR__R; // dimensionless + const double var_Jrel_SR__kCaSR = -(-var_Jrel_SR__Min_SR + var_Jrel_SR__Max_SR) / (1 + pow((var_Jrel_SR__EC50_SR / var_chaste_interface__Ca_buffer__Ca_SR), var_Jrel_SR__HSR)) + var_Jrel_SR__Max_SR; // dimensionless const double var_Jrel_SR__kiCa = 0.5; // per_millimolar_per_millisecond const double var_Jrel_SR__kiSRCa = var_Jrel_SR__kCaSR * var_Jrel_SR__kiCa; // per_millimolar_per_millisecond const double var_Jrel_SR__kim = 0.0050000000000000001; // per_millisecond - const double var_Jrel_SR__koCa = 10.0; // per_millimolar2_per_millisecond + const double var_Jrel_SR__koCa = 10; // per_millimolar2_per_millisecond const double var_Jrel_SR__koSRCa = var_Jrel_SR__koCa / var_Jrel_SR__kCaSR; // per_millimolar2_per_millisecond const double var_Jrel_SR__kom = 0.059999999999999998; // per_millisecond const double d_dt_chaste_interface_var_Jrel_SR__I = -var_chaste_interface__Jrel_SR__I * var_Jrel_SR__kim - var_chaste_interface__Jrel_SR__I * var_Jrel_SR__kom + pow(var_chaste_interface__Ca_buffer__Ca_jct, 2) * var_Jrel_SR__RI * var_Jrel_SR__koSRCa + var_chaste_interface__Ca_buffer__Ca_jct * var_chaste_interface__Jrel_SR__O * var_Jrel_SR__kiSRCa; // 1 / millisecond @@ -473,47 +480,47 @@ const double d_dt_chaste_interface_var_Na_buffer__Na_SL_buf = var_Na_buffer__dNa_SL_buf; // millimolar / millisecond const double var_Na_buffer__dNa_jct_buf = -var_chaste_interface__Na_buffer__Na_jct_buf * var_Na_buffer__koff + (-var_chaste_interface__Na_buffer__Na_jct_buf + var_Na_buffer__Bmax_jct) * var_chaste_interface__Na_buffer__Na_jct * var_Na_buffer__kon; // millimolar_per_millisecond const double d_dt_chaste_interface_var_Na_buffer__Na_jct_buf = var_Na_buffer__dNa_jct_buf; // millimolar / millisecond - const double var_ICaL_d_gate__d_infinity = 1 / (1.0 + exp(-2.4166666666666665 - 0.16666666666666666 * var_chaste_interface__cell__V)); // dimensionless - const double var_ICaL_d_gate__tau_d = 28.571428571428569 * (1.0 - exp(-2.4166666666666665 - 0.16666666666666666 * var_chaste_interface__cell__V)) * var_ICaL_d_gate__d_infinity / (14.5 + var_chaste_interface__cell__V); // millisecond + const double var_ICaL_d_gate__d_infinity = 1 / (1 + exp(-2.4166666666666665 - 0.16666666666666666 * var_chaste_interface__cell__V)); // dimensionless + const double var_ICaL_d_gate__tau_d = 28.571428571428569 * (1 - exp(-2.4166666666666665 - 0.16666666666666666 * var_chaste_interface__cell__V)) * var_ICaL_d_gate__d_infinity / (14.5 + var_chaste_interface__cell__V); // millisecond const double d_dt_chaste_interface_var_ICaL_d_gate__d = (-var_chaste_interface__ICaL_d_gate__d + var_ICaL_d_gate__d_infinity) / var_ICaL_d_gate__tau_d; // 1 / millisecond - const double var_ICaL_f_gate__f_infinity = 1 / (1.0 + exp(9.7388888888888889 + 0.27777777777777779 * var_chaste_interface__cell__V)) + 0.59999999999999998 / (1.0 + exp(2.5 - 0.050000000000000003 * var_chaste_interface__cell__V)); // dimensionless + const double var_ICaL_f_gate__f_infinity = 1 / (1 + exp(9.7388888888888889 + 0.27777777777777779 * var_chaste_interface__cell__V)) + 0.59999999999999998 / (1 + exp(2.5 - 0.050000000000000003 * var_chaste_interface__cell__V)); // dimensionless const double var_ICaL_f_gate__tau_f = 1 / (0.02 + 0.019699999999999999 * exp(-0.23877882250000002 * pow((1 + 0.068965517241379309 * var_chaste_interface__cell__V), 2))); // millisecond const double d_dt_chaste_interface_var_ICaL_f_gate__f = (-var_chaste_interface__ICaL_f_gate__f + var_ICaL_f_gate__f_infinity) / var_ICaL_f_gate__tau_f; // 1 / millisecond - const double var_IKr_Xr_gate__Xr_infinity = 1 / (1.0 + exp(-6.666666666666667 - 0.13333333333333333 * var_chaste_interface__cell__V)); // dimensionless - const double var_IKr_Xr_gate__tau_Xr = 1 / (0.00060999999999999997 * (10.0 + var_chaste_interface__cell__V) / (-1.0 + exp(1.45 + 0.14499999999999999 * var_chaste_interface__cell__V)) + 0.0013799999999999999 * (7.0 + var_chaste_interface__cell__V) / (1.0 - exp(-0.86099999999999999 - 0.123 * var_chaste_interface__cell__V))); // millisecond + const double var_IKr_Xr_gate__Xr_infinity = 1 / (1 + exp(-6.666666666666667 - 0.13333333333333333 * var_chaste_interface__cell__V)); // dimensionless + const double var_IKr_Xr_gate__tau_Xr = 1 / (0.00060999999999999997 * (10 + var_chaste_interface__cell__V) / (-1 + exp(1.45 + 0.14499999999999999 * var_chaste_interface__cell__V)) + 0.0013799999999999999 * (7 + var_chaste_interface__cell__V) / (1 - exp(-0.86099999999999999 - 0.123 * var_chaste_interface__cell__V))); // millisecond const double d_dt_chaste_interface_var_IKr_Xr_gate__Xr = (-var_chaste_interface__IKr_Xr_gate__Xr + var_IKr_Xr_gate__Xr_infinity) / var_IKr_Xr_gate__tau_Xr; // 1 / millisecond - const double var_IKs_Xs_gate__Xs_infinity = 1 / (1.0 + exp(0.089820359281437126 - 0.059880239520958084 * var_chaste_interface__cell__V)); // dimensionless - const double var_IKs_Xs_gate__tau_Xs = 1 / (0.00013100000000000001 * (30.0 + var_chaste_interface__cell__V) / (-1.0 + exp(2.0609999999999999 + 0.068699999999999997 * var_chaste_interface__cell__V)) + 7.1899999999999999e-5 * (30.0 + var_chaste_interface__cell__V) / (1.0 - exp(-4.4399999999999995 - 0.14799999999999999 * var_chaste_interface__cell__V))); // millisecond + const double var_IKs_Xs_gate__Xs_infinity = 1 / (1 + exp(0.089820359281437126 - 0.059880239520958084 * var_chaste_interface__cell__V)); // dimensionless + const double var_IKs_Xs_gate__tau_Xs = 1 / (0.00013100000000000001 * (30 + var_chaste_interface__cell__V) / (-1 + exp(2.0609999999999999 + 0.068699999999999997 * var_chaste_interface__cell__V)) + 7.1899999999999999e-5 * (30 + var_chaste_interface__cell__V) / (1 - exp(-4.4399999999999995 - 0.14799999999999999 * var_chaste_interface__cell__V))); // millisecond const double d_dt_chaste_interface_var_IKs_Xs_gate__Xs = (-var_chaste_interface__IKs_Xs_gate__Xs + var_IKs_Xs_gate__Xs_infinity) / var_IKs_Xs_gate__tau_Xs; // 1 / millisecond - const double var_INa_h_gate__alpha_h = ((var_chaste_interface__cell__V < -40.0) ? (0.13500000000000001 * exp(-11.764705882352942 + 0.14705882352941177 * NV_Ith_S(mParameters, 16) - 0.14705882352941177 * var_chaste_interface__cell__V)) : (0)); // per_millisecond - const double var_INa_h_gate__beta_h = ((var_chaste_interface__cell__V < -40.0) ? (310000.0 * exp(0.34999999999999998 * var_chaste_interface__cell__V - 0.34999999999999998 * NV_Ith_S(mParameters, 16)) + 3.5600000000000001 * exp(0.079000000000000001 * var_chaste_interface__cell__V - 0.079000000000000001 * NV_Ith_S(mParameters, 16))) : (7.6923076923076916 / (1.0 + exp(-0.96036036036036043 + 0.0900900900900901 * NV_Ith_S(mParameters, 16) - 0.0900900900900901 * var_chaste_interface__cell__V)))); // per_millisecond - const double var_INa_h_gate__h_infinity = 0.01 * NV_Ith_S(mParameters, 15) + (1.0 - 0.01 * NV_Ith_S(mParameters, 15)) * var_INa_h_gate__alpha_h / (var_INa_h_gate__alpha_h + var_INa_h_gate__beta_h); // dimensionless + const double var_INa_h_gate__alpha_h = ((var_chaste_interface__cell__V < -40) ? (0.13500000000000001 * exp(-11.764705882352942 + 0.14705882352941177 * NV_Ith_S(mParameters, 16) - 0.14705882352941177 * var_chaste_interface__cell__V)) : (0)); // per_millisecond + const double var_INa_h_gate__beta_h = ((var_chaste_interface__cell__V < -40) ? (310000 * exp(0.34999999999999998 * var_chaste_interface__cell__V - 0.34999999999999998 * NV_Ith_S(mParameters, 16)) + 3.5600000000000001 * exp(0.079000000000000001 * var_chaste_interface__cell__V - 0.079000000000000001 * NV_Ith_S(mParameters, 16))) : (7.6923076923076916 / (1 + exp(-0.96036036036036043 + 0.0900900900900901 * NV_Ith_S(mParameters, 16) - 0.0900900900900901 * var_chaste_interface__cell__V)))); // per_millisecond + const double var_INa_h_gate__h_infinity = 0.01 * NV_Ith_S(mParameters, 15) + (1 - 0.01 * NV_Ith_S(mParameters, 15)) * var_INa_h_gate__alpha_h / (var_INa_h_gate__alpha_h + var_INa_h_gate__beta_h); // dimensionless const double var_INa_h_gate__tau_h = 1 / (var_INa_h_gate__alpha_h + var_INa_h_gate__beta_h); // millisecond const double d_dt_chaste_interface_var_INa_h_gate__h = (-var_chaste_interface__INa_h_gate__h + var_INa_h_gate__h_infinity) / var_INa_h_gate__tau_h; // 1 / millisecond - const double var_INa_j_gate__alpha_j = ((var_chaste_interface__cell__V < -40.0) ? ((37.780000000000001 + var_chaste_interface__cell__V) * (-127140.0 * exp(0.24440000000000001 * var_chaste_interface__cell__V - 0.24440000000000001 * NV_Ith_S(mParameters, 16)) - 3.4740000000000003e-5 * exp(0.043909999999999998 * NV_Ith_S(mParameters, 16) - 0.043909999999999998 * var_chaste_interface__cell__V)) / (1.0 + exp(24.640530000000002 + 0.311 * var_chaste_interface__cell__V - 0.311 * NV_Ith_S(mParameters, 16)))) : (0)); // per_millisecond - const double var_INa_j_gate__beta_j = ((var_chaste_interface__cell__V < -40.0) ? (0.1212 * exp(0.01052 * NV_Ith_S(mParameters, 16) - 0.01052 * var_chaste_interface__cell__V) / (1.0 + exp(-5.5312920000000005 + 0.13780000000000001 * NV_Ith_S(mParameters, 16) - 0.13780000000000001 * var_chaste_interface__cell__V))) : (0.29999999999999999 * exp(2.5349999999999999e-7 * NV_Ith_S(mParameters, 16) - 2.5349999999999999e-7 * var_chaste_interface__cell__V) / (1.0 + exp(-3.2000000000000002 + 0.10000000000000001 * NV_Ith_S(mParameters, 16) - 0.10000000000000001 * var_chaste_interface__cell__V)))); // per_millisecond - const double var_INa_j_gate__j_infinity = 0.01 * NV_Ith_S(mParameters, 15) + (1.0 - 0.01 * NV_Ith_S(mParameters, 15)) * var_INa_j_gate__alpha_j / (var_INa_j_gate__alpha_j + var_INa_j_gate__beta_j); // dimensionless + const double var_INa_j_gate__alpha_j = ((var_chaste_interface__cell__V < -40) ? ((37.780000000000001 + var_chaste_interface__cell__V) * (-127140 * exp(0.24440000000000001 * var_chaste_interface__cell__V - 0.24440000000000001 * NV_Ith_S(mParameters, 16)) - 3.4740000000000003e-5 * exp(0.043909999999999998 * NV_Ith_S(mParameters, 16) - 0.043909999999999998 * var_chaste_interface__cell__V)) / (1 + exp(24.640530000000002 + 0.311 * var_chaste_interface__cell__V - 0.311 * NV_Ith_S(mParameters, 16)))) : (0)); // per_millisecond + const double var_INa_j_gate__beta_j = ((var_chaste_interface__cell__V < -40) ? (0.1212 * exp(0.01052 * NV_Ith_S(mParameters, 16) - 0.01052 * var_chaste_interface__cell__V) / (1 + exp(-5.5312920000000005 + 0.13780000000000001 * NV_Ith_S(mParameters, 16) - 0.13780000000000001 * var_chaste_interface__cell__V))) : (0.29999999999999999 * exp(2.5349999999999999e-7 * NV_Ith_S(mParameters, 16) - 2.5349999999999999e-7 * var_chaste_interface__cell__V) / (1 + exp(-3.2000000000000002 + 0.10000000000000001 * NV_Ith_S(mParameters, 16) - 0.10000000000000001 * var_chaste_interface__cell__V)))); // per_millisecond + const double var_INa_j_gate__j_infinity = 0.01 * NV_Ith_S(mParameters, 15) + (1 - 0.01 * NV_Ith_S(mParameters, 15)) * var_INa_j_gate__alpha_j / (var_INa_j_gate__alpha_j + var_INa_j_gate__beta_j); // dimensionless const double var_INa_j_gate__tau_j = 1 / (var_INa_j_gate__alpha_j + var_INa_j_gate__beta_j); // millisecond const double d_dt_chaste_interface_var_INa_j_gate__j = (-var_chaste_interface__INa_j_gate__j + var_INa_j_gate__j_infinity) / var_INa_j_gate__tau_j; // 1 / millisecond - const double var_INa_m_gate__alpha_m = 0.32000000000000001 * (47.130000000000003 + var_chaste_interface__cell__V) / (1.0 - exp(-4.7130000000000001 - 0.10000000000000001 * var_chaste_interface__cell__V)); // per_millisecond + const double var_INa_m_gate__alpha_m = 0.32000000000000001 * (47.130000000000003 + var_chaste_interface__cell__V) / (1 - exp(-4.7130000000000001 - 0.10000000000000001 * var_chaste_interface__cell__V)); // per_millisecond const double var_INa_m_gate__beta_m = 0.080000000000000002 * exp(-0.090909090909090912 * var_chaste_interface__cell__V); // per_millisecond const double var_INa_m_gate__m_infinity = var_INa_m_gate__alpha_m / (var_INa_m_gate__alpha_m + var_INa_m_gate__beta_m); // dimensionless const double var_INa_m_gate__tau_m = 1 / (var_INa_m_gate__alpha_m + var_INa_m_gate__beta_m); // millisecond const double d_dt_chaste_interface_var_INa_m_gate__m = (-var_chaste_interface__INa_m_gate__m + var_INa_m_gate__m_infinity) / var_INa_m_gate__tau_m; // 1 / millisecond - const double var_Itof_X_gate__X_tof_infinity = 1 / (1.0 + exp(-0.20000000000000001 - 0.066666666666666666 * var_chaste_interface__cell__V)); // dimensionless + const double var_Itof_X_gate__X_tof_infinity = 1 / (1 + exp(-0.20000000000000001 - 0.066666666666666666 * var_chaste_interface__cell__V)); // dimensionless const double var_Itof_X_gate__tau_X_tof = 1.5 + 3.5 * exp(-0.0011111111111111111 * pow(var_chaste_interface__cell__V, 2)); // millisecond const double d_dt_chaste_interface_var_Itof_X_gate__X_tof = (-var_chaste_interface__Itof_X_gate__X_tof + var_Itof_X_gate__X_tof_infinity) / var_Itof_X_gate__tau_X_tof; // 1 / millisecond - const double var_Itof_Y_gate__Y_tof_infinity = 1 / (1.0 + exp(3.3500000000000001 + 0.10000000000000001 * var_chaste_interface__cell__V)); // dimensionless - const double var_Itof_Y_gate__tau_Y_tof = 20.0 + 20.0 / (1.0 + exp(3.3500000000000001 + 0.10000000000000001 * var_chaste_interface__cell__V)); // millisecond + const double var_Itof_Y_gate__Y_tof_infinity = 1 / (1 + exp(3.3500000000000001 + 0.10000000000000001 * var_chaste_interface__cell__V)); // dimensionless + const double var_Itof_Y_gate__tau_Y_tof = 20 + 20 / (1 + exp(3.3500000000000001 + 0.10000000000000001 * var_chaste_interface__cell__V)); // millisecond const double d_dt_chaste_interface_var_Itof_Y_gate__Y_tof = (-var_chaste_interface__Itof_Y_gate__Y_tof + var_Itof_Y_gate__Y_tof_infinity) / var_Itof_Y_gate__tau_Y_tof; // 1 / millisecond - const double var_Itos_R_gate__R_tos_infinity = 1 / (1.0 + exp(3.3500000000000001 + 0.10000000000000001 * var_chaste_interface__cell__V)); // dimensionless - const double var_Itos_R_gate__tau_R_tos = 220.0 + 2800.0 / (1.0 + exp(6.0 + 0.10000000000000001 * var_chaste_interface__cell__V)); // millisecond + const double var_Itos_R_gate__R_tos_infinity = 1 / (1 + exp(3.3500000000000001 + 0.10000000000000001 * var_chaste_interface__cell__V)); // dimensionless + const double var_Itos_R_gate__tau_R_tos = 220 + 2800 / (1 + exp(6 + 0.10000000000000001 * var_chaste_interface__cell__V)); // millisecond const double d_dt_chaste_interface_var_Itos_R_gate__R_tos = (-var_chaste_interface__Itos_R_gate__R_tos + var_Itos_R_gate__R_tos_infinity) / var_Itos_R_gate__tau_R_tos; // 1 / millisecond - const double var_Itos_X_gate__X_tos_infinity = 1 / (1.0 + exp(-0.20000000000000001 - 0.066666666666666666 * var_chaste_interface__cell__V)); // dimensionless - const double var_Itos_X_gate__tau_X_tos = 0.5 + 9.0 / (1.0 + exp(0.20000000000000001 + 0.066666666666666666 * var_chaste_interface__cell__V)); // millisecond + const double var_Itos_X_gate__X_tos_infinity = 1 / (1 + exp(-0.20000000000000001 - 0.066666666666666666 * var_chaste_interface__cell__V)); // dimensionless + const double var_Itos_X_gate__tau_X_tos = 0.5 + 9 / (1 + exp(0.20000000000000001 + 0.066666666666666666 * var_chaste_interface__cell__V)); // millisecond const double d_dt_chaste_interface_var_Itos_X_gate__X_tos = (-var_chaste_interface__Itos_X_gate__X_tos + var_Itos_X_gate__X_tos_infinity) / var_Itos_X_gate__tau_X_tos; // 1 / millisecond - const double var_Itos_Y_gate__Y_tos_infinity = 1 / (1.0 + exp(3.3500000000000001 + 0.10000000000000001 * var_chaste_interface__cell__V)); // dimensionless - const double var_Itos_Y_gate__tau_Y_tos = 30.0 + 3000.0 / (1.0 + exp(6.0 + 0.10000000000000001 * var_chaste_interface__cell__V)); // millisecond + const double var_Itos_Y_gate__Y_tos_infinity = 1 / (1 + exp(3.3500000000000001 + 0.10000000000000001 * var_chaste_interface__cell__V)); // dimensionless + const double var_Itos_Y_gate__tau_Y_tos = 30 + 3000 / (1 + exp(6 + 0.10000000000000001 * var_chaste_interface__cell__V)); // millisecond const double d_dt_chaste_interface_var_Itos_Y_gate__Y_tos = (-var_chaste_interface__Itos_Y_gate__Y_tos + var_Itos_Y_gate__Y_tos_infinity) / var_Itos_Y_gate__tau_Y_tos; // 1 / millisecond const double var_cytosolic_Ca_buffer__Bmax_Calmodulin = 0.024; // millimolar const double var_cytosolic_Ca_buffer__Bmax_Myosin_Ca = 0.14000000000000001; // millimolar @@ -529,14 +536,14 @@ const double var_cytosolic_Ca_buffer__koff_TroponinC = 0.019599999999999999; // per_millisecond const double var_cytosolic_Ca_buffer__koff_TroponinC_Ca_Mg_Ca = 3.1999999999999999e-5; // per_millisecond const double var_cytosolic_Ca_buffer__koff_TroponinC_Ca_Mg_Mg = 0.0033300000000000001; // per_millisecond - const double var_cytosolic_Ca_buffer__kon_Calmodulin = 34.0; // per_millimolar_per_millisecond + const double var_cytosolic_Ca_buffer__kon_Calmodulin = 34; // per_millimolar_per_millisecond const double var_cytosolic_Ca_buffer__dCa_Calmodulin = -var_chaste_interface__cytosolic_Ca_buffer__Ca_Calmodulin * var_cytosolic_Ca_buffer__koff_Calmodulin + (-var_chaste_interface__cytosolic_Ca_buffer__Ca_Calmodulin + var_cytosolic_Ca_buffer__Bmax_Calmodulin) * var_chaste_interface__Ca_buffer__Cai * var_cytosolic_Ca_buffer__kon_Calmodulin; // millimolar_per_millisecond const double d_dt_chaste_interface_var_cytosolic_Ca_buffer__Ca_Calmodulin = var_cytosolic_Ca_buffer__dCa_Calmodulin; // millimolar / millisecond const double var_cytosolic_Ca_buffer__kon_Myosin_Ca = 13.800000000000001; // per_millimolar_per_millisecond const double var_cytosolic_Ca_buffer__dCa_Myosin = -var_chaste_interface__cytosolic_Ca_buffer__Ca_Myosin * var_cytosolic_Ca_buffer__koff_Myosin_Ca + (-var_chaste_interface__cytosolic_Ca_buffer__Ca_Myosin - var_chaste_interface__cytosolic_Ca_buffer__Mg_Myosin + var_cytosolic_Ca_buffer__Bmax_Myosin_Ca) * var_chaste_interface__Ca_buffer__Cai * var_cytosolic_Ca_buffer__kon_Myosin_Ca; // millimolar_per_millisecond const double d_dt_chaste_interface_var_cytosolic_Ca_buffer__Ca_Myosin = var_cytosolic_Ca_buffer__dCa_Myosin; // millimolar / millisecond const double var_cytosolic_Ca_buffer__kon_Myosin_Mg = 0.015699999999999999; // per_millimolar_per_millisecond - const double var_cytosolic_Ca_buffer__kon_SRB = 100.0; // per_millimolar_per_millisecond + const double var_cytosolic_Ca_buffer__kon_SRB = 100; // per_millimolar_per_millisecond const double var_cytosolic_Ca_buffer__dCa_SRB = -var_chaste_interface__cytosolic_Ca_buffer__Ca_SRB * var_cytosolic_Ca_buffer__koff_SRB + (-var_chaste_interface__cytosolic_Ca_buffer__Ca_SRB + var_cytosolic_Ca_buffer__Bmax_SRB) * var_chaste_interface__Ca_buffer__Cai * var_cytosolic_Ca_buffer__kon_SRB; // millimolar_per_millisecond const double d_dt_chaste_interface_var_cytosolic_Ca_buffer__Ca_SRB = var_cytosolic_Ca_buffer__dCa_SRB; // millimolar / millisecond const double var_cytosolic_Ca_buffer__kon_TroponinC = 32.700000000000003; // per_millimolar_per_millisecond @@ -556,41 +563,41 @@ const double var_indo_fluo_Ca_buffer_not_connected__Indo1 = 0; // millimolar const double var_indo_fluo_Ca_buffer_not_connected__koff_Fluo3 = 0.11; // per_millisecond const double var_indo_fluo_Ca_buffer_not_connected__koff_Indo1 = 0.059999999999999998; // per_millisecond - const double var_indo_fluo_Ca_buffer_not_connected__kon_Fluo3 = 100.0; // per_millimolar2_per_millisecond - const double var_indo_fluo_Ca_buffer_not_connected__kon_Indo1 = 100.0; // per_millimolar2_per_millisecond + const double var_indo_fluo_Ca_buffer_not_connected__kon_Fluo3 = 100; // per_millimolar2_per_millisecond + const double var_indo_fluo_Ca_buffer_not_connected__kon_Indo1 = 100; // per_millimolar2_per_millisecond const double var_ion_diffusion__J_Ca_SL_cytosol = 3.7243000000000002e-12 * var_chaste_interface__Ca_buffer__Ca_SL - 3.7243000000000002e-12 * var_chaste_interface__Ca_buffer__Cai; // millimole_per_millisecond const double var_ion_diffusion__J_Ca_jct_SL = 8.2413000000000004e-13 * var_chaste_interface__Ca_buffer__Ca_jct - 8.2413000000000004e-13 * var_chaste_interface__Ca_buffer__Ca_SL; // millimole_per_millisecond const double var_ion_diffusion__J_Na_SL_cytosol = 1.6385999999999999e-12 * var_chaste_interface__Na_buffer__Na_SL - 1.6385999999999999e-12 * var_chaste_interface__Na_buffer__Nai; // millimole_per_millisecond const double var_ion_diffusion__J_Na_jct_SL = 1.8312999999999999e-14 * var_chaste_interface__Na_buffer__Na_jct - 1.8312999999999999e-14 * var_chaste_interface__Na_buffer__Na_SL; // millimole_per_millisecond const double var_model_parameters__Cm_per_area = 1.9999999999999999e-6; // farad_per_cm2 - const double var_model_parameters__Mgi = 1.0; // millimolar + const double var_model_parameters__Mgi = 1; // millimolar const double var_cytosolic_Ca_buffer__dMg_Myosin = -var_chaste_interface__cytosolic_Ca_buffer__Mg_Myosin * var_cytosolic_Ca_buffer__koff_Myosin_Mg + (-var_chaste_interface__cytosolic_Ca_buffer__Ca_Myosin - var_chaste_interface__cytosolic_Ca_buffer__Mg_Myosin + var_cytosolic_Ca_buffer__Bmax_Myosin_Mg) * var_cytosolic_Ca_buffer__kon_Myosin_Mg * var_model_parameters__Mgi; // millimolar_per_millisecond const double d_dt_chaste_interface_var_cytosolic_Ca_buffer__Mg_Myosin = var_cytosolic_Ca_buffer__dMg_Myosin; // millimolar / millisecond const double var_cytosolic_Ca_buffer__dMg_TroponinC_Ca_Mg = -var_chaste_interface__cytosolic_Ca_buffer__Mg_TroponinC_Ca_Mg * var_cytosolic_Ca_buffer__koff_TroponinC_Ca_Mg_Mg + (-var_chaste_interface__cytosolic_Ca_buffer__Ca_TroponinC_Ca_Mg - var_chaste_interface__cytosolic_Ca_buffer__Mg_TroponinC_Ca_Mg + var_cytosolic_Ca_buffer__Bmax_TroponinC_Ca_Mg_Mg) * var_cytosolic_Ca_buffer__kon_TroponinC_Ca_Mg_Mg * var_model_parameters__Mgi; // millimolar_per_millisecond const double d_dt_chaste_interface_var_cytosolic_Ca_buffer__Mg_TroponinC_Ca_Mg = var_cytosolic_Ca_buffer__dMg_TroponinC_Ca_Mg; // millimolar / millisecond const double var_cytosolic_Ca_buffer__dCa_cytosol_tot_bound = var_cytosolic_Ca_buffer__dCa_Calmodulin + var_cytosolic_Ca_buffer__dCa_Myosin + var_cytosolic_Ca_buffer__dCa_SRB + var_cytosolic_Ca_buffer__dCa_TroponinC + var_cytosolic_Ca_buffer__dCa_TroponinC_Ca_Mg + var_cytosolic_Ca_buffer__dMg_Myosin + var_cytosolic_Ca_buffer__dMg_TroponinC_Ca_Mg; // millimolar_per_millisecond const double var_INaK__sigma = -0.14285714285714285 + 0.14285714285714285 * exp(0.01485884101040119 * NV_Ith_S(mParameters, 9)); // dimensionless - const double var_ICaL__Q_CaL = pow(var_ICaL__Q10_CaL, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_ICaL__Q_CaL = pow(var_ICaL__Q10_CaL, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless const double var_ICaL__temp = 0.45000000000000001 * pow(NV_Ith_S(mParameters, 10), 2) * var_ICaL__Q_CaL * var_chaste_interface__ICaL_d_gate__d * var_chaste_interface__ICaL_f_gate__f * var_chaste_interface__cell__V / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)); // coulomb_per_mole - const double var_ICaL__i_CaL_Ca_SL = 4.0 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_SL * var_ICaL__gamma_Cai * exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1.0 + exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Ca_jct = 4.0 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_jct * var_ICaL__gamma_Cai * exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1.0 + exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Na_SL = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_SL * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Na_jct = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_jct * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICap__Q_SLCaP = pow(var_ICap__Q10_SLCaP, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_ICap__i_Cap_SL = var_ICap__Fx_SLCaP_SL * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1.0 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_SL), var_ICap__H)); // microA_per_microF - const double var_ICap__i_Cap_jct = var_ICap__Fx_SLCaP_jct * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1.0 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_jct), var_ICap__H)); // microA_per_microF - const double var_INaCa__Q_NCX = pow(var_INaCa__Q10_NCX, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_INaCa__temp_SL = (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1.0 + var_INaCa__ksat * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 - const double var_INaCa__i_NaCa_SL = var_INaCa__Fx_NCX_SL * var_INaCa__Ka_SL * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_SL / (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1.0 + var_chaste_interface__Ca_buffer__Ca_SL / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_SL + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1.0 + pow((var_chaste_interface__Na_buffer__Na_SL / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF - const double var_INaCa__temp_jct = (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1.0 + var_INaCa__ksat * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 - const double var_INaCa__i_NaCa_jct = var_INaCa__Fx_NCX_jct * var_INaCa__Ka_jct * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_jct / (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1.0 + var_chaste_interface__Ca_buffer__Ca_jct / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_jct + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1.0 + pow((var_chaste_interface__Na_buffer__Na_jct / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF - const double var_INaK__Q_Km_Nai = pow(var_INaK__Q10_Km_Nai, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_INaK__Q_NaK = pow(var_INaK__Q10_NaK, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_INaK__f_NaK = 1 / (1.0 + 0.1245 * exp(-0.10000000000000001 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) + 0.036499999999999998 * var_INaK__sigma * exp(-var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // dimensionless - const double var_INaK__i_NaK_SL = var_INaK__Fx_NaK_SL * var_INaK__I_NaK_max * var_INaK__Q_NaK * var_INaK__f_NaK * NV_Ith_S(mParameters, 8) / ((1.0 + pow((var_INaK__Km_Nai * var_INaK__Q_Km_Nai / var_chaste_interface__Na_buffer__Na_SL), var_INaK__H_NaK)) * (var_INaK__Km_Ko + NV_Ith_S(mParameters, 8))); // microA_per_microF - const double var_INaK__i_NaK_jct = var_INaK__Fx_NaK_jct * var_INaK__I_NaK_max * var_INaK__Q_NaK * var_INaK__f_NaK * NV_Ith_S(mParameters, 8) / ((1.0 + pow((var_INaK__Km_Nai * var_INaK__Q_Km_Nai / var_chaste_interface__Na_buffer__Na_jct), var_INaK__H_NaK)) * (var_INaK__Km_Ko + NV_Ith_S(mParameters, 8))); // microA_per_microF - const double var_Jpump_SR__Q_SRCaP = pow(var_Jpump_SR__Q10_SRCaP, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_model_parameters__cell_length = 100.0; // micrometre + const double var_ICaL__i_CaL_Ca_SL = 4 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_SL * var_ICaL__gamma_Cai * exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1 + exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Ca_jct = 4 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_jct * var_ICaL__gamma_Cai * exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1 + exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Na_SL = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_SL * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Na_jct = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_jct * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICap__Q_SLCaP = pow(var_ICap__Q10_SLCaP, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_ICap__i_Cap_SL = var_ICap__Fx_SLCaP_SL * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_SL), var_ICap__H)); // microA_per_microF + const double var_ICap__i_Cap_jct = var_ICap__Fx_SLCaP_jct * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_jct), var_ICap__H)); // microA_per_microF + const double var_INaCa__Q_NCX = pow(var_INaCa__Q10_NCX, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_INaCa__temp_SL = (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1 + var_INaCa__ksat * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 + const double var_INaCa__i_NaCa_SL = var_INaCa__Fx_NCX_SL * var_INaCa__Ka_SL * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_SL / (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1 + var_chaste_interface__Ca_buffer__Ca_SL / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_SL + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1 + pow((var_chaste_interface__Na_buffer__Na_SL / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF + const double var_INaCa__temp_jct = (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1 + var_INaCa__ksat * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 + const double var_INaCa__i_NaCa_jct = var_INaCa__Fx_NCX_jct * var_INaCa__Ka_jct * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_jct / (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1 + var_chaste_interface__Ca_buffer__Ca_jct / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_jct + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1 + pow((var_chaste_interface__Na_buffer__Na_jct / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF + const double var_INaK__Q_Km_Nai = pow(var_INaK__Q10_Km_Nai, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_INaK__Q_NaK = pow(var_INaK__Q10_NaK, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_INaK__f_NaK = 1 / (1 + 0.1245 * exp(-0.10000000000000001 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) + 0.036499999999999998 * var_INaK__sigma * exp(-var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // dimensionless + const double var_INaK__i_NaK_SL = var_INaK__Fx_NaK_SL * var_INaK__I_NaK_max * var_INaK__Q_NaK * var_INaK__f_NaK * NV_Ith_S(mParameters, 8) / ((1 + pow((var_INaK__Km_Nai * var_INaK__Q_Km_Nai / var_chaste_interface__Na_buffer__Na_SL), var_INaK__H_NaK)) * (var_INaK__Km_Ko + NV_Ith_S(mParameters, 8))); // microA_per_microF + const double var_INaK__i_NaK_jct = var_INaK__Fx_NaK_jct * var_INaK__I_NaK_max * var_INaK__Q_NaK * var_INaK__f_NaK * NV_Ith_S(mParameters, 8) / ((1 + pow((var_INaK__Km_Nai * var_INaK__Q_Km_Nai / var_chaste_interface__Na_buffer__Na_jct), var_INaK__H_NaK)) * (var_INaK__Km_Ko + NV_Ith_S(mParameters, 8))); // microA_per_microF + const double var_Jpump_SR__Q_SRCaP = pow(var_Jpump_SR__Q10_SRCaP, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_model_parameters__cell_length = 100; // micrometre const double var_model_parameters__cell_radius = 10.25; // micrometre const double var_model_parameters__Cm = 2.0e-8 * M_PI * var_model_parameters__Cm_per_area * var_model_parameters__cell_length * var_model_parameters__cell_radius; // farad const double var_model_parameters__Vol_Cell = 3.1415926540000002e-15 * pow(var_model_parameters__cell_radius, 2) * var_model_parameters__cell_length; // liter @@ -605,7 +612,7 @@ const double d_dt_chaste_interface_var_Ca_buffer__Ca_SLB_SL = var_Ca_buffer__dCa_SLB_SL; // millimolar / millisecond const double d_dt_chaste_interface_var_Ca_buffer__Ca_SLHigh_SL = var_Ca_buffer__dCa_SLHigh_SL; // millimolar / millisecond const double d_dt_chaste_interface_var_Na_buffer__Nai = NV_Ith_S(mParameters, 3) * var_ion_diffusion__J_Na_SL_cytosol / var_model_parameters__Vol_cytosol; // millimolar / millisecond - const double var_Jpump_SR__j_pump_SR = (pow((var_chaste_interface__Ca_buffer__Cai / var_Jpump_SR__Kmf), var_Jpump_SR__H) - pow((var_chaste_interface__Ca_buffer__Ca_SR / var_Jpump_SR__Kmr), var_Jpump_SR__H)) * var_Jpump_SR__Q_SRCaP * NV_Ith_S(mParameters, 2) * var_model_parameters__Vol_cytosol / ((1.0 + pow((var_chaste_interface__Ca_buffer__Cai / var_Jpump_SR__Kmf), var_Jpump_SR__H) + pow((var_chaste_interface__Ca_buffer__Ca_SR / var_Jpump_SR__Kmr), var_Jpump_SR__H)) * var_model_parameters__Vol_SR); // millimolar_per_millisecond + const double var_Jpump_SR__j_pump_SR = (pow((var_chaste_interface__Ca_buffer__Cai / var_Jpump_SR__Kmf), var_Jpump_SR__H) - pow((var_chaste_interface__Ca_buffer__Ca_SR / var_Jpump_SR__Kmr), var_Jpump_SR__H)) * var_Jpump_SR__Q_SRCaP * NV_Ith_S(mParameters, 2) * var_model_parameters__Vol_cytosol / ((1 + pow((var_chaste_interface__Ca_buffer__Cai / var_Jpump_SR__Kmf), var_Jpump_SR__H) + pow((var_chaste_interface__Ca_buffer__Ca_SR / var_Jpump_SR__Kmr), var_Jpump_SR__H)) * var_model_parameters__Vol_SR); // millimolar_per_millisecond const double d_dt_chaste_interface_var_Ca_buffer__Ca_SR = -var_Ca_buffer__dCalsequestrin - var_Jrel_SR__j_rel_SR - var_Jleak_SR__j_leak_SR * var_model_parameters__Vol_cytosol / var_model_parameters__Vol_SR + var_Jpump_SR__j_pump_SR; // millimolar / millisecond const double d_dt_chaste_interface_var_Ca_buffer__Cai = -var_cytosolic_Ca_buffer__dCa_cytosol_tot_bound + var_ion_diffusion__J_Ca_SL_cytosol / var_model_parameters__Vol_cytosol - var_Jpump_SR__j_pump_SR * var_model_parameters__Vol_SR / var_model_parameters__Vol_cytosol; // millimolar / millisecond const double var_model_parameters__Vol_jct = 0.00051000000000000004 * var_model_parameters__Vol_Cell; // liter @@ -630,20 +637,20 @@ const double d_dt_chaste_interface_var_indo_fluo_Ca_buffer_not_connected__Ca_Indo1_jct = var_indo_fluo_Ca_buffer_not_connected__dCa_Indo1_jct; // millimolar / millisecond const double var_reversal_potentials__E_Ca_SL = 0.5 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 6) / var_chaste_interface__Ca_buffer__Ca_SL) / NV_Ith_S(mParameters, 10); // millivolt const double var_ICab__i_Cab_SL = (-var_reversal_potentials__E_Ca_SL + var_chaste_interface__cell__V) * var_ICab__Fx_CaBk_SL * var_ICab__G_CaBk; // microA_per_microF - const double var_Ca_buffer__i_Ca_SL_tot = -2.0 * var_INaCa__i_NaCa_SL + var_ICaL__i_CaL_Ca_SL + var_ICab__i_Cab_SL + var_ICap__i_Cap_SL; // microA_per_microF + const double var_Ca_buffer__i_Ca_SL_tot = -2 * var_INaCa__i_NaCa_SL + var_ICaL__i_CaL_Ca_SL + var_ICab__i_Cab_SL + var_ICap__i_Cap_SL; // microA_per_microF const double d_dt_chaste_interface_var_Ca_buffer__Ca_SL = -var_Ca_buffer__dCa_SL_tot_bound + (-var_ion_diffusion__J_Ca_SL_cytosol + var_ion_diffusion__J_Ca_jct_SL) / var_model_parameters__Vol_SL - 0.5 * var_Ca_buffer__i_Ca_SL_tot * var_model_parameters__Cm / (NV_Ith_S(mParameters, 10) * var_model_parameters__Vol_SL); // millimolar / millisecond const double var_reversal_potentials__E_Ca_jct = 0.5 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 6) / var_chaste_interface__Ca_buffer__Ca_jct) / NV_Ith_S(mParameters, 10); // millivolt const double var_ICab__i_Cab_jct = (-var_reversal_potentials__E_Ca_jct + var_chaste_interface__cell__V) * var_ICab__Fx_CaBk_jct * var_ICab__G_CaBk; // microA_per_microF - const double var_Ca_buffer__i_Ca_jct_tot = -2.0 * var_INaCa__i_NaCa_jct + var_ICaL__i_CaL_Ca_jct + var_ICab__i_Cab_jct + var_ICap__i_Cap_jct; // microA_per_microF + const double var_Ca_buffer__i_Ca_jct_tot = -2 * var_INaCa__i_NaCa_jct + var_ICaL__i_CaL_Ca_jct + var_ICab__i_Cab_jct + var_ICap__i_Cap_jct; // microA_per_microF const double d_dt_chaste_interface_var_Ca_buffer__Ca_jct = -var_Ca_buffer__dCa_jct_tot_bound - var_ion_diffusion__J_Ca_jct_SL / var_model_parameters__Vol_jct + var_Jleak_SR__j_leak_SR * var_model_parameters__Vol_cytosol / var_model_parameters__Vol_jct + var_Jrel_SR__j_rel_SR * var_model_parameters__Vol_SR / var_model_parameters__Vol_jct - 0.5 * var_Ca_buffer__i_Ca_jct_tot * var_model_parameters__Cm / (NV_Ith_S(mParameters, 10) * var_model_parameters__Vol_jct); // millimolar / millisecond const double var_reversal_potentials__E_Na_SL = NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 9) / var_chaste_interface__Na_buffer__Na_SL) / NV_Ith_S(mParameters, 10); // millivolt const double var_INa__i_Na_SL = (-var_reversal_potentials__E_Na_SL + var_chaste_interface__cell__V) * var_INa__Fx_Na_SL * NV_Ith_S(mParameters, 14) * var_INa__openProb; // microA_per_microF const double var_INab__i_Nab_SL = (-var_reversal_potentials__E_Na_SL + var_chaste_interface__cell__V) * var_INab__Fx_NaBk_SL * var_INab__G_NaBk; // microA_per_microF - const double d_dt_chaste_interface_var_Na_buffer__Na_SL = (-var_Na_buffer__dNa_SL_buf + (-var_ion_diffusion__J_Na_SL_cytosol + var_ion_diffusion__J_Na_jct_SL) / var_model_parameters__Vol_SL - (3.0 * var_INaCa__i_NaCa_SL + 3.0 * var_INaK__i_NaK_SL + var_ICaL__i_CaL_Na_SL + var_INa__i_Na_SL + var_INab__i_Nab_SL) * var_model_parameters__Cm / (NV_Ith_S(mParameters, 10) * var_model_parameters__Vol_SL)) * NV_Ith_S(mParameters, 3); // millimolar / millisecond + const double d_dt_chaste_interface_var_Na_buffer__Na_SL = (-var_Na_buffer__dNa_SL_buf + (-var_ion_diffusion__J_Na_SL_cytosol + var_ion_diffusion__J_Na_jct_SL) / var_model_parameters__Vol_SL - (3 * var_INaCa__i_NaCa_SL + 3 * var_INaK__i_NaK_SL + var_ICaL__i_CaL_Na_SL + var_INa__i_Na_SL + var_INab__i_Nab_SL) * var_model_parameters__Cm / (NV_Ith_S(mParameters, 10) * var_model_parameters__Vol_SL)) * NV_Ith_S(mParameters, 3); // millimolar / millisecond const double var_reversal_potentials__E_Na_jct = NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 9) / var_chaste_interface__Na_buffer__Na_jct) / NV_Ith_S(mParameters, 10); // millivolt const double var_INa__i_Na_jct = (-var_reversal_potentials__E_Na_jct + var_chaste_interface__cell__V) * var_INa__Fx_Na_jct * NV_Ith_S(mParameters, 14) * var_INa__openProb; // microA_per_microF const double var_INab__i_Nab_jct = (-var_reversal_potentials__E_Na_jct + var_chaste_interface__cell__V) * var_INab__Fx_NaBk_jct * var_INab__G_NaBk; // microA_per_microF - const double d_dt_chaste_interface_var_Na_buffer__Na_jct = (-var_Na_buffer__dNa_jct_buf - var_ion_diffusion__J_Na_jct_SL / var_model_parameters__Vol_jct - (3.0 * var_INaCa__i_NaCa_jct + 3.0 * var_INaK__i_NaK_jct + var_ICaL__i_CaL_Na_jct + var_INa__i_Na_jct + var_INab__i_Nab_jct) * var_model_parameters__Cm / (NV_Ith_S(mParameters, 10) * var_model_parameters__Vol_jct)) * NV_Ith_S(mParameters, 3); // millimolar / millisecond + const double d_dt_chaste_interface_var_Na_buffer__Na_jct = (-var_Na_buffer__dNa_jct_buf - var_ion_diffusion__J_Na_jct_SL / var_model_parameters__Vol_jct - (3 * var_INaCa__i_NaCa_jct + 3 * var_INaK__i_NaK_jct + var_ICaL__i_CaL_Na_jct + var_INa__i_Na_jct + var_INab__i_Nab_jct) * var_model_parameters__Cm / (NV_Ith_S(mParameters, 10) * var_model_parameters__Vol_jct)) * NV_Ith_S(mParameters, 3); // millimolar / millisecond if (mSetVoltageDerivativeToZero) { @@ -660,17 +667,17 @@ const double var_ICl_Ca__Kd_ClCa = 0.10000000000000001; // millimolar const double var_IKs__Fx_Ks_SL = 0.89000000000000001; // dimensionless const double var_IKs__Fx_Ks_jct = 0.11; // dimensionless - const double var_IKs__pCa_SL = 3.0 - log10(var_chaste_interface__Ca_buffer__Ca_SL); // dimensionless - const double var_IKs__G_Ks_SL = (0.057000000000000002 + 0.19 / (1.0 + exp(-12.0 + 1.6666666666666667 * var_IKs__pCa_SL))) * NV_Ith_S(mParameters, 20); // milliS_per_microF - const double var_IKs__pCa_jct = 3.0 - log10(var_chaste_interface__Ca_buffer__Ca_jct); // dimensionless - const double var_IKs__G_Ks_jct = (0.057000000000000002 + 0.19 / (1.0 + exp(-12.0 + 1.6666666666666667 * var_IKs__pCa_jct))) * NV_Ith_S(mParameters, 20); // milliS_per_microF + const double var_IKs__pCa_SL = 3 - log10(var_chaste_interface__Ca_buffer__Ca_SL); // dimensionless + const double var_IKs__G_Ks_SL = (0.057000000000000002 + 0.19 / (1 + exp(-12 + 1.6666666666666667 * var_IKs__pCa_SL))) * NV_Ith_S(mParameters, 20); // milliS_per_microF + const double var_IKs__pCa_jct = 3 - log10(var_chaste_interface__Ca_buffer__Ca_jct); // dimensionless + const double var_IKs__G_Ks_jct = (0.057000000000000002 + 0.19 / (1 + exp(-12 + 1.6666666666666667 * var_IKs__pCa_jct))) * NV_Ith_S(mParameters, 20); // milliS_per_microF const double var_IKs__pKNa = 0.018329999999999999; // dimensionless - const double var_IKr_Rr_gate__Rr = 1 / (1.0 + exp(1.4732142857142858 + 0.044642857142857144 * var_chaste_interface__cell__V)); // dimensionless + const double var_IKr_Rr_gate__Rr = 1 / (1 + exp(1.4732142857142858 + 0.044642857142857144 * var_chaste_interface__cell__V)); // dimensionless const double var_cell__i_Stim_converted = GetIntracellularAreaStimulus(var_chaste_interface__environment__time); // uA_per_cm2 const double var_cell__i_Stim = var_cell__i_Stim_converted / HeartConfig::Instance()->GetCapacitance(); // microA_per_microF const double var_IK1__G_K1 = 0.43033148291193518 * sqrt(NV_Ith_S(mParameters, 8)) * NV_Ith_S(mParameters, 18); // milliS_per_microF const double var_IKr__G_IKr = 0.43033148291193518 * sqrt(NV_Ith_S(mParameters, 8)) * NV_Ith_S(mParameters, 19); // milliS_per_microF - const double var_ICaL__i_CaL_K = (var_ICaL__Fx_ICaL_SL * var_ICaL_fCa_gate__fCa_SL + var_ICaL__Fx_ICaL_jct * var_ICaL_fCa_gate__fCa_jct) * (-var_ICaL__gamma_Ko * NV_Ith_S(mParameters, 8) + var_ICaL__gamma_Ki * NV_Ith_S(mParameters, 5) * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__PK * var_ICaL__temp / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_K = (var_ICaL__Fx_ICaL_SL * var_ICaL_fCa_gate__fCa_SL + var_ICaL__Fx_ICaL_jct * var_ICaL_fCa_gate__fCa_jct) * (-var_ICaL__gamma_Ko * NV_Ith_S(mParameters, 8) + var_ICaL__gamma_Ki * NV_Ith_S(mParameters, 5) * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__PK * var_ICaL__temp / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF const double var_ICaL__i_CaL = var_ICaL__i_CaL_Ca_SL + var_ICaL__i_CaL_Ca_jct + var_ICaL__i_CaL_K + var_ICaL__i_CaL_Na_SL + var_ICaL__i_CaL_Na_jct; // microA_per_microF const double var_ICap__i_Cap = var_ICap__i_Cap_SL + var_ICap__i_Cap_jct; // microA_per_microF const double var_IKs__E_Ks = NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log((var_IKs__pKNa * NV_Ith_S(mParameters, 9) + NV_Ith_S(mParameters, 8)) / (var_IKs__pKNa * var_chaste_interface__Na_buffer__Nai + NV_Ith_S(mParameters, 5))) / NV_Ith_S(mParameters, 10); // millivolt @@ -681,11 +688,11 @@ const double var_INaK__i_NaK = var_INaK__i_NaK_SL + var_INaK__i_NaK_jct; // microA_per_microF const double var_ICab__i_Cab = var_ICab__i_Cab_SL + var_ICab__i_Cab_jct; // microA_per_microF const double var_reversal_potentials__E_Cl = -NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 7) / NV_Ith_S(mParameters, 4)) / NV_Ith_S(mParameters, 10); // millivolt - const double var_ICl_Ca__i_Cl_Ca = (-var_reversal_potentials__E_Cl + var_chaste_interface__cell__V) * (var_ICl_Ca__Fx_Cl_SL / (1.0 + var_ICl_Ca__Kd_ClCa / var_chaste_interface__Ca_buffer__Ca_SL) + var_ICl_Ca__Fx_Cl_jct / (1.0 + var_ICl_Ca__Kd_ClCa / var_chaste_interface__Ca_buffer__Ca_jct)) * var_ICl_Ca__G_Cl; // microA_per_microF + const double var_ICl_Ca__i_Cl_Ca = (-var_reversal_potentials__E_Cl + var_chaste_interface__cell__V) * (var_ICl_Ca__Fx_Cl_SL / (1 + var_ICl_Ca__Kd_ClCa / var_chaste_interface__Ca_buffer__Ca_SL) + var_ICl_Ca__Fx_Cl_jct / (1 + var_ICl_Ca__Kd_ClCa / var_chaste_interface__Ca_buffer__Ca_jct)) * var_ICl_Ca__G_Cl; // microA_per_microF const double var_IClb__i_Clb = (-var_reversal_potentials__E_Cl + var_chaste_interface__cell__V) * NV_Ith_S(mParameters, 13); // microA_per_microF const double var_reversal_potentials__E_K = NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 8) / NV_Ith_S(mParameters, 5)) / NV_Ith_S(mParameters, 10); // millivolt - const double var_IK1_K1_gate__alpha_K1 = 1.02 / (1.0 + exp(-14.1227775 + 0.23849999999999999 * var_chaste_interface__cell__V - 0.23849999999999999 * var_reversal_potentials__E_K)); // per_millisecond - const double var_IK1_K1_gate__beta_K1 = (exp(-36.698642499999998 + 0.061749999999999999 * var_chaste_interface__cell__V - 0.061749999999999999 * var_reversal_potentials__E_K) + 0.49124000000000001 * exp(0.43983232 + 0.080320000000000003 * var_chaste_interface__cell__V - 0.080320000000000003 * var_reversal_potentials__E_K)) / (1.0 + exp(-2.4444678999999998 + 0.51429999999999998 * var_reversal_potentials__E_K - 0.51429999999999998 * var_chaste_interface__cell__V)); // per_millisecond + const double var_IK1_K1_gate__alpha_K1 = 1.02 / (1 + exp(-14.1227775 + 0.23849999999999999 * var_chaste_interface__cell__V - 0.23849999999999999 * var_reversal_potentials__E_K)); // per_millisecond + const double var_IK1_K1_gate__beta_K1 = (exp(-36.698642499999998 + 0.061749999999999999 * var_chaste_interface__cell__V - 0.061749999999999999 * var_reversal_potentials__E_K) + 0.49124000000000001 * exp(0.43983232 + 0.080320000000000003 * var_chaste_interface__cell__V - 0.080320000000000003 * var_reversal_potentials__E_K)) / (1 + exp(-2.4444678999999998 + 0.51429999999999998 * var_reversal_potentials__E_K - 0.51429999999999998 * var_chaste_interface__cell__V)); // per_millisecond const double var_IK1_K1_gate__K1_infinity = var_IK1_K1_gate__alpha_K1 / (var_IK1_K1_gate__alpha_K1 + var_IK1_K1_gate__beta_K1); // dimensionless const double var_IK1__i_K1 = (-var_reversal_potentials__E_K + var_chaste_interface__cell__V) * var_IK1__G_K1 * var_IK1_K1_gate__K1_infinity; // microA_per_microF const double var_IKr__i_Kr = (-var_reversal_potentials__E_K + var_chaste_interface__cell__V) * var_IKr__G_IKr * var_IKr_Rr_gate__Rr * var_chaste_interface__IKr_Xr_gate__Xr; // microA_per_microF @@ -743,7 +750,7 @@ NV_Ith_S(rDY,44) = d_dt_chaste_interface_var_indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct; } - void DynamicShannon2004FromCellMLCvode::EvaluateAnalyticJacobian(double var_chaste_interface__environment__time, N_Vector rY, N_Vector rDY, CHASTE_CVODE_DENSE_MATRIX rJacobian, N_Vector rTmp1, N_Vector rTmp2, N_Vector rTmp3) + void Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::EvaluateAnalyticJacobian(double var_chaste_interface__environment__time, N_Vector rY, N_Vector rDY, CHASTE_CVODE_DENSE_MATRIX rJacobian, N_Vector rTmp1, N_Vector rTmp2, N_Vector rTmp3) { double var_chaste_interface__cell__V = (mSetVoltageDerivativeToZero ? this->mFixedVoltage : NV_Ith_S(rY, 0)); // Units: millivolt; Initial value: -85.721630473733 @@ -836,655 +843,631 @@ double var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct = NV_Ith_S(rY, 44); // Units: millimolar; Initial value: 0.0 const double var_x0 = 1 / var_chaste_interface__Ca_buffer__Ca_jct; - const double var_x1 = 1.0 + 0.10000000000000001 * var_x0; + const double var_x1 = 1 + 0.10000000000000001 * var_x0; const double var_x2 = 1 / var_chaste_interface__Ca_buffer__Ca_SL; - const double var_x3 = 1.0 + 0.10000000000000001 * var_x2; - const double var_x4 = -var_chaste_interface__Itos_Y_gate__Y_tos; - const double var_x5 = (var_x4 - 0.5 * var_chaste_interface__Itos_R_gate__R_tos) * NV_Ith_S(mParameters, 21); - const double var_x6 = NV_Ith_S(mParameters, 17) * var_chaste_interface__Itof_Y_gate__Y_tof; - const double var_x7 = exp(-7.0000000000000009 - 1.6666666666666667 * log10(var_chaste_interface__Ca_buffer__Ca_jct)); - const double var_x8 = 1.0 + var_x7; - const double var_x9 = 0.057000000000000002 + 0.19 / var_x8; - const double var_x10 = pow(var_chaste_interface__IKs_Xs_gate__Xs, 2) * NV_Ith_S(mParameters, 20); - const double var_x11 = var_x10 * var_x9; - const double var_x12 = exp(-7.0000000000000009 - 1.6666666666666667 * log10(var_chaste_interface__Ca_buffer__Ca_SL)); - const double var_x13 = 1.0 + var_x12; - const double var_x14 = 0.057000000000000002 + 0.19 / var_x13; - const double var_x15 = var_x10 * var_x14; - const double var_x16 = sqrt(NV_Ith_S(mParameters, 8)); - const double var_x17 = var_x16 * NV_Ith_S(mParameters, 19) * var_chaste_interface__IKr_Xr_gate__Xr; - const double var_x18 = exp(1.4732142857142858 + 0.044642857142857144 * var_chaste_interface__cell__V); - const double var_x19 = 1.0 + var_x18; - const double var_x20 = 0.43033148291193518 / var_x19; - const double var_x21 = pow(var_chaste_interface__INa_m_gate__m, 3); - const double var_x22 = var_x21 * NV_Ith_S(mParameters, 14) * var_chaste_interface__INa_j_gate__j; - const double var_x23 = var_x22 * var_chaste_interface__INa_h_gate__h; - const double var_x24 = 1 / NV_Ith_S(mParameters, 10); - const double var_x25 = var_x24 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23); - const double var_x26 = var_x25 * log(NV_Ith_S(mParameters, 8) / NV_Ith_S(mParameters, 5)); - const double var_x27 = exp(-14.1227775 + 0.23849999999999999 * var_chaste_interface__cell__V - 0.23849999999999999 * var_x26); - const double var_x28 = 1.0 + var_x27; - const double var_x29 = 1 / var_x28; - const double var_x30 = exp(-2.4444678999999998 + 0.51429999999999998 * var_x26 - 0.51429999999999998 * var_chaste_interface__cell__V); - const double var_x31 = 1.0 + var_x30; - const double var_x32 = 1 / var_x31; - const double var_x33 = exp(-36.698642499999998 + 0.061749999999999999 * var_chaste_interface__cell__V - 0.061749999999999999 * var_x26); - const double var_x34 = exp(0.43983232 + 0.080320000000000003 * var_chaste_interface__cell__V - 0.080320000000000003 * var_x26); - const double var_x35 = var_x33 + 0.49124000000000001 * var_x34; - const double var_x36 = var_x32 * var_x35; - const double var_x37 = var_x16 * NV_Ith_S(mParameters, 18) / (var_x36 + 1.02 * var_x29); - const double var_x38 = -var_x26 + var_chaste_interface__cell__V; - const double var_x39 = var_x27 / pow(var_x28, 2); - const double var_x40 = 0.34999999999999998 * var_chaste_interface__cell__V; - const double var_x41 = 1 / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)); - const double var_x42 = var_x41 * NV_Ith_S(mParameters, 10); - const double var_x43 = exp(var_x40 * var_x42); - const double var_x44 = pow(var_chaste_interface__Na_buffer__Na_jct, 3.0); - const double var_x45 = var_x44 * NV_Ith_S(mParameters, 6); - const double var_x46 = var_x43 * var_x45; - const double var_x47 = 0.34999999999999998 * var_x42; - const double var_x48 = var_x42 * var_chaste_interface__cell__V; - const double var_x49 = exp(-0.65000000000000002 * var_x48); - const double var_x50 = pow(NV_Ith_S(mParameters, 9), 3.0); - const double var_x51 = var_x50 * var_chaste_interface__Ca_buffer__Ca_jct; - const double var_x52 = var_x49 * var_x51; - const double var_x53 = 0.65000000000000002 * var_x42; - const double var_x54 = (1.0 + 278.55153203342621 * var_chaste_interface__Ca_buffer__Ca_jct) * var_chaste_interface__Ca_buffer__Ca_jct; - const double var_x55 = 1.0 + 0.00053869674493876331 * var_x44; - const double var_x56 = 0.0035899999999999999 * var_x50; - const double var_x57 = 1 / (var_x45 + var_x51 + 669921.875 * var_x54 + 1.3 * var_x44 + var_x55 * var_x56); - const double var_x58 = 1.0 + 1.6777215999999998e-11 / pow(var_chaste_interface__Ca_buffer__Ca_jct, 3); - const double var_x59 = 1 / var_x58; - const double var_x60 = 1.0 + 0.27000000000000002 * var_x49; - const double var_x61 = -31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23); - const double var_x62 = pow(1.5700000000000001, var_x61) * NV_Ith_S(mParameters, 22); - const double var_x63 = var_x62 / var_x60; - const double var_x64 = var_x59 * var_x63; - const double var_x65 = var_x57 * var_x64; - const double var_x66 = var_x65 * (var_x46 * var_x47 + var_x52 * var_x53); - const double var_x67 = pow(var_chaste_interface__Na_buffer__Na_SL, 3.0); - const double var_x68 = var_x67 * NV_Ith_S(mParameters, 6); - const double var_x69 = var_x43 * var_x68; - const double var_x70 = var_x50 * var_chaste_interface__Ca_buffer__Ca_SL; - const double var_x71 = var_x49 * var_x70; - const double var_x72 = (1.0 + 278.55153203342621 * var_chaste_interface__Ca_buffer__Ca_SL) * var_chaste_interface__Ca_buffer__Ca_SL; - const double var_x73 = 1.0 + 0.00053869674493876331 * var_x67; - const double var_x74 = 1 / (var_x68 + var_x70 + 669921.875 * var_x72 + 1.3 * var_x67 + var_x56 * var_x73); - const double var_x75 = 1.0 + 1.6777215999999998e-11 / pow(var_chaste_interface__Ca_buffer__Ca_SL, 3); - const double var_x76 = 1 / var_x75; - const double var_x77 = var_x63 * var_x76; - const double var_x78 = var_x74 * var_x77; - const double var_x79 = var_x78 * (var_x47 * var_x69 + var_x53 * var_x71); - const double var_x80 = var_x16 * var_x38; - const double var_x81 = pow(1.49, (-124.0 + 0.40000000000000002 * NV_Ith_S(mParameters, 23))); + const double var_x3 = 1 + 0.10000000000000001 * var_x2; + const double var_x4 = NV_Ith_S(mParameters, 17) * var_chaste_interface__Itof_Y_gate__Y_tof; + const double var_x5 = -var_chaste_interface__Itos_Y_gate__Y_tos - 0.5 * var_chaste_interface__Itos_R_gate__R_tos; + const double var_x6 = exp(-7.0000000000000009 - 1.6666666666666667 * log10(var_chaste_interface__Ca_buffer__Ca_jct)); + const double var_x7 = 1 + var_x6; + const double var_x8 = 0.057000000000000002 + 0.19 / var_x7; + const double var_x9 = pow(var_chaste_interface__IKs_Xs_gate__Xs, 2) * NV_Ith_S(mParameters, 20); + const double var_x10 = var_x8 * var_x9; + const double var_x11 = exp(-7.0000000000000009 - 1.6666666666666667 * log10(var_chaste_interface__Ca_buffer__Ca_SL)); + const double var_x12 = 1 + var_x11; + const double var_x13 = 0.057000000000000002 + 0.19 / var_x12; + const double var_x14 = var_x13 * var_x9; + const double var_x15 = sqrt(NV_Ith_S(mParameters, 8)); + const double var_x16 = exp(1.4732142857142858 + 0.044642857142857144 * var_chaste_interface__cell__V); + const double var_x17 = 1 + var_x16; + const double var_x18 = 0.43033148291193518 / var_x17; + const double var_x19 = pow(var_chaste_interface__INa_m_gate__m, 3); + const double var_x20 = var_x19 * NV_Ith_S(mParameters, 14) * var_chaste_interface__INa_j_gate__j; + const double var_x21 = var_x20 * var_chaste_interface__INa_h_gate__h; + const double var_x22 = log(NV_Ith_S(mParameters, 8) / NV_Ith_S(mParameters, 5)); + const double var_x23 = 1 / NV_Ith_S(mParameters, 10); + const double var_x24 = var_x23 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23); + const double var_x25 = var_x22 * var_x24; + const double var_x26 = exp(-14.1227775 + 0.23849999999999999 * var_chaste_interface__cell__V - 0.23849999999999999 * var_x25); + const double var_x27 = 1 + var_x26; + const double var_x28 = 1 / var_x27; + const double var_x29 = exp(-2.4444678999999998 - 0.51429999999999998 * var_chaste_interface__cell__V + 0.51429999999999998 * var_x22 * var_x23 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)); + const double var_x30 = 1 + var_x29; + const double var_x31 = 1 / var_x30; + const double var_x32 = exp(-36.698642499999998 + 0.061749999999999999 * var_chaste_interface__cell__V - 0.061749999999999999 * var_x25); + const double var_x33 = exp(0.43983232 + 0.080320000000000003 * var_chaste_interface__cell__V - 0.080320000000000003 * var_x25); + const double var_x34 = var_x32 + 0.49124000000000001 * var_x33; + const double var_x35 = var_x31 * var_x34; + const double var_x36 = 1 / (var_x35 + 1.02 * var_x28); + const double var_x37 = 1 / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)); + const double var_x38 = var_x37 * NV_Ith_S(mParameters, 10); + const double var_x39 = exp(0.34999999999999998 * var_x38 * var_chaste_interface__cell__V); + const double var_x40 = pow(var_chaste_interface__Na_buffer__Na_jct, 3); + const double var_x41 = var_x40 * NV_Ith_S(mParameters, 6); + const double var_x42 = var_x39 * var_x41; + const double var_x43 = 0.34999999999999998 * var_x38; + const double var_x44 = var_x38 * var_chaste_interface__cell__V; + const double var_x45 = exp(-0.65000000000000002 * var_x44); + const double var_x46 = pow(NV_Ith_S(mParameters, 9), 3); + const double var_x47 = var_x46 * var_chaste_interface__Ca_buffer__Ca_jct; + const double var_x48 = var_x45 * var_x47; + const double var_x49 = 0.65000000000000002 * var_x38; + const double var_x50 = (1 + 278.55153203342621 * var_chaste_interface__Ca_buffer__Ca_jct) * var_chaste_interface__Ca_buffer__Ca_jct; + const double var_x51 = 1 + 0.00053869674493876331 * var_x40; + const double var_x52 = 0.0035899999999999999 * var_x46; + const double var_x53 = 1 / (var_x41 + var_x47 + 669921.875 * var_x50 + 1.3 * var_x40 + var_x51 * var_x52); + const double var_x54 = 1 + 1.6777215999999998e-11 / pow(var_chaste_interface__Ca_buffer__Ca_jct, 3); + const double var_x55 = 1 / var_x54; + const double var_x56 = 1 + 0.27000000000000002 * var_x45; + const double var_x57 = 1 / var_x56; + const double var_x58 = -31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23); + const double var_x59 = pow(1.5700000000000001, var_x58); + const double var_x60 = var_x59 * NV_Ith_S(mParameters, 22); + const double var_x61 = var_x57 * var_x60; + const double var_x62 = var_x55 * var_x61; + const double var_x63 = var_x53 * var_x62; + const double var_x64 = var_x63 * (var_x42 * var_x43 + var_x48 * var_x49); + const double var_x65 = pow(var_chaste_interface__Na_buffer__Na_SL, 3); + const double var_x66 = var_x65 * NV_Ith_S(mParameters, 6); + const double var_x67 = var_x39 * var_x66; + const double var_x68 = var_x46 * var_chaste_interface__Ca_buffer__Ca_SL; + const double var_x69 = var_x45 * var_x68; + const double var_x70 = (1 + 278.55153203342621 * var_chaste_interface__Ca_buffer__Ca_SL) * var_chaste_interface__Ca_buffer__Ca_SL; + const double var_x71 = 1 + 0.00053869674493876331 * var_x65; + const double var_x72 = 1 / (var_x66 + var_x68 + 669921.875 * var_x70 + 1.3 * var_x65 + var_x52 * var_x71); + const double var_x73 = 1 + 1.6777215999999998e-11 / pow(var_chaste_interface__Ca_buffer__Ca_SL, 3); + const double var_x74 = 1 / var_x73; + const double var_x75 = var_x61 * var_x74; + const double var_x76 = var_x72 * var_x75; + const double var_x77 = var_x76 * (var_x43 * var_x67 + var_x49 * var_x69); + const double var_x78 = pow(var_x27, (-2)); + const double var_x79 = -var_x25 + var_chaste_interface__cell__V; + const double var_x80 = var_x15 * var_x79; + const double var_x81 = pow(1.49, (-124 + 0.40000000000000002 * NV_Ith_S(mParameters, 23))); const double var_x82 = 1 / var_chaste_interface__Na_buffer__Na_jct; - const double var_x83 = var_x81 * pow(var_x82, 4.0); + const double var_x83 = var_x81 * pow(var_x82, 4); const double var_x84 = 0.10000000000000001 * var_chaste_interface__cell__V; - const double var_x85 = exp(-var_x42 * var_x84); + const double var_x85 = exp(-var_x38 * var_x84); const double var_x86 = exp(0.01485884101040119 * NV_Ith_S(mParameters, 9)); - const double var_x87 = exp(-var_x48); - const double var_x88 = 1.0 + 0.1245 * var_x85 + 0.036499999999999998 * var_x87 * (-0.14285714285714285 + 0.14285714285714285 * var_x86); - const double var_x89 = pow(1.6299999999999999, var_x61) * NV_Ith_S(mParameters, 8) / (1.5 + NV_Ith_S(mParameters, 8)); - const double var_x90 = var_x89 * (0.012450000000000001 * var_x42 * var_x85 + var_x42 * var_x87 * (-0.0052142857142857138 + 0.0052142857142857138 * var_x86)) / pow(var_x88, 2); - const double var_x91 = var_x90 / (1.0 + 14641.0 * var_x83); + const double var_x87 = exp(-var_x44); + const double var_x88 = 1 + 0.1245 * var_x85 + 0.036499999999999998 * var_x87 * (-0.14285714285714285 + 0.14285714285714285 * var_x86); + const double var_x89 = pow(1.6299999999999999, var_x58) * NV_Ith_S(mParameters, 8) / (1.5 + NV_Ith_S(mParameters, 8)); + const double var_x90 = var_x89 * (0.012450000000000001 * var_x38 * var_x85 + var_x38 * var_x87 * (-0.0052142857142857138 + 0.0052142857142857138 * var_x86)) / pow(var_x88, 2); + const double var_x91 = var_x90 / (1 + 14641 * var_x83); const double var_x92 = 1 / var_chaste_interface__Na_buffer__Na_SL; - const double var_x93 = var_x81 * pow(var_x92, 4.0); - const double var_x94 = var_x90 / (1.0 + 14641.0 * var_x93); - const double var_x95 = -0.75 * NV_Ith_S(mParameters, 9); - const double var_x96 = exp(var_x48); - const double var_x97 = 0.75 * var_x96; - const double var_x98 = var_x95 + var_x97 * var_chaste_interface__Na_buffer__Na_jct; - const double var_x99 = -1.0 + var_x96; + const double var_x93 = var_x81 * pow(var_x92, 4); + const double var_x94 = var_x90 / (1 + 14641 * var_x93); + const double var_x95 = exp(var_x44); + const double var_x96 = 0.75 * var_x95; + const double var_x97 = -0.75 * NV_Ith_S(mParameters, 8) + var_x96 * NV_Ith_S(mParameters, 5); + const double var_x98 = var_x37 * pow(NV_Ith_S(mParameters, 10), 2); + const double var_x99 = -1 + var_x95; const double var_x100 = 1 / var_x99; - const double var_x101 = pow(1.8, var_x61); + const double var_x101 = pow(1.8, var_x58); const double var_x102 = var_x101 * var_chaste_interface__ICaL_f_gate__f; const double var_x103 = var_x102 * var_chaste_interface__ICaL_d_gate__d; const double var_x104 = var_x100 * var_x103; const double var_x105 = var_x104 * var_x98; - const double var_x106 = 1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct; - const double var_x107 = var_x41 * pow(NV_Ith_S(mParameters, 10), 2); - const double var_x108 = var_x106 * var_x107; - const double var_x109 = 6.0749999999999998e-9 * var_x108; - const double var_x110 = var_x105 * var_x109; - const double var_x111 = var_x104 * var_x107; - const double var_x112 = 1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL; - const double var_x113 = var_x95 + var_x97 * var_chaste_interface__Na_buffer__Na_SL; - const double var_x114 = var_x112 * var_x113; - const double var_x115 = 6.7499999999999994e-10 * var_x114; - const double var_x116 = var_x111 * var_x115; - const double var_x117 = -0.75 * NV_Ith_S(mParameters, 8) + var_x97 * NV_Ith_S(mParameters, 5); - const double var_x118 = var_x111 * var_x117; - const double var_x119 = 1.0 - 0.10000000000000001 * var_chaste_interface__ICaL_fCa_gate__fCaB_SL - 0.90000000000000002 * var_chaste_interface__ICaL_fCa_gate__fCaB_jct; - const double var_x120 = 1.215e-7 * var_x119; - const double var_x121 = var_x69 - var_x71; - const double var_x122 = var_x121 * var_x74; - const double var_x123 = var_x42 * var_x49 * var_x62 / pow(var_x60, 2); - const double var_x124 = var_x122 * var_x123 * var_x76; - const double var_x125 = var_x46 - var_x52; - const double var_x126 = var_x125 * var_x57; - const double var_x127 = var_x123 * var_x126 * var_x59; - const double var_x128 = exp(2.0 * var_x48); - const double var_x129 = -1.0 + var_x128; - const double var_x130 = NV_Ith_S(mParameters, 12) / var_x129; - const double var_x131 = var_x103 * var_x130; - const double var_x132 = var_x112 * var_x131; - const double var_x133 = -0.34100000000000003 * NV_Ith_S(mParameters, 6); - const double var_x134 = 0.34100000000000003 * var_x128; - const double var_x135 = var_x133 + var_x134 * var_chaste_interface__Ca_buffer__Ca_SL; - const double var_x136 = 0.18000000000000002 * var_x135; - const double var_x137 = var_x107 * var_x132 * var_x136; - const double var_x138 = var_x108 * var_x131; - const double var_x139 = var_x133 + var_x134 * var_chaste_interface__Ca_buffer__Ca_jct; - const double var_x140 = 1.6200000000000001 * var_x139; - const double var_x141 = var_x138 * var_x140; - const double var_x142 = var_x106 * var_x98; - const double var_x143 = pow(NV_Ith_S(mParameters, 10), 3) * var_chaste_interface__cell__V / (pow(NV_Ith_S(mParameters, 11), 2) * pow(NV_Ith_S(mParameters, 23), 2)); - const double var_x144 = var_x103 * var_x143; - const double var_x145 = var_x144 * var_x96 / pow(var_x99, 2); - const double var_x146 = 6.0749999999999998e-9 * var_x142 * var_x145; - const double var_x147 = var_x115 * var_x145; - const double var_x148 = var_x117 * var_x120; - const double var_x149 = var_x104 * var_x96; - const double var_x150 = 5.0624999999999998e-10 * var_x112 * var_x96; - const double var_x151 = var_x104 * var_x143 * var_x150 * var_chaste_interface__Na_buffer__Na_SL; - const double var_x152 = 4.5562499999999999e-9 * var_x149; - const double var_x153 = var_x106 * var_x143; - const double var_x154 = var_x152 * var_x153 * var_chaste_interface__Na_buffer__Na_jct; - const double var_x155 = var_x128 * var_x144 * NV_Ith_S(mParameters, 12) / pow(var_x129, 2); - const double var_x156 = 0.36000000000000004 * var_x112 * var_x135 * var_x155; - const double var_x157 = var_x106 * var_x139; - const double var_x158 = 3.2400000000000002 * var_x155 * var_x157; - const double var_x159 = 1.10484 * var_x128 * var_x131 * var_x153 * var_chaste_interface__Ca_buffer__Ca_jct; - const double var_x160 = var_x128 * var_x132; - const double var_x161 = 0.12276000000000002 * var_x143 * var_x160 * var_chaste_interface__Ca_buffer__Ca_SL; - const double var_x162 = -var_x25 * log(var_x82 * NV_Ith_S(mParameters, 9)) + var_chaste_interface__cell__V; - const double var_x163 = 0.11 * var_x162; - const double var_x164 = -var_x25 * log(var_x92 * NV_Ith_S(mParameters, 9)) + var_chaste_interface__cell__V; - const double var_x165 = 0.89000000000000001 * var_x164; - const double var_x166 = NV_Ith_S(mParameters, 14) * var_chaste_interface__INa_h_gate__h; - const double var_x167 = var_x166 * var_x21; - const double var_x168 = var_x166 * pow(var_chaste_interface__INa_m_gate__m, 2) * var_chaste_interface__INa_j_gate__j; - const double var_x169 = var_x162 * var_x168; - const double var_x170 = var_x164 * var_x168; - const double var_x171 = 1 / (0.018329999999999999 * var_chaste_interface__Na_buffer__Nai + NV_Ith_S(mParameters, 5)); - const double var_x172 = -var_x25 * log(var_x171 * (0.018329999999999999 * NV_Ith_S(mParameters, 9) + NV_Ith_S(mParameters, 8))) + var_chaste_interface__cell__V; - const double var_x173 = var_x172 * NV_Ith_S(mParameters, 20) * var_chaste_interface__IKs_Xs_gate__Xs; - const double var_x174 = var_x26 - var_chaste_interface__cell__V; - const double var_x175 = NV_Ith_S(mParameters, 21) * var_chaste_interface__Itos_X_gate__X_tos; - const double var_x176 = var_x100 * var_chaste_interface__cell__V; - const double var_x177 = var_x102 * var_x176; - const double var_x178 = var_x109 * var_x98; - const double var_x179 = var_x107 * var_x177; - const double var_x180 = var_x107 * var_chaste_interface__cell__V; - const double var_x181 = var_x136 * var_x180; - const double var_x182 = var_x102 * var_x130; - const double var_x183 = var_x112 * var_x182; - const double var_x184 = var_x108 * var_chaste_interface__cell__V; - const double var_x185 = var_x140 * var_x184; + const double var_x106 = var_x105 * var_x97; + const double var_x107 = 1 - 0.10000000000000001 * var_chaste_interface__ICaL_fCa_gate__fCaB_SL - 0.90000000000000002 * var_chaste_interface__ICaL_fCa_gate__fCaB_jct; + const double var_x108 = 1.215e-7 * var_x107; + const double var_x109 = var_x67 - var_x69; + const double var_x110 = var_x109 * var_x72; + const double var_x111 = var_x38 * var_x45 * var_x60 / pow(var_x56, 2); + const double var_x112 = var_x110 * var_x111 * var_x74; + const double var_x113 = var_x42 - var_x48; + const double var_x114 = var_x113 * var_x53; + const double var_x115 = var_x111 * var_x114 * var_x55; + const double var_x116 = 1 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL; + const double var_x117 = exp(2 * var_x44); + const double var_x118 = -1 + var_x117; + const double var_x119 = NV_Ith_S(mParameters, 12) / var_x118; + const double var_x120 = var_x103 * var_x119; + const double var_x121 = var_x116 * var_x120; + const double var_x122 = -0.34100000000000003 * NV_Ith_S(mParameters, 6); + const double var_x123 = 0.34100000000000003 * var_x117; + const double var_x124 = var_x122 + var_x123 * var_chaste_interface__Ca_buffer__Ca_SL; + const double var_x125 = 0.18000000000000002 * var_x124; + const double var_x126 = var_x121 * var_x125 * var_x98; + const double var_x127 = 1 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct; + const double var_x128 = var_x127 * var_x98; + const double var_x129 = var_x120 * var_x128; + const double var_x130 = var_x122 + var_x123 * var_chaste_interface__Ca_buffer__Ca_jct; + const double var_x131 = 1.6200000000000001 * var_x130; + const double var_x132 = var_x129 * var_x131; + const double var_x133 = var_x104 * var_x95; + const double var_x134 = pow(NV_Ith_S(mParameters, 10), 3); + const double var_x135 = pow(NV_Ith_S(mParameters, 11), (-2)); + const double var_x136 = pow(NV_Ith_S(mParameters, 23), (-2)); + const double var_x137 = var_x134 * var_x135 * var_x136 * var_chaste_interface__cell__V; + const double var_x138 = pow(var_x99, (-2)); + const double var_x139 = var_x127 * var_x137; + const double var_x140 = 1.10484 * var_x117 * var_x120 * var_x139 * var_chaste_interface__Ca_buffer__Ca_jct; + const double var_x141 = var_x117 * var_x121; + const double var_x142 = 0.12276000000000002 * var_x137 * var_x141 * var_chaste_interface__Ca_buffer__Ca_SL; + const double var_x143 = var_x103 * var_x137; + const double var_x144 = var_x117 * var_x143 * NV_Ith_S(mParameters, 12) / pow(var_x118, 2); + const double var_x145 = 0.36000000000000004 * var_x116 * var_x124 * var_x144; + const double var_x146 = var_x127 * var_x130; + const double var_x147 = 3.2400000000000002 * var_x144 * var_x146; + const double var_x148 = -0.75 * NV_Ith_S(mParameters, 9); + const double var_x149 = var_x148 + var_x96 * var_chaste_interface__Na_buffer__Na_SL; + const double var_x150 = var_x116 * var_x149; + const double var_x151 = 6.7499999999999994e-10 * var_x150; + const double var_x152 = 5.0624999999999998e-10 * var_x116 * var_x95; + const double var_x153 = var_x138 * var_x143 * var_x95; + const double var_x154 = var_x105 * var_x151 - var_x151 * var_x153 + var_x104 * var_x137 * var_x152 * var_chaste_interface__Na_buffer__Na_SL; + const double var_x155 = var_x148 + var_x96 * var_chaste_interface__Na_buffer__Na_jct; + const double var_x156 = var_x104 * var_x155; + const double var_x157 = 6.0749999999999998e-9 * var_x128; + const double var_x158 = 4.5562499999999999e-9 * var_x133; + const double var_x159 = var_x127 * var_x155; + const double var_x160 = var_x156 * var_x157 - 6.0749999999999998e-9 * var_x153 * var_x159 + var_x139 * var_x158 * var_chaste_interface__Na_buffer__Na_jct; + const double var_x161 = -var_x24 * log(var_x82 * NV_Ith_S(mParameters, 9)) + var_chaste_interface__cell__V; + const double var_x162 = 0.11 * var_x161; + const double var_x163 = -var_x24 * log(var_x92 * NV_Ith_S(mParameters, 9)) + var_chaste_interface__cell__V; + const double var_x164 = 0.89000000000000001 * var_x163; + const double var_x165 = NV_Ith_S(mParameters, 14) * var_chaste_interface__INa_h_gate__h; + const double var_x166 = var_x165 * var_x19; + const double var_x167 = var_x165 * pow(var_chaste_interface__INa_m_gate__m, 2) * var_chaste_interface__INa_j_gate__j; + const double var_x168 = var_x161 * var_x167; + const double var_x169 = var_x163 * var_x167; + const double var_x170 = 1 / (0.018329999999999999 * var_chaste_interface__Na_buffer__Nai + NV_Ith_S(mParameters, 5)); + const double var_x171 = -var_x24 * log(var_x170 * (0.018329999999999999 * NV_Ith_S(mParameters, 9) + NV_Ith_S(mParameters, 8))) + var_chaste_interface__cell__V; + const double var_x172 = var_x171 * NV_Ith_S(mParameters, 20) * var_chaste_interface__IKs_Xs_gate__Xs; + const double var_x173 = -var_x79; + const double var_x174 = NV_Ith_S(mParameters, 21) * var_chaste_interface__Itos_X_gate__X_tos; + const double var_x175 = var_x100 * var_chaste_interface__cell__V; + const double var_x176 = var_x102 * var_x175; + const double var_x177 = var_x155 * var_x157; + const double var_x178 = var_x176 * var_x98; + const double var_x179 = var_x108 * var_x97; + const double var_x180 = var_x98 * var_chaste_interface__cell__V; + const double var_x181 = var_x125 * var_x180; + const double var_x182 = var_x102 * var_x119; + const double var_x183 = var_x116 * var_x182; + const double var_x184 = var_x128 * var_chaste_interface__cell__V; + const double var_x185 = var_x131 * var_x184; const double var_x186 = var_x101 * var_chaste_interface__ICaL_d_gate__d; - const double var_x187 = var_x176 * var_x186; - const double var_x188 = var_x107 * var_x187; - const double var_x189 = var_x130 * var_x186; - const double var_x190 = var_x112 * var_x189; - const double var_x191 = var_x111 * var_chaste_interface__cell__V; - const double var_x192 = var_x118 * var_chaste_interface__cell__V; - const double var_x193 = var_x25 * var_x92; - const double var_x194 = 0.00026433000000000001 * var_x193; - const double var_x195 = pow(var_chaste_interface__Na_buffer__Na_SL, 2.0); - const double var_x196 = 3.0 * NV_Ith_S(mParameters, 6); - const double var_x197 = 5.8017639429904805e-6 * var_x50; - const double var_x198 = -3.9000000000000004 * var_x195 - var_x195 * var_x196 - var_x195 * var_x197; - const double var_x199 = 5.3588338192419823e-9 * var_x50; - const double var_x200 = var_x121 * var_x77 / pow((var_x72 + 1.9405247813411081e-6 * var_x67 + 1.4927113702623908e-6 * var_x68 + 1.4927113702623908e-6 * var_x70 + var_x199 * var_x73), 2); - const double var_x201 = 1.9830866390704556e-12 * var_x200; - const double var_x202 = 0.89000000000000001 * var_x23; - const double var_x203 = var_x193 * var_x202; - const double var_x204 = var_x43 * NV_Ith_S(mParameters, 6); - const double var_x205 = var_x195 * var_x204 * var_x78; - const double var_x206 = var_x89 / var_x88; - const double var_x207 = var_x206 * var_x92 * var_x93 / pow((6.8301345536507063e-5 + var_x93), 2); - const double var_x208 = var_x150 * var_x191; - const double var_x209 = var_x25 * var_x82; - const double var_x210 = 3.2670000000000004e-5 * var_x209; - const double var_x211 = pow(var_chaste_interface__Na_buffer__Na_jct, 2.0); - const double var_x212 = -3.9000000000000004 * var_x211 - var_x196 * var_x211 - var_x197 * var_x211; - const double var_x213 = var_x125 * var_x64 / pow((var_x54 + 1.9405247813411081e-6 * var_x44 + 1.4927113702623908e-6 * var_x45 + 1.4927113702623908e-6 * var_x51 + var_x199 * var_x55), 2); - const double var_x214 = 2.4510059584016866e-13 * var_x213; - const double var_x215 = 0.11 * var_x23; - const double var_x216 = var_x209 * var_x215; - const double var_x217 = var_x204 * var_x211 * var_x65; - const double var_x218 = var_x206 * var_x82 * var_x83 / pow((6.8301345536507063e-5 + var_x83), 2); - const double var_x219 = var_x152 * var_x184; - const double var_x220 = var_x171 * var_x25; - const double var_x221 = var_x25 * log(NV_Ith_S(mParameters, 7) / NV_Ith_S(mParameters, 4)) + var_chaste_interface__cell__V; - const double var_x222 = pow(2.3500000000000001, var_x61); + const double var_x187 = var_x175 * var_x186; + const double var_x188 = var_x187 * var_x98; + const double var_x189 = var_x119 * var_x186; + const double var_x190 = var_x116 * var_x189; + const double var_x191 = var_x105 * var_chaste_interface__cell__V; + const double var_x192 = var_x106 * var_chaste_interface__cell__V; + const double var_x193 = pow(var_chaste_interface__Na_buffer__Na_SL, 2); + const double var_x194 = 3 * NV_Ith_S(mParameters, 6); + const double var_x195 = 5.8017639429904805e-6 * var_x46; + const double var_x196 = -3.9000000000000004 * var_x193 - var_x193 * var_x194 - var_x193 * var_x195; + const double var_x197 = 5.3588338192419823e-9 * var_x46; + const double var_x198 = var_x109 * var_x75 / pow((var_x70 + 1.9405247813411081e-6 * var_x65 + 1.4927113702623908e-6 * var_x66 + 1.4927113702623908e-6 * var_x68 + var_x197 * var_x71), 2); + const double var_x199 = 1.9830866390704556e-12 * var_x198; + const double var_x200 = var_x39 * NV_Ith_S(mParameters, 6); + const double var_x201 = var_x193 * var_x200 * var_x76; + const double var_x202 = var_x89 / var_x88; + const double var_x203 = var_x202 * var_x92 * var_x93 / pow((6.8301345536507063e-5 + var_x93), 2); + const double var_x204 = var_x24 * var_x92; + const double var_x205 = 0.89000000000000001 * var_x21; + const double var_x206 = 0.00026433000000000001 * var_x204 + var_x152 * var_x191 + var_x204 * var_x205; + const double var_x207 = pow(var_chaste_interface__Na_buffer__Na_jct, 2); + const double var_x208 = -3.9000000000000004 * var_x207 - var_x194 * var_x207 - var_x195 * var_x207; + const double var_x209 = var_x113 * var_x62 / pow((var_x50 + 1.9405247813411081e-6 * var_x40 + 1.4927113702623908e-6 * var_x41 + 1.4927113702623908e-6 * var_x47 + var_x197 * var_x51), 2); + const double var_x210 = 2.4510059584016866e-13 * var_x209; + const double var_x211 = var_x200 * var_x207 * var_x63; + const double var_x212 = var_x202 * var_x82 * var_x83 / pow((6.8301345536507063e-5 + var_x83), 2); + const double var_x213 = var_x24 * var_x82; + const double var_x214 = 0.11 * var_x21; + const double var_x215 = 3.2670000000000004e-5 * var_x213 + var_x158 * var_x184 + var_x213 * var_x214; + const double var_x216 = var_x170 * var_x24; + const double var_x217 = var_x24 * log(NV_Ith_S(mParameters, 7) / NV_Ith_S(mParameters, 4)) + var_chaste_interface__cell__V; + const double var_x218 = var_x171 * var_x9 / log(10); + const double var_x219 = var_x110 * var_x61 / (pow(var_x73, 2) * pow(var_chaste_interface__Ca_buffer__Ca_SL, 4)); + const double var_x220 = 669921.875 + var_x46; + const double var_x221 = -var_x220 - 373215529.24791086 * var_chaste_interface__Ca_buffer__Ca_SL; + const double var_x222 = pow(2.3500000000000001, var_x58); const double var_x223 = pow(var_x2, 1.6000000000000001); - const double var_x224 = 5.0104537825247566e-7 * var_x2 * var_x222 * var_x223 / pow((1.0 + 5.2281977629563632e-6 * var_x223), 2); - const double var_x225 = 0.00011182849999999999 * var_x2 * var_x25; - const double var_x226 = var_x49 * var_x50; - const double var_x227 = var_x226 * var_x78; - const double var_x228 = var_x10 * var_x172 / log(10); - const double var_x229 = var_x122 * var_x63 / (pow(var_x75, 2) * pow(var_chaste_interface__Ca_buffer__Ca_SL, 4)); - const double var_x230 = -669921.875 - var_x50; - const double var_x231 = var_x230 - 373215529.24791086 * var_chaste_interface__Ca_buffer__Ca_SL; - const double var_x232 = 0.061380000000000011 * var_x160 * var_x180; - const double var_x233 = pow(var_chaste_interface__Ca_buffer__Ca_jct, 2); - const double var_x234 = 1.38215e-5 * var_x0 * var_x25; - const double var_x235 = pow(var_x0, 1.6000000000000001); - const double var_x236 = 6.1926956862665531e-8 * var_x0 * var_x222 * var_x235 / pow((1.0 + 5.2281977629563632e-6 * var_x235), 2); - const double var_x237 = var_x226 * var_x65; - const double var_x238 = var_x230 - 373215529.24791086 * var_chaste_interface__Ca_buffer__Ca_jct; - const double var_x239 = var_x126 * var_x63 / (pow(var_x58, 2) * pow(var_chaste_interface__Ca_buffer__Ca_jct, 4)); - const double var_x240 = 0.55242000000000002 * var_x128 * var_x138 * var_chaste_interface__cell__V; - const double var_x241 = 34.0 * var_chaste_interface__cytosolic_Ca_buffer__Ca_Calmodulin; - const double var_x242 = 100.0 * var_chaste_interface__cytosolic_Ca_buffer__Ca_SRB; - const double var_x243 = 32.700000000000003 * var_chaste_interface__cytosolic_Ca_buffer__Ca_TroponinC; - const double var_x244 = 2.3700000000000001 * var_chaste_interface__cytosolic_Ca_buffer__Ca_TroponinC_Ca_Mg; - const double var_x245 = 2.3700000000000001 * var_chaste_interface__cytosolic_Ca_buffer__Mg_TroponinC_Ca_Mg; - const double var_x246 = 13.800000000000001 * var_chaste_interface__cytosolic_Ca_buffer__Ca_Myosin; - const double var_x247 = 13.800000000000001 * var_chaste_interface__cytosolic_Ca_buffer__Mg_Myosin; - const double var_x248 = pow(var_chaste_interface__Ca_buffer__Cai, 0.78699999999999992); - const double var_x249 = pow(var_chaste_interface__Ca_buffer__Ca_SR, 1.7869999999999999); - const double var_x250 = 0.38742512113256738 * var_x249; - const double var_x251 = pow(var_chaste_interface__Ca_buffer__Cai, 1.7869999999999999); - const double var_x252 = 2814485.1633595936 * var_x251; - const double var_x253 = pow(2.6000000000000001, var_x61) * NV_Ith_S(mParameters, 2); - const double var_x254 = var_x253 / (1.0 + var_x250 + var_x252); - const double var_x255 = var_x248 * var_x254; - const double var_x256 = var_x253 * (var_x252 - var_x250) / pow((3.5530476870814998e-7 + var_x251 + 1.3765399305573384e-7 * var_x249), 2); - const double var_x257 = var_x248 * var_x256; - const double var_x258 = pow(var_chaste_interface__Ca_buffer__Ca_SR, 0.78699999999999992); - const double var_x259 = var_x254 * var_x258; - const double var_x260 = var_x256 * var_x258; - const double var_x261 = 32.700000000000003 * var_chaste_interface__Ca_buffer__Cai; - const double var_x262 = 2.3700000000000001 * var_chaste_interface__Ca_buffer__Cai; - const double var_x263 = 34.0 * var_chaste_interface__Ca_buffer__Cai; - const double var_x264 = 13.800000000000001 * var_chaste_interface__Ca_buffer__Cai; - const double var_x265 = 100.0 * var_chaste_interface__Ca_buffer__Cai; - const double var_x266 = exp(-11.764705882352942 + 0.14705882352941177 * NV_Ith_S(mParameters, 16) - 0.14705882352941177 * var_chaste_interface__cell__V); - const double var_x267 = var_chaste_interface__cell__V < -40.0; - const double var_x268 = ((var_x267) ? (0.13500000000000001 * var_x266) : (0)); - const double var_x269 = var_x268; - const double var_x270 = exp(var_x40 - 0.34999999999999998 * NV_Ith_S(mParameters, 16)); - const double var_x271 = exp(0.079000000000000001 * var_chaste_interface__cell__V - 0.079000000000000001 * NV_Ith_S(mParameters, 16)); - const double var_x272 = exp(-0.96036036036036043 + 0.0900900900900901 * NV_Ith_S(mParameters, 16) - 0.0900900900900901 * var_chaste_interface__cell__V); - const double var_x273 = 1.0 + var_x272; - const double var_x274 = ((var_x267) ? (310000.0 * var_x270 + 3.5600000000000001 * var_x271) : (7.6923076923076916 / var_x273)); - const double var_x275 = var_x274; - const double var_x276 = ((var_x267) ? (-0.019852941176470591 * var_x266) : (0)); - const double var_x277 = var_x268 + var_x274; - const double var_x278 = 0.01 * NV_Ith_S(mParameters, 15); - const double var_x279 = 1.0 - var_x278; - const double var_x280 = var_x279 / var_x277; - const double var_x281 = ((var_x267) ? (0.28123999999999999 * var_x271 + 108500.0 * var_x270) : (0.693000693000693 * var_x272 / pow(var_x273, 2))); - const double var_x282 = exp(-5.5312920000000005 + 0.13780000000000001 * NV_Ith_S(mParameters, 16) - 0.13780000000000001 * var_chaste_interface__cell__V); - const double var_x283 = 1.0 + var_x282; - const double var_x284 = exp(0.01052 * NV_Ith_S(mParameters, 16) - 0.01052 * var_chaste_interface__cell__V); - const double var_x285 = var_x284 / var_x283; - const double var_x286 = -var_x84; - const double var_x287 = exp(-3.2000000000000002 + var_x286 + 0.10000000000000001 * NV_Ith_S(mParameters, 16)); - const double var_x288 = 1.0 + var_x287; - const double var_x289 = exp(2.5349999999999999e-7 * NV_Ith_S(mParameters, 16) - 2.5349999999999999e-7 * var_chaste_interface__cell__V); - const double var_x290 = var_x289 / var_x288; - const double var_x291 = ((var_x267) ? (0.1212 * var_x285) : (0.29999999999999999 * var_x290)); - const double var_x292 = var_x291; - const double var_x293 = 37.780000000000001 + var_chaste_interface__cell__V; - const double var_x294 = exp(0.24440000000000001 * var_chaste_interface__cell__V - 0.24440000000000001 * NV_Ith_S(mParameters, 16)); - const double var_x295 = exp(0.043909999999999998 * NV_Ith_S(mParameters, 16) - 0.043909999999999998 * var_chaste_interface__cell__V); - const double var_x296 = -127140.0 * var_x294 - 3.4740000000000003e-5 * var_x295; - const double var_x297 = exp(24.640530000000002 + 0.311 * var_chaste_interface__cell__V - 0.311 * NV_Ith_S(mParameters, 16)); - const double var_x298 = 1.0 + var_x297; - const double var_x299 = 1 / var_x298; - const double var_x300 = var_x296 * var_x299; - const double var_x301 = ((var_x267) ? (var_x293 * var_x300) : (0)); - const double var_x302 = var_x301; - const double var_x303 = ((var_x267) ? (var_x300 + var_x293 * var_x299 * (1.5254334000000001e-6 * var_x295 - 31073.016 * var_x294) - 0.311 * var_x293 * var_x296 * var_x297 / pow(var_x298, 2)) : (0)); - const double var_x304 = var_x291 + var_x301; - const double var_x305 = var_x279 / var_x304; - const double var_x306 = ((var_x267) ? (-0.001275024 * var_x285 + 0.016701360000000002 * var_x282 * var_x284 / pow(var_x283, 2)) : (-7.6049999999999996e-8 * var_x290 + 0.029999999999999999 * var_x287 * var_x289 / pow(var_x288, 2))); - const double var_x307 = exp(-0.090909090909090912 * var_chaste_interface__cell__V); - const double var_x308 = 0.080000000000000002 * var_x307; - const double var_x309 = 47.130000000000003 + var_chaste_interface__cell__V; - const double var_x310 = exp(-4.7130000000000001 + var_x286); - const double var_x311 = 1.0 - var_x310; - const double var_x312 = 1 / var_x311; - const double var_x313 = 0.32000000000000001 * var_x312; - const double var_x314 = var_x309 * var_x313; - const double var_x315 = var_x308 + var_x314; + const double var_x224 = 0.00011182849999999999 * var_x2 * var_x24 + 0.061380000000000011 * var_x141 * var_x180 + 5.0104537825247566e-7 * var_x2 * var_x222 * var_x223 / pow((1 + 5.2281977629563632e-6 * var_x223), 2); + const double var_x225 = pow(var_chaste_interface__Ca_buffer__Ca_jct, 2); + const double var_x226 = -var_x220 - 373215529.24791086 * var_chaste_interface__Ca_buffer__Ca_jct; + const double var_x227 = var_x114 * var_x61 / (pow(var_x54, 2) * pow(var_chaste_interface__Ca_buffer__Ca_jct, 4)); + const double var_x228 = pow(var_x0, 1.6000000000000001); + const double var_x229 = 1.38215e-5 * var_x0 * var_x24 + 0.55242000000000002 * var_x117 * var_x129 * var_chaste_interface__cell__V + 6.1926956862665531e-8 * var_x0 * var_x222 * var_x228 / pow((1 + 5.2281977629563632e-6 * var_x228), 2); + const double var_x230 = 32.700000000000003 * var_chaste_interface__cytosolic_Ca_buffer__Ca_TroponinC; + const double var_x231 = 34 * var_chaste_interface__cytosolic_Ca_buffer__Ca_Calmodulin; + const double var_x232 = 100 * var_chaste_interface__cytosolic_Ca_buffer__Ca_SRB; + const double var_x233 = pow(var_chaste_interface__Ca_buffer__Cai, 0.78699999999999992); + const double var_x234 = pow(var_chaste_interface__Ca_buffer__Ca_SR, 1.7869999999999999); + const double var_x235 = 0.38742512113256738 * var_x234; + const double var_x236 = pow(var_chaste_interface__Ca_buffer__Cai, 1.7869999999999999); + const double var_x237 = 1 / (1 + var_x235 + 2814485.1633595936 * var_x236); + const double var_x238 = pow(2.6000000000000001, var_x58); + const double var_x239 = var_x238 * NV_Ith_S(mParameters, 2); + const double var_x240 = var_x237 * var_x239; + const double var_x241 = var_x239 * (-var_x235 + 2814485.1633595936 * var_x236) / pow((3.5530476870814998e-7 + var_x236 + 1.3765399305573384e-7 * var_x234), 2); + const double var_x242 = var_x233 * var_x241; + const double var_x243 = 2.3700000000000001 * var_chaste_interface__cytosolic_Ca_buffer__Ca_TroponinC_Ca_Mg + 2.3700000000000001 * var_chaste_interface__cytosolic_Ca_buffer__Mg_TroponinC_Ca_Mg; + const double var_x244 = 13.800000000000001 * var_chaste_interface__cytosolic_Ca_buffer__Ca_Myosin + 13.800000000000001 * var_chaste_interface__cytosolic_Ca_buffer__Mg_Myosin; + const double var_x245 = pow(var_chaste_interface__Ca_buffer__Ca_SR, 0.78699999999999992); + const double var_x246 = var_x240 * var_x245; + const double var_x247 = var_x241 * var_x245; + const double var_x248 = 0.019599999999999999 + 32.700000000000003 * var_chaste_interface__Ca_buffer__Cai; + const double var_x249 = 2.3700000000000001 * var_chaste_interface__Ca_buffer__Cai; + const double var_x250 = 0.23799999999999999 + 34 * var_chaste_interface__Ca_buffer__Cai; + const double var_x251 = 13.800000000000001 * var_chaste_interface__Ca_buffer__Cai; + const double var_x252 = 0.059999999999999998 + 100 * var_chaste_interface__Ca_buffer__Cai; + const double var_x253 = exp(0.14705882352941177 * NV_Ith_S(mParameters, 16) - 0.14705882352941177 * var_chaste_interface__cell__V); + const double var_x254 = var_chaste_interface__cell__V < -40; + const double var_x255 = ((var_x254) ? (1.0495108254269646e-6 * var_x253) : (0)); + const double var_x256 = exp(0.34999999999999998 * var_chaste_interface__cell__V - 0.34999999999999998 * NV_Ith_S(mParameters, 16)); + const double var_x257 = exp(0.079000000000000001 * var_chaste_interface__cell__V - 0.079000000000000001 * NV_Ith_S(mParameters, 16)); + const double var_x258 = exp(0.0900900900900901 * NV_Ith_S(mParameters, 16) - 0.0900900900900901 * var_chaste_interface__cell__V); + const double var_x259 = 1 + 0.38275493141491301 * var_x258; + const double var_x260 = ((var_x254) ? (310000 * var_x256 + 3.5600000000000001 * var_x257) : (7.6923076923076916 / var_x259)); + const double var_x261 = var_x255 + var_x260; + const double var_x262 = ((var_x254) ? (-1.5433982726867125e-7 * var_x253) : (0)); + const double var_x263 = var_x255 + var_x260; + const double var_x264 = 0.01 * NV_Ith_S(mParameters, 15); + const double var_x265 = 1 - var_x264; + const double var_x266 = var_x265 / var_x263; + const double var_x267 = ((var_x254) ? (0.28123999999999999 * var_x257 + 108500 * var_x256) : (0.26524943271996743 * var_x258 / pow(var_x259, 2))); + const double var_x268 = exp(0.13780000000000001 * NV_Ith_S(mParameters, 16) - 0.13780000000000001 * var_chaste_interface__cell__V); + const double var_x269 = 1 + 0.0039608683399042569 * var_x268; + const double var_x270 = exp(0.01052 * NV_Ith_S(mParameters, 16) - 0.01052 * var_chaste_interface__cell__V); + const double var_x271 = var_x270 / var_x269; + const double var_x272 = exp(-var_x84 + 0.10000000000000001 * NV_Ith_S(mParameters, 16)); + const double var_x273 = 1 + 0.040762203978366211 * var_x272; + const double var_x274 = exp(2.5349999999999999e-7 * NV_Ith_S(mParameters, 16) - 2.5349999999999999e-7 * var_chaste_interface__cell__V); + const double var_x275 = var_x274 / var_x273; + const double var_x276 = ((var_x254) ? (0.1212 * var_x271) : (0.29999999999999999 * var_x275)); + const double var_x277 = 37.780000000000001 + var_chaste_interface__cell__V; + const double var_x278 = exp(0.24440000000000001 * var_chaste_interface__cell__V - 0.24440000000000001 * NV_Ith_S(mParameters, 16)); + const double var_x279 = exp(0.043909999999999998 * NV_Ith_S(mParameters, 16) - 0.043909999999999998 * var_chaste_interface__cell__V); + const double var_x280 = -127140 * var_x278 - 3.4740000000000003e-5 * var_x279; + const double var_x281 = exp(0.311 * var_chaste_interface__cell__V - 0.311 * NV_Ith_S(mParameters, 16)); + const double var_x282 = 1 / (1 + 50262745825.953949 * var_x281); + const double var_x283 = var_x280 * var_x282; + const double var_x284 = ((var_x254) ? (var_x277 * var_x283) : (0)); + const double var_x285 = var_x276 + var_x284; + const double var_x286 = ((var_x254) ? (var_x283 + var_x277 * var_x282 * (1.5254334000000001e-6 * var_x279 - 31073.016 * var_x278) - 6.1874852813833003e-12 * var_x277 * var_x280 * var_x281 / pow((1.989545106554116e-11 + var_x281), 2)) : (0)); + const double var_x287 = var_x276 + var_x284; + const double var_x288 = var_x265 / var_x287; + const double var_x289 = ((var_x254) ? (-0.001275024 * var_x271 + 6.6151888057343371e-5 * var_x268 * var_x270 / pow(var_x269, 2)) : (-7.6049999999999996e-8 * var_x275 + 0.0012228661193509863 * var_x272 * var_x274 / pow(var_x273, 2))); + const double var_x290 = exp(-4.7130000000000001 - var_x84); + const double var_x291 = 1 - var_x290; + const double var_x292 = 1 / var_x291; + const double var_x293 = exp(-0.090909090909090912 * var_chaste_interface__cell__V); + const double var_x294 = 47.130000000000003 + var_chaste_interface__cell__V; + const double var_x295 = 0.32000000000000001 * var_x292; + const double var_x296 = 0.080000000000000002 * var_x293 + var_x294 * var_x295; + const double var_x297 = 1 / var_x296; + const double var_x298 = 0.032000000000000001 * var_x290 * var_x294 / pow(var_x291, 2); + const double var_x299 = var_x298 + 0.0072727272727272727 * var_x293 - 0.32000000000000001 * var_x292; + const double var_x300 = var_x292 * var_x294; + const double var_x301 = exp(-6.666666666666667 - 0.13333333333333333 * var_chaste_interface__cell__V); + const double var_x302 = 1 + var_x301; + const double var_x303 = exp(1.45 + 0.14499999999999999 * var_chaste_interface__cell__V); + const double var_x304 = -1 + var_x303; + const double var_x305 = 1 / var_x304; + const double var_x306 = exp(-0.86099999999999999 - 0.123 * var_chaste_interface__cell__V); + const double var_x307 = 1 - var_x306; + const double var_x308 = 1 / var_x307; + const double var_x309 = 7 + var_chaste_interface__cell__V; + const double var_x310 = 10 + var_chaste_interface__cell__V; + const double var_x311 = 0.00060999999999999997 * var_x305 * var_x310 + 0.0013799999999999999 * var_x308 * var_x309; + const double var_x312 = exp(0.089820359281437126 - 0.059880239520958084 * var_chaste_interface__cell__V); + const double var_x313 = 1 + var_x312; + const double var_x314 = exp(2.0609999999999999 + 0.068699999999999997 * var_chaste_interface__cell__V); + const double var_x315 = -1 + var_x314; const double var_x316 = 1 / var_x315; - const double var_x317 = 0.0072727272727272727 * var_x307; - const double var_x318 = 0.032000000000000001 * var_x309 * var_x310 / pow(var_x311, 2); - const double var_x319 = var_x309 * var_x312; - const double var_x320 = exp(-6.666666666666667 - 0.13333333333333333 * var_chaste_interface__cell__V); - const double var_x321 = 1.0 + var_x320; - const double var_x322 = exp(1.45 + 0.14499999999999999 * var_chaste_interface__cell__V); - const double var_x323 = -1.0 + var_x322; - const double var_x324 = 0.00060999999999999997 / var_x323; - const double var_x325 = exp(-0.86099999999999999 - 0.123 * var_chaste_interface__cell__V); - const double var_x326 = 1.0 - var_x325; - const double var_x327 = 0.0013799999999999999 / var_x326; - const double var_x328 = 7.0 + var_chaste_interface__cell__V; - const double var_x329 = 10.0 + var_chaste_interface__cell__V; - const double var_x330 = var_x324 * var_x329; - const double var_x331 = var_x327 * var_x328; - const double var_x332 = exp(0.089820359281437126 - 0.059880239520958084 * var_chaste_interface__cell__V); - const double var_x333 = 1.0 + var_x332; - const double var_x334 = exp(2.0609999999999999 + 0.068699999999999997 * var_chaste_interface__cell__V); - const double var_x335 = -1.0 + var_x334; - const double var_x336 = 0.00013100000000000001 / var_x335; - const double var_x337 = exp(-4.4399999999999995 - 0.14799999999999999 * var_chaste_interface__cell__V); - const double var_x338 = 1.0 - var_x337; - const double var_x339 = 7.1899999999999999e-5 / var_x338; - const double var_x340 = 30.0 + var_chaste_interface__cell__V; - const double var_x341 = var_x336 * var_x340; - const double var_x342 = var_x339 * var_x340; - const double var_x343 = 0.066666666666666666 * var_chaste_interface__cell__V; - const double var_x344 = exp(0.20000000000000001 + var_x343); - const double var_x345 = 1.0 + var_x344; - const double var_x346 = 1 / var_x345; - const double var_x347 = 1 / (0.5 + 9.0 * var_x346); - const double var_x348 = exp(-0.20000000000000001 - var_x343); - const double var_x349 = 1.0 + var_x348; - const double var_x350 = 0.066666666666666666 * var_x348 / pow(var_x349, 2); - const double var_x351 = 1 / var_x349; - const double var_x352 = 0.10000000000000001 * var_chaste_interface__cell__V; - const double var_x353 = exp(6.0 + var_x352); - const double var_x354 = 1.0 + var_x353; - const double var_x355 = 1 / var_x354; - const double var_x356 = 1 / (30.0 + 3000.0 * var_x355); - const double var_x357 = exp(3.3500000000000001 + var_x352); - const double var_x358 = 1.0 + var_x357; - const double var_x359 = var_x357 / pow(var_x358, 2); - const double var_x360 = 0.10000000000000001 * var_x359; - const double var_x361 = 1 / var_x358; - const double var_x362 = var_x361; - const double var_x363 = var_x353 / pow(var_x354, 2); - const double var_x364 = 1 / (220.0 + 2800.0 * var_x355); - const double var_x365 = exp(-0.0011111111111111111 * pow(var_chaste_interface__cell__V, 2)); - const double var_x366 = 1 / (1.5 + 3.5 * var_x365); - const double var_x367 = 1 / (20.0 + 20.0 * var_x361); - const double var_x368 = exp(-2.4166666666666665 - 0.16666666666666666 * var_chaste_interface__cell__V); - const double var_x369 = 1.0 - var_x368; - const double var_x370 = 1 / var_x369; - const double var_x371 = 1.0 + var_x368; - const double var_x372 = 1 / var_x371; - const double var_x373 = -var_chaste_interface__ICaL_d_gate__d + var_x372; - const double var_x374 = var_x370 * var_x373; - const double var_x375 = 0.035000000000000003 * var_x371; - const double var_x376 = 14.5 + var_chaste_interface__cell__V; - const double var_x377 = var_x370 * var_x376; - const double var_x378 = 0.0058333333333333336 * var_x368; - const double var_x379 = var_x376 * var_x378; - const double var_x380 = 0.019699999999999999 * exp(-0.23877882250000002 * pow((1 + 0.068965517241379309 * var_chaste_interface__cell__V), 2)); - const double var_x381 = exp(2.5 - 0.050000000000000003 * var_chaste_interface__cell__V); - const double var_x382 = 1.0 + var_x381; - const double var_x383 = exp(9.7388888888888889 + 0.27777777777777779 * var_chaste_interface__cell__V); - const double var_x384 = 1.0 + var_x383; - const double var_x385 = 1 / var_chaste_interface__Ca_buffer__Ca_SR; - const double var_x386 = pow(var_x385, 2.5); - const double var_x387 = 1.0 + 0.13584112963311223 * var_x386; - const double var_x388 = 1 / var_x387; - const double var_x389 = 7.0 * var_x388; - const double var_x390 = -7.5 + var_x389; - const double var_x391 = var_x390 * var_chaste_interface__Ca_buffer__Ca_jct; - const double var_x392 = 1 / (15.0 - 14.0 * var_x388); - const double var_x393 = 10.0 * var_x233 * var_x392; - const double var_x394 = -var_x393; - const double var_x395 = var_chaste_interface__Ca_buffer__Ca_jct * var_chaste_interface__Jrel_SR__R; - const double var_x396 = var_x385 * var_x386 / pow(var_x387, 2); - const double var_x397 = 2.3772197685794643 * var_x396; - const double var_x398 = 0.21130842387373014 * var_x233 * var_x396 / pow((1 - 0.93333333333333335 * var_x388), 2); - const double var_x399 = var_x398 * var_chaste_interface__Jrel_SR__R; - const double var_x400 = 20.0 * var_x392; - const double var_x401 = var_x395 * var_x400; - const double var_x402 = 7.5 - var_x389; - const double var_x403 = var_x397 * var_chaste_interface__Ca_buffer__Ca_jct * var_chaste_interface__Jrel_SR__O; - const double var_x404 = 1.0 - var_chaste_interface__Jrel_SR__I - var_chaste_interface__Jrel_SR__O - var_chaste_interface__Jrel_SR__R; - const double var_x405 = M_PI * var_x24; - const double var_x406 = 62.109246076532294 * var_x405; - const double var_x407 = var_x406 * NV_Ith_S(mParameters, 3); - const double var_x408 = var_x405 * NV_Ith_S(mParameters, 3); - const double var_x409 = var_x22 * var_x408; - const double var_x410 = 55.277229008113743 * var_x164; - const double var_x411 = var_x167 * var_x408; - const double var_x412 = var_x100 * var_x102; - const double var_x413 = M_PI * var_x48; - const double var_x414 = var_x413 * NV_Ith_S(mParameters, 3); - const double var_x415 = 4.1923741101659298e-8 * var_x414; - const double var_x416 = var_x114 * var_x415; - const double var_x417 = var_x100 * var_x186; - const double var_x418 = 0.0001 * var_chaste_interface__Na_buffer__Na_SL_buf; - const double var_x419 = 5.9492599172113663e-12 * var_x200; - const double var_x420 = 0.0001 * var_chaste_interface__Na_buffer__Na_SL; - const double var_x421 = 2435.6567088836191 * var_x405; - const double var_x422 = var_x421 * NV_Ith_S(mParameters, 3); - const double var_x423 = 267.92223797719811 * var_x162; - const double var_x424 = 1.4796614506467986e-5 * var_x414; - const double var_x425 = var_x142 * var_x424; - const double var_x426 = 0.0001 * var_chaste_interface__Na_buffer__Na_jct_buf; - const double var_x427 = 7.3530178752050587e-13 * var_x213; - const double var_x428 = 0.0001 * var_chaste_interface__Na_buffer__Na_jct; - const double var_x429 = 0.076376893524206985 * NV_Ith_S(mParameters, 3); - const double var_x430 = 100.0 * var_chaste_interface__Ca_buffer__Ca_Calsequestrin; - const double var_x431 = 18.571428571428569 * NV_Ith_S(mParameters, 0); - const double var_x432 = var_chaste_interface__Jrel_SR__O * NV_Ith_S(mParameters, 1); - const double var_x433 = 100.0 * var_chaste_interface__Ca_buffer__Ca_SR; - const double var_x434 = 31.054623038266147 * var_x405; - const double var_x435 = 5.5898321468879066 * var_x135 * var_x413; - const double var_x436 = 3.9661732781409111e-12 * var_x200; - const double var_x437 = 100.0 * var_chaste_interface__Ca_buffer__Ca_SLB_SL; - const double var_x438 = 100.0 * var_chaste_interface__Ca_buffer__Ca_SLHigh_SL; - const double var_x439 = 100.0 * var_chaste_interface__Ca_buffer__Ca_SL; - const double var_x440 = 1217.8283544418096 * var_x405; - const double var_x441 = 1972.8819341957317 * var_x413; - const double var_x442 = var_x157 * var_x441; - const double var_x443 = 4.9020119168033731e-13 * var_x213; - const double var_x444 = 1274.5098039215686 * NV_Ith_S(mParameters, 0); - const double var_x445 = 68.627450980392155 * var_x432; - const double var_x446 = 100.0 * var_chaste_interface__Ca_buffer__Ca_SLB_jct; - const double var_x447 = 100.0 * var_chaste_interface__Ca_buffer__Ca_SLHigh_jct; - const double var_x448 = 100.0 * var_chaste_interface__Ca_buffer__Ca_jct; - const double var_x449 = -var_x439; - const double var_x450 = -var_x448; - const double var_x451 = -var_x262; - const double var_x452 = -var_x264; - const double var_x453 = 100.0 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_Cytosol; - const double var_x454 = -var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_Cytosol - 0.030769230769230767 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_SL - 0.00078461538461538469 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_jct; - const double var_x455 = 0.078461538461538471 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_jct; - const double var_x456 = 3.0769230769230771 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_SL; - const double var_x457 = var_x453 + var_x455 + var_x456; - const double var_x458 = 100.0 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_SL; - const double var_x459 = 100.0 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_jct; - const double var_x460 = 100.0 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_Cytosol; - const double var_x461 = -var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_Cytosol - 0.030769230769230767 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_SL - 0.00078461538461538469 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct; - const double var_x462 = 0.078461538461538471 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct; - const double var_x463 = 3.0769230769230771 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_SL; - const double var_x464 = var_x460 + var_x462 + var_x463; - const double var_x465 = 100.0 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_SL; - const double var_x466 = 100.0 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct; + const double var_x317 = exp(-4.4399999999999995 - 0.14799999999999999 * var_chaste_interface__cell__V); + const double var_x318 = 1 - var_x317; + const double var_x319 = 1 / var_x318; + const double var_x320 = 30 + var_chaste_interface__cell__V; + const double var_x321 = 0.00013100000000000001 * var_x316 * var_x320 + 7.1899999999999999e-5 * var_x319 * var_x320; + const double var_x322 = 0.20000000000000001 + 0.066666666666666666 * var_chaste_interface__cell__V; + const double var_x323 = exp(var_x322); + const double var_x324 = 1 + var_x323; + const double var_x325 = 1 / var_x324; + const double var_x326 = 1 / (0.5 + 9 * var_x325); + const double var_x327 = exp(-var_x322); + const double var_x328 = 1 + var_x327; + const double var_x329 = 0.066666666666666666 * var_x327 / pow(var_x328, 2); + const double var_x330 = -1 / var_x328; + const double var_x331 = 0.10000000000000001 * var_chaste_interface__cell__V; + const double var_x332 = exp(6 + var_x331); + const double var_x333 = 1 + var_x332; + const double var_x334 = 1 / var_x333; + const double var_x335 = 1 / (30 + 3000 * var_x334); + const double var_x336 = exp(3.3500000000000001 + var_x331); + const double var_x337 = 1 + var_x336; + const double var_x338 = pow(var_x337, (-2)); + const double var_x339 = 0.10000000000000001 * var_x336 * var_x338; + const double var_x340 = pow(var_x333, (-2)); + const double var_x341 = 1 / var_x337; + const double var_x342 = -var_x341; + const double var_x343 = 1 / (220 + 2800 * var_x334); + const double var_x344 = exp(-0.0011111111111111111 * pow(var_chaste_interface__cell__V, 2)); + const double var_x345 = 1 / (1.5 + 3.5 * var_x344); + const double var_x346 = 1 / (20 + 20 * var_x341); + const double var_x347 = exp(-2.4166666666666665 - 0.16666666666666666 * var_chaste_interface__cell__V); + const double var_x348 = 1 - var_x347; + const double var_x349 = 1 / var_x348; + const double var_x350 = 1 + var_x347; + const double var_x351 = 1 / var_x350; + const double var_x352 = -var_chaste_interface__ICaL_d_gate__d + var_x351; + const double var_x353 = 14.5 + var_chaste_interface__cell__V; + const double var_x354 = 0.0058333333333333336 * var_x347 * var_x353; + const double var_x355 = 0.019699999999999999 * exp(-0.23877882250000002 * pow((1 + 0.068965517241379309 * var_chaste_interface__cell__V), 2)); + const double var_x356 = 0.02 + var_x355; + const double var_x357 = exp(9.7388888888888889 + 0.27777777777777779 * var_chaste_interface__cell__V); + const double var_x358 = 1 + var_x357; + const double var_x359 = exp(2.5 - 0.050000000000000003 * var_chaste_interface__cell__V); + const double var_x360 = 1 + var_x359; + const double var_x361 = 1 / var_chaste_interface__Ca_buffer__Ca_SR; + const double var_x362 = pow(var_x361, 2.5); + const double var_x363 = 1 + 0.13584112963311223 * var_x362; + const double var_x364 = 1 / var_x363; + const double var_x365 = 7.5 - 7 * var_x364; + const double var_x366 = -var_x365; + const double var_x367 = 1 / (15 - 14 * var_x364); + const double var_x368 = 10 * var_x225 * var_x367; + const double var_x369 = pow(var_x363, (-2)); + const double var_x370 = var_x361 * var_x362 * var_x369; + const double var_x371 = 0.21130842387373014 * var_x225 * var_x370 / pow((1 - 0.93333333333333335 * var_x364), 2); + const double var_x372 = var_x371 * var_chaste_interface__Jrel_SR__R; + const double var_x373 = 20 * var_x367; + const double var_x374 = var_x373 * var_chaste_interface__Ca_buffer__Ca_jct * var_chaste_interface__Jrel_SR__R; + const double var_x375 = 2.3772197685794643 * var_x370 * var_chaste_interface__Ca_buffer__Ca_jct * var_chaste_interface__Jrel_SR__O; + const double var_x376 = 1 - var_chaste_interface__Jrel_SR__I - var_chaste_interface__Jrel_SR__O - var_chaste_interface__Jrel_SR__R; + const double var_x377 = M_PI * var_x23; + const double var_x378 = 62.109246076532294 * var_x377; + const double var_x379 = var_x378 * NV_Ith_S(mParameters, 3); + const double var_x380 = var_x377 * NV_Ith_S(mParameters, 3); + const double var_x381 = var_x20 * var_x380; + const double var_x382 = 55.277229008113743 * var_x163; + const double var_x383 = var_x166 * var_x380; + const double var_x384 = var_x100 * var_x102; + const double var_x385 = M_PI * var_x44; + const double var_x386 = var_x385 * NV_Ith_S(mParameters, 3); + const double var_x387 = 4.1923741101659298e-8 * var_x386; + const double var_x388 = var_x150 * var_x387; + const double var_x389 = var_x100 * var_x186; + const double var_x390 = 0.0001 * var_chaste_interface__Na_buffer__Na_SL_buf; + const double var_x391 = 5.9492599172113663e-12 * var_x198; + const double var_x392 = 0.001 + 0.0001 * var_chaste_interface__Na_buffer__Na_SL; + const double var_x393 = var_x45 * var_x46; + const double var_x394 = var_x393 * var_x76; + const double var_x395 = 2435.6567088836191 * var_x377; + const double var_x396 = var_x395 * NV_Ith_S(mParameters, 3); + const double var_x397 = 267.92223797719811 * var_x161; + const double var_x398 = 1.4796614506467986e-5 * var_x386; + const double var_x399 = var_x159 * var_x398; + const double var_x400 = 0.0001 * var_chaste_interface__Na_buffer__Na_jct_buf; + const double var_x401 = 7.3530178752050587e-13 * var_x209; + const double var_x402 = 0.001 + 0.0001 * var_chaste_interface__Na_buffer__Na_jct; + const double var_x403 = var_x393 * var_x63; + const double var_x404 = 0.076376893524206985 * NV_Ith_S(mParameters, 3); + const double var_x405 = 100 * var_chaste_interface__Ca_buffer__Ca_Calsequestrin; + const double var_x406 = var_chaste_interface__Jrel_SR__O * NV_Ith_S(mParameters, 1); + const double var_x407 = var_x406 + 18.571428571428569 * NV_Ith_S(mParameters, 0); + const double var_x408 = 65 + 100 * var_chaste_interface__Ca_buffer__Ca_SR; + const double var_x409 = 31.054623038266147 * var_x377; + const double var_x410 = 5.5898321468879066 * var_x124 * var_x385; + const double var_x411 = 3.9661732781409111e-12 * var_x198; + const double var_x412 = 100 * var_chaste_interface__Ca_buffer__Ca_SLB_SL; + const double var_x413 = 100 * var_chaste_interface__Ca_buffer__Ca_SLHigh_SL; + const double var_x414 = 100 * var_chaste_interface__Ca_buffer__Ca_SL; + const double var_x415 = 1.3 + var_x414; + const double var_x416 = 0.029999999999999999 + var_x414; + const double var_x417 = 1217.8283544418096 * var_x377; + const double var_x418 = 1972.8819341957317 * var_x385; + const double var_x419 = var_x146 * var_x418; + const double var_x420 = 4.9020119168033731e-13 * var_x209; + const double var_x421 = 68.627450980392155 * var_x406 + 1274.5098039215686 * NV_Ith_S(mParameters, 0); + const double var_x422 = 100 * var_chaste_interface__Ca_buffer__Ca_SLB_jct; + const double var_x423 = 100 * var_chaste_interface__Ca_buffer__Ca_SLHigh_jct; + const double var_x424 = 100 * var_chaste_interface__Ca_buffer__Ca_jct; + const double var_x425 = 1.3 + var_x424; + const double var_x426 = 0.029999999999999999 + var_x424; + const double var_x427 = 100 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_Cytosol; + const double var_x428 = -2.5 + var_x427; + const double var_x429 = -var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_Cytosol - 0.030769230769230767 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_SL - 0.00078461538461538469 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_jct; + const double var_x430 = 0.078461538461538471 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_jct; + const double var_x431 = 3.0769230769230771 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_SL; + const double var_x432 = var_x427 + var_x430 + var_x431; + const double var_x433 = -2.5024999999999999 + 100 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_SL; + const double var_x434 = -2.5490196078431375 + 100 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_jct; + const double var_x435 = 100 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_Cytosol; + const double var_x436 = -2.5 + var_x435; + const double var_x437 = -var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_Cytosol - 0.030769230769230767 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_SL - 0.00078461538461538469 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct; + const double var_x438 = 0.078461538461538471 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct; + const double var_x439 = 3.0769230769230771 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_SL; + const double var_x440 = var_x435 + var_x438 + var_x439; + const double var_x441 = -2.5024999999999999 + 100 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_SL; + const double var_x442 = -2.5490196078431375 + 100 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct; // Matrix entries - IJth(rJacobian, 0, 0) = mSetVoltageDerivativeToZero ? 0.0 : (-0.00054830000000000005 + var_x146 + var_x147 + var_x156 + var_x158 - var_x110 - var_x116 - var_x137 - var_x141 - var_x151 - var_x154 - var_x159 - var_x161 - NV_Ith_S(mParameters, 13) - 0.11 * var_x11 - 0.11 * var_x66 - 0.89000000000000001 * var_x15 - 0.89000000000000001 * var_x79 - 0.15619500000000003 * var_x124 - 1.0 * var_x23 - 0.01205875 / var_x1 - 0.019305000000000003 * var_x127 - 0.097566250000000007 / var_x3 - 0.21009999999999998 * var_x91 - 1.6999 * var_x94 + var_x145 * var_x148 + var_x5 * var_chaste_interface__Itos_X_gate__X_tos - var_x118 * var_x120 - var_x17 * var_x20 - var_x6 * var_chaste_interface__Itof_X_gate__X_tof - 0.4389381125701739 * var_x29 * var_x37 + 0.10468673984798647 * var_x37 * var_x38 * var_x39 + 0.019211226915711394 * var_x17 * var_x18 * var_x38 / pow(var_x19, 2) - 9.1125000000000004e-8 * var_x119 * var_x143 * var_x149 * NV_Ith_S(mParameters, 5) - 0.42189361069797565 * var_x29 * var_x80 * (0.24326999999999999 * var_x39 - var_x32 * (0.061749999999999999 * var_x33 + 0.039456396800000001 * var_x34) - 0.51429999999999998 * var_x30 * var_x35 / pow(var_x31, 2)) * NV_Ith_S(mParameters, 18) / pow((var_x29 + 0.98039215686274506 * var_x36), 2)); - IJth(rJacobian, 2, 0) = (var_x269 + var_x275) * (var_x276 * var_x280 + var_x268 * var_x279 * (-var_x276 - var_x281) / pow(var_x277, 2)) + (var_x276 + var_x281) * (var_x278 - var_chaste_interface__INa_h_gate__h + var_x268 * var_x280); - IJth(rJacobian, 3, 0) = (var_x292 + var_x302) * (var_x303 * var_x305 + var_x279 * var_x301 * (-var_x303 - var_x306) / pow(var_x304, 2)) + (var_x303 + var_x306) * (var_x278 - var_chaste_interface__INa_j_gate__j + var_x301 * var_x305); - IJth(rJacobian, 4, 0) = var_x315 * (var_x313 * var_x316 - var_x316 * var_x318 + 3.125 * var_x319 * (var_x317 + var_x318 - var_x313) / pow((var_x319 + 0.25 * var_x307), 2)) + (-var_chaste_interface__INa_m_gate__m + var_x314 * var_x316) * (var_x313 - var_x317 - var_x318); - IJth(rJacobian, 5, 0) = (-var_chaste_interface__IKr_Xr_gate__Xr + 1 / var_x321) * (var_x324 + var_x327 - 0.00016973999999999998 * var_x325 * var_x328 / pow(var_x326, 2) - 8.8449999999999995e-5 * var_x322 * var_x329 / pow(var_x323, 2)) + 0.13333333333333333 * var_x320 * (var_x330 + var_x331) / pow(var_x321, 2); - IJth(rJacobian, 6, 0) = (-var_chaste_interface__IKs_Xs_gate__Xs + 1 / var_x333) * (var_x336 + var_x339 - 8.9997000000000013e-6 * var_x334 * var_x340 / pow(var_x335, 2) - 1.0641199999999999e-5 * var_x337 * var_x340 / pow(var_x338, 2)) + 0.059880239520958084 * var_x332 * (var_x341 + var_x342) / pow(var_x333, 2); - IJth(rJacobian, 7, 0) = var_x347 * var_x350 + 0.0074074074074074077 * var_x344 * (var_x351 - var_chaste_interface__Itos_X_gate__X_tos) / (pow(var_x345, 2) * pow((0.055555555555555552 + var_x346), 2)); - IJth(rJacobian, 8, 0) = -var_x356 * var_x360 + 3.3333333333333335e-5 * var_x363 * (var_x362 + var_x4) / pow((0.01 + var_x355), 2); - IJth(rJacobian, 9, 0) = -var_x360 * var_x364 + 3.5714285714285717e-5 * var_x363 * (var_x362 - var_chaste_interface__Itos_R_gate__R_tos) / pow((0.07857142857142857 + var_x355), 2); - IJth(rJacobian, 10, 0) = var_x350 * var_x366 + 0.00063492063492063492 * var_x365 * (var_x351 - var_chaste_interface__Itof_X_gate__X_tof) * var_chaste_interface__cell__V / pow((0.42857142857142855 + var_x365), 2); - IJth(rJacobian, 11, 0) = -var_x360 * var_x367 + 0.0050000000000000001 * var_x359 * (var_x362 - var_chaste_interface__Itof_Y_gate__Y_tof) / pow((1 + var_x361), 2); - IJth(rJacobian, 12, 0) = var_x374 * var_x375 - var_x374 * var_x379 + var_x372 * var_x377 * var_x378 - var_x371 * var_x373 * var_x379 / pow(var_x369, 2); - IJth(rJacobian, 13, 0) = (0.02 + var_x380) * (0.029999999999999999 * var_x381 / pow(var_x382, 2) - 0.27777777777777779 * var_x383 / pow(var_x384, 2)) + var_x380 * (-0.032935010000000001 - 0.0022713799999999999 * var_chaste_interface__cell__V) * (-var_chaste_interface__ICaL_f_gate__f + 1 / var_x384 + 0.59999999999999998 / var_x382); - IJth(rJacobian, 19, 0) = -var_x407 * (0.00026433000000000001 + var_x116 + var_x151 + var_x202 - var_x147 + 2.6699999999999999 * var_x79 + 5.0996999999999995 * var_x94 + 0.46858500000000003 * var_x124); - IJth(rJacobian, 20, 0) = -var_x422 * (3.2670000000000004e-5 + var_x110 + var_x154 + var_x215 - var_x146 + 0.33000000000000002 * var_x66 + 0.63029999999999997 * var_x91 + 0.057915000000000008 * var_x127); - IJth(rJacobian, 25, 0) = -var_x434 * (0.00022365699999999999 + var_x137 + var_x161 - var_x156 - 1.78 * var_x79 - 0.31239000000000006 * var_x124); - IJth(rJacobian, 26, 0) = -var_x440 * (2.7642999999999999e-5 + var_x141 + var_x159 - var_x158 - 0.22 * var_x66 - 0.038610000000000005 * var_x127); - IJth(rJacobian, 1, 1) = -7.2523935948689155 + var_x241 + var_x242 + var_x243 + var_x244 + var_x245 + var_x246 + var_x247 + 6.3492962168146398e-7 * var_x257 - 5029484.9869235931 * var_x255; - IJth(rJacobian, 24, 1) = 93404721.185723871 * var_x255 - 1.1791550116941473e-5 * var_x257; + IJth(rJacobian, 0, 0) = mSetVoltageDerivativeToZero ? 0.0 : (-0.00054830000000000005 + var_x145 + var_x147 - var_x126 - var_x132 - var_x140 - var_x142 - var_x154 - var_x160 - NV_Ith_S(mParameters, 13) - 0.11 * var_x10 - 0.11 * var_x64 - 0.89000000000000001 * var_x14 - 0.89000000000000001 * var_x77 - 0.15619500000000003 * var_x112 - 1 * var_x21 - 0.01205875 / var_x1 - 0.019305000000000003 * var_x115 - 0.097566250000000007 / var_x3 - 0.21009999999999998 * var_x91 - 1.6999 * var_x94 - var_x106 * var_x108 - var_x4 * var_chaste_interface__Itof_X_gate__X_tof + var_x5 * NV_Ith_S(mParameters, 21) * var_chaste_interface__Itos_X_gate__X_tos - var_x15 * var_x18 * NV_Ith_S(mParameters, 19) * var_chaste_interface__IKr_Xr_gate__Xr - 9.1125000000000004e-8 * var_x107 * var_x133 * var_x137 * NV_Ith_S(mParameters, 5) - 0.4389381125701739 * var_x15 * var_x28 * var_x36 * NV_Ith_S(mParameters, 18) - 0.42189361069797565 * var_x28 * var_x80 * (-var_x31 * (0.061749999999999999 * var_x32 + 0.039456396800000001 * var_x33) + 0.24326999999999999 * var_x26 * var_x78 - 0.51429999999999998 * var_x29 * var_x34 / pow(var_x30, 2)) * NV_Ith_S(mParameters, 18) / pow((var_x28 + 0.98039215686274506 * var_x35), 2) + 0.10468673984798647 * var_x15 * var_x26 * var_x36 * var_x78 * var_x79 * NV_Ith_S(mParameters, 18) + 0.019211226915711394 * var_x15 * var_x16 * var_x79 * NV_Ith_S(mParameters, 19) * var_chaste_interface__IKr_Xr_gate__Xr / pow(var_x17, 2) + 1.215e-7 * var_x101 * var_x107 * var_x134 * var_x135 * var_x136 * var_x138 * var_x95 * var_x97 * var_chaste_interface__ICaL_d_gate__d * var_chaste_interface__ICaL_f_gate__f * var_chaste_interface__cell__V); + IJth(rJacobian, 2, 0) = var_x261 * (var_x262 * var_x266 + var_x255 * var_x265 * (-var_x262 - var_x267) / pow(var_x263, 2)) + (var_x262 + var_x267) * (var_x264 - var_chaste_interface__INa_h_gate__h + var_x255 * var_x266); + IJth(rJacobian, 3, 0) = var_x285 * (var_x286 * var_x288 + var_x265 * var_x284 * (-var_x286 - var_x289) / pow(var_x287, 2)) + (var_x286 + var_x289) * (var_x264 - var_chaste_interface__INa_j_gate__j + var_x284 * var_x288); + IJth(rJacobian, 4, 0) = var_x296 * (var_x295 * var_x297 - var_x297 * var_x298 + 3.125 * var_x299 * var_x300 / pow((var_x300 + 0.25 * var_x293), 2)) - var_x299 * (-var_chaste_interface__INa_m_gate__m + 0.32000000000000001 * var_x292 * var_x294 * var_x297); + IJth(rJacobian, 5, 0) = (-var_chaste_interface__IKr_Xr_gate__Xr + 1 / var_x302) * (0.00060999999999999997 * var_x305 + 0.0013799999999999999 * var_x308 - 0.00016973999999999998 * var_x306 * var_x309 / pow(var_x307, 2) - 8.8449999999999995e-5 * var_x303 * var_x310 / pow(var_x304, 2)) + 0.13333333333333333 * var_x301 * var_x311 / pow(var_x302, 2); + IJth(rJacobian, 6, 0) = (-var_chaste_interface__IKs_Xs_gate__Xs + 1 / var_x313) * (0.00013100000000000001 * var_x316 + 7.1899999999999999e-5 * var_x319 - 8.9997000000000013e-6 * var_x314 * var_x320 / pow(var_x315, 2) - 1.0641199999999999e-5 * var_x317 * var_x320 / pow(var_x318, 2)) + 0.059880239520958084 * var_x312 * var_x321 / pow(var_x313, 2); + IJth(rJacobian, 7, 0) = var_x326 * var_x329 + 0.0074074074074074077 * var_x323 * (-var_x330 - var_chaste_interface__Itos_X_gate__X_tos) / (pow(var_x324, 2) * pow((0.055555555555555552 + var_x325), 2)); + IJth(rJacobian, 8, 0) = -var_x335 * var_x339 + 3.3333333333333335e-5 * var_x332 * var_x340 * (-var_x342 - var_chaste_interface__Itos_Y_gate__Y_tos) / pow((0.01 + var_x334), 2); + IJth(rJacobian, 9, 0) = -var_x339 * var_x343 + 3.5714285714285717e-5 * var_x332 * var_x340 * (-var_x342 - var_chaste_interface__Itos_R_gate__R_tos) / pow((0.07857142857142857 + var_x334), 2); + IJth(rJacobian, 10, 0) = var_x329 * var_x345 + 0.00063492063492063492 * var_x344 * (-var_x330 - var_chaste_interface__Itof_X_gate__X_tof) * var_chaste_interface__cell__V / pow((0.42857142857142855 + var_x344), 2); + IJth(rJacobian, 11, 0) = -var_x339 * var_x346 + 0.0050000000000000001 * var_x336 * var_x338 * (-var_x342 - var_chaste_interface__Itof_Y_gate__Y_tof) / pow((1 + var_x341), 2); + IJth(rJacobian, 12, 0) = -var_x349 * var_x352 * var_x354 + 0.035000000000000003 * var_x349 * var_x350 * var_x352 - var_x350 * var_x352 * var_x354 / pow(var_x348, 2) + 0.0058333333333333336 * var_x347 * var_x349 * var_x351 * var_x353; + IJth(rJacobian, 13, 0) = var_x356 * (0.029999999999999999 * var_x359 / pow(var_x360, 2) - 0.27777777777777779 * var_x357 / pow(var_x358, 2)) + var_x355 * (-0.032935010000000001 - 0.0022713799999999999 * var_chaste_interface__cell__V) * (-var_chaste_interface__ICaL_f_gate__f + 1 / var_x358 + 0.59999999999999998 / var_x360); + IJth(rJacobian, 19, 0) = -var_x379 * (0.00026433000000000001 + var_x154 + var_x205 + 2.6699999999999999 * var_x77 + 5.0996999999999995 * var_x94 + 0.46858500000000003 * var_x112); + IJth(rJacobian, 20, 0) = -var_x396 * (3.2670000000000004e-5 + var_x160 + var_x214 + 0.33000000000000002 * var_x64 + 0.63029999999999997 * var_x91 + 0.057915000000000008 * var_x115); + IJth(rJacobian, 25, 0) = -var_x409 * (0.00022365699999999999 + var_x126 + var_x142 - var_x145 - 1.78 * var_x77 - 0.31239000000000006 * var_x112); + IJth(rJacobian, 26, 0) = -var_x417 * (2.7642999999999999e-5 + var_x132 + var_x140 - var_x147 - 0.22 * var_x64 - 0.038610000000000005 * var_x115); + IJth(rJacobian, 1, 1) = -7.2523935948689155 + var_x230 + var_x231 + var_x232 + var_x243 + var_x244 + 6.3492962168146398e-7 * var_x242 - 5029484.9869235931 * var_x233 * var_x240; + IJth(rJacobian, 24, 1) = -1.1791550116941473e-5 * var_x242 + 93404721.185723871 * var_x233 * var_x237 * var_x238 * NV_Ith_S(mParameters, 2); IJth(rJacobian, 25, 1) = 5.6417918332397381; - IJth(rJacobian, 32, 1) = 2.2890000000000006 - var_x243; - IJth(rJacobian, 33, 1) = 0.33180000000000004 - var_x244 - var_x245; - IJth(rJacobian, 35, 1) = 0.81600000000000006 - var_x241; - IJth(rJacobian, 36, 1) = 1.9320000000000004 - var_x246 - var_x247; - IJth(rJacobian, 38, 1) = 1.71 - var_x242; - IJth(rJacobian, 39, 1) = var_x454 * (2.5 - var_x453); - IJth(rJacobian, 42, 1) = var_x461 * (2.5 - var_x460); - IJth(rJacobian, 0, 2) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x163 * var_x22 - var_x165 * var_x22); - IJth(rJacobian, 2, 2) = -var_x269 - var_x275; - IJth(rJacobian, 19, 2) = -var_x409 * var_x410; - IJth(rJacobian, 20, 2) = -var_x409 * var_x423; - IJth(rJacobian, 0, 3) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x163 * var_x167 - var_x165 * var_x167); - IJth(rJacobian, 3, 3) = -var_x292 - var_x302; - IJth(rJacobian, 19, 3) = -var_x410 * var_x411; - IJth(rJacobian, 20, 3) = -var_x411 * var_x423; - IJth(rJacobian, 0, 4) = mSetVoltageDerivativeToZero ? 0.0 : (-0.33000000000000002 * var_x169 - 2.6699999999999999 * var_x170); - IJth(rJacobian, 4, 4) = -var_x308 - var_x314; - IJth(rJacobian, 19, 4) = -165.83168702434122 * var_x170 * var_x408; - IJth(rJacobian, 20, 4) = -803.76671393159438 * var_x169 * var_x408; - IJth(rJacobian, 0, 5) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x20 * var_x80 * NV_Ith_S(mParameters, 19)); - IJth(rJacobian, 5, 5) = -var_x330 - var_x331; - IJth(rJacobian, 0, 6) = mSetVoltageDerivativeToZero ? 0.0 : (-0.22 * var_x173 * var_x9 - 1.78 * var_x14 * var_x173); - IJth(rJacobian, 6, 6) = -var_x341 - var_x342; - IJth(rJacobian, 0, 7) = mSetVoltageDerivativeToZero ? 0.0 : (var_x38 * var_x5); - IJth(rJacobian, 7, 7) = -var_x347; - IJth(rJacobian, 0, 8) = mSetVoltageDerivativeToZero ? 0.0 : (var_x174 * var_x175); - IJth(rJacobian, 8, 8) = -var_x356; - IJth(rJacobian, 0, 9) = mSetVoltageDerivativeToZero ? 0.0 : (var_x175 * (0.5 * var_x26 - 0.5 * var_chaste_interface__cell__V)); - IJth(rJacobian, 9, 9) = -var_x364; - IJth(rJacobian, 0, 10) = mSetVoltageDerivativeToZero ? 0.0 : (var_x174 * var_x6); - IJth(rJacobian, 10, 10) = -var_x366; - IJth(rJacobian, 0, 11) = mSetVoltageDerivativeToZero ? 0.0 : (var_x174 * NV_Ith_S(mParameters, 17) * var_chaste_interface__Itof_X_gate__X_tof); - IJth(rJacobian, 11, 11) = -var_x367; - IJth(rJacobian, 0, 12) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x115 * var_x179 - var_x148 * var_x179 - var_x177 * var_x178 - var_x181 * var_x183 - var_x182 * var_x185); - IJth(rJacobian, 12, 12) = -var_x375 * var_x377; - IJth(rJacobian, 19, 12) = -var_x412 * var_x416; - IJth(rJacobian, 20, 12) = -var_x412 * var_x425; - IJth(rJacobian, 25, 12) = -var_x183 * var_x435; - IJth(rJacobian, 26, 12) = -var_x182 * var_x442; - IJth(rJacobian, 0, 13) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x115 * var_x188 - var_x148 * var_x188 - var_x178 * var_x187 - var_x181 * var_x190 - var_x185 * var_x189); - IJth(rJacobian, 13, 13) = -0.02 - var_x380; - IJth(rJacobian, 19, 13) = -var_x416 * var_x417; - IJth(rJacobian, 20, 13) = -var_x417 * var_x425; - IJth(rJacobian, 25, 13) = -var_x190 * var_x435; - IJth(rJacobian, 26, 13) = -var_x189 * var_x442; - IJth(rJacobian, 0, 14) = mSetVoltageDerivativeToZero ? 0.0 : (1.2150000000000001e-8 * var_x192 + var_x131 * var_x181 + 6.7499999999999994e-10 * var_x113 * var_x191); + IJth(rJacobian, 32, 1) = 2.2890000000000006 - var_x230; + IJth(rJacobian, 33, 1) = 0.33180000000000004 - var_x243; + IJth(rJacobian, 35, 1) = 0.81600000000000006 - var_x231; + IJth(rJacobian, 36, 1) = 1.9320000000000004 - var_x244; + IJth(rJacobian, 38, 1) = 1.71 - var_x232; + IJth(rJacobian, 39, 1) = -var_x428 * var_x429; + IJth(rJacobian, 42, 1) = -var_x436 * var_x437; + IJth(rJacobian, 0, 2) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x162 * var_x20 - var_x164 * var_x20); + IJth(rJacobian, 2, 2) = -var_x261; + IJth(rJacobian, 19, 2) = -var_x381 * var_x382; + IJth(rJacobian, 20, 2) = -var_x381 * var_x397; + IJth(rJacobian, 0, 3) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x162 * var_x166 - var_x164 * var_x166); + IJth(rJacobian, 3, 3) = -var_x285; + IJth(rJacobian, 19, 3) = -var_x382 * var_x383; + IJth(rJacobian, 20, 3) = -var_x383 * var_x397; + IJth(rJacobian, 0, 4) = mSetVoltageDerivativeToZero ? 0.0 : (-0.33000000000000002 * var_x168 - 2.6699999999999999 * var_x169); + IJth(rJacobian, 4, 4) = -var_x296; + IJth(rJacobian, 19, 4) = -165.83168702434122 * var_x169 * var_x380; + IJth(rJacobian, 20, 4) = -803.76671393159438 * var_x168 * var_x380; + IJth(rJacobian, 0, 5) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x18 * var_x80 * NV_Ith_S(mParameters, 19)); + IJth(rJacobian, 5, 5) = -var_x311; + IJth(rJacobian, 0, 6) = mSetVoltageDerivativeToZero ? 0.0 : (-0.22 * var_x172 * var_x8 - 1.78 * var_x13 * var_x172); + IJth(rJacobian, 6, 6) = -var_x321; + IJth(rJacobian, 0, 7) = mSetVoltageDerivativeToZero ? 0.0 : (var_x5 * var_x79 * NV_Ith_S(mParameters, 21)); + IJth(rJacobian, 7, 7) = -var_x326; + IJth(rJacobian, 0, 8) = mSetVoltageDerivativeToZero ? 0.0 : (var_x173 * var_x174); + IJth(rJacobian, 8, 8) = -var_x335; + IJth(rJacobian, 0, 9) = mSetVoltageDerivativeToZero ? 0.0 : (var_x174 * (-0.5 * var_chaste_interface__cell__V + 0.5 * var_x22 * var_x23 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))); + IJth(rJacobian, 9, 9) = -var_x343; + IJth(rJacobian, 0, 10) = mSetVoltageDerivativeToZero ? 0.0 : (var_x173 * var_x4); + IJth(rJacobian, 10, 10) = -var_x345; + IJth(rJacobian, 0, 11) = mSetVoltageDerivativeToZero ? 0.0 : (var_x173 * NV_Ith_S(mParameters, 17) * var_chaste_interface__Itof_X_gate__X_tof); + IJth(rJacobian, 11, 11) = -var_x346; + IJth(rJacobian, 0, 12) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x151 * var_x178 - var_x176 * var_x177 - var_x178 * var_x179 - var_x181 * var_x183 - var_x182 * var_x185); + IJth(rJacobian, 12, 12) = -0.035000000000000003 * var_x349 * var_x350 * var_x353; + IJth(rJacobian, 19, 12) = -var_x384 * var_x388; + IJth(rJacobian, 20, 12) = -var_x384 * var_x399; + IJth(rJacobian, 25, 12) = -var_x183 * var_x410; + IJth(rJacobian, 26, 12) = -var_x182 * var_x419; + IJth(rJacobian, 0, 13) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x151 * var_x188 - var_x177 * var_x187 - var_x179 * var_x188 - var_x181 * var_x190 - var_x185 * var_x189); + IJth(rJacobian, 13, 13) = -var_x356; + IJth(rJacobian, 19, 13) = -var_x388 * var_x389; + IJth(rJacobian, 20, 13) = -var_x389 * var_x399; + IJth(rJacobian, 25, 13) = -var_x190 * var_x410; + IJth(rJacobian, 26, 13) = -var_x189 * var_x419; + IJth(rJacobian, 0, 14) = mSetVoltageDerivativeToZero ? 0.0 : (1.2150000000000001e-8 * var_x192 + var_x120 * var_x181 + 6.7499999999999994e-10 * var_x149 * var_x191); IJth(rJacobian, 14, 14) = -0.011900000000000001 - 1.7 * var_chaste_interface__Ca_buffer__Ca_SL; - IJth(rJacobian, 19, 14) = var_x104 * var_x113 * var_x415; - IJth(rJacobian, 25, 14) = var_x131 * var_x435; - IJth(rJacobian, 0, 15) = mSetVoltageDerivativeToZero ? 0.0 : (1.0935000000000001e-7 * var_x192 + 6.0749999999999998e-9 * var_x105 * var_x180 + var_x131 * var_x140 * var_x180); + IJth(rJacobian, 19, 14) = var_x104 * var_x149 * var_x387; + IJth(rJacobian, 25, 14) = var_x120 * var_x410; + IJth(rJacobian, 0, 15) = mSetVoltageDerivativeToZero ? 0.0 : (1.0935000000000001e-7 * var_x192 + 6.0749999999999998e-9 * var_x156 * var_x180 + var_x120 * var_x131 * var_x180); IJth(rJacobian, 15, 15) = -0.011900000000000001 - 1.7 * var_chaste_interface__Ca_buffer__Ca_jct; - IJth(rJacobian, 20, 15) = var_x105 * var_x424; - IJth(rJacobian, 26, 15) = var_x131 * var_x139 * var_x441; - IJth(rJacobian, 16, 16) = -0.0050000000000000001 + var_x391 + var_x394; - IJth(rJacobian, 17, 16) = var_x394; - IJth(rJacobian, 18, 16) = var_x393; + IJth(rJacobian, 20, 15) = var_x156 * var_x398; + IJth(rJacobian, 26, 15) = var_x120 * var_x130 * var_x418; + IJth(rJacobian, 16, 16) = -0.0050000000000000001 - var_x368 + var_x366 * var_chaste_interface__Ca_buffer__Ca_jct; + IJth(rJacobian, 17, 16) = -var_x368; + IJth(rJacobian, 18, 16) = var_x368; IJth(rJacobian, 16, 17) = -0.0050000000000000001; - IJth(rJacobian, 17, 17) = -0.065000000000000002 + var_x394; + IJth(rJacobian, 17, 17) = -0.065000000000000002 - var_x368; IJth(rJacobian, 18, 17) = 0.0050000000000000001; IJth(rJacobian, 16, 18) = 0.055; - IJth(rJacobian, 17, 18) = var_x394 + var_x402 * var_chaste_interface__Ca_buffer__Ca_jct; - IJth(rJacobian, 18, 18) = -0.059999999999999998 + var_x391; + IJth(rJacobian, 17, 18) = -var_x368 + var_x365 * var_chaste_interface__Ca_buffer__Ca_jct; + IJth(rJacobian, 18, 18) = -0.059999999999999998 + var_x366 * var_chaste_interface__Ca_buffer__Ca_jct; IJth(rJacobian, 24, 18) = (-var_chaste_interface__Ca_buffer__Ca_SR + var_chaste_interface__Ca_buffer__Ca_jct) * NV_Ith_S(mParameters, 1); IJth(rJacobian, 26, 18) = (68.627450980392155 * var_chaste_interface__Ca_buffer__Ca_SR - 68.627450980392155 * var_chaste_interface__Ca_buffer__Ca_jct) * NV_Ith_S(mParameters, 1); - IJth(rJacobian, 0, 19) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x194 - var_x203 - var_x208 - 2.6699999999999999 * var_x205 - 0.00046442182911003347 * var_x207 - var_x198 * var_x201); - IJth(rJacobian, 19, 19) = (-2.5101556644976917 + var_x418 - var_x406 * (var_x194 + var_x203 + var_x208 + 8.0099999999999998 * var_x205 + 0.0013932654873301004 * var_x207 + var_x198 * var_x419)) * NV_Ith_S(mParameters, 3); + IJth(rJacobian, 0, 19) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x206 - 2.6699999999999999 * var_x201 - 0.00046442182911003347 * var_x203 - var_x196 * var_x199); + IJth(rJacobian, 19, 19) = (-2.5101556644976917 + var_x390 - var_x378 * (var_x206 + 8.0099999999999998 * var_x201 + 0.0013932654873301004 * var_x203 + var_x196 * var_x391)) * NV_Ith_S(mParameters, 3); IJth(rJacobian, 20, 19) = 1.0879068612142859 * NV_Ith_S(mParameters, 3); - IJth(rJacobian, 21, 19) = 0.000165 - var_x418; - IJth(rJacobian, 23, 19) = var_x429; - IJth(rJacobian, 25, 19) = -var_x434 * (-5.3399999999999999 * var_x205 - var_x198 * var_x436); - IJth(rJacobian, 0, 20) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x210 - var_x216 - var_x219 - 0.33000000000000002 * var_x217 - 5.7400450788880541e-5 * var_x218 - var_x212 * var_x214); + IJth(rJacobian, 21, 19) = 0.000165 - var_x390; + IJth(rJacobian, 23, 19) = var_x404; + IJth(rJacobian, 25, 19) = -var_x409 * (-5.3399999999999999 * var_x201 - var_x196 * var_x411); + IJth(rJacobian, 0, 20) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x215 - 0.33000000000000002 * var_x211 - 5.7400450788880541e-5 * var_x212 - var_x208 * var_x210); IJth(rJacobian, 19, 20) = 0.02774162496096429 * NV_Ith_S(mParameters, 3); - IJth(rJacobian, 20, 20) = (-1.0886629612142857 + var_x426 - var_x421 * (var_x210 + var_x216 + var_x219 + 0.98999999999999999 * var_x217 + 0.00017220135236664162 * var_x218 + var_x212 * var_x427)) * NV_Ith_S(mParameters, 3); - IJth(rJacobian, 22, 20) = 0.0007561 - var_x426; - IJth(rJacobian, 26, 20) = -var_x440 * (-0.66000000000000003 * var_x217 - var_x212 * var_x443); - IJth(rJacobian, 19, 21) = (0.001 + var_x420) * NV_Ith_S(mParameters, 3); - IJth(rJacobian, 21, 21) = -0.001 - var_x420; - IJth(rJacobian, 20, 22) = (0.001 + var_x428) * NV_Ith_S(mParameters, 3); - IJth(rJacobian, 22, 22) = -0.001 - var_x428; - IJth(rJacobian, 0, 23) = mSetVoltageDerivativeToZero ? 0.0 : (-0.0020162999999999999 * var_x11 * var_x220 - 0.0163137 * var_x15 * var_x220); + IJth(rJacobian, 20, 20) = (-1.0886629612142857 + var_x400 - var_x395 * (var_x215 + 0.98999999999999999 * var_x211 + 0.00017220135236664162 * var_x212 + var_x208 * var_x401)) * NV_Ith_S(mParameters, 3); + IJth(rJacobian, 22, 20) = 0.0007561 - var_x400; + IJth(rJacobian, 26, 20) = -var_x417 * (-0.66000000000000003 * var_x211 - var_x208 * var_x420); + IJth(rJacobian, 19, 21) = var_x392 * NV_Ith_S(mParameters, 3); + IJth(rJacobian, 21, 21) = -var_x392; + IJth(rJacobian, 20, 22) = var_x402 * NV_Ith_S(mParameters, 3); + IJth(rJacobian, 22, 22) = -var_x402; + IJth(rJacobian, 0, 23) = mSetVoltageDerivativeToZero ? 0.0 : (-0.0020162999999999999 * var_x10 * var_x216 - 0.0163137 * var_x14 * var_x216); IJth(rJacobian, 19, 23) = 2.4822490395367272 * NV_Ith_S(mParameters, 3); - IJth(rJacobian, 23, 23) = -var_x429; - IJth(rJacobian, 1, 24) = 0.69232869146389786 * var_x259 + 8.7400597733819945e-14 * var_x260; - IJth(rJacobian, 16, 24) = -var_x399 + var_x395 * var_x397; - IJth(rJacobian, 17, 24) = -var_x403 + var_x398 * var_x404; - IJth(rJacobian, 18, 24) = var_x399 + var_x403; - IJth(rJacobian, 24, 24) = -260.0 + var_x430 - var_x431 - var_x432 - 1.6231539579137989e-12 * var_x260 - 12.857532841472388 * var_x259; - IJth(rJacobian, 26, 24) = var_x444 + var_x445; - IJth(rJacobian, 31, 24) = 260.0 - var_x430; - IJth(rJacobian, 0, 25) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x224 - var_x225 - var_x232 + 0.89000000000000001 * var_x227 - 4.4795166719999994e-11 * var_x229 - var_x201 * var_x231 - 0.0097566250000000014 * var_x221 / (pow(var_x3, 2) * pow(var_chaste_interface__Ca_buffer__Ca_SL, 2)) - 0.28183333333333332 * var_x12 * var_x2 * var_x228 / pow(var_x13, 2)); + IJth(rJacobian, 23, 23) = -var_x404; + IJth(rJacobian, 1, 24) = 0.69232869146389786 * var_x246 + 8.7400597733819945e-14 * var_x247; + IJth(rJacobian, 16, 24) = -var_x372 + 2.3772197685794643 * var_x361 * var_x362 * var_x369 * var_chaste_interface__Ca_buffer__Ca_jct * var_chaste_interface__Jrel_SR__R; + IJth(rJacobian, 17, 24) = -var_x375 + var_x371 * var_x376; + IJth(rJacobian, 18, 24) = var_x372 + var_x375; + IJth(rJacobian, 24, 24) = -260 + var_x405 - var_x407 - 1.6231539579137989e-12 * var_x247 - 12.857532841472388 * var_x246; + IJth(rJacobian, 26, 24) = var_x421; + IJth(rJacobian, 31, 24) = 260 - var_x405; + IJth(rJacobian, 0, 25) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x224 - 4.4795166719999994e-11 * var_x219 - var_x199 * var_x221 - 0.0097566250000000014 * var_x217 / (pow(var_x3, 2) * pow(var_chaste_interface__Ca_buffer__Ca_SL, 2)) - 0.28183333333333332 * var_x11 * var_x2 * var_x218 / pow(var_x12, 2) + 0.89000000000000001 * var_x45 * var_x46 * var_x57 * var_x59 * var_x72 * var_x74 * NV_Ith_S(mParameters, 22)); IJth(rJacobian, 1, 25) = 0.17359359486891501; IJth(rJacobian, 14, 25) = 1.7 - 1.7 * var_chaste_interface__ICaL_fCa_gate__fCaB_SL; - IJth(rJacobian, 19, 25) = -var_x407 * (1.3438550016e-10 * var_x229 - 2.6699999999999999 * var_x227 + var_x231 * var_x419); - IJth(rJacobian, 25, 25) = -171.99023312516786 + var_x437 + var_x438 - var_x434 * (var_x224 + var_x225 + var_x232 + 1.78 * var_x227 - 8.9590333439999989e-11 * var_x229 - var_x231 * var_x436); + IJth(rJacobian, 19, 25) = -var_x379 * (1.3438550016e-10 * var_x219 - 2.6699999999999999 * var_x394 + var_x221 * var_x391); + IJth(rJacobian, 25, 25) = -171.99023312516786 + var_x412 + var_x413 - var_x409 * (var_x224 + 1.78 * var_x394 - 8.9590333439999989e-11 * var_x219 - var_x221 * var_x411); IJth(rJacobian, 26, 25) = 48.958482036396518; - IJth(rJacobian, 27, 25) = 121.55000000000001 - var_x437; - IJth(rJacobian, 29, 25) = 43.550000000000004 - var_x438; - IJth(rJacobian, 40, 25) = var_x454 * (2.5024999999999999 - var_x458); - IJth(rJacobian, 43, 25) = var_x461 * (2.5024999999999999 - var_x465); - IJth(rJacobian, 0, 26) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x234 - var_x236 - var_x240 + 0.11 * var_x237 - 5.5364812799999996e-12 * var_x239 - var_x214 * var_x238 - 0.0012058750000000001 * var_x221 / (pow(var_x1, 2) * var_x233) - 0.034833333333333334 * var_x0 * var_x228 * var_x7 / pow(var_x8, 2)); + IJth(rJacobian, 27, 25) = 121.55000000000001 - var_x412; + IJth(rJacobian, 29, 25) = 43.550000000000004 - var_x413; + IJth(rJacobian, 40, 25) = -var_x429 * var_x433; + IJth(rJacobian, 43, 25) = -var_x437 * var_x441; + IJth(rJacobian, 0, 26) = mSetVoltageDerivativeToZero ? 0.0 : (-var_x229 - 5.5364812799999996e-12 * var_x227 - var_x210 * var_x226 - 0.0012058750000000001 * var_x217 / (pow(var_x1, 2) * var_x225) - 0.034833333333333334 * var_x0 * var_x218 * var_x6 / pow(var_x7, 2) + 0.11 * var_x45 * var_x46 * var_x53 * var_x55 * var_x57 * var_x59 * NV_Ith_S(mParameters, 22)); IJth(rJacobian, 15, 26) = 1.7 - 1.7 * var_chaste_interface__ICaL_fCa_gate__fCaB_jct; - IJth(rJacobian, 16, 26) = -var_x401 + var_x390 * var_chaste_interface__Jrel_SR__R; - IJth(rJacobian, 17, 26) = var_x402 * var_chaste_interface__Jrel_SR__O + var_x400 * var_x404 * var_chaste_interface__Ca_buffer__Ca_jct; - IJth(rJacobian, 18, 26) = var_x401 + var_x390 * var_chaste_interface__Jrel_SR__O; - IJth(rJacobian, 20, 26) = -var_x422 * (1.6609443839999999e-11 * var_x239 - 0.33000000000000002 * var_x237 + var_x238 * var_x427); - IJth(rJacobian, 24, 26) = var_x431 + var_x432; + IJth(rJacobian, 16, 26) = -var_x374 + var_x366 * var_chaste_interface__Jrel_SR__R; + IJth(rJacobian, 17, 26) = var_x365 * var_chaste_interface__Jrel_SR__O + var_x373 * var_x376 * var_chaste_interface__Ca_buffer__Ca_jct; + IJth(rJacobian, 18, 26) = var_x374 + var_x366 * var_chaste_interface__Jrel_SR__O; + IJth(rJacobian, 20, 26) = -var_x396 * (1.6609443839999999e-11 * var_x227 - 0.33000000000000002 * var_x403 + var_x226 * var_x401); + IJth(rJacobian, 24, 26) = var_x407; IJth(rJacobian, 25, 26) = 1.2484412919281114; - IJth(rJacobian, 26, 26) = -128.61534478149457 + var_x446 + var_x447 - var_x444 - var_x445 - var_x440 * (var_x234 + var_x236 + var_x240 + 0.22 * var_x237 - 1.1072962559999999e-11 * var_x239 - var_x238 * var_x443); - IJth(rJacobian, 28, 26) = 58.627450980392155 - var_x446; - IJth(rJacobian, 30, 26) = 21.029411764705884 - var_x447; - IJth(rJacobian, 41, 26) = var_x454 * (2.5490196078431375 - var_x459); - IJth(rJacobian, 44, 26) = var_x461 * (2.5490196078431375 - var_x466); - IJth(rJacobian, 25, 27) = 1.3 + var_x439; - IJth(rJacobian, 27, 27) = -1.3 + var_x449; - IJth(rJacobian, 26, 28) = 1.3 + var_x448; - IJth(rJacobian, 28, 28) = -1.3 + var_x450; - IJth(rJacobian, 25, 29) = 0.029999999999999999 + var_x439; - IJth(rJacobian, 29, 29) = -0.029999999999999999 + var_x449; - IJth(rJacobian, 26, 30) = 0.029999999999999999 + var_x448; - IJth(rJacobian, 30, 30) = -0.029999999999999999 + var_x450; - IJth(rJacobian, 24, 31) = 65.0 + var_x433; - IJth(rJacobian, 31, 31) = -65.0 - var_x433; - IJth(rJacobian, 1, 32) = 0.019599999999999999 + var_x261; - IJth(rJacobian, 32, 32) = -0.019599999999999999 - var_x261; - IJth(rJacobian, 1, 33) = 0.003032 + var_x262; - IJth(rJacobian, 33, 33) = -3.1999999999999999e-5 + var_x451; + IJth(rJacobian, 26, 26) = -128.61534478149457 + var_x422 + var_x423 - var_x421 - var_x417 * (var_x229 + 0.22 * var_x403 - 1.1072962559999999e-11 * var_x227 - var_x226 * var_x420); + IJth(rJacobian, 28, 26) = 58.627450980392155 - var_x422; + IJth(rJacobian, 30, 26) = 21.029411764705884 - var_x423; + IJth(rJacobian, 41, 26) = -var_x429 * var_x434; + IJth(rJacobian, 44, 26) = -var_x437 * var_x442; + IJth(rJacobian, 25, 27) = var_x415; + IJth(rJacobian, 27, 27) = -var_x415; + IJth(rJacobian, 26, 28) = var_x425; + IJth(rJacobian, 28, 28) = -var_x425; + IJth(rJacobian, 25, 29) = var_x416; + IJth(rJacobian, 29, 29) = -var_x416; + IJth(rJacobian, 26, 30) = var_x426; + IJth(rJacobian, 30, 30) = -var_x426; + IJth(rJacobian, 24, 31) = var_x408; + IJth(rJacobian, 31, 31) = -var_x408; + IJth(rJacobian, 1, 32) = var_x248; + IJth(rJacobian, 32, 32) = -var_x248; + IJth(rJacobian, 1, 33) = 0.003032 + var_x249; + IJth(rJacobian, 33, 33) = -3.1999999999999999e-5 - var_x249; IJth(rJacobian, 34, 33) = -0.0030000000000000001; - IJth(rJacobian, 1, 34) = 0.0063300000000000006 + var_x262; - IJth(rJacobian, 33, 34) = var_x451; + IJth(rJacobian, 1, 34) = 0.0063300000000000006 + var_x249; + IJth(rJacobian, 33, 34) = -var_x249; IJth(rJacobian, 34, 34) = -0.0063300000000000006; - IJth(rJacobian, 1, 35) = 0.23799999999999999 + var_x263; - IJth(rJacobian, 35, 35) = -0.23799999999999999 - var_x263; - IJth(rJacobian, 1, 36) = 0.016159999999999997 + var_x264; - IJth(rJacobian, 36, 36) = -0.00046000000000000001 + var_x452; + IJth(rJacobian, 1, 35) = var_x250; + IJth(rJacobian, 35, 35) = -var_x250; + IJth(rJacobian, 1, 36) = 0.016159999999999997 + var_x251; + IJth(rJacobian, 36, 36) = -0.00046000000000000001 - var_x251; IJth(rJacobian, 37, 36) = -0.015699999999999999; - IJth(rJacobian, 1, 37) = 0.015757 + var_x264; - IJth(rJacobian, 36, 37) = var_x452; + IJth(rJacobian, 1, 37) = 0.015757 + var_x251; + IJth(rJacobian, 36, 37) = -var_x251; IJth(rJacobian, 37, 37) = -0.015757; - IJth(rJacobian, 1, 38) = 0.059999999999999998 + var_x265; - IJth(rJacobian, 38, 38) = -0.059999999999999998 - var_x265; - IJth(rJacobian, 39, 39) = -0.059999999999999998 + var_x457 * var_chaste_interface__Ca_buffer__Cai + (-2.5 + var_x453) * var_chaste_interface__Ca_buffer__Cai; - IJth(rJacobian, 40, 39) = (-2.5024999999999999 + var_x458) * var_chaste_interface__Ca_buffer__Ca_SL; - IJth(rJacobian, 41, 39) = (-2.5490196078431375 + var_x459) * var_chaste_interface__Ca_buffer__Ca_jct; + IJth(rJacobian, 1, 38) = var_x252; + IJth(rJacobian, 38, 38) = -var_x252; + IJth(rJacobian, 39, 39) = -0.059999999999999998 + var_x428 * var_chaste_interface__Ca_buffer__Cai + var_x432 * var_chaste_interface__Ca_buffer__Cai; + IJth(rJacobian, 40, 39) = var_x433 * var_chaste_interface__Ca_buffer__Ca_SL; + IJth(rJacobian, 41, 39) = var_x434 * var_chaste_interface__Ca_buffer__Ca_jct; IJth(rJacobian, 39, 40) = (-0.076923076923076927 + 3.0769230769230771 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_Cytosol) * var_chaste_interface__Ca_buffer__Cai; - IJth(rJacobian, 40, 40) = -0.059999999999999998 + var_x457 * var_chaste_interface__Ca_buffer__Ca_SL + (-0.076999999999999999 + var_x456) * var_chaste_interface__Ca_buffer__Ca_SL; + IJth(rJacobian, 40, 40) = -0.059999999999999998 + var_x432 * var_chaste_interface__Ca_buffer__Ca_SL + (-0.076999999999999999 + var_x431) * var_chaste_interface__Ca_buffer__Ca_SL; IJth(rJacobian, 41, 40) = (-0.078431372549019607 + 3.0769230769230771 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_jct) * var_chaste_interface__Ca_buffer__Ca_jct; IJth(rJacobian, 39, 41) = (-0.0019615384615384616 + 0.078461538461538471 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_Cytosol) * var_chaste_interface__Ca_buffer__Cai; IJth(rJacobian, 40, 41) = (-0.0019635 + 0.078461538461538471 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Indo1_SL) * var_chaste_interface__Ca_buffer__Ca_SL; - IJth(rJacobian, 41, 41) = -0.059999999999999998 + var_x457 * var_chaste_interface__Ca_buffer__Ca_jct + (-0.002 + var_x455) * var_chaste_interface__Ca_buffer__Ca_jct; - IJth(rJacobian, 42, 42) = -0.11 + var_x464 * var_chaste_interface__Ca_buffer__Cai + (-2.5 + var_x460) * var_chaste_interface__Ca_buffer__Cai; - IJth(rJacobian, 43, 42) = (-2.5024999999999999 + var_x465) * var_chaste_interface__Ca_buffer__Ca_SL; - IJth(rJacobian, 44, 42) = (-2.5490196078431375 + var_x466) * var_chaste_interface__Ca_buffer__Ca_jct; + IJth(rJacobian, 41, 41) = -0.059999999999999998 + var_x432 * var_chaste_interface__Ca_buffer__Ca_jct + (-0.002 + var_x430) * var_chaste_interface__Ca_buffer__Ca_jct; + IJth(rJacobian, 42, 42) = -0.11 + var_x436 * var_chaste_interface__Ca_buffer__Cai + var_x440 * var_chaste_interface__Ca_buffer__Cai; + IJth(rJacobian, 43, 42) = var_x441 * var_chaste_interface__Ca_buffer__Ca_SL; + IJth(rJacobian, 44, 42) = var_x442 * var_chaste_interface__Ca_buffer__Ca_jct; IJth(rJacobian, 42, 43) = (-0.076923076923076927 + 3.0769230769230771 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_Cytosol) * var_chaste_interface__Ca_buffer__Cai; - IJth(rJacobian, 43, 43) = -0.11 + var_x464 * var_chaste_interface__Ca_buffer__Ca_SL + (-0.076999999999999999 + var_x463) * var_chaste_interface__Ca_buffer__Ca_SL; + IJth(rJacobian, 43, 43) = -0.11 + var_x440 * var_chaste_interface__Ca_buffer__Ca_SL + (-0.076999999999999999 + var_x439) * var_chaste_interface__Ca_buffer__Ca_SL; IJth(rJacobian, 44, 43) = (-0.078431372549019607 + 3.0769230769230771 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_jct) * var_chaste_interface__Ca_buffer__Ca_jct; IJth(rJacobian, 42, 44) = (-0.0019615384615384616 + 0.078461538461538471 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_Cytosol) * var_chaste_interface__Ca_buffer__Cai; IJth(rJacobian, 43, 44) = (-0.0019635 + 0.078461538461538471 * var_chaste_interface__indo_fluo_Ca_buffer_not_connected__Ca_Fluo3_SL) * var_chaste_interface__Ca_buffer__Ca_SL; - IJth(rJacobian, 44, 44) = -0.11 + var_x464 * var_chaste_interface__Ca_buffer__Ca_jct + (-0.002 + var_x462) * var_chaste_interface__Ca_buffer__Ca_jct; + IJth(rJacobian, 44, 44) = -0.11 + var_x440 * var_chaste_interface__Ca_buffer__Ca_jct + (-0.002 + var_x438) * var_chaste_interface__Ca_buffer__Ca_jct; } - N_Vector DynamicShannon2004FromCellMLCvode::ComputeDerivedQuantities(double var_chaste_interface__environment__time, const N_Vector & rY) + N_Vector Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode::ComputeDerivedQuantities(double var_chaste_interface__environment__time, const N_Vector & rY) { // Inputs: // Time units: millisecond @@ -1545,8 +1528,8 @@ const double var_ICaL__gamma_Ko = 0.75; // dimensionless const double var_ICaL__gamma_Nai = 0.75; // dimensionless const double var_ICaL__gamma_Nao = 0.75; // dimensionless - const double var_ICaL_fCa_gate__fCa_SL = 1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL; // dimensionless - const double var_ICaL_fCa_gate__fCa_jct = 1.0 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct; // dimensionless + const double var_ICaL_fCa_gate__fCa_SL = 1 - var_chaste_interface__ICaL_fCa_gate__fCaB_SL; // dimensionless + const double var_ICaL_fCa_gate__fCa_jct = 1 - var_chaste_interface__ICaL_fCa_gate__fCaB_jct; // dimensionless const double var_ICab__Fx_CaBk_SL = 0.89000000000000001; // dimensionless const double var_ICab__Fx_CaBk_jct = 0.11; // dimensionless const double var_ICab__G_CaBk = 0.00025129999999999998; // milliS_per_microF @@ -1558,23 +1541,23 @@ const double var_ICap__V_maxAF = 0.067299999999999999; // microA_per_microF const double var_IKs__Fx_Ks_SL = 0.89000000000000001; // dimensionless const double var_IKs__Fx_Ks_jct = 0.11; // dimensionless - const double var_IKs__pCa_SL = 3.0 - log10(var_chaste_interface__Ca_buffer__Ca_SL); // dimensionless - const double var_IKs__G_Ks_SL = (0.057000000000000002 + 0.19 / (1.0 + exp(-12.0 + 1.6666666666666667 * var_IKs__pCa_SL))) * NV_Ith_S(mParameters, 20); // milliS_per_microF - const double var_IKs__pCa_jct = 3.0 - log10(var_chaste_interface__Ca_buffer__Ca_jct); // dimensionless - const double var_IKs__G_Ks_jct = (0.057000000000000002 + 0.19 / (1.0 + exp(-12.0 + 1.6666666666666667 * var_IKs__pCa_jct))) * NV_Ith_S(mParameters, 20); // milliS_per_microF + const double var_IKs__pCa_SL = 3 - log10(var_chaste_interface__Ca_buffer__Ca_SL); // dimensionless + const double var_IKs__G_Ks_SL = (0.057000000000000002 + 0.19 / (1 + exp(-12 + 1.6666666666666667 * var_IKs__pCa_SL))) * NV_Ith_S(mParameters, 20); // milliS_per_microF + const double var_IKs__pCa_jct = 3 - log10(var_chaste_interface__Ca_buffer__Ca_jct); // dimensionless + const double var_IKs__G_Ks_jct = (0.057000000000000002 + 0.19 / (1 + exp(-12 + 1.6666666666666667 * var_IKs__pCa_jct))) * NV_Ith_S(mParameters, 20); // milliS_per_microF const double var_IKs__pKNa = 0.018329999999999999; // dimensionless const double var_INa__Fx_Na_SL = 0.89000000000000001; // dimensionless const double var_INa__Fx_Na_jct = 0.11; // dimensionless const double var_INaCa__Fx_NCX_SL = 0.89000000000000001; // dimensionless const double var_INaCa__Fx_NCX_jct = 0.11; // dimensionless - const double var_INaCa__HNa = 3.0; // dimensionless + const double var_INaCa__HNa = 3; // dimensionless const double var_INaCa__K_mCai = 0.0035899999999999999; // millimolar const double var_INaCa__K_mCao = 1.3; // millimolar const double var_INaCa__K_mNai = 12.289999999999999; // millimolar const double var_INaCa__K_mNao = 87.5; // millimolar const double var_INaCa__Kd_act = 0.00025599999999999999; // millimolar - const double var_INaCa__Ka_SL = 1 / (1.0 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_SL, 3)); // dimensionless - const double var_INaCa__Ka_jct = 1 / (1.0 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_jct, 3)); // dimensionless + const double var_INaCa__Ka_SL = 1 / (1 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_SL, 3)); // dimensionless + const double var_INaCa__Ka_jct = 1 / (1 + pow(var_INaCa__Kd_act, 3) / pow(var_chaste_interface__Ca_buffer__Ca_jct, 3)); // dimensionless const double var_INaCa__Q10_NCX = 1.5700000000000001; // dimensionless const double var_INaCa__eta = 0.34999999999999998; // dimensionless const double var_INaCa__ksat = 0.27000000000000002; // dimensionless @@ -1584,29 +1567,29 @@ const double var_INab__G_NaBk = 0.00029700000000000001; // milliS_per_microF const double var_Jrel_SR__j_rel_SR = (-var_chaste_interface__Ca_buffer__Ca_jct + var_chaste_interface__Ca_buffer__Ca_SR) * var_chaste_interface__Jrel_SR__O * NV_Ith_S(mParameters, 1); // millimolar_per_millisecond const double var_ICaL_f_gate__tau_f = 1 / (0.02 + 0.019699999999999999 * exp(-0.23877882250000002 * pow((1 + 0.068965517241379309 * var_chaste_interface__cell__V), 2))); // millisecond - const double var_IKr_Rr_gate__Rr = 1 / (1.0 + exp(1.4732142857142858 + 0.044642857142857144 * var_chaste_interface__cell__V)); // dimensionless - const double var_INa_h_gate__alpha_h = ((var_chaste_interface__cell__V < -40.0) ? (0.13500000000000001 * exp(-11.764705882352942 + 0.14705882352941177 * NV_Ith_S(mParameters, 16) - 0.14705882352941177 * var_chaste_interface__cell__V)) : (0)); // per_millisecond - const double var_INa_h_gate__beta_h = ((var_chaste_interface__cell__V < -40.0) ? (310000.0 * exp(0.34999999999999998 * var_chaste_interface__cell__V - 0.34999999999999998 * NV_Ith_S(mParameters, 16)) + 3.5600000000000001 * exp(0.079000000000000001 * var_chaste_interface__cell__V - 0.079000000000000001 * NV_Ith_S(mParameters, 16))) : (7.6923076923076916 / (1.0 + exp(-0.96036036036036043 + 0.0900900900900901 * NV_Ith_S(mParameters, 16) - 0.0900900900900901 * var_chaste_interface__cell__V)))); // per_millisecond + const double var_IKr_Rr_gate__Rr = 1 / (1 + exp(1.4732142857142858 + 0.044642857142857144 * var_chaste_interface__cell__V)); // dimensionless + const double var_INa_h_gate__alpha_h = ((var_chaste_interface__cell__V < -40) ? (0.13500000000000001 * exp(-11.764705882352942 + 0.14705882352941177 * NV_Ith_S(mParameters, 16) - 0.14705882352941177 * var_chaste_interface__cell__V)) : (0)); // per_millisecond + const double var_INa_h_gate__beta_h = ((var_chaste_interface__cell__V < -40) ? (310000 * exp(0.34999999999999998 * var_chaste_interface__cell__V - 0.34999999999999998 * NV_Ith_S(mParameters, 16)) + 3.5600000000000001 * exp(0.079000000000000001 * var_chaste_interface__cell__V - 0.079000000000000001 * NV_Ith_S(mParameters, 16))) : (7.6923076923076916 / (1 + exp(-0.96036036036036043 + 0.0900900900900901 * NV_Ith_S(mParameters, 16) - 0.0900900900900901 * var_chaste_interface__cell__V)))); // per_millisecond const double var_INa_h_gate__tau_h = 1 / (var_INa_h_gate__alpha_h + var_INa_h_gate__beta_h); // millisecond - const double var_INa_j_gate__alpha_j = ((var_chaste_interface__cell__V < -40.0) ? ((37.780000000000001 + var_chaste_interface__cell__V) * (-127140.0 * exp(0.24440000000000001 * var_chaste_interface__cell__V - 0.24440000000000001 * NV_Ith_S(mParameters, 16)) - 3.4740000000000003e-5 * exp(0.043909999999999998 * NV_Ith_S(mParameters, 16) - 0.043909999999999998 * var_chaste_interface__cell__V)) / (1.0 + exp(24.640530000000002 + 0.311 * var_chaste_interface__cell__V - 0.311 * NV_Ith_S(mParameters, 16)))) : (0)); // per_millisecond - const double var_INa_j_gate__beta_j = ((var_chaste_interface__cell__V < -40.0) ? (0.1212 * exp(0.01052 * NV_Ith_S(mParameters, 16) - 0.01052 * var_chaste_interface__cell__V) / (1.0 + exp(-5.5312920000000005 + 0.13780000000000001 * NV_Ith_S(mParameters, 16) - 0.13780000000000001 * var_chaste_interface__cell__V))) : (0.29999999999999999 * exp(2.5349999999999999e-7 * NV_Ith_S(mParameters, 16) - 2.5349999999999999e-7 * var_chaste_interface__cell__V) / (1.0 + exp(-3.2000000000000002 + 0.10000000000000001 * NV_Ith_S(mParameters, 16) - 0.10000000000000001 * var_chaste_interface__cell__V)))); // per_millisecond + const double var_INa_j_gate__alpha_j = ((var_chaste_interface__cell__V < -40) ? ((37.780000000000001 + var_chaste_interface__cell__V) * (-127140 * exp(0.24440000000000001 * var_chaste_interface__cell__V - 0.24440000000000001 * NV_Ith_S(mParameters, 16)) - 3.4740000000000003e-5 * exp(0.043909999999999998 * NV_Ith_S(mParameters, 16) - 0.043909999999999998 * var_chaste_interface__cell__V)) / (1 + exp(24.640530000000002 + 0.311 * var_chaste_interface__cell__V - 0.311 * NV_Ith_S(mParameters, 16)))) : (0)); // per_millisecond + const double var_INa_j_gate__beta_j = ((var_chaste_interface__cell__V < -40) ? (0.1212 * exp(0.01052 * NV_Ith_S(mParameters, 16) - 0.01052 * var_chaste_interface__cell__V) / (1 + exp(-5.5312920000000005 + 0.13780000000000001 * NV_Ith_S(mParameters, 16) - 0.13780000000000001 * var_chaste_interface__cell__V))) : (0.29999999999999999 * exp(2.5349999999999999e-7 * NV_Ith_S(mParameters, 16) - 2.5349999999999999e-7 * var_chaste_interface__cell__V) / (1 + exp(-3.2000000000000002 + 0.10000000000000001 * NV_Ith_S(mParameters, 16) - 0.10000000000000001 * var_chaste_interface__cell__V)))); // per_millisecond const double var_INa_j_gate__tau_j = 1 / (var_INa_j_gate__alpha_j + var_INa_j_gate__beta_j); // millisecond const double var_cell__i_Stim_converted = GetIntracellularAreaStimulus(var_chaste_interface__environment__time); // uA_per_cm2 const double var_model_parameters__Cm_per_area = 1.9999999999999999e-6; // farad_per_cm2 const double var_IK1__G_K1 = 0.43033148291193518 * sqrt(NV_Ith_S(mParameters, 8)) * NV_Ith_S(mParameters, 18); // milliS_per_microF const double var_IKr__G_IKr = 0.43033148291193518 * sqrt(NV_Ith_S(mParameters, 8)) * NV_Ith_S(mParameters, 19); // milliS_per_microF - const double var_ICaL__Q_CaL = pow(var_ICaL__Q10_CaL, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_ICaL__Q_CaL = pow(var_ICaL__Q10_CaL, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless const double var_ICaL__temp = 0.45000000000000001 * pow(NV_Ith_S(mParameters, 10), 2) * var_ICaL__Q_CaL * var_chaste_interface__ICaL_d_gate__d * var_chaste_interface__ICaL_f_gate__f * var_chaste_interface__cell__V / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)); // coulomb_per_mole - const double var_ICaL__i_CaL_Ca_SL = 4.0 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_SL * var_ICaL__gamma_Cai * exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1.0 + exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Ca_jct = 4.0 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_jct * var_ICaL__gamma_Cai * exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1.0 + exp(2.0 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_K = (var_ICaL__Fx_ICaL_SL * var_ICaL_fCa_gate__fCa_SL + var_ICaL__Fx_ICaL_jct * var_ICaL_fCa_gate__fCa_jct) * (-var_ICaL__gamma_Ko * NV_Ith_S(mParameters, 8) + var_ICaL__gamma_Ki * NV_Ith_S(mParameters, 5) * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__PK * var_ICaL__temp / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Na_SL = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_SL * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF - const double var_ICaL__i_CaL_Na_jct = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_jct * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1.0 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Ca_SL = 4 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_SL * var_ICaL__gamma_Cai * exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1 + exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Ca_jct = 4 * (-var_ICaL__gamma_Cao * NV_Ith_S(mParameters, 6) + var_chaste_interface__Ca_buffer__Ca_jct * var_ICaL__gamma_Cai * exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * NV_Ith_S(mParameters, 12) * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1 + exp(2 * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_K = (var_ICaL__Fx_ICaL_SL * var_ICaL_fCa_gate__fCa_SL + var_ICaL__Fx_ICaL_jct * var_ICaL_fCa_gate__fCa_jct) * (-var_ICaL__gamma_Ko * NV_Ith_S(mParameters, 8) + var_ICaL__gamma_Ki * NV_Ith_S(mParameters, 5) * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__PK * var_ICaL__temp / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Na_SL = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_SL * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_SL * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_SL / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF + const double var_ICaL__i_CaL_Na_jct = (-var_ICaL__gamma_Nao * NV_Ith_S(mParameters, 9) + var_ICaL__gamma_Nai * var_chaste_interface__Na_buffer__Na_jct * exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) * var_ICaL__Fx_ICaL_jct * var_ICaL__PNa * var_ICaL__temp * var_ICaL_fCa_gate__fCa_jct / (-1 + exp(var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // microA_per_microF const double var_ICaL__i_CaL = var_ICaL__i_CaL_Ca_SL + var_ICaL__i_CaL_Ca_jct + var_ICaL__i_CaL_K + var_ICaL__i_CaL_Na_SL + var_ICaL__i_CaL_Na_jct; // microA_per_microF const double var_ICaL__i_CaL_converted = HeartConfig::Instance()->GetCapacitance() * var_ICaL__i_CaL; // uA_per_cm2 - const double var_ICap__Q_SLCaP = pow(var_ICap__Q10_SLCaP, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_ICap__i_Cap_SL = var_ICap__Fx_SLCaP_SL * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1.0 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_SL), var_ICap__H)); // microA_per_microF - const double var_ICap__i_Cap_jct = var_ICap__Fx_SLCaP_jct * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1.0 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_jct), var_ICap__H)); // microA_per_microF + const double var_ICap__Q_SLCaP = pow(var_ICap__Q10_SLCaP, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_ICap__i_Cap_SL = var_ICap__Fx_SLCaP_SL * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_SL), var_ICap__H)); // microA_per_microF + const double var_ICap__i_Cap_jct = var_ICap__Fx_SLCaP_jct * var_ICap__Q_SLCaP * var_ICap__V_maxAF / (1 + pow((var_ICap__Km / var_chaste_interface__Ca_buffer__Ca_jct), var_ICap__H)); // microA_per_microF const double var_ICap__i_Cap = var_ICap__i_Cap_SL + var_ICap__i_Cap_jct; // microA_per_microF const double var_ICap__i_Cap_converted = HeartConfig::Instance()->GetCapacitance() * var_ICap__i_Cap; // uA_per_cm2 const double var_IKs__E_Ks = NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log((var_IKs__pKNa * NV_Ith_S(mParameters, 9) + NV_Ith_S(mParameters, 8)) / (var_IKs__pKNa * var_chaste_interface__Na_buffer__Nai + NV_Ith_S(mParameters, 5))) / NV_Ith_S(mParameters, 10); // millivolt @@ -1614,17 +1597,17 @@ const double var_IKs__i_Ks_jct = pow(var_chaste_interface__IKs_Xs_gate__Xs, 2) * (-var_IKs__E_Ks + var_chaste_interface__cell__V) * var_IKs__Fx_Ks_jct * var_IKs__G_Ks_jct; // microA_per_microF const double var_IKs__i_Ks = var_IKs__i_Ks_SL + var_IKs__i_Ks_jct; // microA_per_microF const double var_IKs__i_Ks_converted = HeartConfig::Instance()->GetCapacitance() * var_IKs__i_Ks; // uA_per_cm2 - const double var_INaCa__Q_NCX = pow(var_INaCa__Q10_NCX, (-31.0 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless - const double var_INaCa__temp_SL = (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1.0 + var_INaCa__ksat * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 - const double var_INaCa__i_NaCa_SL = var_INaCa__Fx_NCX_SL * var_INaCa__Ka_SL * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_SL / (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1.0 + var_chaste_interface__Ca_buffer__Ca_SL / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_SL + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1.0 + pow((var_chaste_interface__Na_buffer__Na_SL / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF - const double var_INaCa__temp_jct = (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1.0 + var_INaCa__ksat * exp((-1.0 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 - const double var_INaCa__i_NaCa_jct = var_INaCa__Fx_NCX_jct * var_INaCa__Ka_jct * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_jct / (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1.0 + var_chaste_interface__Ca_buffer__Ca_jct / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_jct + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1.0 + pow((var_chaste_interface__Na_buffer__Na_jct / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF + const double var_INaCa__Q_NCX = pow(var_INaCa__Q10_NCX, (-31 + 0.10000000000000001 * NV_Ith_S(mParameters, 23))); // dimensionless + const double var_INaCa__temp_SL = (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1 + var_INaCa__ksat * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 + const double var_INaCa__i_NaCa_SL = var_INaCa__Fx_NCX_SL * var_INaCa__Ka_SL * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_SL / (pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_SL, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_SL + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1 + var_chaste_interface__Ca_buffer__Ca_SL / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_SL + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1 + pow((var_chaste_interface__Na_buffer__Na_SL / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF + const double var_INaCa__temp_jct = (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) * exp(var_INaCa__eta * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23))) - pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))) / (1 + var_INaCa__ksat * exp((-1 + var_INaCa__eta) * var_chaste_interface__cell__V * NV_Ith_S(mParameters, 10) / (NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23)))); // millimolar4 + const double var_INaCa__i_NaCa_jct = var_INaCa__Fx_NCX_jct * var_INaCa__Ka_jct * var_INaCa__Q_NCX * NV_Ith_S(mParameters, 22) * var_INaCa__temp_jct / (pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * var_INaCa__K_mCao + pow(var_chaste_interface__Na_buffer__Na_jct, var_INaCa__HNa) * NV_Ith_S(mParameters, 6) + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * var_chaste_interface__Ca_buffer__Ca_jct + pow(var_INaCa__K_mNao, var_INaCa__HNa) * (1 + var_chaste_interface__Ca_buffer__Ca_jct / var_INaCa__K_mCai) * var_chaste_interface__Ca_buffer__Ca_jct + pow(NV_Ith_S(mParameters, 9), var_INaCa__HNa) * (1 + pow((var_chaste_interface__Na_buffer__Na_jct / var_INaCa__K_mNai), var_INaCa__HNa)) * var_INaCa__K_mCai); // microA_per_microF const double var_INaCa__i_NaCa = var_INaCa__i_NaCa_SL + var_INaCa__i_NaCa_jct; // microA_per_microF const double var_INaCa__i_NaCa_converted = HeartConfig::Instance()->GetCapacitance() * var_INaCa__i_NaCa; // uA_per_cm2 - const double var_model_parameters__cell_length = 100.0; // micrometre + const double var_model_parameters__cell_length = 100; // micrometre const double var_model_parameters__cell_radius = 10.25; // micrometre const double var_model_parameters__Cm = 2.0e-8 * M_PI * var_model_parameters__Cm_per_area * var_model_parameters__cell_length * var_model_parameters__cell_radius; // farad - const double var_model_parameters__Cm_converted = 1000000.0 * var_model_parameters__Cm; // uF + const double var_model_parameters__Cm_converted = 1000000 * var_model_parameters__Cm; // uF const double var_reversal_potentials__E_Ca_SL = 0.5 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 6) / var_chaste_interface__Ca_buffer__Ca_SL) / NV_Ith_S(mParameters, 10); // millivolt const double var_ICab__i_Cab_SL = (-var_reversal_potentials__E_Ca_SL + var_chaste_interface__cell__V) * var_ICab__Fx_CaBk_SL * var_ICab__G_CaBk; // microA_per_microF const double var_reversal_potentials__E_Ca_jct = 0.5 * NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 6) / var_chaste_interface__Ca_buffer__Ca_jct) / NV_Ith_S(mParameters, 10); // millivolt @@ -1635,8 +1618,8 @@ const double var_IClb__i_Clb = (-var_reversal_potentials__E_Cl + var_chaste_interface__cell__V) * NV_Ith_S(mParameters, 13); // microA_per_microF const double var_IClb__i_Clb_converted = HeartConfig::Instance()->GetCapacitance() * var_IClb__i_Clb; // uA_per_cm2 const double var_reversal_potentials__E_K = NV_Ith_S(mParameters, 11) * NV_Ith_S(mParameters, 23) * log(NV_Ith_S(mParameters, 8) / NV_Ith_S(mParameters, 5)) / NV_Ith_S(mParameters, 10); // millivolt - const double var_IK1_K1_gate__alpha_K1 = 1.02 / (1.0 + exp(-14.1227775 + 0.23849999999999999 * var_chaste_interface__cell__V - 0.23849999999999999 * var_reversal_potentials__E_K)); // per_millisecond - const double var_IK1_K1_gate__beta_K1 = (exp(-36.698642499999998 + 0.061749999999999999 * var_chaste_interface__cell__V - 0.061749999999999999 * var_reversal_potentials__E_K) + 0.49124000000000001 * exp(0.43983232 + 0.080320000000000003 * var_chaste_interface__cell__V - 0.080320000000000003 * var_reversal_potentials__E_K)) / (1.0 + exp(-2.4444678999999998 + 0.51429999999999998 * var_reversal_potentials__E_K - 0.51429999999999998 * var_chaste_interface__cell__V)); // per_millisecond + const double var_IK1_K1_gate__alpha_K1 = 1.02 / (1 + exp(-14.1227775 + 0.23849999999999999 * var_chaste_interface__cell__V - 0.23849999999999999 * var_reversal_potentials__E_K)); // per_millisecond + const double var_IK1_K1_gate__beta_K1 = (exp(-36.698642499999998 + 0.061749999999999999 * var_chaste_interface__cell__V - 0.061749999999999999 * var_reversal_potentials__E_K) + 0.49124000000000001 * exp(0.43983232 + 0.080320000000000003 * var_chaste_interface__cell__V - 0.080320000000000003 * var_reversal_potentials__E_K)) / (1 + exp(-2.4444678999999998 + 0.51429999999999998 * var_reversal_potentials__E_K - 0.51429999999999998 * var_chaste_interface__cell__V)); // per_millisecond const double var_IK1_K1_gate__K1_infinity = var_IK1_K1_gate__alpha_K1 / (var_IK1_K1_gate__alpha_K1 + var_IK1_K1_gate__beta_K1); // dimensionless const double var_IK1__i_K1 = (-var_reversal_potentials__E_K + var_chaste_interface__cell__V) * var_IK1__G_K1 * var_IK1_K1_gate__K1_infinity; // microA_per_microF const double var_IK1__i_K1_converted = HeartConfig::Instance()->GetCapacitance() * var_IK1__i_K1; // uA_per_cm2 @@ -1685,7 +1668,7 @@ } template<> -void OdeSystemInformation::Initialise(void) +void OdeSystemInformation::Initialise(void) { this->mSystemName = "shannon_wang_puglisi_weber_bers_2004_model_updated"; this->mFreeVariableName = "time"; @@ -2109,14 +2092,14 @@ void OdeSystemInformation::Initialise(void) // Serialization for Boost >= 1.36 #include "SerializationExportWrapperForCpp.hpp" -CHASTE_CLASS_EXPORT(DynamicShannon2004FromCellMLCvode) +CHASTE_CLASS_EXPORT(Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode) extern "C" { AbstractCardiacCellInterface* MakeCardiacCell( boost::shared_ptr pSolver, boost::shared_ptr pStimulus) { - return new DynamicShannon2004FromCellMLCvode(pSolver, pStimulus); + return new Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode(pSolver, pStimulus); } } diff --git a/chaste_codegen/data/tests/chaste_reference_models/Cvode_opt_with_jacobian/dynamic_Shannon2004.hpp b/chaste_codegen/data/tests/chaste_reference_models/Cvode_opt_with_jacobian/dynamic_Shannon2004.hpp index 9f032220..2daa77bf 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/Cvode_opt_with_jacobian/dynamic_Shannon2004.hpp +++ b/chaste_codegen/data/tests/chaste_reference_models/Cvode_opt_with_jacobian/dynamic_Shannon2004.hpp @@ -1,6 +1,6 @@ #ifdef CHASTE_CVODE -#ifndef DYNAMICSHANNON2004FROMCELLMLCVODE_HPP_ -#define DYNAMICSHANNON2004FROMCELLMLCVODE_HPP_ +#ifndef DYNAMICSHANNON_WANG_PUGLISI_WEBER_BERS_2004FROMCELLMLCVODE_HPP_ +#define DYNAMICSHANNON_WANG_PUGLISI_WEBER_BERS_2004FROMCELLMLCVODE_HPP_ //! @file //! @@ -20,7 +20,7 @@ #include "AbstractStimulusFunction.hpp" #include "AbstractCvodeCell.hpp" -class DynamicShannon2004FromCellMLCvode : public AbstractCvodeCell, public AbstractDynamicallyLoadableEntity +class Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode : public AbstractCvodeCell, public AbstractDynamicallyLoadableEntity { friend class boost::serialization::access; template @@ -34,12 +34,15 @@ class DynamicShannon2004FromCellMLCvode : public AbstractCvodeCell, public Abstr // Settable parameters and readable variables // +private: + static AbstractCvodeCell* CreateMethod(boost::shared_ptr p_solver, boost::shared_ptr p_stimulus); + static bool registered; public: boost::shared_ptr UseCellMLDefaultStimulus(); double GetIntracellularCalciumConcentration(); - DynamicShannon2004FromCellMLCvode(boost::shared_ptr pOdeSolver /* unused; should be empty */, boost::shared_ptr pIntracellularStimulus); - ~DynamicShannon2004FromCellMLCvode(); + Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode(boost::shared_ptr pOdeSolver /* unused; should be empty */, boost::shared_ptr pIntracellularStimulus); + ~Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode(); double GetIIonic(const std::vector* pStateVariables=NULL); void EvaluateYDerivatives(double var_chaste_interface__environment__time, const N_Vector rY, N_Vector rDY); N_Vector ComputeDerivedQuantities(double var_chaste_interface__environment__time, const N_Vector & rY); @@ -48,7 +51,7 @@ class DynamicShannon2004FromCellMLCvode : public AbstractCvodeCell, public Abstr // Needs to be included last #include "SerializationExportWrapper.hpp" -CHASTE_CLASS_EXPORT(DynamicShannon2004FromCellMLCvode) +CHASTE_CLASS_EXPORT(Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode) namespace boost { @@ -56,7 +59,7 @@ namespace boost { template inline void save_construct_data( - Archive & ar, const DynamicShannon2004FromCellMLCvode * t, const unsigned int fileVersion) + Archive & ar, const Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode * t, const unsigned int fileVersion) { const boost::shared_ptr p_solver = t->GetSolver(); const boost::shared_ptr p_stimulus = t->GetStimulusFunction(); @@ -66,18 +69,18 @@ namespace boost template inline void load_construct_data( - Archive & ar, DynamicShannon2004FromCellMLCvode * t, const unsigned int fileVersion) + Archive & ar, Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode * t, const unsigned int fileVersion) { boost::shared_ptr p_solver; boost::shared_ptr p_stimulus; ar >> p_solver; ar >> p_stimulus; - ::new(t)DynamicShannon2004FromCellMLCvode(p_solver, p_stimulus); + ::new(t)Dynamicshannon_wang_puglisi_weber_bers_2004FromCellMLCvode(p_solver, p_stimulus); } } } -#endif // DYNAMICSHANNON2004FROMCELLMLCVODE_HPP_ +#endif // DYNAMICSHANNON_WANG_PUGLISI_WEBER_BERS_2004FROMCELLMLCVODE_HPP_ #endif // CHASTE_CVODE \ No newline at end of file diff --git a/chaste_codegen/data/tests/chaste_reference_models/GRL1Opt/dynamic_matsuoka_model_2003.cpp b/chaste_codegen/data/tests/chaste_reference_models/GRL1Opt/dynamic_matsuoka_model_2003.cpp index 8e1d6355..f1b7e1b3 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/GRL1Opt/dynamic_matsuoka_model_2003.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/GRL1Opt/dynamic_matsuoka_model_2003.cpp @@ -455,7 +455,7 @@ class Dynamicmatsuoka_model_2003FromCellMLGRL1Opt_LookupTables : public Abstract for (unsigned i=0 ; i<_table_size_0; i++) { auto f = [](double var_chaste_interface__membrane__Vm) { - return 8000 * exp(0.01 * var_chaste_interface__membrane__Vm) + 9000000000 * exp(0.20000000000000001 * var_chaste_interface__membrane__Vm); + return 8000 * exp(0.01 * var_chaste_interface__membrane__Vm) + 9000000000.0 * exp(0.20000000000000001 * var_chaste_interface__membrane__Vm); }; const double var_chaste_interface__membrane__Vm = mTableMins[0] + i*mTableSteps[0]; double val = f(var_chaste_interface__membrane__Vm); @@ -2827,7 +2827,7 @@ std::shared_ptr Dynami const double var_x349 = exp(var_x347); const double var_x350 = exp(var_x345); - partialF = -1 / (4000 * var_x348 + 0.014 * var_x346) - 1 / (8000 * var_x349 + 9000000000 * var_x350); + partialF = -1 / (4000 * var_x348 + 0.014 * var_x346) - 1 / (8000 * var_x349 + 9000000000.0 * var_x350); } else { diff --git a/chaste_codegen/data/tests/chaste_reference_models/GRL1Opt/dynamic_matsuoka_model_2003.cpp_alt b/chaste_codegen/data/tests/chaste_reference_models/GRL1Opt/dynamic_matsuoka_model_2003.cpp_alt index 9fc91ba6..68ad7d87 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/GRL1Opt/dynamic_matsuoka_model_2003.cpp_alt +++ b/chaste_codegen/data/tests/chaste_reference_models/GRL1Opt/dynamic_matsuoka_model_2003.cpp_alt @@ -455,7 +455,7 @@ protected: for (unsigned i=0 ; i<_table_size_0; i++) { auto f = [](double var_chaste_interface__membrane__Vm) { - return 8000 * exp(0.01 * var_chaste_interface__membrane__Vm) + 9000000000 * exp(0.20000000000000001 * var_chaste_interface__membrane__Vm); + return 8000 * exp(0.01 * var_chaste_interface__membrane__Vm) + 9000000000.0 * exp(0.20000000000000001 * var_chaste_interface__membrane__Vm); }; const double var_chaste_interface__membrane__Vm = mTableMins[0] + i*mTableSteps[0]; double val = f(var_chaste_interface__membrane__Vm); @@ -2860,7 +2860,7 @@ std::shared_ptr Dynami const double var_x394 = exp(-var_x392); const double var_x395 = exp(-var_x390); - partialF = -1 / (4000 * var_x395 + 0.014 * var_x394) - 1 / (8000 * var_x391 + 9000000000 * var_x393); + partialF = -1 / (4000 * var_x395 + 0.014 * var_x394) - 1 / (8000 * var_x391 + 9000000000.0 * var_x393); } else { diff --git a/chaste_codegen/data/tests/chaste_reference_models/GRL2/dynamic_winslow_model_1999.cpp b/chaste_codegen/data/tests/chaste_reference_models/GRL2/dynamic_winslow_model_1999.cpp index 3c8d3928..4c16dd0f 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/GRL2/dynamic_winslow_model_1999.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/GRL2/dynamic_winslow_model_1999.cpp @@ -382,9 +382,9 @@ const double var_Na_Ca_exchanger__K_sat = 0.20000000000000001; // dimensionless const double var_Na_Ca_exchanger__eta = 0.34999999999999998; // dimensionless const double var_RyR_channel__k_a_minus = 576; // per_second - const double var_RyR_channel__k_a_plus = 12150000000000; // millimolar4_per_second + const double var_RyR_channel__k_a_plus = 12150000000000.0; // millimolar4_per_second const double var_RyR_channel__k_b_minus = 1930; // per_second - const double var_RyR_channel__k_b_plus = 4050000000; // millimolar3_per_second + const double var_RyR_channel__k_b_plus = 4050000000.0; // millimolar3_per_second const double var_RyR_channel__k_c_minus = 0.80000000000000004; // per_second const double var_RyR_channel__k_c_plus = 100; // per_second const double var_RyR_channel__P_C2_orig_deriv = var_chaste_interface__RyR_channel__P_O1 * var_RyR_channel__k_c_plus - var_chaste_interface__RyR_channel__P_C2 * var_RyR_channel__k_c_minus; // 1 / second @@ -2295,9 +2295,9 @@ // Mathematics const double var_RyR_channel__k_a_minus = 576; // per_second - const double var_RyR_channel__k_a_plus = 12150000000000; // millimolar4_per_second + const double var_RyR_channel__k_a_plus = 12150000000000.0; // millimolar4_per_second const double var_RyR_channel__k_b_minus = 1930; // per_second - const double var_RyR_channel__k_b_plus = 4050000000; // millimolar3_per_second + const double var_RyR_channel__k_b_plus = 4050000000.0; // millimolar3_per_second const double var_RyR_channel__k_c_minus = 0.80000000000000004; // per_second const double var_RyR_channel__k_c_plus = 100; // per_second const double var_RyR_channel__m = 3; // dimensionless @@ -2345,7 +2345,7 @@ // Mathematics const double var_RyR_channel__k_b_minus = 1930; // per_second - const double var_RyR_channel__k_b_plus = 4050000000; // millimolar3_per_second + const double var_RyR_channel__k_b_plus = 4050000000.0; // millimolar3_per_second const double var_RyR_channel__m = 3; // dimensionless const double var_RyR_channel__P_O2_orig_deriv = -var_chaste_interface__RyR_channel__P_O2 * var_RyR_channel__k_b_minus + pow(var_chaste_interface__intracellular_ion_concentrations__Ca_ss, var_RyR_channel__m) * var_chaste_interface__RyR_channel__P_O1 * var_RyR_channel__k_b_plus; // 1 / second const double d_dt_chaste_interface_var_RyR_channel__P_O2 = 0.001 * var_RyR_channel__P_O2_orig_deriv; // 1 / millisecond @@ -2386,7 +2386,7 @@ // Mathematics const double var_RyR_channel__k_a_minus = 576; // per_second - const double var_RyR_channel__k_a_plus = 12150000000000; // millimolar4_per_second + const double var_RyR_channel__k_a_plus = 12150000000000.0; // millimolar4_per_second const double var_RyR_channel__n = 4; // dimensionless const double var_RyR_channel__P_C1_orig_deriv = var_chaste_interface__RyR_channel__P_O1 * var_RyR_channel__k_a_minus - pow(var_chaste_interface__intracellular_ion_concentrations__Ca_ss, var_RyR_channel__n) * var_chaste_interface__RyR_channel__P_C1 * var_RyR_channel__k_a_plus; // 1 / second const double d_dt_chaste_interface_var_RyR_channel__P_C1 = 0.001 * var_RyR_channel__P_C1_orig_deriv; // 1 / millisecond @@ -2403,7 +2403,7 @@ // Units: millimolar; Initial value: 0.00011 - const double var_x244 = 12150000000 * pow(var_chaste_interface__intracellular_ion_concentrations__Ca_ss, 4); + const double var_x244 = 12150000000.0 * pow(var_chaste_interface__intracellular_ion_concentrations__Ca_ss, 4); partialF = -var_x244; } diff --git a/chaste_codegen/data/tests/chaste_reference_models/GRL2/dynamic_winslow_model_1999.cpp_alt b/chaste_codegen/data/tests/chaste_reference_models/GRL2/dynamic_winslow_model_1999.cpp_alt index 4d11fca4..411e0495 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/GRL2/dynamic_winslow_model_1999.cpp_alt +++ b/chaste_codegen/data/tests/chaste_reference_models/GRL2/dynamic_winslow_model_1999.cpp_alt @@ -382,9 +382,9 @@ const double var_Na_Ca_exchanger__K_sat = 0.20000000000000001; // dimensionless const double var_Na_Ca_exchanger__eta = 0.34999999999999998; // dimensionless const double var_RyR_channel__k_a_minus = 576; // per_second - const double var_RyR_channel__k_a_plus = 12150000000000; // millimolar4_per_second + const double var_RyR_channel__k_a_plus = 12150000000000.0; // millimolar4_per_second const double var_RyR_channel__k_b_minus = 1930; // per_second - const double var_RyR_channel__k_b_plus = 4050000000; // millimolar3_per_second + const double var_RyR_channel__k_b_plus = 4050000000.0; // millimolar3_per_second const double var_RyR_channel__k_c_minus = 0.80000000000000004; // per_second const double var_RyR_channel__k_c_plus = 100; // per_second const double var_RyR_channel__P_C2_orig_deriv = var_chaste_interface__RyR_channel__P_O1 * var_RyR_channel__k_c_plus - var_chaste_interface__RyR_channel__P_C2 * var_RyR_channel__k_c_minus; // 1 / second @@ -2294,9 +2294,9 @@ // Mathematics const double var_RyR_channel__k_a_minus = 576; // per_second - const double var_RyR_channel__k_a_plus = 12150000000000; // millimolar4_per_second + const double var_RyR_channel__k_a_plus = 12150000000000.0; // millimolar4_per_second const double var_RyR_channel__k_b_minus = 1930; // per_second - const double var_RyR_channel__k_b_plus = 4050000000; // millimolar3_per_second + const double var_RyR_channel__k_b_plus = 4050000000.0; // millimolar3_per_second const double var_RyR_channel__k_c_minus = 0.80000000000000004; // per_second const double var_RyR_channel__k_c_plus = 100; // per_second const double var_RyR_channel__m = 3; // dimensionless @@ -2344,7 +2344,7 @@ // Mathematics const double var_RyR_channel__k_b_minus = 1930; // per_second - const double var_RyR_channel__k_b_plus = 4050000000; // millimolar3_per_second + const double var_RyR_channel__k_b_plus = 4050000000.0; // millimolar3_per_second const double var_RyR_channel__m = 3; // dimensionless const double var_RyR_channel__P_O2_orig_deriv = -var_chaste_interface__RyR_channel__P_O2 * var_RyR_channel__k_b_minus + pow(var_chaste_interface__intracellular_ion_concentrations__Ca_ss, var_RyR_channel__m) * var_chaste_interface__RyR_channel__P_O1 * var_RyR_channel__k_b_plus; // 1 / second const double d_dt_chaste_interface_var_RyR_channel__P_O2 = 0.001 * var_RyR_channel__P_O2_orig_deriv; // 1 / millisecond @@ -2385,7 +2385,7 @@ // Mathematics const double var_RyR_channel__k_a_minus = 576; // per_second - const double var_RyR_channel__k_a_plus = 12150000000000; // millimolar4_per_second + const double var_RyR_channel__k_a_plus = 12150000000000.0; // millimolar4_per_second const double var_RyR_channel__n = 4; // dimensionless const double var_RyR_channel__P_C1_orig_deriv = var_chaste_interface__RyR_channel__P_O1 * var_RyR_channel__k_a_minus - pow(var_chaste_interface__intracellular_ion_concentrations__Ca_ss, var_RyR_channel__n) * var_chaste_interface__RyR_channel__P_C1 * var_RyR_channel__k_a_plus; // 1 / second const double d_dt_chaste_interface_var_RyR_channel__P_C1 = 0.001 * var_RyR_channel__P_C1_orig_deriv; // 1 / millisecond @@ -2402,7 +2402,7 @@ // Units: millimolar; Initial value: 0.00011 - const double var_x242 = 12150000000 * pow(var_chaste_interface__intracellular_ion_concentrations__Ca_ss, 4); + const double var_x242 = 12150000000.0 * pow(var_chaste_interface__intracellular_ion_concentrations__Ca_ss, 4); partialF = -var_x242; } diff --git a/chaste_codegen/data/tests/chaste_reference_models/Normal/fox_mcharg_gilmour_2002_console_script.cpp b/chaste_codegen/data/tests/chaste_reference_models/Normal/fox_mcharg_gilmour_2002_console_script.cpp index cec580dd..333f2936 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/Normal/fox_mcharg_gilmour_2002_console_script.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/Normal/fox_mcharg_gilmour_2002_console_script.cpp @@ -227,7 +227,7 @@ const double var_calcium_dynamics__J_up = mParameters[2] / (1 + pow(var_calcium_dynamics__K_mup, 2) / pow(var_calcium_dynamics__Ca_i, 2)); // micromolar_per_millisecond const double var_calcium_dynamics__beta_SR = 1 / (1 + var_calcium_dynamics__CSQN_tot * var_calcium_dynamics__K_mCSQN / pow((var_chaste_interface__calcium_dynamics__Ca_SR + var_calcium_dynamics__K_mCSQN), 2)); // dimensionless const double var_calcium_dynamics__beta_i = 1 / (1 + var_calcium_dynamics__CMDN_tot * var_calcium_dynamics__K_mCMDN / pow((var_calcium_dynamics__Ca_i + var_calcium_dynamics__K_mCMDN), 2)); // dimensionless - const double var_calcium_dynamics__gamma = 1 / (1 + 8000000000 / pow(var_chaste_interface__calcium_dynamics__Ca_SR, 3)); // dimensionless + const double var_calcium_dynamics__gamma = 1 / (1 + 8000000000.0 / pow(var_chaste_interface__calcium_dynamics__Ca_SR, 3)); // dimensionless const double var_membrane__F = 96.5; // coulomb_per_millimole const double var_membrane__R = 8.3140000000000001; // joule_per_mole_kelvin const double var_membrane__T = 310; // kelvin @@ -366,7 +366,7 @@ const double var_Na_Ca_exchanger__K_sat = 0.20000000000000001; // dimensionless const double var_Na_Ca_exchanger__eta = 0.34999999999999998; // dimensionless const double var_calcium_dynamics__Ca_i = 1000 * var_chaste_interface__calcium_dynamics__Ca_i_converted; // micromolar - const double var_calcium_dynamics__gamma = 1 / (1 + 8000000000 / pow(var_chaste_interface__calcium_dynamics__Ca_SR, 3)); // dimensionless + const double var_calcium_dynamics__gamma = 1 / (1 + 8000000000.0 / pow(var_chaste_interface__calcium_dynamics__Ca_SR, 3)); // dimensionless const double var_membrane__F = 96.5; // coulomb_per_millimole const double var_membrane__R = 8.3140000000000001; // joule_per_mole_kelvin const double var_membrane__T = 310; // kelvin diff --git a/chaste_codegen/data/tests/chaste_reference_models/Normal/test_luo_rudy_1991_with_range_cap_dimensionless.cpp b/chaste_codegen/data/tests/chaste_reference_models/Normal/test_luo_rudy_1991_with_range_cap_dimensionless.cpp index af58aa1a..42cd5824 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/Normal/test_luo_rudy_1991_with_range_cap_dimensionless.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/Normal/test_luo_rudy_1991_with_range_cap_dimensionless.cpp @@ -363,7 +363,7 @@ std::shared_ptr p_cellml_stim(new RegularStimulus( diff --git a/chaste_codegen/data/tests/chaste_reference_models/Normal/test_luo_rudy_1991_with_range_cap_dimensionless.cpp_alt b/chaste_codegen/data/tests/chaste_reference_models/Normal/test_luo_rudy_1991_with_range_cap_dimensionless.cpp_alt index b45644ed..abadc9a7 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/Normal/test_luo_rudy_1991_with_range_cap_dimensionless.cpp_alt +++ b/chaste_codegen/data/tests/chaste_reference_models/Normal/test_luo_rudy_1991_with_range_cap_dimensionless.cpp_alt @@ -363,7 +363,7 @@ std::shared_ptr p_cellml_stim(new RegularStimulus( diff --git a/chaste_codegen/data/tests/chaste_reference_models/RLopt/dynamic_bondarenko_szigeti_bett_kim_rasmusson_2004_apical.cpp b/chaste_codegen/data/tests/chaste_reference_models/RLopt/dynamic_bondarenko_szigeti_bett_kim_rasmusson_2004_apical.cpp index 7bfedf67..7418f877 100644 --- a/chaste_codegen/data/tests/chaste_reference_models/RLopt/dynamic_bondarenko_szigeti_bett_kim_rasmusson_2004_apical.cpp +++ b/chaste_codegen/data/tests/chaste_reference_models/RLopt/dynamic_bondarenko_szigeti_bett_kim_rasmusson_2004_apical.cpp @@ -692,7 +692,7 @@ std::shared_ptrGetCapacitance() * var_chaste_interface__fast_sodium_current__O_Na * mParameters[9]; // uA_per_cm2 const double var_rapid_delayed_rectifier_potassium_current__i_Kr_converted = (-25.674321243523316 * log((mParameters[5] + 0.020408163265306124 * mParameters[6]) / (var_chaste_interface__potassium_concentration__Ki + 0.020408163265306124 * var_chaste_interface__sodium_concentration__Nai)) + var_chaste_interface__membrane__V) * HeartConfig::Instance()->GetCapacitance() * var_chaste_interface__rapid_delayed_rectifier_potassium_current__O_K * mParameters[13]; // uA_per_cm2 const double var_sodium_background_current__i_Nab = 0.0025999999999999999 * var_chaste_interface__membrane__V - 0.0025999999999999999 * var_fast_sodium_current__E_Na; // picoA_per_picoF - const double var_sodium_calcium_exchange_current__i_NaCa_converted = (pow(var_chaste_interface__sodium_concentration__Nai, 3) * mParameters[4] * _lt_0_row[1] - pow(mParameters[6], 3) * var_calcium_concentration__Cai * _lt_0_row[2]) * HeartConfig::Instance()->GetCapacitance() * mParameters[15] / ((_lt_0_row[3]) * (1380 + mParameters[4]) * (669921875000000 + pow(mParameters[6], 3))); // uA_per_cm2 + const double var_sodium_calcium_exchange_current__i_NaCa_converted = (pow(var_chaste_interface__sodium_concentration__Nai, 3) * mParameters[4] * _lt_0_row[1] - pow(mParameters[6], 3) * var_calcium_concentration__Cai * _lt_0_row[2]) * HeartConfig::Instance()->GetCapacitance() * mParameters[15] / ((_lt_0_row[3]) * (1380 + mParameters[4]) * (669921875000000.0 + pow(mParameters[6], 3))); // uA_per_cm2 const double var_sodium_potassium_pump_current__i_NaK = 0.88 * mParameters[5] / ((1 + 3043189.1166997822 * pow((1 / var_chaste_interface__sodium_concentration__Nai), 1.5)) * (1500 + mParameters[5]) * (1 + _lt_0_row[5] + 0.036499999999999998 * (-0.14285714285714285 + 0.14285714285714285 * exp(1.4858841010401188e-5 * mParameters[6])) * _lt_0_row[4])); // picoA_per_picoF const double var_time_independent_potassium_current__i_K1_converted = (-var_fast_transient_outward_potassium_current__E_K + var_chaste_interface__membrane__V) * HeartConfig::Instance()->GetCapacitance() * mParameters[5] * mParameters[11] / ((1 + exp(0.089599999999999999 * var_chaste_interface__membrane__V - 0.089599999999999999 * var_fast_transient_outward_potassium_current__E_K)) * (210 + mParameters[5])); // uA_per_cm2 const double var_ultra_rapidly_activating_delayed_rectifier_potassium_current__i_Kur = 0.16 * (-var_fast_transient_outward_potassium_current__E_K + var_chaste_interface__membrane__V) * var_chaste_interface__ultra_rapidly_activating_delayed_rectifier_potassium_current__aur * var_chaste_interface__ultra_rapidly_activating_delayed_rectifier_potassium_current__iur; // picoA_per_picoF diff --git a/chaste_codegen/tests/test_labview_printer.py b/chaste_codegen/tests/test_labview_printer.py index 24dbf653..dd497d1d 100644 --- a/chaste_codegen/tests/test_labview_printer.py +++ b/chaste_codegen/tests/test_labview_printer.py @@ -135,6 +135,10 @@ def test_numbers(self, printer, x): assert printer.doprint(sp.pi) == 'pi' assert printer.doprint(sp.E) == 'exp(1)' + # large ints + assert printer.doprint(8034023767017108950029959168) == '8.034023767017109e+27' + assert printer.doprint(-8034023767017108950029959168) == '-8.034023767017109e+27' + def test_unsupported_function(self, printer, x): f = sp.Function('f') with pytest.raises(ValueError) as err: diff --git a/chaste_codegen/tests/test_printer.py b/chaste_codegen/tests/test_printer.py index fb521823..d1c7523f 100644 --- a/chaste_codegen/tests/test_printer.py +++ b/chaste_codegen/tests/test_printer.py @@ -135,6 +135,10 @@ def test_numbers(self, printer, x): assert printer.doprint(sp.pi) == 'M_PI' assert printer.doprint(sp.E) == 'e' + # large ints + assert printer.doprint(8034023767017108950029959168) == '8.034023767017109e+27' + assert printer.doprint(-8034023767017108950029959168) == '-8.034023767017109e+27' + def test_unsupported_function(self, printer, x): f = sp.Function('f') with pytest.raises(ValueError) as err: diff --git a/chaste_codegen/version.txt b/chaste_codegen/version.txt index 85b7c695..c81aa44a 100644 --- a/chaste_codegen/version.txt +++ b/chaste_codegen/version.txt @@ -1 +1 @@ -0.9.6 +0.9.7