4
Nonlinear Systems
Partials ยท Nullclines ยท Jacobian ยท Coexistence ยท Hopf
โ Partial Derivatives
The idea โ change only one variable at a time
A partial derivative $\frac{\partial f}{\partial x}$ asks: "If I change $x$ by a tiny bit while holding every other variable frozen, how does $f$ change?"How to compute: Treat all variables except $x$ as plain numbers (constants). Then differentiate normally with respect to $x$ only.
Three worked examples
1. $f(x,y)=3x^2y+5y^3$$\frac{\partial f}{\partial x}=6xy+0=6xy$ (treat $y$ as a constant; the $5y^3$ term has no $x$ โ becomes 0)
$\frac{\partial f}{\partial y}=3x^2+15y^2$ (treat $x$ as a constant; $3x^2$ acts like a coefficient)
2. $g(M,S)=3M-M^2-2MS$
$\frac{\partial g}{\partial M}=3-2M-2S$ (product rule on $2MS$: treat $S$ as a constant, differentiate $M$)
$\frac{\partial g}{\partial S}=-2M$ (only the $-2MS$ term contains $S$; $3M$ and $-M^2$ have no $S$)
3. $h(N,P)=\frac{wN}{d+N}P$
$\frac{\partial h}{\partial N}=\frac{wd}{(d+N)^2}P$ (quotient rule on $\frac{wN}{d+N}$, treating $P$ as constant)
$\frac{\partial h}{\partial P}=\frac{wN}{d+N}$ (the whole fraction is just a constant with respect to $P$; differentiate $P$)
๐ Tangent Plane (Linear Approximation)
The formula
For small changes $\Delta x$ and $\Delta y$ near a point $(x_0,y_0)$:
$$\Delta f \approx \frac{\partial f}{\partial x}\bigg|_{(x_0,y_0)}\Delta x + \frac{\partial f}{\partial y}\bigg|_{(x_0,y_0)}\Delta y$$
This is the best linear approximation to $f$ near $(x_0,y_0)$. It's the same idea as the Jacobian, just applied to a single function.
Full exam-style worked example (BMI)
$B(W,H)=703W/H^2$ where $W$=weight (lbs), $H$=height (inches).Starting point: $W_0=160$, $H_0=60$. Changes: $\Delta W=-9$ (lost 9 lbs), $\Delta H=+1$ (grew 1 inch).
Step 1 โ compute partial derivatives at $(160,60)$:
$\frac{\partial B}{\partial W}=\frac{703}{H^2}\bigg|_{H=60}=\frac{703}{3600}\approx 0.195$
$\frac{\partial B}{\partial H}=703W\cdot(-2)H^{-3}\bigg|_{(160,60)}=\frac{-1406\times 160}{216000}\approx -1.041$
Step 2 โ apply linear approximation:
$\Delta B\approx(0.195)(-9)+(-1.041)(1)\approx-1.755-1.041\approx\mathbf{-2.8}$
The patient's BMI decreases by approximately 2.8 points.
๐ฏ Nullclines & Finding All Equilibria
What is a nullcline?
A nullcline for variable $X$ is the set of points where $X'=0$ โ i.e., where $X$ is momentarily not changing.An equilibrium point (EP) is where BOTH $X'=0$ AND $Y'=0$ simultaneously โ i.e., the intersection of an $X$-nullcline and a $Y$-nullcline.
๐ฅ Complete procedure for finding all EPs in a 2D system
Set $X'=0$. Factor the expression. This gives you conditions like "$X=0$ OR [some equation relating $X$ and $Y$]."
Set $Y'=0$. Factor. This gives you more conditions.
Consider all combinations. If $X'=0$ gives "$X=0$ or $f(X,Y)=0$" and $Y'=0$ gives "$Y=0$ or $g(X,Y)=0$" โ you have $2\times 2=4$ cases to check.
Solve each case. Substitute one condition into the other. Some cases give impossible solutions (discard) or give actual $(X^*,Y^*)$ values.
State all EPs found. A biologically valid EP must have $X^*\geq 0$ and $Y^*\geq 0$.
Full worked example โ Frogs & Salamanders (from review session)
$$X'=5X-X^2-XY=X(5-X-Y)$$
$$Y'=10Y-Y^2-6XY=Y(10-Y-6X)$$
Step 1 โ Set $X'=0$:$X(5-X-Y)=0$ โ Either $X=0$ or $5-X-Y=0$ (i.e., $Y=5-X$)
Step 2 โ Set $Y'=0$:
$Y(10-Y-6X)=0$ โ Either $Y=0$ or $10-Y-6X=0$ (i.e., $Y=10-6X$)
Step 3 โ Four cases:
| Case | From $X'=0$ | From $Y'=0$ | Solve | EP found |
|---|---|---|---|---|
| 1 | $X=0$ | $Y=0$ | โ | $(0,0)$ |
| 2 | $X=0$ | $Y=10-6X=10$ | $Y=10$ | $(0,10)$ |
| 3 | $Y=5-X$ | $Y=0$ | $5-X=0$โ$X=5$ | $(5,0)$ |
| 4 | $Y=5-X$ | $Y=10-6X$ | $5-X=10-6X$โ$5X=5$โ$X=1$, $Y=4$ | $(1,4)$ |
Second worked example โ Mouth Microbiome (M. mutans & S. sanguinis)
$$M'=3M-M^2-2MS=M(3-M-2S)$$
$$S'=4S-2MS-2S^2=S(4-2M-2S)=2S(2-M-S)$$
$M'=0$: $M=0$ or $M=3-2S$$S'=0$: $S=0$ or $S=2-M$
Four cases:
• $M=0,S=0$: EP = $(0,0)$
• $M=0$: $S=2-0=2$. EP = $(0,2)$
• $S=0$: $M=3-2(0)=3$. EP = $(3,0)$
• $M=3-2S$ and $S=2-M$: sub โ $M=3-2(2-M)=3-4+2M$โ$-M=-1$โ$M=1$, $S=1$. EP = $(1,1)$
Four EPs: $(0,0)$, $(0,2)$, $(3,0)$, $(1,1)$.
Jacobian stability analysis โ procedure
โ Schematic illustration only โ not drawn to scale or from simulation.
๐งฎ The Jacobian Matrix
What the Jacobian does
Near an equilibrium point, a nonlinear system behaves approximately like a linear one. The Jacobian $J$ is the matrix of that linear approximation. It tells you the stability of the EP.For a system $X'=f(X,Y)$, $Y'=g(X,Y)$: $$J=\begin{pmatrix}\frac{\partial f}{\partial X}&\frac{\partial f}{\partial Y}\\\frac{\partial g}{\partial X}&\frac{\partial g}{\partial Y}\end{pmatrix}$$ Each entry is a partial derivative. Then evaluate at the EP $(X^*,Y^*)$.
๐ฅ Step-by-step Jacobian procedure
Write down both equations: $f(X,Y)=X'$ and $g(X,Y)=Y'$
Compute all four partial derivatives: $\partial f/\partial X$, $\partial f/\partial Y$, $\partial g/\partial X$, $\partial g/\partial Y$
Substitute the EP $(X^*,Y^*)$ into each partial derivative to get numbers
Compute $(J_{11}+J_{22})$ (sum of diagonal entries) and $(J_{11}J_{22}-J_{12}J_{21})$
Classify the EP using the diagonal sum/det rules below
Full worked example โ Frogs & Salamanders at EP $(1,4)$
$f=X(5-X-Y)=5X-X^2-XY$, $g=Y(10-Y-6X)=10Y-Y^2-6XY$Partial derivatives:
$\frac{\partial f}{\partial X}=5-2X-Y$, $\frac{\partial f}{\partial Y}=-X$
$\frac{\partial g}{\partial X}=-6Y$, $\frac{\partial g}{\partial Y}=10-2Y-6X$
Evaluate at $(X^*,Y^*)=(1,4)$:
$J_{11}=5-2(1)-4=\mathbf{-1}$, $J_{12}=-1=\mathbf{-1}$
$J_{21}=-6(4)=\mathbf{-24}$, $J_{22}=10-2(4)-6(1)=10-8-6=\mathbf{-4}$
$$J=\begin{pmatrix}-1&-1\\-24&-4\end{pmatrix}$$ sum of diag $= -1+(-4)=-5$, $(J_{11}J_{22}-J_{12}J_{21})=(-1)(-4)-(-1)(-24)=4-24=-20$
Classify: $(J_{11}J_{22}-J_{12}J_{21})=-20<0$ โ Saddle point (unstable).
๐ Classifying Equilibria via diagonal sum and det
๐ The complete classification rules
| Condition | EP Type | Stable? |
|---|---|---|
| $(J_{11}J_{22}-J_{12}J_{21})<0$ | Saddle point | No (always unstable) |
| $(J_{11}J_{22}-J_{12}J_{21})>0$, $(J_{11}+J_{22})<0$, $(J_{11}+J_{22})^2>4(J_{11}J_{22}-J_{12}J_{21})$ | Stable node | Yes |
| $(J_{11}J_{22}-J_{12}J_{21})>0$, $(J_{11}+J_{22})>0$, $(J_{11}+J_{22})^2>4(J_{11}J_{22}-J_{12}J_{21})$ | Unstable node | No |
| $(J_{11}J_{22}-J_{12}J_{21})>0$, $(J_{11}+J_{22})<0$, $(J_{11}+J_{22})^2<4(J_{11}J_{22}-J_{12}J_{21})$ | Stable spiral | Yes |
| $(J_{11}J_{22}-J_{12}J_{21})>0$, $(J_{11}+J_{22})>0$, $(J_{11}+J_{22})^2<4(J_{11}J_{22}-J_{12}J_{21})$ | Unstable spiral | No |
| $(J_{11}J_{22}-J_{12}J_{21})>0$, $(J_{11}+J_{22})=0$ | Center / Hopf bifurcation | Borderline |
๐ค Coexistence of Populations
Definition and procedure
Two species coexist if both survive long-term โ the stable EP has both coordinates positive.Find all EPs of the system
For each EP, compute $J$ and find eigenvalues โ identify which EP is stable (all Re(ฮป) < 0)
Check the stable EP: if both coordinates > 0 โ coexistence. If one = 0 โ that species goes extinct. If one < 0 โ biologically impossible, not a real EP.
๐ฅ Common mistake: forgetting to check signs
A "coexistence EP" like $(-2, 5)$ is biologically impossible โ populations can't be negative. Always check $X^*\geq 0$ and $Y^*\geq 0$ before calling it coexistence.
Phase portraits โ continuous-time stability types
โ Schematic illustration only โ not drawn to scale or from simulation.
๐ Finding the Hopf Bifurcation Parameter
Glycolysis example (Class 18) โ fully worked
$$S'=1-cSP^2 \qquad P'=cSP^2-P$$
Find EP: $S'=0$: $cSP^2=1$. $P'=0$: $cSP^2=P$ โ $P=1$. Then $cS(1)=1$โ$S=1/c$. EP: $(1/c,1)$Compute Jacobian at EP:
$\frac{\partial S'}{\partial S}=-cP^2\big|_1=-c$ $\frac{\partial S'}{\partial P}=-2cSP\big|_{(1/c,1)}=-2c(1/c)(1)=-2$
$\frac{\partial P'}{\partial S}=cP^2\big|_1=c$ $\frac{\partial P'}{\partial P}=(2cSP-1)\big|_{(1/c,1)}=2-1=1$
$$J=\begin{pmatrix}-c&-2\\c&1\end{pmatrix}$$ Find Hopf: Sum of diagonal entries $= -c+1=1-c$. Set to zero: $1-c=0$ โ $c^*=1$
Verify: $(J_{11}J_{22}-J_{12}J_{21})\big|_{c=1}=(-1)(1)-(-2)(1)=-1+2=1>0$ โ
Interpret: For $c<1$: diagonal sum $(1-c)>0$ โ unstable spiral + limit cycle (oscillations!). For $c>1$: diagonal sum $(1-c)<0$ โ stable spiral (no oscillations).
โฆ Unit 4 Practice Quiz
โฆ Quiz โ Nullclines, Jacobian & Stability
Q1. For $f(M,S)=3M-M^2-2MS$, what is $\partial f/\partial S$?
Q2. For the system $X'=X(5-X-Y)$, $Y'=Y(10-Y-6X)$, how many equilibrium points are there?
Q3. A Jacobian at an EP has diagonal sum $(J_{11}+J_{22})=-2$ and $(J_{11}J_{22}-J_{12}J_{21})=-5$. The EP is:
Q4. The diagonal sum $(J_{11}+J_{22})=w-0.3$ at an EP with $(J_{11}J_{22}-J_{12}J_{21})=2>0$. The Hopf bifurcation occurs at:
Q5. The only stable EP is $(2,5)$. Do the species coexist?
Q6. The triangular Jacobian at a boundary EP is $J=\begin{pmatrix}-3&7\\0&-2\end{pmatrix}$. The eigenvalues are: