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 2 entries in the algebraic variable array.
C There are a total of 1 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 (minute).
C CONSTS(1) is PLA in component atrial_natriuretic_peptide (mmHg).
C CONSTS(2) is PRA in component atrial_natriuretic_peptide (mmHg).
C CONSTS(9) is ANP in component total_ANP_secreted (dimensionless).
C CONSTS(7) is ANPL in component total_ANP_secreted (dimensionless).
C CONSTS(8) is ANPR2 in component total_ANP_secreted (dimensionless).
C CONSTS(10) is ANP1 in component ANP_into_circulation (dimensionless).
C CONSTS(3) is ANPKNS in component parameter_values (dimensionless).
C CONSTS(4) is ANPINF in component parameter_values (dimensionless).
C STATES(1) is ANPC in component ANP_in_plasma (dimensionless).
C CONSTS(5) is ANPTC in component parameter_values (minute).
C ALGBRC(2) is ANPX in component ANP_effect_on_renal_afferent_arteriolar_resistance (dimensionless).
C CONSTS(6) is ANPXUL in component parameter_values (dimensionless).
C ALGBRC(1) is ANPX1 in component ANP_effect_on_renal_afferent_arteriolar_resistance (dimensionless).
C RATES(1) is d/dt ANPC in component ANP_in_plasma (dimensionless).
C
      SUBROUTINE initConsts(CONSTS, RATES, STATES)
      REAL CONSTS(*), RATES(*), STATES(*)
      CONSTS(1) = 2
      CONSTS(2) = 0.00852183
      CONSTS(3) = 0
      CONSTS(4) = 0
      STATES(1) = 1.0
      CONSTS(5) = 4
      CONSTS(6) = 10
      CONSTS(7) = TERNRY( (CONSTS(1) - 1.00000)*1.00000.LT.0.00000, 0.00000,  (CONSTS(1) - 1.00000)*1.00000)
      CONSTS(8) = TERNRY( (CONSTS(2)+1.00000)*2.00000.LT.0.00000, 0.00000,  (CONSTS(2)+1.00000)*2.00000)
      CONSTS(9) = (CONSTS(7)+CONSTS(8))/3.00000
      CONSTS(10) = TERNRY(CONSTS(3).GT.0.00000, CONSTS(3), CONSTS(9)+CONSTS(4))
      RETURN
      END
      SUBROUTINE computeRates(VOI, CONSTS,  RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      RATES(1) = (CONSTS(10) - STATES(1))/CONSTS(5)
      RETURN
      END
      SUBROUTINE computeVariables(VOI, CONSTS, RATES, STATES, ALGBRC)
      REAL VOI, CONSTS(*), RATES(*), STATES(*), ALGBRC(*)
      ALGBRC(1) = CONSTS(6) - CONSTS(6)/( 0.555556*(1.00000+STATES(1)))
      ALGBRC(2) = TERNRY(ALGBRC(1).LT.- 1.00000, - 1.00000, ALGBRC(1))
      RETURN
      END
      REAL FUNCTION TERNRY(TEST, VALA, VALB)
      LOGICAL TEST
      REAL VALA, VALB
      IF (TEST) THEN
        TERNRY = VALA
      ELSE
        TERNRY = VALB
      ENDIF
      RETURN
      END