Generated Code

The following is f77 code generated by the CellML API from this CellML file. (Back to language selection)

The raw code is available.

C
C There are a total of 94 entries in the algebraic variable array.
C There are a total of 35 entries in each of the rate and state variable arrays.
C There are a total of 80 entries in the constant variable array.
C
C
C VOI is time in component environment (second).
C STATES(1) is V in component membrane (millivolt).
C CONSTS(1) is R in component membrane (joule_per_kilomole_kelvin).
C CONSTS(2) is T in component membrane (kelvin).
C CONSTS(3) is F in component membrane (coulomb_per_mole).
C CONSTS(4) is Cm in component membrane (microF).
C ALGBRC(12) is I_st in component membrane (microA_per_microF).
C ALGBRC(31) is i_Na in component fast_sodium_current (microA_per_microF).
C ALGBRC(54) is i_Ca_L in component L_type_Ca_channel (microA_per_microF).
C ALGBRC(79) is i_Ca_T in component T_type_Ca_channel (microA_per_microF).
C ALGBRC(58) is i_Kr in component rapid_delayed_rectifier_potassium_current (microA_per_microF).
C ALGBRC(62) is i_Ks in component slow_delayed_rectifier_potassium_current (microA_per_microF).
C ALGBRC(72) is i_K_Na in component sodium_activated_potassium_current (microA_per_microF).
C ALGBRC(73) is i_K_ATP in component ATP_sensitive_potassium_current (microA_per_microF).
C ALGBRC(75) is i_to in component transient_outward_current (microA_per_microF).
C ALGBRC(88) is i_NaCa in component Na_Ca_exchanger (microA_per_microF).
C ALGBRC(67) is i_K1 in component time_independent_potassium_current (microA_per_microF).
C ALGBRC(69) is i_Kp in component plateau_potassium_current (microA_per_microF).
C ALGBRC(76) is i_p_Ca in component sarcolemmal_calcium_pump (microA_per_microF).
C ALGBRC(77) is i_Na_b in component sodium_background_current (microA_per_microF).
C ALGBRC(80) is i_Ca_b in component calcium_background_current (microA_per_microF).
C ALGBRC(82) is i_NaK in component sodium_potassium_pump (microA_per_microF).
C ALGBRC(87) is i_ns_Ca in component non_specific_calcium_activated_current (microA_per_microF).
C ALGBRC(89) is dVdt in component membrane (dimensionless).
C CONSTS(5) is stim_start in component membrane (second).
C CONSTS(6) is stim_end in component membrane (second).
C CONSTS(7) is stim_period in component membrane (dimensionless).
C CONSTS(8) is stim_duration in component membrane (second).
C CONSTS(9) is stim_amplitude in component membrane (microA_per_microF).
C ALGBRC(24) is E_Na in component fast_sodium_current (millivolt).
C CONSTS(10) is g_Na in component fast_sodium_current (milliS_per_microF).
C CONSTS(11) is Nao in component ionic_concentrations (millimolar).
C STATES(2) is Nai in component ionic_concentrations (millimolar).
C STATES(3) is P_O_Na in component Na_channel_states (dimensionless).
C STATES(4) is P_C1 in component Na_channel_states (dimensionless).
C STATES(5) is P_C2 in component Na_channel_states (dimensionless).
C STATES(6) is P_C3 in component Na_channel_states (dimensionless).
C STATES(7) is P_IF in component Na_channel_states (dimensionless).
C STATES(8) is P_IC3 in component Na_channel_states (dimensionless).
C STATES(9) is P_IC2 in component Na_channel_states (dimensionless).
C STATES(10) is P_IM1 in component Na_channel_states (dimensionless).
C STATES(11) is P_IM2 in component Na_channel_states (dimensionless).
C ALGBRC(1) is alpha_11 in component Na_channel_states (per_second).
C ALGBRC(32) is beta_11 in component Na_channel_states (per_second).
C ALGBRC(13) is alpha_12 in component Na_channel_states (per_second).
C ALGBRC(39) is beta_12 in component Na_channel_states (per_second).
C ALGBRC(25) is alpha_13 in component Na_channel_states (per_second).
C ALGBRC(43) is beta_13 in component Na_channel_states (per_second).
C ALGBRC(45) is alpha_2 in component Na_channel_states (per_second).
C ALGBRC(51) is beta_2 in component Na_channel_states (per_second).
C ALGBRC(47) is alpha_3 in component Na_channel_states (per_second).
C ALGBRC(49) is beta_3 in component Na_channel_states (per_second).
C ALGBRC(53) is alpha_4 in component Na_channel_states (per_second).
C ALGBRC(55) is beta_4 in component Na_channel_states (per_second).
C ALGBRC(57) is alpha_5 in component Na_channel_states (per_second).
C ALGBRC(59) is beta_5 in component Na_channel_states (per_second).
C ALGBRC(48) is i_CaCa in component L_type_Ca_channel (microA_per_microF).
C ALGBRC(52) is i_CaK in component L_type_Ca_channel (microA_per_microF).
C ALGBRC(50) is i_CaNa in component L_type_Ca_channel (microA_per_microF).
C CONSTS(12) is gamma_Nai in component L_type_Ca_channel (dimensionless).
C CONSTS(13) is gamma_Nao in component L_type_Ca_channel (dimensionless).
C CONSTS(14) is gamma_Ki in component L_type_Ca_channel (dimensionless).
C CONSTS(15) is gamma_Ko in component L_type_Ca_channel (dimensionless).
C ALGBRC(38) is I_CaCa in component L_type_Ca_channel (microA_per_microF).
C ALGBRC(44) is I_CaK in component L_type_Ca_channel (microA_per_microF).
C ALGBRC(42) is I_CaNa in component L_type_Ca_channel (microA_per_microF).
C CONSTS(16) is P_Ca in component L_type_Ca_channel (cm_per_second).
C CONSTS(17) is P_Na in component L_type_Ca_channel (cm_per_second).
C CONSTS(18) is P_K in component L_type_Ca_channel (cm_per_second).
C CONSTS(19) is gamma_Cai in component L_type_Ca_channel (dimensionless).
C CONSTS(20) is gamma_Cao in component L_type_Ca_channel (dimensionless).
C STATES(12) is Cai in component calcium_dynamics (millimolar).
C CONSTS(21) is Cao in component calcium_dynamics (millimolar).
C CONSTS(22) is Ko in component ionic_concentrations (millimolar).
C STATES(13) is Ki in component ionic_concentrations (millimolar).
C STATES(14) is d in component L_type_Ca_channel_d_gate (dimensionless).
C STATES(15) is f in component L_type_Ca_channel_f_gate (dimensionless).
C ALGBRC(46) is f_Ca in component L_type_Ca_channel_f_Ca_gate (dimensionless).
C ALGBRC(33) is alpha_d in component L_type_Ca_channel_d_gate (per_second).
C ALGBRC(40) is beta_d in component L_type_Ca_channel_d_gate (per_second).
C ALGBRC(14) is d_infinity in component L_type_Ca_channel_d_gate (dimensionless).
C ALGBRC(26) is tau_d in component L_type_Ca_channel_d_gate (second).
C ALGBRC(2) is E0_d in component L_type_Ca_channel_d_gate (millivolt).
C ALGBRC(27) is alpha_f in component L_type_Ca_channel_f_gate (per_second).
C ALGBRC(34) is beta_f in component L_type_Ca_channel_f_gate (per_second).
C ALGBRC(3) is f_infinity in component L_type_Ca_channel_f_gate (dimensionless).
C ALGBRC(15) is tau_f in component L_type_Ca_channel_f_gate (second).
C CONSTS(23) is Km_Ca in component L_type_Ca_channel_f_Ca_gate (millimolar).
C CONSTS(24) is g_CaT in component T_type_Ca_channel (milliS_per_microF).
C ALGBRC(78) is E_Ca in component calcium_background_current (millivolt).
C STATES(16) is b in component T_type_Ca_channel_b_gate (dimensionless).
C STATES(17) is g in component T_type_Ca_channel_g_gate (dimensionless).
C ALGBRC(4) is b_inf in component T_type_Ca_channel_b_gate (dimensionless).
C ALGBRC(16) is tau_b in component T_type_Ca_channel_b_gate (second).
C ALGBRC(5) is g_inf in component T_type_Ca_channel_g_gate (dimensionless).
C ALGBRC(17) is tau_g in component T_type_Ca_channel_g_gate (second).
C CONSTS(67) is g_Kr in component rapid_delayed_rectifier_potassium_current (milliS_per_microF).
C ALGBRC(56) is E_Kr in component rapid_delayed_rectifier_potassium_current (millivolt).
C STATES(18) is P_O in component Kr_channel_states (dimensionless).
C STATES(19) is P_C1 in component Kr_channel_states (dimensionless).
C STATES(20) is P_C2 in component Kr_channel_states (dimensionless).
C STATES(21) is P_C3 in component Kr_channel_states (dimensionless).
C STATES(22) is P_I in component Kr_channel_states (dimensionless).
C ALGBRC(6) is alpha in component Kr_channel_states (per_second).
C ALGBRC(18) is beta in component Kr_channel_states (per_second).
C CONSTS(25) is alpha_in in component Kr_channel_states (per_second).
C CONSTS(26) is beta_in in component Kr_channel_states (per_second).
C ALGBRC(7) is alpha_alpha in component Kr_channel_states (per_second).
C ALGBRC(19) is beta_beta in component Kr_channel_states (per_second).
C ALGBRC(28) is alpha_i in component Kr_channel_states (per_second).
C ALGBRC(35) is beta_i in component Kr_channel_states (per_second).
C ALGBRC(41) is mu in component Kr_channel_states (per_second).
C ALGBRC(61) is g_Ks in component slow_delayed_rectifier_potassium_current (milliS_per_microF).
C ALGBRC(60) is E_Ks in component slow_delayed_rectifier_potassium_current (millivolt).
C CONSTS(27) is PNaK in component slow_delayed_rectifier_potassium_current (dimensionless).
C STATES(23) is xs1 in component slow_delayed_rectifier_potassium_current_xs1_gate (dimensionless).
C STATES(24) is xs2 in component slow_delayed_rectifier_potassium_current_xs2_gate (dimensionless).
C ALGBRC(8) is xs1_infinity in component slow_delayed_rectifier_potassium_current_xs1_gate (dimensionless).
C ALGBRC(20) is tau_xs1 in component slow_delayed_rectifier_potassium_current_xs1_gate (second).
C ALGBRC(9) is xs2_infinity in component slow_delayed_rectifier_potassium_current_xs2_gate (dimensionless).
C ALGBRC(21) is tau_xs2 in component slow_delayed_rectifier_potassium_current_xs2_gate (second).
C ALGBRC(63) is E_K in component time_independent_potassium_current (millivolt).
C CONSTS(68) is g_K1 in component time_independent_potassium_current (milliS_per_cm2).
C ALGBRC(66) is K1_infinity in component time_independent_potassium_current_K1_gate (dimensionless).
C ALGBRC(64) is alpha_K1 in component time_independent_potassium_current_K1_gate (per_second).
C ALGBRC(65) is beta_K1 in component time_independent_potassium_current_K1_gate (per_second).
C CONSTS(28) is g_Kp in component plateau_potassium_current (milliS_per_microF).
C ALGBRC(68) is Kp in component plateau_potassium_current (dimensionless).
C CONSTS(69) is g_K_Na in component sodium_activated_potassium_current (milliS_per_microF).
C CONSTS(29) is nKNa in component sodium_activated_potassium_current (dimensionless).
C ALGBRC(70) is pona in component sodium_activated_potassium_current (dimensionless).
C ALGBRC(71) is pov in component sodium_activated_potassium_current (dimensionless).
C CONSTS(30) is kdKNa in component sodium_activated_potassium_current (millimolar).
C CONSTS(70) is g_K_ATP in component ATP_sensitive_potassium_current (milliS_per_microF).
C CONSTS(31) is i_K_ATP_on in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(32) is nATP in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(33) is nicholsarea in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(34) is ATPi in component ATP_sensitive_potassium_current (millimolar).
C CONSTS(35) is hATP in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(36) is kATP in component ATP_sensitive_potassium_current (millimolar).
C CONSTS(76) is pATP in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(78) is GKbaraATP in component ATP_sensitive_potassium_current (milliS_per_microF).
C CONSTS(71) is g_to in component transient_outward_current (milliS_per_microF).
C ALGBRC(74) is rvdv in component transient_outward_current (dimensionless).
C STATES(25) is zdv in component transient_outward_current_zdv_gate (dimensionless).
C STATES(26) is ydv in component transient_outward_current_ydv_gate (dimensionless).
C ALGBRC(10) is alpha_zdv in component transient_outward_current_zdv_gate (per_second).
C ALGBRC(22) is beta_zdv in component transient_outward_current_zdv_gate (per_second).
C ALGBRC(29) is tau_zdv in component transient_outward_current_zdv_gate (second).
C ALGBRC(36) is zdv_ss in component transient_outward_current_zdv_gate (dimensionless).
C ALGBRC(11) is alpha_ydv in component transient_outward_current_ydv_gate (per_second).
C ALGBRC(23) is beta_ydv in component transient_outward_current_ydv_gate (per_second).
C ALGBRC(30) is tau_ydv in component transient_outward_current_ydv_gate (second).
C ALGBRC(37) is ydv_ss in component transient_outward_current_ydv_gate (dimensionless).
C CONSTS(37) is K_mpCa in component sarcolemmal_calcium_pump (millimolar).
C CONSTS(38) is I_pCa in component sarcolemmal_calcium_pump (microA_per_microF).
C CONSTS(39) is g_Nab in component sodium_background_current (milliS_per_microF).
C CONSTS(40) is g_Cab in component calcium_background_current (milliS_per_microF).
C CONSTS(41) is I_NaK in component sodium_potassium_pump (microA_per_microF).
C ALGBRC(81) is f_NaK in component sodium_potassium_pump (dimensionless).
C CONSTS(42) is K_mNai in component sodium_potassium_pump (millimolar).
C CONSTS(43) is K_mKo in component sodium_potassium_pump (millimolar).
C CONSTS(72) is sigma in component sodium_potassium_pump (dimensionless).
C ALGBRC(85) is i_ns_Na in component non_specific_calcium_activated_current (microA_per_microF).
C ALGBRC(86) is i_ns_K in component non_specific_calcium_activated_current (microA_per_microF).
C CONSTS(73) is P_ns_Ca in component non_specific_calcium_activated_current (cm_per_second).
C ALGBRC(83) is I_ns_Na in component non_specific_calcium_activated_current (microA_per_microF).
C ALGBRC(84) is I_ns_K in component non_specific_calcium_activated_current (microA_per_microF).
C CONSTS(44) is K_m_ns_Ca in component non_specific_calcium_activated_current (millimolar).
C CONSTS(45) is c1 in component Na_Ca_exchanger (microA_per_microF).
C CONSTS(46) is c2 in component Na_Ca_exchanger (millimolar).
C CONSTS(47) is gamma in component Na_Ca_exchanger (dimensionless).
C ALGBRC(91) is i_rel in component calcium_dynamics (millimolar_per_second).
C ALGBRC(92) is i_up in component calcium_dynamics (millimolar_per_second).
C ALGBRC(93) is i_leak in component calcium_dynamics (millimolar_per_second).
C ALGBRC(94) is i_tr in component calcium_dynamics (millimolar_per_second).
C ALGBRC(90) is G_rel in component calcium_dynamics (per_second).
C CONSTS(48) is G_rel_max in component calcium_dynamics (per_second).
C CONSTS(49) is G_rel_overload in component calcium_dynamics (per_second).
C CONSTS(50) is tau_tr in component calcium_dynamics (second).
C CONSTS(51) is K_mrel in component calcium_dynamics (millimolar).
C CONSTS(52) is delta_Ca_ith in component calcium_dynamics (millimolar).
C CONSTS(53) is CSQN_max in component calcium_dynamics (millimolar).
C CONSTS(54) is K_mCSQN in component calcium_dynamics (millimolar).
C CONSTS(55) is K_mup in component calcium_dynamics (millimolar).
C CONSTS(74) is K_leak in component calcium_dynamics (per_second).
C CONSTS(56) is I_up in component calcium_dynamics (millimolar_per_second).
C CONSTS(57) is Ca_NSR_max in component calcium_dynamics (millimolar).
C STATES(27) is Ca_JSR in component calcium_dynamics (millimolar).
C STATES(28) is Ca_NSR in component calcium_dynamics (millimolar).
C CONSTS(77) is V_myo in component ionic_concentrations (micro_litre).
C CONSTS(58) is A_cap in component ionic_concentrations (mm2).
C CONSTS(79) is V_JSR in component calcium_dynamics (micro_litre).
C CONSTS(80) is V_NSR in component calcium_dynamics (micro_litre).
C CONSTS(59) is K_mTn in component calcium_dynamics (millimolar).
C CONSTS(60) is K_mCMDN in component calcium_dynamics (millimolar).
C CONSTS(61) is Tn_max in component calcium_dynamics (millimolar).
C CONSTS(62) is CMDN_max in component calcium_dynamics (millimolar).
C STATES(29) is APtrack in component calcium_dynamics (dimensionless).
C STATES(30) is APtrack2 in component calcium_dynamics (dimensionless).
C STATES(31) is APtrack3 in component calcium_dynamics (dimensionless).
C STATES(32) is Cainfluxtrack in component calcium_dynamics (dimensionless).
C STATES(33) is OVRLDtrack in component calcium_dynamics (dimensionless).
C STATES(34) is OVRLDtrack2 in component calcium_dynamics (dimensionless).
C STATES(35) is OVRLDtrack3 in component calcium_dynamics (dimensionless).
C CONSTS(63) is CSQNthresh in component calcium_dynamics (millimolar).
C CONSTS(64) is Logicthresh in component calcium_dynamics (dimensionless).
C CONSTS(65) is preplength in component ionic_concentrations (mm).
C CONSTS(66) is radius in component ionic_concentrations (mm).
C CONSTS(75) is volume in component ionic_concentrations (micro_litre).
C RATES(1) is d/dt V in component membrane (millivolt).
C RATES(6) is d/dt P_C3 in component Na_channel_states (dimensionless).
C RATES(5) is d/dt P_C2 in component Na_channel_states (dimensionless).
C RATES(4) is d/dt P_C1 in component Na_channel_states (dimensionless).
C RATES(3) is d/dt P_O_Na in component Na_channel_states (dimensionless).
C RATES(7) is d/dt P_IF in component Na_channel_states (dimensionless).
C RATES(8) is d/dt P_IC3 in component Na_channel_states (dimensionless).
C RATES(9) is d/dt P_IC2 in component Na_channel_states (dimensionless).
C RATES(10) is d/dt P_IM1 in component Na_channel_states (dimensionless).
C RATES(11) is d/dt P_IM2 in component Na_channel_states (dimensionless).
C RATES(14) is d/dt d in component L_type_Ca_channel_d_gate (dimensionless).
C RATES(15) is d/dt f in component L_type_Ca_channel_f_gate (dimensionless).
C RATES(16) is d/dt b in component T_type_Ca_channel_b_gate (dimensionless).
C RATES(17) is d/dt g in component T_type_Ca_channel_g_gate (dimensionless).
C RATES(21) is d/dt P_C3 in component Kr_channel_states (dimensionless).
C RATES(20) is d/dt P_C2 in component Kr_channel_states (dimensionless).
C RATES(19) is d/dt P_C1 in component Kr_channel_states (dimensionless).
C RATES(18) is d/dt P_O in component Kr_channel_states (dimensionless).
C RATES(22) is d/dt P_I in component Kr_channel_states (dimensionless).
C RATES(23) is d/dt xs1 in component slow_delayed_rectifier_potassium_current_xs1_gate (dimensionless).
C RATES(24) is d/dt xs2 in component slow_delayed_rectifier_potassium_current_xs2_gate (dimensionless).
C RATES(25) is d/dt zdv in component transient_outward_current_zdv_gate (dimensionless).
C RATES(26) is d/dt ydv in component transient_outward_current_ydv_gate (dimensionless).
C RATES(29) is d/dt APtrack in component calcium_dynamics (dimensionless).
C RATES(30) is d/dt APtrack2 in component calcium_dynamics (dimensionless).
C RATES(31) is d/dt APtrack3 in component calcium_dynamics (dimensionless).
C RATES(32) is d/dt Cainfluxtrack in component calcium_dynamics (dimensionless).
C RATES(33) is d/dt OVRLDtrack in component calcium_dynamics (dimensionless).
C RATES(34) is d/dt OVRLDtrack2 in component calcium_dynamics (dimensionless).
C RATES(35) is d/dt OVRLDtrack3 in component calcium_dynamics (dimensionless).
C RATES(27) is d/dt Ca_JSR in component calcium_dynamics (millimolar).
C RATES(28) is d/dt Ca_NSR in component calcium_dynamics (millimolar).
C RATES(12) is d/dt Cai in component calcium_dynamics (millimolar).
C RATES(2) is d/dt Nai in component ionic_concentrations (millimolar).
C RATES(13) is d/dt Ki in component ionic_concentrations (millimolar).
C
      SUBROUTINE initConsts(CONSTS, RATES, STATES)
      REAL CONSTS(*), RATES(*), STATES(*)
      STATES(1) = -89.179
      CONSTS(1) = 8314
      CONSTS(2) = 310
      CONSTS(3) = 96485
      CONSTS(4) = 0.001
      CONSTS(5) = 3
      CONSTS(6) = 9
      CONSTS(7) = 1
      CONSTS(8) = 0.002
      CONSTS(9) = -50
      CONSTS(10) = 23.5
      CONSTS(11) = 132
      STATES(2) = 12.306
      STATES(3) = 3.286e-13
      STATES(4) = 4.376e-10
      STATES(5) = 9.443e-8
      STATES(6) = 7.645e-6
      STATES(7) = 7.126e-11
      STATES(8) = 1.245e-6
      STATES(9) = 1.538e-8
      STATES(10) = 7.977e-12
      STATES(11) = 4.722e-14
      CONSTS(12) = 0.75
      CONSTS(13) = 0.75
      CONSTS(14) = 0.75
      CONSTS(15) = 0.75
      CONSTS(16) = 0.00054
      CONSTS(17) = 6.75e-7
      CONSTS(18) = 1.93e-7
      CONSTS(19) = 1
      CONSTS(20) = 0.341
      STATES(12) = 0.000123
      CONSTS(21) = 1.8
      CONSTS(22) = 4.5
      STATES(13) = 140.22
      STATES(14) = 3.085e-6
      STATES(15) = 0.9998
      CONSTS(23) = 0.0006
      CONSTS(24) = 0.05
      STATES(16) = 0.000947
      STATES(17) = 0.99457
      STATES(18) = 1.032e-10
      STATES(19) = 3.2864e-8
      STATES(20) = 1.63e-8
      STATES(21) = 4.951e-6
      STATES(22) = 3.135e-11
      CONSTS(25) = 2172
      CONSTS(26) = 1077
      CONSTS(27) = 0.01833
      STATES(23) = 0.00437
      STATES(24) = 0.00437
      CONSTS(28) = 0.00552
      CONSTS(29) = 2.8
      CONSTS(30) = 66
      CONSTS(31) = 1
      CONSTS(32) = 0.24
      CONSTS(33) = 5e-5
      CONSTS(34) = 3
      CONSTS(35) = 2
      CONSTS(36) = 0.00025
      STATES(25) = 0.0114
      STATES(26) = 0.99998
      CONSTS(37) = 0.0005
      CONSTS(38) = 1.15
      CONSTS(39) = 0.004
      CONSTS(40) = 0.003016
      CONSTS(41) = 2.25
      CONSTS(42) = 10
      CONSTS(43) = 1.5
      CONSTS(44) = 0.0012
      CONSTS(45) = 0.00025
      CONSTS(46) = 0.0001
      CONSTS(47) = 0.15
      CONSTS(48) = 60000
      CONSTS(49) = 4000
      CONSTS(50) = 0.18
      CONSTS(51) = 0.0008
      CONSTS(52) = 0.00018
      CONSTS(53) = 10
      CONSTS(54) = 0.8
      CONSTS(55) = 0.00092
      CONSTS(56) = 8.75
      CONSTS(57) = 15
      STATES(27) = 1.763
      STATES(28) = 1.764
      CONSTS(58) = 1.434e-7
      CONSTS(59) = 0.0005
      CONSTS(60) = 0.00238
      CONSTS(61) = 0.07
      CONSTS(62) = 0.05
      STATES(29) = 0
      STATES(30) = 0
      STATES(31) = 0
      STATES(32) = 0
      STATES(33) = 0
      STATES(34) = 0
      STATES(35) = 0
      CONSTS(63) = 0.7
      CONSTS(64) = 0.98
      CONSTS(65) = 0.001
      CONSTS(66) = 1.1e-4
      CONSTS(67) =  0.0135000*CONSTS(22) ** 0.590000
      CONSTS(68) =  0.750000* (CONSTS(22)/5.40000) ** (1.0 / 2)
      CONSTS(69) =  0.00000*0.128480
      CONSTS(70) = ( CONSTS(31)*0.000193000)/CONSTS(33)
      CONSTS(71) = 0.0500000
      CONSTS(72) =  (1.00000/7.00000)*(EXP(CONSTS(11)/67.3000) - 1.00000)
      CONSTS(73) =  0.00000*1.75000e-07
      CONSTS(74) = CONSTS(56)/CONSTS(57)
      CONSTS(75) =   3.14159265358979*CONSTS(65)*CONSTS(66) ** 2.00000
      CONSTS(76) = 1.00000/(1.00000+CONSTS(34)/CONSTS(36) ** CONSTS(35))
      CONSTS(77) =  0.680000*CONSTS(75)
      CONSTS(78) =  CONSTS(70)*CONSTS(76)*CONSTS(22)/4.00000 ** CONSTS(32)
      CONSTS(79) =  (0.00480000/0.680000)*CONSTS(77)
      CONSTS(80) =  (0.0552000/0.680000)*CONSTS(77)
      RETURN
      END
      SUBROUTINE computeRates(VOI, CONSTS,  RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      RATES(30) = TERNRY(STATES(29).LT.0.200000.AND.STATES(29).GT.0.180000,  100000.*(1.00000 - STATES(30)) -  500.000*STATES(30),  - 500.000*STATES(30))
      RATES(31) = TERNRY(STATES(29).LT.0.200000.AND.STATES(29).GT.0.180000,  100000.*(1.00000 - STATES(31)) -  500.000*STATES(31),  - 10.0000*STATES(31))
      RATES(33) = TERNRY(1.00000/(1.00000+CONSTS(54)/STATES(28)).GT.CONSTS(63).AND.STATES(35).LT.0.370000.AND.STATES(31).LT.0.370000,  50000.0*(1.00000 - STATES(33)),  - 500.000*STATES(33))
      RATES(34) = TERNRY(STATES(33).GT.CONSTS(64).AND.STATES(34).LT.CONSTS(64),  50000.0*(1.00000 - STATES(34)),  - 500.000*STATES(34))
      RATES(35) = TERNRY(STATES(33).GT.CONSTS(64).AND.STATES(35).LT.CONSTS(64),  50000.0*(1.00000 - STATES(35)),  - 10.0000*STATES(35))
      ALGBRC(4) = 1.00000/(1.00000+EXP(- (STATES(1)+14.0000)/10.8000))
      ALGBRC(16) = 0.00370000+0.00610000/(1.00000+EXP((STATES(1)+25.0000)/4.50000))
      RATES(16) = (ALGBRC(4) - STATES(16))/ALGBRC(16)
      ALGBRC(5) = 1.00000/(1.00000+EXP((STATES(1)+60.0000)/5.60000))
      ALGBRC(17) = TERNRY(STATES(1).LE.0.00000,  - 0.000875000*STATES(1)+0.0120000, 0.0120000)
      RATES(17) = (ALGBRC(5) - STATES(17))/ALGBRC(17)
      ALGBRC(6) =  55.5000*EXP( 0.0554715*(STATES(1) - 12.0000))
      ALGBRC(18) =  2.35700*EXP( - 0.0365880*STATES(1))
      RATES(21) =  ALGBRC(18)*STATES(20) -  ALGBRC(6)*STATES(21)
      RATES(20) =  - (ALGBRC(18)+CONSTS(25))*STATES(20)+ ALGBRC(6)*STATES(21)+ CONSTS(26)*STATES(19)
      ALGBRC(8) = 1.00000/(1.00000+EXP(- (STATES(1) - 1.50000)/16.7000))
      ALGBRC(20) = 0.00100000/(( 7.19000e-05*(STATES(1)+30.0000))/(1.00000 - EXP( - 0.148000*(STATES(1)+30.0000)))+( 0.000131000*(STATES(1)+30.0000))/(EXP( 0.0687000*(STATES(1)+30.0000)) - 1.00000))
      RATES(23) = (ALGBRC(8) - STATES(23))/ALGBRC(20)
      ALGBRC(9) = 1.00000/(1.00000+EXP(- (STATES(1) - 1.50000)/16.7000))
      ALGBRC(21) = ( 4.00000*0.00100000)/(( 7.19000e-05*(STATES(1)+30.0000))/(1.00000 - EXP( - 0.148000*(STATES(1)+30.0000)))+( 0.000131000*(STATES(1)+30.0000))/(EXP( 0.0687000*(STATES(1)+30.0000)) - 1.00000))
      RATES(24) = (ALGBRC(9) - STATES(24))/ALGBRC(21)
      ALGBRC(3) = 1.00000/(1.00000+EXP((STATES(1)+32.0000)/8.00000))+0.600000/(1.00000+EXP((50.0000 - STATES(1))/20.0000))
      ALGBRC(15) = 0.00100000/( 0.0197000*EXP(-  0.0337000*(STATES(1)+10.0000) ** 2.00000)+0.0200000)
      ALGBRC(27) = ALGBRC(3)/ALGBRC(15)
      ALGBRC(34) = (1.00000 - ALGBRC(3))/ALGBRC(15)
      RATES(15) =  ALGBRC(27)*(1.00000 - STATES(15)) -  ALGBRC(34)*STATES(15)
      ALGBRC(7) =  65.5000*EXP( 0.0554715*(STATES(1) - 36.0000))
      ALGBRC(19) =  2.93570*EXP( - 0.0215800*STATES(1))
      ALGBRC(28) = ( 439.000*EXP( - 0.0235200*(STATES(1)+25.0000))*4.50000)/CONSTS(22)
      ALGBRC(35) = ( 656.000*EXP( 0.000942000*STATES(1))*4.50000 ** 0.300000)/CONSTS(22) ** 0.300000
      RATES(18) =  - (ALGBRC(19)+ALGBRC(35))*STATES(18)+ ALGBRC(7)*STATES(19)+ ALGBRC(28)*STATES(22)
      ALGBRC(10) = ( 10000.0*EXP((STATES(1) - 40.0000)/25.0000))/(1.00000+EXP((STATES(1) - 40.0000)/25.0000))
      ALGBRC(22) = ( 10000.0*EXP(- (STATES(1)+90.0000)/25.0000))/(1.00000+EXP(- (STATES(1)+90.0000)/25.0000))
      ALGBRC(29) = 1.00000/(ALGBRC(10)+ALGBRC(22))
      ALGBRC(36) = ALGBRC(10)/(ALGBRC(10)+ALGBRC(22))
      RATES(25) = (ALGBRC(36) - STATES(25))/ALGBRC(29)
      ALGBRC(11) = 15.0000/(1.00000+EXP((STATES(1)+60.0000)/5.00000))
      ALGBRC(23) = ( 100.000*EXP((STATES(1)+25.0000)/5.00000))/(1.00000+EXP((STATES(1)+25.0000)/5.00000))
      ALGBRC(30) = 1.00000/(ALGBRC(11)+ALGBRC(23))
      ALGBRC(37) = ALGBRC(11)/(ALGBRC(11)+ALGBRC(23))
      RATES(26) = (ALGBRC(37) - STATES(26))/ALGBRC(30)
      ALGBRC(2) = STATES(1)+10.0000
      ALGBRC(14) = 1.00000/(1.00000+EXP(- ALGBRC(2)/6.24000))
      ALGBRC(26) = TERNRY(ABS(ALGBRC(2)).LT.1.00000e-05, 0.00100000/( 0.0350000*6.24000), ( 0.00100000*ALGBRC(14)*(1.00000 - EXP(- ALGBRC(2)/6.24000)))/( 0.0350000*ALGBRC(2)))
      ALGBRC(33) = ALGBRC(14)/ALGBRC(26)
      ALGBRC(40) = (1.00000 - ALGBRC(14))/ALGBRC(26)
      RATES(14) =  ALGBRC(33)*(1.00000 - STATES(14)) -  ALGBRC(40)*STATES(14)
      ALGBRC(41) = ( ALGBRC(28)*ALGBRC(19)*ALGBRC(7))/( ALGBRC(7)*ALGBRC(35))
      RATES(19) =  - (CONSTS(26)+ALGBRC(7)+ALGBRC(7))*STATES(19)+ CONSTS(25)*STATES(20)+ ALGBRC(19)*STATES(18)+ ALGBRC(41)*STATES(22)
      RATES(22) =  - (ALGBRC(41)+ALGBRC(28))*STATES(22)+ ALGBRC(7)*STATES(19)+ ALGBRC(35)*STATES(18)
      ALGBRC(1) = 3802.00/( 0.102700*EXP(- STATES(1)/17.0000)+ 0.200000*EXP(- STATES(1)/150.000))
      ALGBRC(32) =  191.700*EXP(- STATES(1)/20.3000)
      ALGBRC(47) =  0.000379330*EXP(- STATES(1)/7.70000)
      ALGBRC(49) = 8.40000+ 0.0200000*STATES(1)
      RATES(6) =  - (ALGBRC(49)+ALGBRC(1))*STATES(6)+ ALGBRC(47)*STATES(8)+ ALGBRC(32)*STATES(5)
      ALGBRC(13) = 3802.00/( 0.102700*EXP(- STATES(1)/15.0000)+ 0.230000*EXP(- STATES(1)/150.000))
      ALGBRC(39) =  200.000*EXP(- (STATES(1) - 5.00000)/20.3000)
      RATES(5) =  - (ALGBRC(32)+ALGBRC(49)+ALGBRC(13))*STATES(5)+ ALGBRC(1)*STATES(6)+ ALGBRC(39)*STATES(4)+ ALGBRC(47)*STATES(9)
      ALGBRC(25) = 3802.00/( 0.102700*EXP(- STATES(1)/12.0000)+ 0.250000*EXP(- STATES(1)/150.000))
      ALGBRC(43) =  220.000*EXP(- (STATES(1) - 10.0000)/20.3000)
      RATES(4) =  - (ALGBRC(39)+ALGBRC(25)+ALGBRC(49))*STATES(4)+ ALGBRC(13)*STATES(5)+ ALGBRC(43)*STATES(3)+ ALGBRC(47)*STATES(7)
      RATES(8) =  - (ALGBRC(47)+ALGBRC(1))*STATES(8)+ ALGBRC(49)*STATES(6)+ ALGBRC(32)*STATES(9)
      RATES(9) =  - (ALGBRC(47)+ALGBRC(13)+ALGBRC(32))*STATES(9)+ ALGBRC(49)*STATES(5)+ ALGBRC(39)*STATES(7)+ ALGBRC(1)*STATES(8)
      ALGBRC(45) =  9178.00*EXP(STATES(1)/29.6800)
      ALGBRC(51) = ( ALGBRC(25)*ALGBRC(45)*ALGBRC(47))/( ALGBRC(43)*ALGBRC(49))
      RATES(3) =  - (ALGBRC(45)+ALGBRC(43))*STATES(3)+ ALGBRC(51)*STATES(7)+ ALGBRC(25)*STATES(4)
      ALGBRC(53) = ALGBRC(45)/100.000
      ALGBRC(55) = ALGBRC(47)
      RATES(7) =  - (ALGBRC(51)+ALGBRC(47)+ALGBRC(53)+ALGBRC(39))*STATES(7)+ ALGBRC(49)*STATES(4)+ ALGBRC(55)*STATES(10)+ ALGBRC(45)*STATES(3)+ ALGBRC(13)*STATES(9)
      ALGBRC(57) = ALGBRC(45)/95000.0
      ALGBRC(59) = ALGBRC(47)/50.0000
      RATES(10) =  - (ALGBRC(57)+ALGBRC(55))*STATES(10)+ ALGBRC(59)*STATES(11)+ ALGBRC(53)*STATES(7)
      RATES(11) =  ALGBRC(57)*STATES(10) -  ALGBRC(59)*STATES(11)
      ALGBRC(56) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(22)/STATES(13))
      ALGBRC(58) =  CONSTS(67)*STATES(18)*(STATES(1) - ALGBRC(56))
      ALGBRC(61) =  0.968000*0.433000*(1.00000+0.600000/(1.00000+3.80000e-05/STATES(12) ** 1.40000))
      ALGBRC(60) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log((CONSTS(22)+ CONSTS(27)*CONSTS(11))/(STATES(13)+ CONSTS(27)*STATES(2)))
      ALGBRC(62) =  ALGBRC(61)*STATES(23)*STATES(24)*(STATES(1) - ALGBRC(60))
      ALGBRC(63) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(22)/STATES(13))
      ALGBRC(70) = 0.850000/(1.00000+CONSTS(30)/STATES(2) ** CONSTS(29))
      ALGBRC(71) = 0.800000 - 0.650000/(1.00000+EXP((STATES(1)+125.000)/15.0000))
      ALGBRC(72) =  CONSTS(69)*ALGBRC(70)*ALGBRC(71)*(STATES(1) - ALGBRC(63))
      ALGBRC(73) =  CONSTS(78)*(STATES(1) - ALGBRC(63))
      ALGBRC(74) = EXP(STATES(1)/100.000)
      ALGBRC(75) =  CONSTS(71)*STATES(25) ** 3.00000*STATES(26)*ALGBRC(74)*(STATES(1) - ALGBRC(63))
      ALGBRC(64) = 1020.00/(1.00000+EXP( 0.238500*((STATES(1) - ALGBRC(63)) - 59.2150)))
      ALGBRC(65) = ( 1000.00*( 0.491240*EXP( 0.0803200*((STATES(1) - ALGBRC(63))+5.47600))+EXP( 0.0617500*((STATES(1) - ALGBRC(63)) - 594.310))))/(1.00000+EXP( - 0.514300*((STATES(1) - ALGBRC(63))+4.75300)))
      ALGBRC(66) = ALGBRC(64)/(ALGBRC(64)+ALGBRC(65))
      ALGBRC(67) =  CONSTS(68)*ALGBRC(66)*(STATES(1) - ALGBRC(63))
      ALGBRC(68) = 1.00000/(1.00000+EXP((7.48800 - STATES(1))/5.98000))
      ALGBRC(69) =  CONSTS(28)*ALGBRC(68)*(STATES(1) - ALGBRC(63))
      ALGBRC(81) = 1.00000/(1.00000+ 0.124500*EXP(( - 0.100000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))+ 0.0365000*CONSTS(72)*EXP(( - STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))))
      ALGBRC(82) = ( (( CONSTS(41)*ALGBRC(81)*1.00000)/(1.00000+CONSTS(42)/STATES(2) ** 2.00000))*CONSTS(22))/(CONSTS(22)+CONSTS(43))
      ALGBRC(44) = ( (( CONSTS(18)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(14)*STATES(13)*EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(15)*CONSTS(22)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(46) = 1.00000/(1.00000+STATES(12)/CONSTS(23))
      ALGBRC(52) =  STATES(14)*STATES(15)*ALGBRC(46)*ALGBRC(44)
      ALGBRC(84) = ( (( CONSTS(73)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(14)*STATES(13)*EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(15)*CONSTS(22)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(86) = ( ALGBRC(84)*1.00000)/(1.00000+CONSTS(44)/STATES(12) ** 3.00000)
      RATES(13) = ( - (ALGBRC(52)+ALGBRC(58)+ALGBRC(62)+ALGBRC(67)+ALGBRC(69)+ALGBRC(72)+ALGBRC(73)+ALGBRC(75)+ALGBRC(86)+ - ALGBRC(82)*2.00000)*CONSTS(58))/( CONSTS(77)*CONSTS(3))
      ALGBRC(12) = TERNRY(VOI.GE.CONSTS(5).AND.VOI.LE.CONSTS(6).AND.(VOI - CONSTS(5)) -  INT((VOI - CONSTS(5))/CONSTS(7))*CONSTS(7).LE.CONSTS(8), CONSTS(9), 0.00000)
      ALGBRC(24) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(11)/STATES(2))
      ALGBRC(31) =  CONSTS(10)*STATES(3)*(STATES(1) - ALGBRC(24))
      ALGBRC(38) = ( (( CONSTS(16)*2.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(19)*STATES(12)*EXP(( 2.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(20)*CONSTS(21)))/(EXP(( 2.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(48) =  STATES(14)*STATES(15)*ALGBRC(46)*ALGBRC(38)
      ALGBRC(42) = ( (( CONSTS(17)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(12)*STATES(2)*EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(13)*CONSTS(11)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(50) =  STATES(14)*STATES(15)*ALGBRC(46)*ALGBRC(42)
      ALGBRC(54) = ALGBRC(48)+ALGBRC(52)+ALGBRC(50)
      ALGBRC(78) =  (( CONSTS(1)*CONSTS(2))/( 2.00000*CONSTS(3)))*log(CONSTS(21)/STATES(12))
      ALGBRC(79) =  CONSTS(24)*STATES(16)*STATES(16)*STATES(17)*(STATES(1) - ALGBRC(78))
      ALGBRC(88) = ( CONSTS(45)*EXP(( (CONSTS(47) - 1.00000)*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*( EXP(( STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*STATES(2) ** 3.00000*CONSTS(21) -  CONSTS(11) ** 3.00000*STATES(12)))/(1.00000+ CONSTS(46)*EXP(( (CONSTS(47) - 1.00000)*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*( EXP(( STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*STATES(2) ** 3.00000*CONSTS(21)+ CONSTS(11) ** 3.00000*STATES(12)))
      ALGBRC(76) = ( CONSTS(38)*STATES(12))/(CONSTS(37)+STATES(12))
      ALGBRC(77) =  CONSTS(39)*(STATES(1) - ALGBRC(24))
      ALGBRC(80) =  CONSTS(40)*(STATES(1) - ALGBRC(78))
      ALGBRC(83) = ( (( CONSTS(73)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(12)*STATES(2)*EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(13)*CONSTS(11)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(85) = ( ALGBRC(83)*1.00000)/(1.00000+CONSTS(44)/STATES(12) ** 3.00000)
      ALGBRC(87) = ALGBRC(85)+ALGBRC(86)
      RATES(1) =  (- 1.00000/CONSTS(4))*(ALGBRC(31)+ALGBRC(54)+ALGBRC(79)+ALGBRC(58)+ALGBRC(62)+ALGBRC(72)+ALGBRC(73)+ALGBRC(75)+ALGBRC(67)+ALGBRC(69)+ALGBRC(88)+ALGBRC(76)+ALGBRC(77)+ALGBRC(80)+ALGBRC(82)+ALGBRC(87)+ALGBRC(12))
      RATES(32) = TERNRY(STATES(29).GT.0.200000, ( - CONSTS(58)*(((ALGBRC(48)+ALGBRC(79)) - ALGBRC(88))+ALGBRC(76)+ALGBRC(80)))/( 2.00000*CONSTS(77)*CONSTS(3)), TERNRY(STATES(30).GT.0.0100000.AND.STATES(29).LE.0.200000, 0.00000,  - 500.000*STATES(32))
      RATES(2) = ( - (ALGBRC(31)+ALGBRC(50)+ALGBRC(77)+ALGBRC(85)+ ALGBRC(88)*3.00000+ ALGBRC(82)*3.00000)*CONSTS(58))/( CONSTS(77)*CONSTS(3))
      ALGBRC(89) =  (- 1.00000/CONSTS(4))*(ALGBRC(31)+ALGBRC(54)+ALGBRC(79)+ALGBRC(58)+ALGBRC(62)+ALGBRC(72)+ALGBRC(73)+ALGBRC(75)+ALGBRC(67)+ALGBRC(69)+ALGBRC(88)+ALGBRC(76)+ALGBRC(77)+ALGBRC(80)+ALGBRC(82)+ALGBRC(87)+ALGBRC(12))
      RATES(29) = TERNRY(ALGBRC(89).GT.150000.,  100000.*(1.00000 - STATES(29)) -  500.000*STATES(29),  - 500.000*STATES(29))
      ALGBRC(90) = TERNRY(STATES(32).GT.CONSTS(52),  (( CONSTS(48)*(STATES(32) - CONSTS(52)))/((CONSTS(51)+STATES(32)) - CONSTS(52)))*(1.00000 - STATES(30))*STATES(30), TERNRY(STATES(32).LE.CONSTS(52).AND.STATES(34).GT.0.00000,  CONSTS(49)*(1.00000 - STATES(34))*STATES(34), 0.00000)
      ALGBRC(91) =  ALGBRC(90)*(STATES(27) - STATES(12))
      ALGBRC(92) = ( CONSTS(56)*STATES(12))/(STATES(12)+CONSTS(55))
      ALGBRC(93) =  CONSTS(74)*STATES(28)
      RATES(12) =  (1.00000/(1.00000+( CONSTS(62)*CONSTS(60))/CONSTS(60)+STATES(12) ** 2.00000+( CONSTS(61)*CONSTS(59))/CONSTS(59)+STATES(12) ** 2.00000))*(( - CONSTS(58)*(((ALGBRC(48)+ALGBRC(79)) -  2.00000*ALGBRC(88))+ALGBRC(76)+ALGBRC(80)))/( 2.00000*CONSTS(77)*CONSTS(3))+( ALGBRC(91)*CONSTS(79))/CONSTS(77)+( (ALGBRC(93) - ALGBRC(92))*CONSTS(80))/CONSTS(77))
      ALGBRC(94) = (STATES(28) - STATES(27))/CONSTS(50)
      RATES(27) =  (1.00000/(1.00000+( CONSTS(53)*CONSTS(54))/CONSTS(54)+STATES(27) ** 2.00000))*(ALGBRC(94) - ALGBRC(91))
      RATES(28) = (( - ALGBRC(94)*CONSTS(79))/CONSTS(80) - ALGBRC(93))+ALGBRC(92)
      RETURN
      END
      SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      ALGBRC(4) = 1.00000/(1.00000+EXP(- (STATES(1)+14.0000)/10.8000))
      ALGBRC(16) = 0.00370000+0.00610000/(1.00000+EXP((STATES(1)+25.0000)/4.50000))
      ALGBRC(5) = 1.00000/(1.00000+EXP((STATES(1)+60.0000)/5.60000))
      ALGBRC(17) = TERNRY(STATES(1).LE.0.00000,  - 0.000875000*STATES(1)+0.0120000, 0.0120000)
      ALGBRC(6) =  55.5000*EXP( 0.0554715*(STATES(1) - 12.0000))
      ALGBRC(18) =  2.35700*EXP( - 0.0365880*STATES(1))
      ALGBRC(8) = 1.00000/(1.00000+EXP(- (STATES(1) - 1.50000)/16.7000))
      ALGBRC(20) = 0.00100000/(( 7.19000e-05*(STATES(1)+30.0000))/(1.00000 - EXP( - 0.148000*(STATES(1)+30.0000)))+( 0.000131000*(STATES(1)+30.0000))/(EXP( 0.0687000*(STATES(1)+30.0000)) - 1.00000))
      ALGBRC(9) = 1.00000/(1.00000+EXP(- (STATES(1) - 1.50000)/16.7000))
      ALGBRC(21) = ( 4.00000*0.00100000)/(( 7.19000e-05*(STATES(1)+30.0000))/(1.00000 - EXP( - 0.148000*(STATES(1)+30.0000)))+( 0.000131000*(STATES(1)+30.0000))/(EXP( 0.0687000*(STATES(1)+30.0000)) - 1.00000))
      ALGBRC(3) = 1.00000/(1.00000+EXP((STATES(1)+32.0000)/8.00000))+0.600000/(1.00000+EXP((50.0000 - STATES(1))/20.0000))
      ALGBRC(15) = 0.00100000/( 0.0197000*EXP(-  0.0337000*(STATES(1)+10.0000) ** 2.00000)+0.0200000)
      ALGBRC(27) = ALGBRC(3)/ALGBRC(15)
      ALGBRC(34) = (1.00000 - ALGBRC(3))/ALGBRC(15)
      ALGBRC(7) =  65.5000*EXP( 0.0554715*(STATES(1) - 36.0000))
      ALGBRC(19) =  2.93570*EXP( - 0.0215800*STATES(1))
      ALGBRC(28) = ( 439.000*EXP( - 0.0235200*(STATES(1)+25.0000))*4.50000)/CONSTS(22)
      ALGBRC(35) = ( 656.000*EXP( 0.000942000*STATES(1))*4.50000 ** 0.300000)/CONSTS(22) ** 0.300000
      ALGBRC(10) = ( 10000.0*EXP((STATES(1) - 40.0000)/25.0000))/(1.00000+EXP((STATES(1) - 40.0000)/25.0000))
      ALGBRC(22) = ( 10000.0*EXP(- (STATES(1)+90.0000)/25.0000))/(1.00000+EXP(- (STATES(1)+90.0000)/25.0000))
      ALGBRC(29) = 1.00000/(ALGBRC(10)+ALGBRC(22))
      ALGBRC(36) = ALGBRC(10)/(ALGBRC(10)+ALGBRC(22))
      ALGBRC(11) = 15.0000/(1.00000+EXP((STATES(1)+60.0000)/5.00000))
      ALGBRC(23) = ( 100.000*EXP((STATES(1)+25.0000)/5.00000))/(1.00000+EXP((STATES(1)+25.0000)/5.00000))
      ALGBRC(30) = 1.00000/(ALGBRC(11)+ALGBRC(23))
      ALGBRC(37) = ALGBRC(11)/(ALGBRC(11)+ALGBRC(23))
      ALGBRC(2) = STATES(1)+10.0000
      ALGBRC(14) = 1.00000/(1.00000+EXP(- ALGBRC(2)/6.24000))
      ALGBRC(26) = TERNRY(ABS(ALGBRC(2)).LT.1.00000e-05, 0.00100000/( 0.0350000*6.24000), ( 0.00100000*ALGBRC(14)*(1.00000 - EXP(- ALGBRC(2)/6.24000)))/( 0.0350000*ALGBRC(2)))
      ALGBRC(33) = ALGBRC(14)/ALGBRC(26)
      ALGBRC(40) = (1.00000 - ALGBRC(14))/ALGBRC(26)
      ALGBRC(41) = ( ALGBRC(28)*ALGBRC(19)*ALGBRC(7))/( ALGBRC(7)*ALGBRC(35))
      ALGBRC(1) = 3802.00/( 0.102700*EXP(- STATES(1)/17.0000)+ 0.200000*EXP(- STATES(1)/150.000))
      ALGBRC(32) =  191.700*EXP(- STATES(1)/20.3000)
      ALGBRC(47) =  0.000379330*EXP(- STATES(1)/7.70000)
      ALGBRC(49) = 8.40000+ 0.0200000*STATES(1)
      ALGBRC(13) = 3802.00/( 0.102700*EXP(- STATES(1)/15.0000)+ 0.230000*EXP(- STATES(1)/150.000))
      ALGBRC(39) =  200.000*EXP(- (STATES(1) - 5.00000)/20.3000)
      ALGBRC(25) = 3802.00/( 0.102700*EXP(- STATES(1)/12.0000)+ 0.250000*EXP(- STATES(1)/150.000))
      ALGBRC(43) =  220.000*EXP(- (STATES(1) - 10.0000)/20.3000)
      ALGBRC(45) =  9178.00*EXP(STATES(1)/29.6800)
      ALGBRC(51) = ( ALGBRC(25)*ALGBRC(45)*ALGBRC(47))/( ALGBRC(43)*ALGBRC(49))
      ALGBRC(53) = ALGBRC(45)/100.000
      ALGBRC(55) = ALGBRC(47)
      ALGBRC(57) = ALGBRC(45)/95000.0
      ALGBRC(59) = ALGBRC(47)/50.0000
      ALGBRC(56) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(22)/STATES(13))
      ALGBRC(58) =  CONSTS(67)*STATES(18)*(STATES(1) - ALGBRC(56))
      ALGBRC(61) =  0.968000*0.433000*(1.00000+0.600000/(1.00000+3.80000e-05/STATES(12) ** 1.40000))
      ALGBRC(60) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log((CONSTS(22)+ CONSTS(27)*CONSTS(11))/(STATES(13)+ CONSTS(27)*STATES(2)))
      ALGBRC(62) =  ALGBRC(61)*STATES(23)*STATES(24)*(STATES(1) - ALGBRC(60))
      ALGBRC(63) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(22)/STATES(13))
      ALGBRC(70) = 0.850000/(1.00000+CONSTS(30)/STATES(2) ** CONSTS(29))
      ALGBRC(71) = 0.800000 - 0.650000/(1.00000+EXP((STATES(1)+125.000)/15.0000))
      ALGBRC(72) =  CONSTS(69)*ALGBRC(70)*ALGBRC(71)*(STATES(1) - ALGBRC(63))
      ALGBRC(73) =  CONSTS(78)*(STATES(1) - ALGBRC(63))
      ALGBRC(74) = EXP(STATES(1)/100.000)
      ALGBRC(75) =  CONSTS(71)*STATES(25) ** 3.00000*STATES(26)*ALGBRC(74)*(STATES(1) - ALGBRC(63))
      ALGBRC(64) = 1020.00/(1.00000+EXP( 0.238500*((STATES(1) - ALGBRC(63)) - 59.2150)))
      ALGBRC(65) = ( 1000.00*( 0.491240*EXP( 0.0803200*((STATES(1) - ALGBRC(63))+5.47600))+EXP( 0.0617500*((STATES(1) - ALGBRC(63)) - 594.310))))/(1.00000+EXP( - 0.514300*((STATES(1) - ALGBRC(63))+4.75300)))
      ALGBRC(66) = ALGBRC(64)/(ALGBRC(64)+ALGBRC(65))
      ALGBRC(67) =  CONSTS(68)*ALGBRC(66)*(STATES(1) - ALGBRC(63))
      ALGBRC(68) = 1.00000/(1.00000+EXP((7.48800 - STATES(1))/5.98000))
      ALGBRC(69) =  CONSTS(28)*ALGBRC(68)*(STATES(1) - ALGBRC(63))
      ALGBRC(81) = 1.00000/(1.00000+ 0.124500*EXP(( - 0.100000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))+ 0.0365000*CONSTS(72)*EXP(( - STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))))
      ALGBRC(82) = ( (( CONSTS(41)*ALGBRC(81)*1.00000)/(1.00000+CONSTS(42)/STATES(2) ** 2.00000))*CONSTS(22))/(CONSTS(22)+CONSTS(43))
      ALGBRC(44) = ( (( CONSTS(18)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(14)*STATES(13)*EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(15)*CONSTS(22)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(46) = 1.00000/(1.00000+STATES(12)/CONSTS(23))
      ALGBRC(52) =  STATES(14)*STATES(15)*ALGBRC(46)*ALGBRC(44)
      ALGBRC(84) = ( (( CONSTS(73)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(14)*STATES(13)*EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(15)*CONSTS(22)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(86) = ( ALGBRC(84)*1.00000)/(1.00000+CONSTS(44)/STATES(12) ** 3.00000)
      ALGBRC(12) = TERNRY(VOI.GE.CONSTS(5).AND.VOI.LE.CONSTS(6).AND.(VOI - CONSTS(5)) -  INT((VOI - CONSTS(5))/CONSTS(7))*CONSTS(7).LE.CONSTS(8), CONSTS(9), 0.00000)
      ALGBRC(24) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(11)/STATES(2))
      ALGBRC(31) =  CONSTS(10)*STATES(3)*(STATES(1) - ALGBRC(24))
      ALGBRC(38) = ( (( CONSTS(16)*2.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(19)*STATES(12)*EXP(( 2.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(20)*CONSTS(21)))/(EXP(( 2.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(48) =  STATES(14)*STATES(15)*ALGBRC(46)*ALGBRC(38)
      ALGBRC(42) = ( (( CONSTS(17)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(12)*STATES(2)*EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(13)*CONSTS(11)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(50) =  STATES(14)*STATES(15)*ALGBRC(46)*ALGBRC(42)
      ALGBRC(54) = ALGBRC(48)+ALGBRC(52)+ALGBRC(50)
      ALGBRC(78) =  (( CONSTS(1)*CONSTS(2))/( 2.00000*CONSTS(3)))*log(CONSTS(21)/STATES(12))
      ALGBRC(79) =  CONSTS(24)*STATES(16)*STATES(16)*STATES(17)*(STATES(1) - ALGBRC(78))
      ALGBRC(88) = ( CONSTS(45)*EXP(( (CONSTS(47) - 1.00000)*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*( EXP(( STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*STATES(2) ** 3.00000*CONSTS(21) -  CONSTS(11) ** 3.00000*STATES(12)))/(1.00000+ CONSTS(46)*EXP(( (CONSTS(47) - 1.00000)*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*( EXP(( STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*STATES(2) ** 3.00000*CONSTS(21)+ CONSTS(11) ** 3.00000*STATES(12)))
      ALGBRC(76) = ( CONSTS(38)*STATES(12))/(CONSTS(37)+STATES(12))
      ALGBRC(77) =  CONSTS(39)*(STATES(1) - ALGBRC(24))
      ALGBRC(80) =  CONSTS(40)*(STATES(1) - ALGBRC(78))
      ALGBRC(83) = ( (( CONSTS(73)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(12)*STATES(2)*EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) -  CONSTS(13)*CONSTS(11)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(85) = ( ALGBRC(83)*1.00000)/(1.00000+CONSTS(44)/STATES(12) ** 3.00000)
      ALGBRC(87) = ALGBRC(85)+ALGBRC(86)
      ALGBRC(89) =  (- 1.00000/CONSTS(4))*(ALGBRC(31)+ALGBRC(54)+ALGBRC(79)+ALGBRC(58)+ALGBRC(62)+ALGBRC(72)+ALGBRC(73)+ALGBRC(75)+ALGBRC(67)+ALGBRC(69)+ALGBRC(88)+ALGBRC(76)+ALGBRC(77)+ALGBRC(80)+ALGBRC(82)+ALGBRC(87)+ALGBRC(12))
      ALGBRC(90) = TERNRY(STATES(32).GT.CONSTS(52),  (( CONSTS(48)*(STATES(32) - CONSTS(52)))/((CONSTS(51)+STATES(32)) - CONSTS(52)))*(1.00000 - STATES(30))*STATES(30), TERNRY(STATES(32).LE.CONSTS(52).AND.STATES(34).GT.0.00000,  CONSTS(49)*(1.00000 - STATES(34))*STATES(34), 0.00000)
      ALGBRC(91) =  ALGBRC(90)*(STATES(27) - STATES(12))
      ALGBRC(92) = ( CONSTS(56)*STATES(12))/(STATES(12)+CONSTS(55))
      ALGBRC(93) =  CONSTS(74)*STATES(28)
      ALGBRC(94) = (STATES(28) - STATES(27))/CONSTS(50)
      RETURN
      END
      REAL FUNCTION TERNRY(TEST, VALA, VALB)
      LOGICAL TEST
      REAL VALA, VALB
      IF (TEST) THEN
        TERNRY = VALA
      ELSE
        TERNRY = VALB
      ENDIF
      RETURN
      END
Source
Derived from workspace Clancy, Rudy, 2002 at changeset 2bd2a331ca0c.
Collaboration
To begin collaborating on this work, please use your git client and issue this command:
License

This work is licensed under a Creative Commons Attribution 3.0 Unported License.