(* Generated by JWS Online *) (* This is an experimental feature of JWS Online. Please report any mistakes.*) (* Note that the following notable SBML entities or features are not supported in notebook outputyet: *) (* Events *) (* Constraints *) (* Units and UnitDefinitions *) (* AlgebraicRules *) (* conversionFactors *) variables = { G1[t], G2[t], T1[t], T2[t] }; initialValues = { G1[0] == 6.6, G2[0] == 10.3, T1[0] == 7.6, T2[0] == 0.41 }; rates = { vG1toT1, vG2toT2, vIn, vOut1T1, vOut1T2, vT2toT1 }; rateEquations = { vG1toT1 -> k1*G1[t]*T1[t], vG2toT2 -> k1*G2[t]*T2[t], vIn -> V\[LetterSpace]in, vOut1T1 -> (kp*T1[t])/(km + T1[t]), vOut1T2 -> (kp*T2[t])/(km + T2[t]), vT2toT1 -> epsilon*(-T1[t] + T2[t]) }; parameters = { V\[LetterSpace]in -> 0.36, epsilon -> 0.01, k1 -> 0.02, km -> 13.0, kp -> 6.0, compartment -> 1.0 }; assignments = { Tsum -> T1[t] + T2[t], Tdiff -> -T1[t] + T2[t] }; events = { }; speciesAnnotations = { }; reactionAnnotations = { }; units = { {"time" -> "", "metabolite" -> "", "extent" -> ""} }; (* Time evolution *) odes = { G1'[t] == 1.0*vIn -1.0*vG1toT1, G2'[t] == 1.0*vIn -1.0*vG2toT2, T1'[t] == 2.0*vG1toT1 +1.0*vT2toT1 -1.0*vOut1T1, T2'[t] == 2.0*vG2toT2 -1.0*vOut1T2 -1.0*vT2toT1 }; timeCourse = NDSolve[Join[odes, initialValues]//.rateEquations//.assignments//.parameters, variables, {t, 0, 100}]; (* Steady-state solution initialized with result of time evolution *) findRootEquations = odes /.D[_[t],t]->0; findRootVariables = Partition[Flatten[{#, #/.timeCourse/.t->100} &/@variables],2]; steadyStateVariables = FindRoot[findRootEquations//.rateEquations//.assignments//.parameters, findRootVariables, MaxIterations->100] fluxes = #//.assignments//.parameters/.steadyStateVariables&/@rateEquations (* Plot the time evolution of the variables *) plotTable=Table[Plot[variables[[i]]/.parameters/.timeCourse,{t,0,100},PlotLegends->variables[[i]],PlotRange->Full],{i,Length[variables]}]