C C There are a total of 4 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 14 entries in the constant variable array. C C C VOI is time in component environment (min). C STATES(1) is Z in component Ca (uM). C STATES(2) is Y in component Ca (uM). C CONSTS(14) is V_in in component V_in (uM_per_min). C ALGBRC(1) is V_2 in component V_2 (uM_per_min). C ALGBRC(4) is V_3 in component V_3 (uM_per_min). C CONSTS(1) is K_f in component Ca (per_min). C CONSTS(2) is K in component Ca (per_min). C CONSTS(3) is beta in component Ca_flux (dimensionless). C CONSTS(4) is v_0 in component V_in (uM_per_min). C CONSTS(5) is v_1 in component V_in (uM_per_min). C CONSTS(6) is V_M2 in component V_2 (uM_per_min). C CONSTS(7) is K_2 in component V_2 (uM). C CONSTS(8) is K_y in component V_3 (uM). C CONSTS(9) is V_M3 in component V_3 (uM_per_min). C ALGBRC(3) is R_plus in component Ca_channels (dimensionless). C STATES(3) is rho in component Ca_channels (dimensionless). C ALGBRC(2) is gamma in component gamma (dimensionless). C CONSTS(10) is k_d in component Ca_channels (per_min). C CONSTS(11) is k_r in component Ca_channels (per_min). C CONSTS(12) is a in component gamma (per_min). C CONSTS(13) is d in component gamma (per_min). C RATES(1) is d/dt Z in component Ca (uM). C RATES(2) is d/dt Y in component Ca (uM). C RATES(3) is d/dt rho in component Ca_channels (dimensionless). C SUBROUTINE initConsts(CONSTS, RATES, STATES) REAL CONSTS(*), RATES(*), STATES(*) STATES(1) = 0.3 STATES(2) = 2.7 CONSTS(1) = 1 CONSTS(2) = 10 CONSTS(3) = 1 CONSTS(4) = 1 CONSTS(5) = 1 CONSTS(6) = 6.5 CONSTS(7) = 0.1 CONSTS(8) = 0.2 CONSTS(9) = 50 STATES(3) = 0.2 CONSTS(10) = 5000.0 CONSTS(11) = 5.0 CONSTS(12) = 10000.0 CONSTS(13) = 100.0 CONSTS(14) = CONSTS(4)+ CONSTS(5)*CONSTS(3) RETURN END SUBROUTINE computeRates(VOI, CONSTS, RATES, STATES, ALGBRC) REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*) RATES(3) = - ( CONSTS(10)*STATES(1) ** 4.00000*STATES(3)*1.00000)+ CONSTS(11)*(1.00000 - STATES(3)) ALGBRC(1) = CONSTS(6)*(STATES(1) ** 2.00000/(CONSTS(7) ** 2.00000+STATES(1) ** 2.00000)) ALGBRC(2) = (CONSTS(12)/CONSTS(13))*STATES(1) ** 4.00000*1.00000 ALGBRC(3) = ALGBRC(2)*(STATES(3)/(1.00000+ALGBRC(2))) ALGBRC(4) = CONSTS(3)*ALGBRC(3)*CONSTS(9)*(STATES(2) ** 2.00000/(CONSTS(8) ** 2.00000+STATES(2) ** 2.00000)) RATES(1) = (CONSTS(14) - ALGBRC(1))+ALGBRC(4)+( CONSTS(1)*STATES(2) - CONSTS(2)*STATES(1)) RATES(2) = (ALGBRC(1) - ALGBRC(4)) - CONSTS(1)*STATES(2) RETURN END SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC) REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*) ALGBRC(1) = CONSTS(6)*(STATES(1) ** 2.00000/(CONSTS(7) ** 2.00000+STATES(1) ** 2.00000)) ALGBRC(2) = (CONSTS(12)/CONSTS(13))*STATES(1) ** 4.00000*1.00000 ALGBRC(3) = ALGBRC(2)*(STATES(3)/(1.00000+ALGBRC(2))) ALGBRC(4) = CONSTS(3)*ALGBRC(3)*CONSTS(9)*(STATES(2) ** 2.00000/(CONSTS(8) ** 2.00000+STATES(2) ** 2.00000)) RETURN END