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 79 entries in the algebraic variable array.
C There are a total of 25 entries in each of the rate and state variable arrays.
C There are a total of 75 entries in the constant variable array.
C
C
C VOI is time in component environment (ms).
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 ALGBRC(13) is I_st in component membrane (microA_per_microF).
C ALGBRC(32) is i_Na in component fast_sodium_current (microA_per_microF).
C ALGBRC(45) is i_Ca_L in component L_type_Ca_channel (microA_per_microF).
C ALGBRC(64) is i_Ca_T in component T_type_Ca_channel (microA_per_microF).
C ALGBRC(51) is i_Kr in component rapid_delayed_rectifier_potassium_current (microA_per_microF).
C ALGBRC(49) is i_Ks in component slow_delayed_rectifier_potassium_current (microA_per_microF).
C ALGBRC(58) is i_K_ATP in component ATP_sensitive_potassium_current (microA_per_microF).
C ALGBRC(60) is i_to in component transient_outward_current (microA_per_microF).
C ALGBRC(55) is i_K1 in component time_independent_potassium_current (microA_per_microF).
C ALGBRC(57) is i_Kp in component plateau_potassium_current (microA_per_microF).
C ALGBRC(61) is i_p_Ca in component sarcolemmal_calcium_pump (microA_per_microF).
C ALGBRC(62) is i_Na_b in component sodium_background_current (microA_per_microF).
C ALGBRC(65) is i_Ca_b in component calcium_background_current (microA_per_microF).
C ALGBRC(67) is i_NaK in component sodium_potassium_pump (microA_per_microF).
C ALGBRC(73) is i_NaCa in component Na_Ca_exchanger (microA_per_microF).
C ALGBRC(72) is i_ns_Ca in component non_specific_calcium_activated_current (microA_per_microF).
C ALGBRC(74) is dVdt in component membrane (millivolt_per_ms).
C CONSTS(4) is stim_start in component membrane (ms).
C CONSTS(5) is stim_end in component membrane (ms).
C CONSTS(6) is stim_period in component membrane (ms).
C CONSTS(7) is stim_duration in component membrane (ms).
C CONSTS(8) is stim_amplitude in component membrane (microA_per_microF).
C ALGBRC(26) is E_Na in component fast_sodium_current (millivolt).
C CONSTS(9) is g_Na in component fast_sodium_current (milliS_per_microF).
C STATES(2) is Nai in component ionic_concentrations (millimolar).
C CONSTS(10) is Nao in component ionic_concentrations (millimolar).
C STATES(3) is m in component fast_sodium_current_m_gate (dimensionless).
C STATES(4) is h in component fast_sodium_current_h_gate (dimensionless).
C STATES(5) is j in component fast_sodium_current_j_gate (dimensionless).
C ALGBRC(14) is alpha_m in component fast_sodium_current_m_gate (per_ms).
C ALGBRC(27) is beta_m in component fast_sodium_current_m_gate (per_ms).
C CONSTS(11) is delta_m in component fast_sodium_current_m_gate (millivolt).
C ALGBRC(1) is E0_m in component fast_sodium_current_m_gate (millivolt).
C ALGBRC(2) is alpha_h in component fast_sodium_current_h_gate (per_ms).
C ALGBRC(15) is beta_h in component fast_sodium_current_h_gate (per_ms).
C ALGBRC(3) is alpha_j in component fast_sodium_current_j_gate (per_ms).
C ALGBRC(16) is beta_j in component fast_sodium_current_j_gate (per_ms).
C ALGBRC(42) 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(43) 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(37) is I_CaCa in component L_type_Ca_channel (microA_per_microF).
C ALGBRC(40) is I_CaK in component L_type_Ca_channel (microA_per_microF).
C ALGBRC(39) is I_CaNa in component L_type_Ca_channel (microA_per_microF).
C CONSTS(16) is P_Ca in component L_type_Ca_channel (litre_per_farad_ms).
C CONSTS(17) is P_Na in component L_type_Ca_channel (litre_per_farad_ms).
C CONSTS(18) is P_K in component L_type_Ca_channel (litre_per_farad_ms).
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(6) 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(7) is Ki in component ionic_concentrations (millimolar).
C STATES(8) is d in component L_type_Ca_channel_d_gate (dimensionless).
C STATES(9) is f in component L_type_Ca_channel_f_gate (dimensionless).
C ALGBRC(41) 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_ms).
C ALGBRC(38) is beta_d in component L_type_Ca_channel_d_gate (per_ms).
C ALGBRC(17) is d_infinity in component L_type_Ca_channel_d_gate (dimensionless).
C ALGBRC(28) is tau_d in component L_type_Ca_channel_d_gate (ms).
C ALGBRC(4) is E0_d in component L_type_Ca_channel_d_gate (millivolt).
C ALGBRC(29) is alpha_f in component L_type_Ca_channel_f_gate (per_ms).
C ALGBRC(34) is beta_f in component L_type_Ca_channel_f_gate (per_ms).
C ALGBRC(5) is f_infinity in component L_type_Ca_channel_f_gate (dimensionless).
C ALGBRC(18) is tau_f in component L_type_Ca_channel_f_gate (ms).
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(63) is E_Ca in component calcium_background_current (millivolt).
C STATES(10) is b in component T_type_Ca_channel_b_gate (dimensionless).
C STATES(11) is g in component T_type_Ca_channel_g_gate (dimensionless).
C ALGBRC(6) is b_inf in component T_type_Ca_channel_b_gate (dimensionless).
C ALGBRC(19) is tau_b in component T_type_Ca_channel_b_gate (ms).
C ALGBRC(7) is g_inf in component T_type_Ca_channel_g_gate (dimensionless).
C ALGBRC(20) is tau_g in component T_type_Ca_channel_g_gate (ms).
C CONSTS(63) is g_Kr in component rapid_delayed_rectifier_potassium_current (milliS_per_microF).
C ALGBRC(46) is Rect in component rapid_delayed_rectifier_potassium_current (dimensionless).
C ALGBRC(50) is E_K in component time_independent_potassium_current (millivolt).
C STATES(12) is xr in component rapid_delayed_rectifier_potassium_current_xr_gate (dimensionless).
C ALGBRC(8) is xr_infinity in component rapid_delayed_rectifier_potassium_current_xr_gate (dimensionless).
C ALGBRC(21) is tau_xr in component rapid_delayed_rectifier_potassium_current_xr_gate (ms).
C ALGBRC(48) is g_Ks in component slow_delayed_rectifier_potassium_current (milliS_per_microF).
C ALGBRC(47) is E_Ks in component slow_delayed_rectifier_potassium_current (millivolt).
C CONSTS(25) is PNaK in component slow_delayed_rectifier_potassium_current (dimensionless).
C STATES(13) is xs1 in component slow_delayed_rectifier_potassium_current_xs1_gate (dimensionless).
C STATES(14) is xs2 in component slow_delayed_rectifier_potassium_current_xs2_gate (dimensionless).
C ALGBRC(9) is xs1_infinity in component slow_delayed_rectifier_potassium_current_xs1_gate (dimensionless).
C ALGBRC(22) is tau_xs1 in component slow_delayed_rectifier_potassium_current_xs1_gate (ms).
C ALGBRC(10) is xs2_infinity in component slow_delayed_rectifier_potassium_current_xs2_gate (dimensionless).
C ALGBRC(23) is tau_xs2 in component slow_delayed_rectifier_potassium_current_xs2_gate (ms).
C CONSTS(64) is g_K1 in component time_independent_potassium_current (milliS_per_microF).
C ALGBRC(54) is K1_infinity in component time_independent_potassium_current_K1_gate (dimensionless).
C ALGBRC(52) is alpha_K1 in component time_independent_potassium_current_K1_gate (per_ms).
C ALGBRC(53) is beta_K1 in component time_independent_potassium_current_K1_gate (per_ms).
C CONSTS(26) is g_Kp in component plateau_potassium_current (milliS_per_microF).
C ALGBRC(56) is Kp in component plateau_potassium_current (dimensionless).
C CONSTS(65) is g_K_ATP in component ATP_sensitive_potassium_current (milliS_per_microF).
C CONSTS(27) is nATP in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(28) is nicholsarea in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(29) is ATPi in component ATP_sensitive_potassium_current (millimolar).
C CONSTS(30) is hATP in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(31) is kATP in component ATP_sensitive_potassium_current (millimolar).
C CONSTS(71) is pATP in component ATP_sensitive_potassium_current (dimensionless).
C CONSTS(73) is GKbaraATP in component ATP_sensitive_potassium_current (milliS_per_microF).
C CONSTS(66) is g_to in component transient_outward_current (milliS_per_microF).
C ALGBRC(59) is rvdv in component transient_outward_current (dimensionless).
C STATES(15) is zdv in component transient_outward_current_zdv_gate (dimensionless).
C STATES(16) is ydv in component transient_outward_current_ydv_gate (dimensionless).
C ALGBRC(11) is alpha_zdv in component transient_outward_current_zdv_gate (per_ms).
C ALGBRC(24) is beta_zdv in component transient_outward_current_zdv_gate (per_ms).
C ALGBRC(30) is tau_zdv in component transient_outward_current_zdv_gate (ms).
C ALGBRC(35) is zdv_ss in component transient_outward_current_zdv_gate (dimensionless).
C ALGBRC(12) is alpha_ydv in component transient_outward_current_ydv_gate (per_ms).
C ALGBRC(25) is beta_ydv in component transient_outward_current_ydv_gate (per_ms).
C ALGBRC(31) is tau_ydv in component transient_outward_current_ydv_gate (ms).
C ALGBRC(36) is ydv_ss in component transient_outward_current_ydv_gate (dimensionless).
C CONSTS(32) is K_mpCa in component sarcolemmal_calcium_pump (millimolar).
C CONSTS(33) is I_pCa in component sarcolemmal_calcium_pump (microA_per_microF).
C CONSTS(34) is g_Nab in component sodium_background_current (milliS_per_microF).
C CONSTS(35) is g_Cab in component calcium_background_current (milliS_per_microF).
C CONSTS(36) is I_NaK in component sodium_potassium_pump (microA_per_microF).
C ALGBRC(66) is f_NaK in component sodium_potassium_pump (dimensionless).
C CONSTS(37) is K_mNai in component sodium_potassium_pump (millimolar).
C CONSTS(38) is K_mKo in component sodium_potassium_pump (millimolar).
C CONSTS(67) is sigma in component sodium_potassium_pump (dimensionless).
C ALGBRC(70) is i_ns_Na in component non_specific_calcium_activated_current (microA_per_microF).
C ALGBRC(71) is i_ns_K in component non_specific_calcium_activated_current (microA_per_microF).
C CONSTS(68) is P_ns_Ca in component non_specific_calcium_activated_current (litre_per_farad_ms).
C ALGBRC(68) is I_ns_Na in component non_specific_calcium_activated_current (microA_per_microF).
C ALGBRC(69) is I_ns_K in component non_specific_calcium_activated_current (microA_per_microF).
C CONSTS(39) is K_m_ns_Ca in component non_specific_calcium_activated_current (millimolar).
C CONSTS(40) is n_NaCa in component Na_Ca_exchanger (dimensionless).
C CONSTS(41) is K_NaCa in component Na_Ca_exchanger (microA_per_microF).
C CONSTS(42) is d_NaCa in component Na_Ca_exchanger (dimensionless).
C CONSTS(43) is gamma in component Na_Ca_exchanger (dimensionless).
C ALGBRC(76) is i_rel in component calcium_dynamics (millimolar_per_ms).
C ALGBRC(77) is i_up in component calcium_dynamics (millimolar_per_ms).
C ALGBRC(78) is i_leak in component calcium_dynamics (millimolar_per_ms).
C ALGBRC(79) is i_tr in component calcium_dynamics (millimolar_per_ms).
C ALGBRC(75) is G_rel in component calcium_dynamics (per_ms).
C CONSTS(44) is G_rel_max in component calcium_dynamics (per_ms).
C CONSTS(45) is G_rel_overload in component calcium_dynamics (per_ms).
C CONSTS(46) is tau_tr in component calcium_dynamics (ms).
C CONSTS(47) is K_mrel in component calcium_dynamics (millimolar).
C CONSTS(48) is delta_Ca_ith in component calcium_dynamics (millimolar).
C CONSTS(49) is CSQN_max in component calcium_dynamics (millimolar).
C CONSTS(50) is K_mCSQN in component calcium_dynamics (millimolar).
C CONSTS(51) is K_mup in component calcium_dynamics (millimolar).
C CONSTS(69) is K_leak in component calcium_dynamics (per_ms).
C CONSTS(52) is I_up in component calcium_dynamics (millimolar_per_ms).
C CONSTS(53) is Ca_NSR_max in component calcium_dynamics (millimolar).
C STATES(17) is Ca_JSR in component calcium_dynamics (millimolar).
C STATES(18) is Ca_NSR in component calcium_dynamics (millimolar).
C CONSTS(72) is V_myo in component ionic_concentrations (micro_litre).
C CONSTS(54) is A_cap in component ionic_concentrations (cm2).
C CONSTS(74) is V_JSR in component calcium_dynamics (micro_litre).
C CONSTS(75) is V_NSR in component calcium_dynamics (micro_litre).
C CONSTS(55) is K_mTn in component calcium_dynamics (millimolar).
C CONSTS(56) is K_mCMDN in component calcium_dynamics (millimolar).
C CONSTS(57) is Tn_max in component calcium_dynamics (millimolar).
C CONSTS(58) is CMDN_max in component calcium_dynamics (millimolar).
C STATES(19) is APtrack in component calcium_dynamics (dimensionless).
C STATES(20) is APtrack2 in component calcium_dynamics (dimensionless).
C STATES(21) is APtrack3 in component calcium_dynamics (dimensionless).
C STATES(22) is Cainfluxtrack in component calcium_dynamics (millimolar).
C STATES(23) is OVRLDtrack in component calcium_dynamics (dimensionless).
C STATES(24) is OVRLDtrack2 in component calcium_dynamics (dimensionless).
C STATES(25) is OVRLDtrack3 in component calcium_dynamics (dimensionless).
C CONSTS(59) is CSQNthresh in component calcium_dynamics (dimensionless).
C CONSTS(60) is Logicthresh in component calcium_dynamics (dimensionless).
C CONSTS(61) is preplength in component ionic_concentrations (mm).
C CONSTS(62) is radius in component ionic_concentrations (mm).
C CONSTS(70) is volume in component ionic_concentrations (micro_litre).
C RATES(1) is d/dt V in component membrane (millivolt).
C RATES(3) is d/dt m in component fast_sodium_current_m_gate (dimensionless).
C RATES(4) is d/dt h in component fast_sodium_current_h_gate (dimensionless).
C RATES(5) is d/dt j in component fast_sodium_current_j_gate (dimensionless).
C RATES(8) is d/dt d in component L_type_Ca_channel_d_gate (dimensionless).
C RATES(9) is d/dt f in component L_type_Ca_channel_f_gate (dimensionless).
C RATES(10) is d/dt b in component T_type_Ca_channel_b_gate (dimensionless).
C RATES(11) is d/dt g in component T_type_Ca_channel_g_gate (dimensionless).
C RATES(12) is d/dt xr in component rapid_delayed_rectifier_potassium_current_xr_gate (dimensionless).
C RATES(13) is d/dt xs1 in component slow_delayed_rectifier_potassium_current_xs1_gate (dimensionless).
C RATES(14) is d/dt xs2 in component slow_delayed_rectifier_potassium_current_xs2_gate (dimensionless).
C RATES(15) is d/dt zdv in component transient_outward_current_zdv_gate (dimensionless).
C RATES(16) is d/dt ydv in component transient_outward_current_ydv_gate (dimensionless).
C RATES(19) is d/dt APtrack in component calcium_dynamics (dimensionless).
C RATES(20) is d/dt APtrack2 in component calcium_dynamics (dimensionless).
C RATES(21) is d/dt APtrack3 in component calcium_dynamics (dimensionless).
C RATES(22) is d/dt Cainfluxtrack in component calcium_dynamics (millimolar).
C RATES(23) is d/dt OVRLDtrack in component calcium_dynamics (dimensionless).
C RATES(24) is d/dt OVRLDtrack2 in component calcium_dynamics (dimensionless).
C RATES(25) is d/dt OVRLDtrack3 in component calcium_dynamics (dimensionless).
C RATES(17) is d/dt Ca_JSR in component calcium_dynamics (millimolar).
C RATES(18) is d/dt Ca_NSR in component calcium_dynamics (millimolar).
C RATES(6) is d/dt Cai in component calcium_dynamics (millimolar).
C RATES(2) is d/dt Nai in component ionic_concentrations (millimolar).
C RATES(7) is d/dt Ki in component ionic_concentrations (millimolar).
C
      SUBROUTINE initConsts(CONSTS, RATES, STATES)
      REAL CONSTS(*), RATES(*), STATES(*)
      STATES(1) = -88.5004
      CONSTS(1) = 8314
      CONSTS(2) = 310
      CONSTS(3) = 96485
      CONSTS(4) = 100
      CONSTS(5) = 99999000
      CONSTS(6) = 1000
      CONSTS(7) = 2
      CONSTS(8) = -25.5
      CONSTS(9) = 16
      STATES(2) = 14.177596
      CONSTS(10) = 132
      STATES(3) = 0.0008601
      STATES(4) = 0.992806
      STATES(5) = 0.99511469
      CONSTS(11) = 1e-5
      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(6) = 0.00034209
      CONSTS(21) = 1.8
      CONSTS(22) = 4.5
      STATES(7) = 138.37949
      STATES(8) = 3.538268e-6
      STATES(9) = 0.995259
      CONSTS(23) = 0.0006
      CONSTS(24) = 0.05
      STATES(10) = 0.0010301
      STATES(11) = 0.9341828
      STATES(12) = 0.0007500578
      CONSTS(25) = 0.01833
      STATES(13) = 0.0421517
      STATES(14) = 0.08866
      CONSTS(26) = 0.00552
      CONSTS(27) = 0.24
      CONSTS(28) = 5e-5
      CONSTS(29) = 3
      CONSTS(30) = 2
      CONSTS(31) = 0.00025
      STATES(15) = 0.01198974
      STATES(16) = 0.97497
      CONSTS(32) = 0.0005
      CONSTS(33) = 1.15
      CONSTS(34) = 0.004
      CONSTS(35) = 0.003016
      CONSTS(36) = 2
      CONSTS(37) = 10
      CONSTS(38) = 1.5
      CONSTS(39) = 0.0012
      CONSTS(40) = 3
      CONSTS(41) = 0.002
      CONSTS(42) = 0.001
      CONSTS(43) = 0.5
      CONSTS(44) = 60000
      CONSTS(45) = 4000
      CONSTS(46) = 0.18
      CONSTS(47) = 0.0008
      CONSTS(48) = 0.00018
      CONSTS(49) = 10
      CONSTS(50) = 0.8
      CONSTS(51) = 0.00092
      CONSTS(52) = 5
      CONSTS(53) = 15
      STATES(17) = 0.8204291
      STATES(18) = 2.7872629
      CONSTS(54) = 1.434e-7
      CONSTS(55) = 0.0005
      CONSTS(56) = 0.00238
      CONSTS(57) = 0.07
      CONSTS(58) = 0.05
      STATES(19) = 3.7458e-87
      STATES(20) = 2.07066e-86
      STATES(21) = 0.01924195
      STATES(22) = 1.660129e-87
      STATES(23) = 1.97626e-323
      STATES(24) = -2.470328e-323
      STATES(25) = 2.2645e-282
      CONSTS(59) = 0.7
      CONSTS(60) = 0.98
      CONSTS(61) = 0.001
      CONSTS(62) = 1.1e-4
      CONSTS(63) =  0.0261400* (CONSTS(22)/5.40000) ** (1.0 / 2)
      CONSTS(64) =  0.750000* (CONSTS(22)/5.40000) ** (1.0 / 2)
      CONSTS(65) = 0.000193000/CONSTS(28)
      CONSTS(66) =  0.00000*0.500000
      CONSTS(67) =  (1.00000/7.00000)*(EXP(CONSTS(10)/67.3000) - 1.00000)
      CONSTS(68) =  0.00000*1.75000e-07
      CONSTS(69) = CONSTS(52)/CONSTS(53)
      CONSTS(70) =   3.14159265358979*CONSTS(61)*CONSTS(62) ** 2.00000
      CONSTS(71) = 1.00000/(1.00000+CONSTS(29)/CONSTS(31) ** CONSTS(30))
      CONSTS(72) =  0.680000*CONSTS(70)
      CONSTS(73) =  CONSTS(65)*CONSTS(71)*CONSTS(22)/4.00000 ** CONSTS(27)
      CONSTS(74) =  (0.00480000/0.680000)*CONSTS(72)
      CONSTS(75) =  (0.0552000/0.680000)*CONSTS(72)
      RETURN
      END
      SUBROUTINE computeRates(VOI, CONSTS,  RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      RATES(20) = TERNRY(STATES(19).LT.0.200000.AND.STATES(19).GT.0.180000,  100.000*(1.00000 - STATES(20)) -  0.500000*STATES(20),  - 0.500000*STATES(20))
      RATES(21) = TERNRY(STATES(19).LT.0.200000.AND.STATES(19).GT.0.180000,  100.000*(1.00000 - STATES(21)) -  0.500000*STATES(21),  - 0.0100000*STATES(21))
      RATES(23) = TERNRY(1.00000/(1.00000+CONSTS(50)/STATES(17)).GT.CONSTS(59).AND.STATES(25).LT.0.370000.AND.STATES(21).LT.0.370000,  50.0000*(1.00000 - STATES(23)),  - 0.500000*STATES(23))
      RATES(24) = TERNRY(STATES(23).GT.CONSTS(60).AND.STATES(24).LT.CONSTS(60),  50.0000*(1.00000 - STATES(24)),  - 0.500000*STATES(24))
      RATES(25) = TERNRY(STATES(23).GT.CONSTS(60).AND.STATES(25).LT.CONSTS(60),  50.0000*(1.00000 - STATES(25)),  - 0.0100000*STATES(25))
      ALGBRC(2) = TERNRY(STATES(1).LT.- 40.0000,  0.135000*EXP((80.0000+STATES(1))/- 6.80000), 0.00000)
      ALGBRC(15) = TERNRY(STATES(1).LT.- 40.0000,  3.56000*EXP( 0.0790000*STATES(1))+ 310000.*EXP( 0.350000*STATES(1)), 1.00000/( 0.130000*(1.00000+EXP((STATES(1)+10.6600)/- 11.1000))))
      RATES(4) =  ALGBRC(2)*(1.00000 - STATES(4)) -  ALGBRC(15)*STATES(4)
      ALGBRC(3) = TERNRY(STATES(1).LT.- 40.0000, ( - ( 127140.*EXP( 0.244400*STATES(1))+ 3.47400e-05*EXP( - 0.0439100*STATES(1)))*(STATES(1)+37.7800))/(1.00000+EXP( 0.311000*(STATES(1)+79.2300))), 0.00000)
      ALGBRC(16) = TERNRY(STATES(1).LT.- 40.0000, ( 0.121200*EXP( - 0.0105200*STATES(1)))/(1.00000+EXP( - 0.137800*(STATES(1)+40.1400))), ( 0.300000*EXP( - 2.53500e-07*STATES(1)))/(1.00000+EXP( - 0.100000*(STATES(1)+32.0000))))
      RATES(5) =  ALGBRC(3)*(1.00000 - STATES(5)) -  ALGBRC(16)*STATES(5)
      ALGBRC(6) = 1.00000/(1.00000+EXP(- (STATES(1)+14.0000)/10.8000))
      ALGBRC(19) = 3.70000+6.10000/(1.00000+EXP((STATES(1)+25.0000)/4.50000))
      RATES(10) = (ALGBRC(6) - STATES(10))/ALGBRC(19)
      ALGBRC(7) = 1.00000/(1.00000+EXP((STATES(1)+60.0000)/5.60000))
      ALGBRC(20) = TERNRY(STATES(1).LE.0.00000,  - 0.875000*STATES(1)+12.0000, 12.0000)
      RATES(11) = (ALGBRC(7) - STATES(11))/ALGBRC(20)
      ALGBRC(8) = 1.00000/(1.00000+EXP(- (STATES(1)+21.5000)/7.50000))
      ALGBRC(21) = 1.00000/(( 0.00138000*(STATES(1)+14.2000))/(1.00000 - EXP( - 0.123000*(STATES(1)+14.2000)))+( 0.000610000*(STATES(1)+38.9000))/(EXP( 0.145000*(STATES(1)+38.9000)) - 1.00000))
      RATES(12) = (ALGBRC(8) - STATES(12))/ALGBRC(21)
      ALGBRC(9) = 1.00000/(1.00000+EXP(- (STATES(1) - 1.50000)/16.7000))
      ALGBRC(22) = 1.00000/(( 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(13) = (ALGBRC(9) - STATES(13))/ALGBRC(22)
      ALGBRC(10) = 1.00000/(1.00000+EXP(- (STATES(1) - 1.50000)/16.7000))
      ALGBRC(23) = 4.00000/(( 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(14) = (ALGBRC(10) - STATES(14))/ALGBRC(23)
      ALGBRC(1) = STATES(1)+47.1300
      ALGBRC(14) = TERNRY(ABS(ALGBRC(1)).GE.CONSTS(11), ( 0.320000*ALGBRC(1))/(1.00000 - EXP( - 0.100000*ALGBRC(1))), 3.20000)
      ALGBRC(27) =  0.0800000*EXP(- STATES(1)/11.0000)
      RATES(3) =  ALGBRC(14)*(1.00000 - STATES(3)) -  ALGBRC(27)*STATES(3)
      ALGBRC(5) = 1.00000/(1.00000+EXP((STATES(1)+32.0000)/8.00000))+0.600000/(1.00000+EXP((50.0000 - STATES(1))/20.0000))
      ALGBRC(18) = 1.00000/( 0.0197000*EXP(-  0.0337000*(STATES(1)+10.0000) ** 2.00000)+0.0200000)
      ALGBRC(29) = ALGBRC(5)/ALGBRC(18)
      ALGBRC(34) = (1.00000 - ALGBRC(5))/ALGBRC(18)
      RATES(9) =  ALGBRC(29)*(1.00000 - STATES(9)) -  ALGBRC(34)*STATES(9)
      ALGBRC(11) = ( 10.0000*EXP((STATES(1) - 40.0000)/25.0000))/(1.00000+EXP((STATES(1) - 40.0000)/25.0000))
      ALGBRC(24) = ( 10.0000*EXP(- (STATES(1)+90.0000)/25.0000))/(1.00000+EXP(- (STATES(1)+90.0000)/25.0000))
      ALGBRC(30) = 1.00000/(ALGBRC(11)+ALGBRC(24))
      ALGBRC(35) = ALGBRC(11)/(ALGBRC(11)+ALGBRC(24))
      RATES(15) = (ALGBRC(35) - STATES(15))/ALGBRC(30)
      ALGBRC(12) = 0.0150000/(1.00000+EXP((STATES(1)+60.0000)/5.00000))
      ALGBRC(25) = ( 0.100000*EXP((STATES(1)+25.0000)/5.00000))/(1.00000+EXP((STATES(1)+25.0000)/5.00000))
      ALGBRC(31) = 1.00000/(ALGBRC(12)+ALGBRC(25))
      ALGBRC(36) = ALGBRC(12)/(ALGBRC(12)+ALGBRC(25))
      RATES(16) = (ALGBRC(36) - STATES(16))/ALGBRC(31)
      ALGBRC(4) = STATES(1)+10.0000
      ALGBRC(17) = 1.00000/(1.00000+EXP(- ALGBRC(4)/6.24000))
      ALGBRC(28) = TERNRY(ABS(ALGBRC(4)).LT.1.00000e-05, 1.00000/( 0.0350000*6.24000), ( ALGBRC(17)*(1.00000 - EXP(- ALGBRC(4)/6.24000)))/( 0.0350000*ALGBRC(4)))
      ALGBRC(33) = ALGBRC(17)/ALGBRC(28)
      ALGBRC(38) = (1.00000 - ALGBRC(17))/ALGBRC(28)
      RATES(8) =  ALGBRC(33)*(1.00000 - STATES(8)) -  ALGBRC(38)*STATES(8)
      ALGBRC(46) = 1.00000/(1.00000+EXP((STATES(1)+9.00000)/22.4000))
      ALGBRC(50) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(22)/STATES(7))
      ALGBRC(51) =  CONSTS(63)*STATES(12)*ALGBRC(46)*(STATES(1) - ALGBRC(50))
      ALGBRC(48) =  0.289000*(1.00000+0.600000/(1.00000+3.80000e-05/STATES(6) ** 1.40000))
      ALGBRC(47) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log((CONSTS(22)+ CONSTS(25)*CONSTS(10))/(STATES(7)+ CONSTS(25)*STATES(2)))
      ALGBRC(49) =  ALGBRC(48)*STATES(13)*STATES(14)*(STATES(1) - ALGBRC(47))
      ALGBRC(58) =  CONSTS(73)*(STATES(1) - ALGBRC(50))
      ALGBRC(59) = EXP(STATES(1)/100.000)
      ALGBRC(60) =  CONSTS(66)*STATES(15) ** 3.00000*STATES(16)*ALGBRC(59)*(STATES(1) - ALGBRC(50))
      ALGBRC(52) = 1.02000/(1.00000+EXP( 0.238500*((STATES(1) - ALGBRC(50)) - 59.2150)))
      ALGBRC(53) = ( 1.00000*( 0.491240*EXP( 0.0803200*((STATES(1) - ALGBRC(50))+5.47600))+EXP( 0.0617500*((STATES(1) - ALGBRC(50)) - 594.310))))/(1.00000+EXP( - 0.514300*((STATES(1) - ALGBRC(50))+4.75300)))
      ALGBRC(54) = ALGBRC(52)/(ALGBRC(52)+ALGBRC(53))
      ALGBRC(55) =  CONSTS(64)*ALGBRC(54)*(STATES(1) - ALGBRC(50))
      ALGBRC(56) = 1.00000/(1.00000+EXP((7.48800 - STATES(1))/5.98000))
      ALGBRC(57) =  CONSTS(26)*ALGBRC(56)*(STATES(1) - ALGBRC(50))
      ALGBRC(66) = 1.00000/(1.00000+ 0.124500*EXP(( - 0.100000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))+ 0.0365000*CONSTS(67)*EXP(( - STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))))
      ALGBRC(67) = ( (( CONSTS(36)*ALGBRC(66)*1.00000)/(1.00000+CONSTS(37)/STATES(2) ** 2.00000))*CONSTS(22))/(CONSTS(22)+CONSTS(38))
      ALGBRC(40) = ( (( CONSTS(18)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(14)*STATES(7)*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(41) = 1.00000/(1.00000+STATES(6)/CONSTS(23))
      ALGBRC(44) =  STATES(8)*STATES(9)*ALGBRC(41)*ALGBRC(40)
      ALGBRC(69) = ( (( CONSTS(68)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(14)*STATES(7)*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(71) = ( ALGBRC(69)*1.00000)/(1.00000+CONSTS(39)/STATES(6) ** 3.00000)
      RATES(7) = ( - 0.00100000*(ALGBRC(44)+ALGBRC(51)+ALGBRC(49)+ALGBRC(55)+ALGBRC(57)+ALGBRC(58)+ALGBRC(60)+ALGBRC(71)+ - ALGBRC(67)*2.00000)*CONSTS(54))/( CONSTS(72)*CONSTS(3))
      ALGBRC(63) =  (( CONSTS(1)*CONSTS(2))/( 2.00000*CONSTS(3)))*log(CONSTS(21)/STATES(6))
      ALGBRC(64) =  CONSTS(24)*STATES(10)*STATES(10)*STATES(11)*(STATES(1) - ALGBRC(63))
      ALGBRC(61) = ( CONSTS(33)*STATES(6))/(CONSTS(32)+STATES(6))
      ALGBRC(65) =  CONSTS(35)*(STATES(1) - ALGBRC(63))
      ALGBRC(73) = ( CONSTS(41)*( EXP(( CONSTS(43)*(CONSTS(40) - 2.00000)*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*STATES(2) ** CONSTS(40)*CONSTS(21) -  EXP(( (CONSTS(43) - 1.00000)*(CONSTS(40) - 2.00000)*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*CONSTS(10) ** CONSTS(40)*STATES(6)))/( (1.00000+ CONSTS(42)*( STATES(6)*CONSTS(10) ** CONSTS(40)+ CONSTS(21)*STATES(2) ** CONSTS(40)))*(1.00000+STATES(6)/0.00690000))
      ALGBRC(37) = ( (( CONSTS(16)*2.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(19)*STATES(6)*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(42) =  STATES(8)*STATES(9)*ALGBRC(41)*ALGBRC(37)
      RATES(22) = TERNRY(STATES(19).GT.0.200000, ( - 1.00000*CONSTS(54)*(((ALGBRC(42)+ALGBRC(64)) - ALGBRC(73))+ALGBRC(61)+ALGBRC(65)))/( 2.00000*CONSTS(72)*CONSTS(3)), TERNRY(STATES(20).GT.0.0100000.AND.STATES(19).LE.0.200000, 0.00000,  - 0.500000*STATES(22))
      ALGBRC(26) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(10)/STATES(2))
      ALGBRC(32) =  CONSTS(9)*STATES(3) ** 3.00000*STATES(4)*STATES(5)*(STATES(1) - ALGBRC(26))
      ALGBRC(62) =  CONSTS(34)*(STATES(1) - ALGBRC(26))
      ALGBRC(39) = ( (( 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(10)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(43) =  STATES(8)*STATES(9)*ALGBRC(41)*ALGBRC(39)
      ALGBRC(68) = ( (( CONSTS(68)*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(10)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(70) = ( ALGBRC(68)*1.00000)/(1.00000+CONSTS(39)/STATES(6) ** 3.00000)
      RATES(2) = ( - 0.00100000*(ALGBRC(32)+ALGBRC(43)+ALGBRC(62)+ALGBRC(70)+ ALGBRC(73)*3.00000+ ALGBRC(67)*3.00000)*CONSTS(54))/( CONSTS(72)*CONSTS(3))
      ALGBRC(13) = TERNRY(VOI.GE.CONSTS(4).AND.VOI.LE.CONSTS(5).AND.(VOI - CONSTS(4)) -  INT((VOI - CONSTS(4))/CONSTS(6))*CONSTS(6).LE.CONSTS(7), CONSTS(8), 0.00000)
      ALGBRC(45) = ALGBRC(42)+ALGBRC(44)+ALGBRC(43)
      ALGBRC(72) = ALGBRC(70)+ALGBRC(71)
      ALGBRC(74) = - (ALGBRC(32)+ALGBRC(45)+ALGBRC(64)+ALGBRC(51)+ALGBRC(49)+ALGBRC(58)+ALGBRC(60)+ALGBRC(55)+ALGBRC(57)+ALGBRC(61)+ALGBRC(62)+ALGBRC(65)+ALGBRC(67)+ALGBRC(73)+ALGBRC(72)+ALGBRC(13))
      RATES(1) = ALGBRC(74)
      RATES(19) = TERNRY(ALGBRC(74).GT.150.000,  100.000*(1.00000 - STATES(19)) -  0.500000*STATES(19),  - 0.500000*STATES(19))
      ALGBRC(75) = TERNRY(STATES(22).GT.CONSTS(48),  (( CONSTS(44)*(STATES(22) - CONSTS(48)))/((CONSTS(47)+STATES(22)) - CONSTS(48)))*(1.00000 - STATES(20))*STATES(20), TERNRY(STATES(22).LE.CONSTS(48).AND.STATES(24).GT.0.00000,  CONSTS(45)*(1.00000 - STATES(24))*STATES(24), 0.00000)
      ALGBRC(76) =  ALGBRC(75)*(STATES(17) - STATES(6))
      ALGBRC(77) = ( CONSTS(52)*STATES(6))/(STATES(6)+CONSTS(51))
      ALGBRC(78) =  CONSTS(69)*STATES(18)
      RATES(6) =  (0.00100000/(1.00000+( CONSTS(58)*CONSTS(56))/CONSTS(56)+STATES(6) ** 2.00000+( CONSTS(57)*CONSTS(55))/CONSTS(55)+STATES(6) ** 2.00000))*(( - 1.00000*CONSTS(54)*(((ALGBRC(42)+ALGBRC(64)) - ALGBRC(73))+ALGBRC(61)+ALGBRC(65)))/( 2.00000*CONSTS(72)*CONSTS(3))+( ALGBRC(76)*CONSTS(74))/CONSTS(72)+( (ALGBRC(78) - ALGBRC(77))*CONSTS(75))/CONSTS(72))
      ALGBRC(79) = (STATES(18) - STATES(17))/CONSTS(46)
      RATES(17) =  (0.00100000/(1.00000+( CONSTS(49)*CONSTS(50))/CONSTS(50)+STATES(17) ** 2.00000))*(ALGBRC(79) - ALGBRC(76))
      RATES(18) =  0.00100000*((( - ALGBRC(79)*CONSTS(74))/CONSTS(75) - ALGBRC(78))+ALGBRC(77))
      RETURN
      END
      SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      ALGBRC(2) = TERNRY(STATES(1).LT.- 40.0000,  0.135000*EXP((80.0000+STATES(1))/- 6.80000), 0.00000)
      ALGBRC(15) = TERNRY(STATES(1).LT.- 40.0000,  3.56000*EXP( 0.0790000*STATES(1))+ 310000.*EXP( 0.350000*STATES(1)), 1.00000/( 0.130000*(1.00000+EXP((STATES(1)+10.6600)/- 11.1000))))
      ALGBRC(3) = TERNRY(STATES(1).LT.- 40.0000, ( - ( 127140.*EXP( 0.244400*STATES(1))+ 3.47400e-05*EXP( - 0.0439100*STATES(1)))*(STATES(1)+37.7800))/(1.00000+EXP( 0.311000*(STATES(1)+79.2300))), 0.00000)
      ALGBRC(16) = TERNRY(STATES(1).LT.- 40.0000, ( 0.121200*EXP( - 0.0105200*STATES(1)))/(1.00000+EXP( - 0.137800*(STATES(1)+40.1400))), ( 0.300000*EXP( - 2.53500e-07*STATES(1)))/(1.00000+EXP( - 0.100000*(STATES(1)+32.0000))))
      ALGBRC(6) = 1.00000/(1.00000+EXP(- (STATES(1)+14.0000)/10.8000))
      ALGBRC(19) = 3.70000+6.10000/(1.00000+EXP((STATES(1)+25.0000)/4.50000))
      ALGBRC(7) = 1.00000/(1.00000+EXP((STATES(1)+60.0000)/5.60000))
      ALGBRC(20) = TERNRY(STATES(1).LE.0.00000,  - 0.875000*STATES(1)+12.0000, 12.0000)
      ALGBRC(8) = 1.00000/(1.00000+EXP(- (STATES(1)+21.5000)/7.50000))
      ALGBRC(21) = 1.00000/(( 0.00138000*(STATES(1)+14.2000))/(1.00000 - EXP( - 0.123000*(STATES(1)+14.2000)))+( 0.000610000*(STATES(1)+38.9000))/(EXP( 0.145000*(STATES(1)+38.9000)) - 1.00000))
      ALGBRC(9) = 1.00000/(1.00000+EXP(- (STATES(1) - 1.50000)/16.7000))
      ALGBRC(22) = 1.00000/(( 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(10) = 1.00000/(1.00000+EXP(- (STATES(1) - 1.50000)/16.7000))
      ALGBRC(23) = 4.00000/(( 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(1) = STATES(1)+47.1300
      ALGBRC(14) = TERNRY(ABS(ALGBRC(1)).GE.CONSTS(11), ( 0.320000*ALGBRC(1))/(1.00000 - EXP( - 0.100000*ALGBRC(1))), 3.20000)
      ALGBRC(27) =  0.0800000*EXP(- STATES(1)/11.0000)
      ALGBRC(5) = 1.00000/(1.00000+EXP((STATES(1)+32.0000)/8.00000))+0.600000/(1.00000+EXP((50.0000 - STATES(1))/20.0000))
      ALGBRC(18) = 1.00000/( 0.0197000*EXP(-  0.0337000*(STATES(1)+10.0000) ** 2.00000)+0.0200000)
      ALGBRC(29) = ALGBRC(5)/ALGBRC(18)
      ALGBRC(34) = (1.00000 - ALGBRC(5))/ALGBRC(18)
      ALGBRC(11) = ( 10.0000*EXP((STATES(1) - 40.0000)/25.0000))/(1.00000+EXP((STATES(1) - 40.0000)/25.0000))
      ALGBRC(24) = ( 10.0000*EXP(- (STATES(1)+90.0000)/25.0000))/(1.00000+EXP(- (STATES(1)+90.0000)/25.0000))
      ALGBRC(30) = 1.00000/(ALGBRC(11)+ALGBRC(24))
      ALGBRC(35) = ALGBRC(11)/(ALGBRC(11)+ALGBRC(24))
      ALGBRC(12) = 0.0150000/(1.00000+EXP((STATES(1)+60.0000)/5.00000))
      ALGBRC(25) = ( 0.100000*EXP((STATES(1)+25.0000)/5.00000))/(1.00000+EXP((STATES(1)+25.0000)/5.00000))
      ALGBRC(31) = 1.00000/(ALGBRC(12)+ALGBRC(25))
      ALGBRC(36) = ALGBRC(12)/(ALGBRC(12)+ALGBRC(25))
      ALGBRC(4) = STATES(1)+10.0000
      ALGBRC(17) = 1.00000/(1.00000+EXP(- ALGBRC(4)/6.24000))
      ALGBRC(28) = TERNRY(ABS(ALGBRC(4)).LT.1.00000e-05, 1.00000/( 0.0350000*6.24000), ( ALGBRC(17)*(1.00000 - EXP(- ALGBRC(4)/6.24000)))/( 0.0350000*ALGBRC(4)))
      ALGBRC(33) = ALGBRC(17)/ALGBRC(28)
      ALGBRC(38) = (1.00000 - ALGBRC(17))/ALGBRC(28)
      ALGBRC(46) = 1.00000/(1.00000+EXP((STATES(1)+9.00000)/22.4000))
      ALGBRC(50) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(22)/STATES(7))
      ALGBRC(51) =  CONSTS(63)*STATES(12)*ALGBRC(46)*(STATES(1) - ALGBRC(50))
      ALGBRC(48) =  0.289000*(1.00000+0.600000/(1.00000+3.80000e-05/STATES(6) ** 1.40000))
      ALGBRC(47) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log((CONSTS(22)+ CONSTS(25)*CONSTS(10))/(STATES(7)+ CONSTS(25)*STATES(2)))
      ALGBRC(49) =  ALGBRC(48)*STATES(13)*STATES(14)*(STATES(1) - ALGBRC(47))
      ALGBRC(58) =  CONSTS(73)*(STATES(1) - ALGBRC(50))
      ALGBRC(59) = EXP(STATES(1)/100.000)
      ALGBRC(60) =  CONSTS(66)*STATES(15) ** 3.00000*STATES(16)*ALGBRC(59)*(STATES(1) - ALGBRC(50))
      ALGBRC(52) = 1.02000/(1.00000+EXP( 0.238500*((STATES(1) - ALGBRC(50)) - 59.2150)))
      ALGBRC(53) = ( 1.00000*( 0.491240*EXP( 0.0803200*((STATES(1) - ALGBRC(50))+5.47600))+EXP( 0.0617500*((STATES(1) - ALGBRC(50)) - 594.310))))/(1.00000+EXP( - 0.514300*((STATES(1) - ALGBRC(50))+4.75300)))
      ALGBRC(54) = ALGBRC(52)/(ALGBRC(52)+ALGBRC(53))
      ALGBRC(55) =  CONSTS(64)*ALGBRC(54)*(STATES(1) - ALGBRC(50))
      ALGBRC(56) = 1.00000/(1.00000+EXP((7.48800 - STATES(1))/5.98000))
      ALGBRC(57) =  CONSTS(26)*ALGBRC(56)*(STATES(1) - ALGBRC(50))
      ALGBRC(66) = 1.00000/(1.00000+ 0.124500*EXP(( - 0.100000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))+ 0.0365000*CONSTS(67)*EXP(( - STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))))
      ALGBRC(67) = ( (( CONSTS(36)*ALGBRC(66)*1.00000)/(1.00000+CONSTS(37)/STATES(2) ** 2.00000))*CONSTS(22))/(CONSTS(22)+CONSTS(38))
      ALGBRC(40) = ( (( CONSTS(18)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(14)*STATES(7)*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(41) = 1.00000/(1.00000+STATES(6)/CONSTS(23))
      ALGBRC(44) =  STATES(8)*STATES(9)*ALGBRC(41)*ALGBRC(40)
      ALGBRC(69) = ( (( CONSTS(68)*1.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(14)*STATES(7)*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(71) = ( ALGBRC(69)*1.00000)/(1.00000+CONSTS(39)/STATES(6) ** 3.00000)
      ALGBRC(63) =  (( CONSTS(1)*CONSTS(2))/( 2.00000*CONSTS(3)))*log(CONSTS(21)/STATES(6))
      ALGBRC(64) =  CONSTS(24)*STATES(10)*STATES(10)*STATES(11)*(STATES(1) - ALGBRC(63))
      ALGBRC(61) = ( CONSTS(33)*STATES(6))/(CONSTS(32)+STATES(6))
      ALGBRC(65) =  CONSTS(35)*(STATES(1) - ALGBRC(63))
      ALGBRC(73) = ( CONSTS(41)*( EXP(( CONSTS(43)*(CONSTS(40) - 2.00000)*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*STATES(2) ** CONSTS(40)*CONSTS(21) -  EXP(( (CONSTS(43) - 1.00000)*(CONSTS(40) - 2.00000)*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2)))*CONSTS(10) ** CONSTS(40)*STATES(6)))/( (1.00000+ CONSTS(42)*( STATES(6)*CONSTS(10) ** CONSTS(40)+ CONSTS(21)*STATES(2) ** CONSTS(40)))*(1.00000+STATES(6)/0.00690000))
      ALGBRC(37) = ( (( CONSTS(16)*2.00000 ** 2.00000*STATES(1)*CONSTS(3) ** 2.00000)/( CONSTS(1)*CONSTS(2)))*( CONSTS(19)*STATES(6)*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(42) =  STATES(8)*STATES(9)*ALGBRC(41)*ALGBRC(37)
      ALGBRC(26) =  (( CONSTS(1)*CONSTS(2))/CONSTS(3))*log(CONSTS(10)/STATES(2))
      ALGBRC(32) =  CONSTS(9)*STATES(3) ** 3.00000*STATES(4)*STATES(5)*(STATES(1) - ALGBRC(26))
      ALGBRC(62) =  CONSTS(34)*(STATES(1) - ALGBRC(26))
      ALGBRC(39) = ( (( 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(10)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(43) =  STATES(8)*STATES(9)*ALGBRC(41)*ALGBRC(39)
      ALGBRC(68) = ( (( CONSTS(68)*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(10)))/(EXP(( 1.00000*STATES(1)*CONSTS(3))/( CONSTS(1)*CONSTS(2))) - 1.00000)
      ALGBRC(70) = ( ALGBRC(68)*1.00000)/(1.00000+CONSTS(39)/STATES(6) ** 3.00000)
      ALGBRC(13) = TERNRY(VOI.GE.CONSTS(4).AND.VOI.LE.CONSTS(5).AND.(VOI - CONSTS(4)) -  INT((VOI - CONSTS(4))/CONSTS(6))*CONSTS(6).LE.CONSTS(7), CONSTS(8), 0.00000)
      ALGBRC(45) = ALGBRC(42)+ALGBRC(44)+ALGBRC(43)
      ALGBRC(72) = ALGBRC(70)+ALGBRC(71)
      ALGBRC(74) = - (ALGBRC(32)+ALGBRC(45)+ALGBRC(64)+ALGBRC(51)+ALGBRC(49)+ALGBRC(58)+ALGBRC(60)+ALGBRC(55)+ALGBRC(57)+ALGBRC(61)+ALGBRC(62)+ALGBRC(65)+ALGBRC(67)+ALGBRC(73)+ALGBRC(72)+ALGBRC(13))
      ALGBRC(75) = TERNRY(STATES(22).GT.CONSTS(48),  (( CONSTS(44)*(STATES(22) - CONSTS(48)))/((CONSTS(47)+STATES(22)) - CONSTS(48)))*(1.00000 - STATES(20))*STATES(20), TERNRY(STATES(22).LE.CONSTS(48).AND.STATES(24).GT.0.00000,  CONSTS(45)*(1.00000 - STATES(24))*STATES(24), 0.00000)
      ALGBRC(76) =  ALGBRC(75)*(STATES(17) - STATES(6))
      ALGBRC(77) = ( CONSTS(52)*STATES(6))/(STATES(6)+CONSTS(51))
      ALGBRC(78) =  CONSTS(69)*STATES(18)
      ALGBRC(79) = (STATES(18) - STATES(17))/CONSTS(46)
      RETURN
      END
      REAL FUNCTION TERNRY(TEST, VALA, VALB)
      LOGICAL TEST
      REAL VALA, VALB
      IF (TEST) THEN
        TERNRY = VALA
      ELSE
        TERNRY = VALB
      ENDIF
      RETURN
      END