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 0 entries in the algebraic variable array.
C There are a total of 4 entries in each of the rate and state variable arrays.
C There are a total of 10 entries in the constant variable array.
C
C
C VOI is time in component environment (day).
C CONSTS(1) is lambda in component uninfected (per_ml_day).
C CONSTS(2) is d_T in component uninfected (per_day).
C CONSTS(3) is efficacy in component drug_efficacy (dimensionless).
C CONSTS(4) is k in component uninfected (ml_per_day).
C STATES(1) is V in component viral_load (per_ml).
C STATES(2) is T in component uninfected (per_ml).
C CONSTS(5) is d_0 in component latently_infected (per_day).
C CONSTS(6) is a_L in component latently_infected (per_day).
C CONSTS(7) is eta in component latently_infected (dimensionless).
C STATES(3) is L in component latently_infected (per_ml).
C CONSTS(8) is delta in component productively_infected (per_day).
C STATES(4) is T_star in component productively_infected (per_ml).
C CONSTS(9) is N in component viral_load (dimensionless).
C CONSTS(10) is c in component viral_load (per_day).
C RATES(2) is d/dt T in component uninfected (per_ml).
C RATES(3) is d/dt L in component latently_infected (per_ml).
C RATES(4) is d/dt T_star in component productively_infected (per_ml).
C RATES(1) is d/dt V in component viral_load (per_ml).
C
      SUBROUTINE initConsts(CONSTS, RATES, STATES)
      REAL CONSTS(*), RATES(*), STATES(*)
      CONSTS(1) = 1E4
      CONSTS(2) = 0.01
      CONSTS(3) = 0.4
      CONSTS(4) = 2.4E-8
      STATES(1) = 50
      STATES(2) = 600000
      CONSTS(5) = 0.001
      CONSTS(6) = 0.1
      CONSTS(7) = 0.001
      STATES(3) = 2
      CONSTS(8) = 1
      STATES(4) = 0.3
      CONSTS(9) = 2000
      CONSTS(10) = 23
      RETURN
      END
      SUBROUTINE computeRates(VOI, CONSTS,  RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      RATES(2) = (CONSTS(1) -  CONSTS(2)*STATES(2)) -  (1.00000 - CONSTS(3))*CONSTS(4)*STATES(1)*STATES(2)
      RATES(3) = ( CONSTS(7)*(1.00000 - CONSTS(3))*CONSTS(4)*STATES(1)*STATES(2) -  CONSTS(5)*STATES(3)) -  CONSTS(6)*STATES(3)
      RATES(4) = ( (1.00000 - CONSTS(7))*(1.00000 - CONSTS(3))*CONSTS(4)*STATES(1)*STATES(2) -  CONSTS(8)*STATES(4))+ CONSTS(6)*STATES(3)
      RATES(1) =  CONSTS(9)*CONSTS(8)*STATES(4) -  CONSTS(10)*STATES(1)
      RETURN
      END
      SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      RETURN
      END