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 1 entries in the algebraic variable array.
C There are a total of 3 entries in each of the rate and state variable arrays.
C There are a total of 5 entries in the constant variable array.
C
C
C VOI is time in component environment (day).
C CONSTS(1) is T in component T (per_ml).
C STATES(1) is T_star in component T_star (per_ml).
C CONSTS(2) is k in component T_star (second_order_rate_constant).
C STATES(2) is VI in component VI (per_ml).
C CONSTS(3) is delta in component kinetic_parameters (first_order_rate_constant).
C CONSTS(4) is c in component kinetic_parameters (first_order_rate_constant).
C STATES(3) is VNI in component VNI (per_ml).
C CONSTS(5) is N in component VNI (dimensionless).
C ALGBRC(1) is V in component V (per_ml).
C RATES(1) is d/dt T_star in component T_star (per_ml).
C RATES(2) is d/dt VI in component VI (per_ml).
C RATES(3) is d/dt VNI in component VNI (per_ml).
C
      SUBROUTINE initConsts(CONSTS, RATES, STATES)
      REAL CONSTS(*), RATES(*), STATES(*)
      CONSTS(1) = 170000
      STATES(1) = 0
      CONSTS(2) = 2.4e-5
      STATES(2) = 216000.0
      CONSTS(3) = 0.49
      CONSTS(4) = 3.07
      STATES(3) = 0
      CONSTS(5) = 774
      RETURN
      END
      SUBROUTINE computeRates(VOI, CONSTS,  RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      RATES(1) =  CONSTS(2)*STATES(2)*CONSTS(1) -  CONSTS(3)*STATES(1)
      RATES(2) = - ( CONSTS(4)*STATES(2))
      RATES(3) =  CONSTS(5)*CONSTS(3)*STATES(1) -  CONSTS(4)*STATES(3)
      RETURN
      END
      SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      ALGBRC(1) = STATES(2)+STATES(3)
      RETURN
      END