Generated Code
The following is c code generated by the CellML API from this CellML file. (Back to language selection)
The raw code is available.
/* There are a total of 3 entries in the algebraic variable array. There are a total of 9 entries in each of the rate and state variable arrays. There are a total of 18 entries in the constant variable array. */ /* * VOI is time in component environment (second). * CONSTANTS[0] is EGF in component EGF (dimensionless). * CONSTANTS[1] is pro_EGFR in component pro_EGFR (dimensionless). * STATES[0] is EGFR in component EGFR (dimensionless). * STATES[1] is EGF_EGFR in component EGF_EGFR (dimensionless). * CONSTANTS[2] is k2_EGF_EGFR in component model_parameters (first_order_rate_constant). * CONSTANTS[3] is k1_EGF_EGFR in component model_parameters (first_order_rate_constant). * CONSTANTS[4] is EGFR_turnover in component model_parameters (first_order_rate_constant). * CONSTANTS[5] is k1_EGFR_phosphorylation in component model_parameters (first_order_rate_constant). * STATES[2] is pEGFR in component pEGFR (dimensionless). * STATES[3] is pEGFR_Akt in component pEGFR_Akt (dimensionless). * STATES[4] is Akt in component Akt (dimensionless). * CONSTANTS[6] is k1_pEGFR_degradation in component model_parameters (first_order_rate_constant). * CONSTANTS[7] is k1_Akt_phosphorylation in component model_parameters (first_order_rate_constant). * CONSTANTS[8] is k1_pEGFR_Akt in component model_parameters (first_order_rate_constant). * CONSTANTS[9] is k2_pEGFR_Akt in component model_parameters (first_order_rate_constant). * STATES[5] is pAkt in component pAkt (dimensionless). * CONSTANTS[10] is k1_pAkt_dephosphorylation in component model_parameters (first_order_rate_constant). * STATES[6] is S6 in component S6 (dimensionless). * STATES[7] is pAkt_S6 in component pAkt_S6 (dimensionless). * CONSTANTS[11] is k1_pAkt_S6 in component model_parameters (first_order_rate_constant). * CONSTANTS[12] is k2_pAkt_S6 in component model_parameters (first_order_rate_constant). * CONSTANTS[13] is k1_S6_phosphorylation in component model_parameters (first_order_rate_constant). * STATES[8] is pS6 in component pS6 (dimensionless). * CONSTANTS[14] is k1_pS6_dephosphorylation in component model_parameters (first_order_rate_constant). * ALGEBRAIC[0] is pEGFR_total in component pEGFR_total (dimensionless). * CONSTANTS[15] is pEGFR_scalefactor in component pEGFR_total (dimensionless). * ALGEBRAIC[1] is pAkt_total in component pAkt_total (dimensionless). * CONSTANTS[16] is pAkt_scalefactor in component pAkt_total (dimensionless). * ALGEBRAIC[2] is pS6_total in component pS6_total (dimensionless). * CONSTANTS[17] is pS6_scalefactor in component pS6_total (dimensionless). * RATES[0] is d/dt EGFR in component EGFR (dimensionless). * RATES[1] is d/dt EGF_EGFR in component EGF_EGFR (dimensionless). * RATES[2] is d/dt pEGFR in component pEGFR (dimensionless). * RATES[3] is d/dt pEGFR_Akt in component pEGFR_Akt (dimensionless). * RATES[4] is d/dt Akt in component Akt (dimensionless). * RATES[5] is d/dt pAkt in component pAkt (dimensionless). * RATES[7] is d/dt pAkt_S6 in component pAkt_S6 (dimensionless). * RATES[6] is d/dt S6 in component S6 (dimensionless). * RATES[8] is d/dt pS6 in component pS6 (dimensionless). */ void initConsts(double* CONSTANTS, double* RATES, double *STATES) { CONSTANTS[0] = 30.0; CONSTANTS[1] = 6.81902e4; STATES[0] = 6.81902e4; STATES[1] = 0.0; CONSTANTS[2] = 4.07490e-2; CONSTANTS[3] = 6.73816e-3; CONSTANTS[4] = 1.06386129269658e-4; CONSTANTS[5] = 1.92391e-2; STATES[2] = 0.0; STATES[3] = 0.0; STATES[4] = 4.33090e-2; CONSTANTS[6] = 9.97194e-2; CONSTANTS[7] = 3.05684e-2; CONSTANTS[8] = 1.55430e-5; CONSTANTS[9] = 5.17473e-3; STATES[5] = 0.0; CONSTANTS[10] = 3.27962e-2; STATES[6] = 3.54317e0; STATES[7] = 0.0; CONSTANTS[11] = 2.10189e-6; CONSTANTS[12] = 5.17940e-15; CONSTANTS[13] = 1.21498e-3; STATES[8] = 0.0; CONSTANTS[14] = 1.13102e-3; CONSTANTS[15] = 1.81735e-4; CONSTANTS[16] = 6.00588e1; CONSTANTS[17] = 4.98862e4; } void computeRates(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC) { RATES[0] = ( CONSTANTS[2]*STATES[1]+ CONSTANTS[4]*(CONSTANTS[1] - STATES[0])) - CONSTANTS[3]*CONSTANTS[0]*STATES[0]; RATES[1] = CONSTANTS[3]*CONSTANTS[0]*STATES[0] - ( CONSTANTS[2]*STATES[1]+ CONSTANTS[5]*STATES[1]); RATES[2] = ( CONSTANTS[5]*STATES[1]+ CONSTANTS[7]*STATES[3]+ CONSTANTS[9]*STATES[3]) - ( CONSTANTS[6]*STATES[2]+ CONSTANTS[8]*STATES[2]*STATES[4]); RATES[3] = CONSTANTS[8]*STATES[2]*STATES[4] - ( CONSTANTS[9]*STATES[3]+ CONSTANTS[7]*STATES[3]); RATES[4] = ( CONSTANTS[9]*STATES[3]+ CONSTANTS[10]*STATES[5]) - CONSTANTS[8]*STATES[2]*STATES[4]; RATES[5] = ( CONSTANTS[7]*STATES[3]+ CONSTANTS[12]*STATES[7]+ CONSTANTS[13]*STATES[7]) - ( CONSTANTS[10]*STATES[5]+ CONSTANTS[11]*STATES[5]*STATES[6]); RATES[7] = CONSTANTS[11]*STATES[5]*STATES[6] - ( CONSTANTS[12]*STATES[7]+ CONSTANTS[13]*STATES[7]); RATES[6] = ( CONSTANTS[12]*STATES[7]+ CONSTANTS[14]*STATES[8]) - CONSTANTS[11]*STATES[5]*STATES[6]; RATES[8] = CONSTANTS[13]*STATES[7] - CONSTANTS[14]*STATES[8]; } void computeVariables(double VOI, double* CONSTANTS, double* RATES, double* STATES, double* ALGEBRAIC) { ALGEBRAIC[0] = (STATES[2]+STATES[3])*CONSTANTS[15]; ALGEBRAIC[1] = (STATES[5]+STATES[7])*CONSTANTS[16]; ALGEBRAIC[2] = STATES[8]*CONSTANTS[17]; }