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 23 entries in the algebraic variable array. C There are a total of 13 entries in each of the rate and state variable arrays. C There are a total of 28 entries in the constant variable array. C C C VOI is time in component environment (minute). C STATES(1) is S1 in component S1 (millimolar). C ALGBRC(14) is v8 in component v8 (flux). C ALGBRC(16) is v9 in component v9 (flux). C CONSTS(1) is S in component S (millimolar). C ALGBRC(1) is S2 in component S (millimolar). C STATES(2) is sul in component sul (millimolar). C ALGBRC(6) is v1 in component v1 (flux). C ALGBRC(7) is v2 in component v2 (flux). C STATES(3) is aps in component aps (millimolar). C ALGBRC(8) is v3 in component v3 (flux). C STATES(4) is pap in component pap (millimolar). C ALGBRC(9) is v4 in component v4 (flux). C STATES(5) is hyd in component hyd (millimolar). C ALGBRC(10) is v5 in component v5 (flux). C ALGBRC(12) is v17 in component v17 (flux). C STATES(6) is cys in component cys (millimolar). C ALGBRC(13) is v6 in component v6 (flux). C STATES(7) is eth in component eth (millimolar). C CONSTS(2) is v13 in component v13 (flux). C ALGBRC(11) is v7 in component v7 (flux). C STATES(8) is aco in component aco (millimolar). C ALGBRC(15) is v15 in component v15 (flux). C STATES(9) is oxy in component oxy (millimolar). C CONSTS(3) is v10 in component v10 (flux). C ALGBRC(19) is v11A in component v11A (flux). C ALGBRC(20) is v14 in component v14 (flux). C STATES(10) is A3_c in component A3_c (millimolar). C ALGBRC(22) is v12 in component v12 (flux). C ALGBRC(23) is v16 in component v16 (flux). C STATES(11) is A3_m in component A3_m (millimolar). C ALGBRC(21) is v11B in component v11B (flux). C CONSTS(4) is A_c in component A_c (millimolar). C ALGBRC(2) is A2_c in component A_c (millimolar). C CONSTS(5) is A_m in component A_m (millimolar). C ALGBRC(3) is A2_m in component A_m (millimolar). C STATES(12) is N2 in component N2 (millimolar). C CONSTS(6) is N in component N (millimolar). C ALGBRC(4) is N1 in component N (millimolar). C STATES(13) is oah in component oah (millimolar). C ALGBRC(18) is v18 in component v18 (flux). C CONSTS(7) is v0 in component v1 (flux). C ALGBRC(5) is f1 in component v1 (dimensionless). C CONSTS(8) is n in component v1 (dimensionless). C CONSTS(9) is Kc in component v1 (millimolar). C CONSTS(10) is k2 in component v2 (second_order_rate_constant). C CONSTS(11) is k3 in component v3 (second_order_rate_constant). C CONSTS(12) is k4 in component v4 (second_order_rate_constant). C CONSTS(13) is k5 in component v5 (second_order_rate_constant). C CONSTS(14) is k6 in component v6 (first_order_rate_constant). C CONSTS(15) is k7 in component v7 (second_order_rate_constant). C CONSTS(16) is k8 in component v8 (second_order_rate_constant). C CONSTS(17) is k9 in component v9 (second_order_rate_constant). C CONSTS(18) is alpha in component v11A (dimensionless). C ALGBRC(17) is f2 in component v11A (dimensionless). C CONSTS(19) is m in component v11A (dimensionless). C CONSTS(20) is KH in component v11A (millimolar). C CONSTS(21) is k11 in component v11A (first_order_rate_constant). C CONSTS(22) is KA in component v11B (millimolar). C CONSTS(23) is k12 in component v12 (first_order_rate_constant). C CONSTS(24) is k14 in component v14 (first_order_rate_constant). C CONSTS(25) is k15 in component v15 (first_order_rate_constant). C CONSTS(26) is k16 in component v16 (second_order_rate_constant). C CONSTS(27) is k17 in component v17 (first_order_rate_constant). C CONSTS(28) is k18 in component v18 (first_order_rate_constant). C RATES(1) is d/dt S1 in component S1 (millimolar). C RATES(2) is d/dt sul in component sul (millimolar). C RATES(3) is d/dt aps in component aps (millimolar). C RATES(4) is d/dt pap in component pap (millimolar). C RATES(5) is d/dt hyd in component hyd (millimolar). C RATES(6) is d/dt cys in component cys (millimolar). C RATES(7) is d/dt eth in component eth (millimolar). C RATES(8) is d/dt aco in component aco (millimolar). C RATES(9) is d/dt oxy in component oxy (millimolar). C RATES(10) is d/dt A3_c in component A3_c (millimolar). C RATES(11) is d/dt A3_m in component A3_m (millimolar). C RATES(12) is d/dt N2 in component N2 (millimolar). C RATES(13) is d/dt oah in component oah (millimolar). C SUBROUTINE initConsts(CONSTS, RATES, STATES) REAL CONSTS(*), RATES(*), STATES(*) STATES(1) = 1.892468811 CONSTS(1) = 2 STATES(2) = 0.012871557 STATES(3) = 0.053366179 STATES(4) = 0.082791522 STATES(5) = 0.159317029 STATES(6) = 0.805117739 STATES(7) = 10.25246999 CONSTS(2) = 4 STATES(8) = 1.139360412 STATES(9) = 6.146549084 CONSTS(3) = 80 STATES(10) = 1.570847601 STATES(11) = 1.835158493 CONSTS(4) = 2 CONSTS(5) = 2 STATES(12) = 1.933616149 CONSTS(6) = 2 STATES(13) = 5.571685096 CONSTS(7) = 1.6 CONSTS(8) = 4 CONSTS(9) = 0.1 CONSTS(10) = 0.2 CONSTS(11) = 0.2 CONSTS(12) = 0.2 CONSTS(13) = 0.1 CONSTS(14) = 0.12 CONSTS(15) = 10 CONSTS(16) = 10 CONSTS(17) = 10 CONSTS(18) = 0.1 CONSTS(19) = 4 CONSTS(20) = 0.5 CONSTS(21) = 10 CONSTS(22) = 1 CONSTS(23) = 5 CONSTS(24) = 10 CONSTS(25) = 5 CONSTS(26) = 10 CONSTS(27) = 0.02 CONSTS(28) = 1 RETURN END SUBROUTINE computeRates(VOI, CONSTS, RATES, STATES, ALGBRC) REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*) ALGBRC(5) = 1.00000+STATES(6)/CONSTS(9) ** CONSTS(8) ** - 1.00000 ALGBRC(6) = CONSTS(7)*ALGBRC(5) ALGBRC(7) = CONSTS(10)*STATES(2)*STATES(10) RATES(2) = ALGBRC(6) - ALGBRC(7) ALGBRC(8) = CONSTS(11)*STATES(3)*STATES(10) RATES(3) = ALGBRC(7) - ALGBRC(8) ALGBRC(9) = CONSTS(12)*STATES(4)*STATES(12) RATES(4) = ALGBRC(8) - ALGBRC(9) ALGBRC(10) = CONSTS(13)*STATES(5)*STATES(13) ALGBRC(12) = CONSTS(27)*STATES(5) RATES(5) = ALGBRC(9) - (ALGBRC(10)+ALGBRC(12)) ALGBRC(13) = CONSTS(14)*STATES(6) RATES(6) = ALGBRC(10) - ALGBRC(13) ALGBRC(4) = CONSTS(6) - STATES(12) ALGBRC(11) = CONSTS(15)*STATES(7)*ALGBRC(4) RATES(7) = CONSTS(2) - ALGBRC(11) ALGBRC(1) = CONSTS(1) - STATES(1) ALGBRC(14) = CONSTS(16)*STATES(8)*ALGBRC(1) ALGBRC(16) = CONSTS(17)*STATES(1)*ALGBRC(4) RATES(1) = ALGBRC(14) - ALGBRC(16) ALGBRC(15) = CONSTS(25)*STATES(8) RATES(8) = ALGBRC(11) - (ALGBRC(14)+ALGBRC(15)) ALGBRC(18) = CONSTS(28)*STATES(13) RATES(13) = ALGBRC(15) - (ALGBRC(10)+ALGBRC(18)) ALGBRC(17) = 1.00000+STATES(5)/CONSTS(20) ** CONSTS(19) ** - 1.00000 ALGBRC(19) = ( CONSTS(21)*STATES(12)*STATES(9)*ALGBRC(17))/( CONSTS(18)*STATES(12)+STATES(9)) RATES(12) = ( 2.00000*ALGBRC(11)+ 4.00000*ALGBRC(16)) - ( 3.00000*ALGBRC(9)+ALGBRC(19)) ALGBRC(20) = CONSTS(24)*STATES(9) RATES(9) = CONSTS(3) - (ALGBRC(19)+ALGBRC(20)) ALGBRC(22) = CONSTS(23)*STATES(10) ALGBRC(2) = CONSTS(4) - STATES(10) ALGBRC(23) = CONSTS(26)*STATES(11)*ALGBRC(2) RATES(10) = ALGBRC(23) - (ALGBRC(7)+ALGBRC(8)+ALGBRC(22)) ALGBRC(3) = CONSTS(5) - STATES(11) ALGBRC(21) = ( 3.00000*ALGBRC(19)*ALGBRC(3))/(CONSTS(22)+ALGBRC(3)) RATES(11) = ALGBRC(21) - ALGBRC(23) RETURN END SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC) REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*) ALGBRC(5) = 1.00000+STATES(6)/CONSTS(9) ** CONSTS(8) ** - 1.00000 ALGBRC(6) = CONSTS(7)*ALGBRC(5) ALGBRC(7) = CONSTS(10)*STATES(2)*STATES(10) ALGBRC(8) = CONSTS(11)*STATES(3)*STATES(10) ALGBRC(9) = CONSTS(12)*STATES(4)*STATES(12) ALGBRC(10) = CONSTS(13)*STATES(5)*STATES(13) ALGBRC(12) = CONSTS(27)*STATES(5) ALGBRC(13) = CONSTS(14)*STATES(6) ALGBRC(4) = CONSTS(6) - STATES(12) ALGBRC(11) = CONSTS(15)*STATES(7)*ALGBRC(4) ALGBRC(1) = CONSTS(1) - STATES(1) ALGBRC(14) = CONSTS(16)*STATES(8)*ALGBRC(1) ALGBRC(16) = CONSTS(17)*STATES(1)*ALGBRC(4) ALGBRC(15) = CONSTS(25)*STATES(8) ALGBRC(18) = CONSTS(28)*STATES(13) ALGBRC(17) = 1.00000+STATES(5)/CONSTS(20) ** CONSTS(19) ** - 1.00000 ALGBRC(19) = ( CONSTS(21)*STATES(12)*STATES(9)*ALGBRC(17))/( CONSTS(18)*STATES(12)+STATES(9)) ALGBRC(20) = CONSTS(24)*STATES(9) ALGBRC(22) = CONSTS(23)*STATES(10) ALGBRC(2) = CONSTS(4) - STATES(10) ALGBRC(23) = CONSTS(26)*STATES(11)*ALGBRC(2) ALGBRC(3) = CONSTS(5) - STATES(11) ALGBRC(21) = ( 3.00000*ALGBRC(19)*ALGBRC(3))/(CONSTS(22)+ALGBRC(3)) RETURN END