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 13 entries in the algebraic variable array.
C There are a total of 6 entries in each of the rate and state variable arrays.
C There are a total of 21 entries in the constant variable array.
C
C
C VOI is t in component environment (second).
C CONSTS(1) is C_m in component environment (fF).
C ALGBRC(8) is v_RyR in component RyR (fmol_per_sec).
C CONSTS(2) is F in component constants (C_per_mol).
C STATES(1) is q_Ca_SR in component environment (fmol).
C STATES(2) is q_Ca_D in component environment (fmol).
C STATES(3) is q_C_RyR in component environment (fmol).
C STATES(4) is q_CI_RyR in component environment (fmol).
C STATES(5) is q_I_RyR in component environment (fmol).
C STATES(6) is q_O_RyR in component environment (fmol).
C ALGBRC(13) is v_RyRgate_Ca_D in component RyR (fmol_per_sec).
C CONSTS(3) is kappa_RyR in component RyR_parameters (fmol_per_sec).
C CONSTS(4) is kappa_OC in component RyR_parameters (fmol_per_sec).
C CONSTS(5) is kappa_CCI in component RyR_parameters (fmol_per_sec).
C CONSTS(6) is kappa_CII in component RyR_parameters (fmol_per_sec).
C CONSTS(7) is kappa_IO in component RyR_parameters (fmol_per_sec).
C CONSTS(8) is K_Ca_SR in component RyR_parameters (per_fmol).
C CONSTS(9) is K_Ca_D in component RyR_parameters (per_fmol).
C CONSTS(10) is K_C_RyR in component RyR_parameters (per_fmol).
C CONSTS(11) is K_CI_RyR in component RyR_parameters (per_fmol).
C CONSTS(12) is K_I_RyR in component RyR_parameters (per_fmol).
C CONSTS(13) is K_O_RyR in component RyR_parameters (per_fmol).
C CONSTS(14) is R in component constants (J_per_K_per_mol).
C CONSTS(15) is T in component constants (kelvin).
C CONSTS(16) is nCa_1 in component RyR (dimensionless).
C CONSTS(17) is nCa_2 in component RyR (dimensionless).
C ALGBRC(1) is mu_Ca_SR in component RyR (J_per_mol).
C ALGBRC(3) is mu_Ca_D in component RyR (J_per_mol).
C ALGBRC(2) is q_Ca_gate_complexes in component RyR (fmol).
C ALGBRC(4) is mu_C_RyR in component RyR (J_per_mol).
C ALGBRC(5) is mu_CI_RyR in component RyR (J_per_mol).
C ALGBRC(6) is mu_I_RyR in component RyR (J_per_mol).
C ALGBRC(7) is mu_O_RyR in component RyR (J_per_mol).
C ALGBRC(9) is v_OC in component RyR (fmol_per_sec).
C ALGBRC(10) is v_CCI in component RyR (fmol_per_sec).
C ALGBRC(11) is v_CII in component RyR (fmol_per_sec).
C ALGBRC(12) is v_IO in component RyR (fmol_per_sec).
C CONSTS(18) is zNa in component ion_valences (dimensionless).
C CONSTS(19) is zCl in component ion_valences (dimensionless).
C CONSTS(20) is zK in component ion_valences (dimensionless).
C CONSTS(21) is zCa in component ion_valences (dimensionless).
C RATES(1) is d/dt q_Ca_SR in component environment (fmol).
C RATES(2) is d/dt q_Ca_D in component environment (fmol).
C RATES(6) is d/dt q_O_RyR in component environment (fmol).
C RATES(3) is d/dt q_C_RyR in component environment (fmol).
C RATES(4) is d/dt q_CI_RyR in component environment (fmol).
C RATES(5) is d/dt q_I_RyR in component environment (fmol).
C
      SUBROUTINE initConsts(CONSTS, RATES, STATES)
      REAL CONSTS(*), RATES(*), STATES(*)
      CONSTS(1) = 1.381e5
      CONSTS(2) = 96485
      STATES(1) = 6.41e-1
      STATES(2) = 3.68876E-07
      STATES(3) = 2.9682830E-06
      STATES(4) = 2.9682830E-06
      STATES(5) = 2.9682830E-06
      STATES(6) = 2.9682830E-06
      CONSTS(3) = 498020
      CONSTS(4) = 5.01701
      CONSTS(5) = 6.61466
      CONSTS(6) = 5.43605
      CONSTS(7) = 0.453004
      CONSTS(8) = 102.047
      CONSTS(9) = 66.2643
      CONSTS(10) = 0.819033
      CONSTS(11) = 0.755897
      CONSTS(12) = 11.0374
      CONSTS(13) = 11.9593
      CONSTS(14) = 8.31
      CONSTS(15) = 310
      CONSTS(16) = 1
      CONSTS(17) = 2
      CONSTS(18) = 1
      CONSTS(19) = -1
      CONSTS(20) = 1
      CONSTS(21) = 2
      RETURN
      END
      SUBROUTINE computeRates(VOI, CONSTS,  RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      ALGBRC(1) =  CONSTS(14)*CONSTS(15)*log( CONSTS(8)*STATES(1))
      ALGBRC(3) =  CONSTS(14)*CONSTS(15)*log( CONSTS(9)*STATES(2))
      ALGBRC(7) =  CONSTS(14)*CONSTS(15)*log( CONSTS(13)*STATES(6))
      ALGBRC(8) =  CONSTS(3)*EXP(ALGBRC(7)/( CONSTS(14)*CONSTS(15)))*(EXP(ALGBRC(1)/( CONSTS(14)*CONSTS(15))) - EXP(ALGBRC(3)/( CONSTS(14)*CONSTS(15))))
      RATES(1) = - ALGBRC(8)
      ALGBRC(4) =  CONSTS(14)*CONSTS(15)*log( CONSTS(10)*STATES(3))
      ALGBRC(9) =  CONSTS(4)*(EXP(ALGBRC(7)/( CONSTS(14)*CONSTS(15))) - EXP((ALGBRC(4)+ CONSTS(17)*ALGBRC(3))/( CONSTS(14)*CONSTS(15))))
      ALGBRC(5) =  CONSTS(14)*CONSTS(15)*log( CONSTS(11)*STATES(4))
      ALGBRC(10) =  CONSTS(5)*(EXP((ALGBRC(4)+ CONSTS(16)*ALGBRC(3))/( CONSTS(14)*CONSTS(15))) - EXP(ALGBRC(5)/( CONSTS(14)*CONSTS(15))))
      RATES(3) = ALGBRC(9) - ALGBRC(10)
      ALGBRC(6) =  CONSTS(14)*CONSTS(15)*log( CONSTS(12)*STATES(5))
      ALGBRC(11) =  CONSTS(6)*(EXP((ALGBRC(5)+ CONSTS(17)*ALGBRC(3))/( CONSTS(14)*CONSTS(15))) - EXP(ALGBRC(6)/( CONSTS(14)*CONSTS(15))))
      RATES(4) = ALGBRC(10) - ALGBRC(11)
      ALGBRC(12) =  CONSTS(7)*(EXP(ALGBRC(6)/( CONSTS(14)*CONSTS(15))) - EXP((ALGBRC(7)+ CONSTS(16)*ALGBRC(3))/( CONSTS(14)*CONSTS(15))))
      RATES(6) = ALGBRC(12) - ALGBRC(9)
      RATES(5) = ALGBRC(11) - ALGBRC(12)
      ALGBRC(13) = (( CONSTS(17)*ALGBRC(9) -  CONSTS(16)*ALGBRC(10)) -  CONSTS(17)*ALGBRC(11))+ CONSTS(16)*ALGBRC(12)
      RATES(2) = ALGBRC(8)+ALGBRC(13)
      RETURN
      END
      SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      ALGBRC(1) =  CONSTS(14)*CONSTS(15)*log( CONSTS(8)*STATES(1))
      ALGBRC(3) =  CONSTS(14)*CONSTS(15)*log( CONSTS(9)*STATES(2))
      ALGBRC(7) =  CONSTS(14)*CONSTS(15)*log( CONSTS(13)*STATES(6))
      ALGBRC(8) =  CONSTS(3)*EXP(ALGBRC(7)/( CONSTS(14)*CONSTS(15)))*(EXP(ALGBRC(1)/( CONSTS(14)*CONSTS(15))) - EXP(ALGBRC(3)/( CONSTS(14)*CONSTS(15))))
      ALGBRC(4) =  CONSTS(14)*CONSTS(15)*log( CONSTS(10)*STATES(3))
      ALGBRC(9) =  CONSTS(4)*(EXP(ALGBRC(7)/( CONSTS(14)*CONSTS(15))) - EXP((ALGBRC(4)+ CONSTS(17)*ALGBRC(3))/( CONSTS(14)*CONSTS(15))))
      ALGBRC(5) =  CONSTS(14)*CONSTS(15)*log( CONSTS(11)*STATES(4))
      ALGBRC(10) =  CONSTS(5)*(EXP((ALGBRC(4)+ CONSTS(16)*ALGBRC(3))/( CONSTS(14)*CONSTS(15))) - EXP(ALGBRC(5)/( CONSTS(14)*CONSTS(15))))
      ALGBRC(6) =  CONSTS(14)*CONSTS(15)*log( CONSTS(12)*STATES(5))
      ALGBRC(11) =  CONSTS(6)*(EXP((ALGBRC(5)+ CONSTS(17)*ALGBRC(3))/( CONSTS(14)*CONSTS(15))) - EXP(ALGBRC(6)/( CONSTS(14)*CONSTS(15))))
      ALGBRC(12) =  CONSTS(7)*(EXP(ALGBRC(6)/( CONSTS(14)*CONSTS(15))) - EXP((ALGBRC(7)+ CONSTS(16)*ALGBRC(3))/( CONSTS(14)*CONSTS(15))))
      ALGBRC(13) = (( CONSTS(17)*ALGBRC(9) -  CONSTS(16)*ALGBRC(10)) -  CONSTS(17)*ALGBRC(11))+ CONSTS(16)*ALGBRC(12)
      ALGBRC(2) =  CONSTS(17)*STATES(6)+ CONSTS(16)*STATES(4)+ (CONSTS(16)+CONSTS(17))*STATES(5)
      RETURN
      END