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 3 entries in the algebraic variable array.
C There are a total of 5 entries in each of the rate and state variable arrays.
C There are a total of 6 entries in the constant variable array.
C
C
C VOI is t in component time (second).
C CONSTS(1) is R in component geometry (per_um).
C ALGBRC(1) is J1 in component Cformation (uM_per_s).
C ALGBRC(2) is J2 in component Eformation (per_um2_per_s).
C CONSTS(6) is Cpc in component C_interface (uM_um2).
C ALGBRC(3) is JTotal in component C_interface (uM_per_s).
C STATES(1) is C in component C (uM).
C STATES(2) is A in component Cformation (uM).
C STATES(3) is B in component Cformation (uM).
C CONSTS(2) is kf1 in component Cformation (per_uM_per_s).
C CONSTS(3) is kr1 in component Cformation (per_s).
C STATES(4) is D in component Eformation (per_um2).
C STATES(5) is E in component Eformation (per_um2).
C CONSTS(4) is kf2 in component Eformation (per_uM_per_s).
C CONSTS(5) is kr2 in component Eformation (per_s).
C RATES(1) is d/dt C in component C (uM).
C RATES(2) is d/dt A in component Cformation (uM).
C RATES(3) is d/dt B in component Cformation (uM).
C RATES(4) is d/dt D in component Eformation (per_um2).
C RATES(5) is d/dt E in component Eformation (per_um2).
C
      SUBROUTINE initConsts(CONSTS, RATES, STATES)
      REAL CONSTS(*), RATES(*), STATES(*)
      CONSTS(1) = 5
      STATES(1) = 0
      STATES(2) = 10
      STATES(3) = 5
      CONSTS(2) = 0.2
      CONSTS(3) = 0.05
      STATES(4) = 4
      STATES(5) = 0
      CONSTS(4) = 0.006
      CONSTS(5) = 0.001
      CONSTS(6) = CONSTS(1)/602.200
      RETURN
      END
      SUBROUTINE computeRates(VOI, CONSTS,  RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      ALGBRC(1) =  CONSTS(2)*STATES(2)*STATES(3) -  CONSTS(3)*STATES(1)
      RATES(2) = - ALGBRC(1)
      RATES(3) = - ALGBRC(1)
      ALGBRC(2) =  CONSTS(4)*STATES(1)*STATES(4) -  CONSTS(5)*STATES(5)
      RATES(4) = - ALGBRC(2)
      RATES(5) = ALGBRC(2)
      ALGBRC(3) = ALGBRC(1) -  CONSTS(6)*ALGBRC(2)
      RATES(1) = ALGBRC(3)
      RETURN
      END
      SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      ALGBRC(1) =  CONSTS(2)*STATES(2)*STATES(3) -  CONSTS(3)*STATES(1)
      ALGBRC(2) =  CONSTS(4)*STATES(1)*STATES(4) -  CONSTS(5)*STATES(5)
      ALGBRC(3) = ALGBRC(1) -  CONSTS(6)*ALGBRC(2)
      RETURN
      END