PathwayLab Research Edition Products
-----
 /
PathwayLab Research Edition
*Features
*Examples
*BioCircuit
<A MAPK Cascade
*Integral Feedback Control
*Cell Cycle Control in Xenopus Frog Eggs
*Buy Online
*Trial Version
*For More Information
*Life & Medical Sciences Solutions
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

Example: A MAPK Cascade

This model is taken from B. N. Kholodenko et al. 2002 1. The model can be launched in PathwayLab Research Edition from the Start menu, but its pathway diagram is also shown as plain graphics in the figure below. The file MAPKCascade.nb* used below was generated by Export to > Mathematica in the PathwayLab menu.

    [Graphics:HTMLFiles/mapk_1.gif]

A mitogen-activated protein kinase (MAPK) cascade

Load the package.

In[1]:=

Needs["PathwayLab`"]

Load the model and store it in a variable.

In[2]:=

mapk = Get[ToFileName[{"PathwayLab", "Examples"}, "MAPKCascade.m"]]

Out[2]=

-Pathway[9 state variables, 12 rate variables, 48 parameters]-

Here are the state variables of the pathway.

In[3]:=

states = StateVariables[mapk]

Out[3]=

{MKK—P, MKK—PP, MAPK—PP, MKKK, MKKK—P, MKKK—PP, MKK, MAPK—P, MAPK}

These are the rate variables of the pathway.

In[4]:=

rates = RateVariables[mapk]

Out[4]=

{v2, v8, v1, v3, v4, v5, v7, v6, v12, v9, v11, v10}

This lists mass balance equations.

In[5]:=

mbeqn = RateEquations[mapk, EquationFormat→MassBalances]/.V '[t] →0 ;

mbeqn//TableForm//TraditionalForm

Out[6]//TraditionalForm=

MKK—P^′(t) v5(t) - v6(t) + v7(t) - v8(t)
MKK—PP^′(t) v6(t) - v7(t)
MAPK—PP^′(t) v10(t) - v11(t)
MKKK^′(t) v4(t) - v1(t)
MKKK—P^′(t) v1(t) - v2(t) + v3(t) - v4(t)
MKKK—PP^′(t) v2(t) - v3(t)
MKK^′(t) v8(t) - v5(t)
MAPK—P^′(t)  -v10(t) + v11(t) - v12(t) + v9(t)
MAPK^′(t) v12(t) - v9(t)

Once the model equations are available in Mathematica, it is easy to analyze them in various ways. Here we will compute the stoichiometric matrix.

This gives the right-hand side of the mass balance equations.

In[7]:=

rhs = mbeqn/.lhs_ == rhs_:→rhs

Out[7]=

{v5[t] - v6[t] + v7[t] - v8[t], v6[t] - v7[t], v10[t] - v11[t], -v1[t] + v4[t], v1[t] - v2[t] + v3[t] - v4[t], v2[t] - v3[t], -v5[t] + v8[t], -v10[t] + v11[t] - v12[t] + v9[t], v12[t] - v9[t]}

This gives the stoichiometric matrix (in Mathematica 5.1 or later this can be directly accomplished by D[rhs,{#[t]&/@rates}]).

In[8]:=

m = Outer[D, rhs, #[t] &/@rates] ;

MatrixForm[m]

Out[9]//MatrixForm=

Here are the mass balance equations in matrix notation.

In[10]:=

MatrixForm[# '[t] &/@states] == MatrixForm[m] . MatrixForm[#[t] &/@rates]

Out[10]=

Linear dependent rows of the stoichiometric matrix imply that there are conserved moieties in the system. In this particular case it is easy to find these linear combinations by inspection. The corresponding linear relations between the state derivatives show that certain combinations of states are constant over time.

Here are the linear combinations and a test that they map zero.

In[11]:=

l1 = {1, 1, 0, 0, 0, 0, 1, 0, 0} ;

l2 = {0, 0, 1, 0, 0, 0, 0, 1, 1} ;

l3 = {0, 0, 0, 1, 1, 1, 0, 0, 0} ;

{l1 . m, l2 . m, l3 . m}//MatrixForm

Out[14]//MatrixForm=

( {{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}} )

These are the conservation equations.

In[15]:=

qeqn = Thread[{MKK_tot, MAPK_tot, MKKK_tot} == {l1, l2, l3} . (#[t] &/@states)]

Out[15]=

{MKK_tot == MKK[t] + MKK—P[t] + MKK—PP[t], MAPK_tot == MAPK[t] + MAPK—P[t] + MAPK—PP[t], MKKK_tot == MKKK[t] + MKKK—P[t] + MKKK—PP[t]}

This gives a list of rules for the total amounts of MKKK, MKK, and MAPK.

In[16]:=

totRules = ToRules[And @@ qeqn]/.t→0/.ToRules[And @@ InitialConditions[mapk]]

Out[16]=

{MKK_tot→180, MAPK_tot→360, MKKK_tot→200}

By utilizing the existence of conserved moieties in the system, the rate equations can be reduced.

This is the rate equation for all states except MKKK—PP, MKK—PP.

In[17]:=

reqn = Join[RateEquations[mapk][[{1, 4, 5, 7, 8, 9}]], qeqn] ;

In Mathematica 5 NDSolve can handle some differential algebraic equations; NDSolve[mapk,{t,0,300}] gives the same result and can be used in earlier Mathematica versions.

In[18]:=

sol = NDSolve[{reqn/.ParameterRules[mapk]/.totRules, InitialConditions[mapk]}, states, {t, 0, 300}]//First

Out[18]=

Here is a plot of MKKK—PP, MKK—PP, and MAPK—PP.

In[19]:=

Needs["Graphics`Colors`"] ;

Plot[Evaluate[{MKKK—PP[t], MKK—PP[t], MAPK—PP[t]}/.sol], {t, 0, 300}, PlotStyle→ {Red, Blue, Green}] ;

[Graphics:HTMLFiles/mapk_41.gif]

This gives a plot of MAPK, MAPK—P, MAPK—PP, and their sum.

In[21]:=

Plot[Evaluate[{MAPK[t], MAPK—P[t], MAPK—PP[t], MAPK[t] + MAPK—P[t] + MAPK—PP[t]}/.sol], {t, 0, 300}, PlotStyle→ {Red, Blue, Green, DarkGreen}] ;

[Graphics:HTMLFiles/mapk_43.gif]

An advantage of having the system in reduced form is that its steady state can be computed algebraically. For this example, the rate expressions all are rational functions of the state. Hence, NSolve can be used to find all steady-state solutions.

Here are the equations for the steady state, with functions that are explicitly dependent on time fixed to their values at t=0.

In[22]:=

sseqn = reqn/.ParameterRules[mapk]/.totRules/.{x_ '[t] →0, t→0} ;

This finds solutions of the steady-state equations (this may take several seconds). There are very many solutions!

In[23]:=

allsssol = NSolve[sseqn, #[0] &/@states] ;

Length[allsssol]

Out[24]=

47

This gives the subset of solutions that are both real and positive.

In[25]:=

sssol = Complement[allsssol, Cases[allsssol, {___, a_→Complex[_, _], ___} | {___, a_→b_ ? Negative, ___}]]

Out[25]=

The states approach these values close to t=100 in the transient simulation above.

In[26]:=

Thread[states→ (#[100] &/@states/.sol)]

Out[26]=

In this case FindRoot also finds the steady state starting in the initial conditions for the rate equations (which is not a good approximation to the steady state).

In[27]:=

FindRoot[sseqn, InitialConditions[mapk]/.Equal→List]

Out[27]=



1   Kholodenko, B. N., A. Kiyatkin, F. J. Bruggeman, et al. "Untangling the Wires:  A Strategy to Trace Functional Interactions in Signaling and Gene Networks."  Proceedings of the National Academy of Sciences of the United States of America 99, no. 20 (2002): 12841-12846 . [ online version ]

* Note: If you do not own a copy of Mathematica, you will need to download a trial version in order to view the notebook document.