Homework 1 — Cell Population Dynamics

Three problems: logistic growth of cells in a Petri dish (with Euler time-step error analysis), a two-species predator-prey system with phase-plane analysis, and the stiff three-species Bacillus / Staphylococcus / bacteriophage model.  ← back to index

Problem 1 — Logistic growth in a 120 cm² Petri dish

dP/dt = rP(1 − P/K),   K = 5×108 cells, r = 0.56/day. Solved with forward Euler exactly as the assignment requires, at three time steps (Δt = 1 hr, 1 min, 1 s) to show discretization error.

–
Time to 80% of K
–
P(3 days), Δt = 1 s
–
% error @3 d, Δt = 1 hr
–
% error @3 d, Δt = 1 min

Assignment question: can a seeding density reach 80% saturation in exactly 8 days? Drag the seeding slider and watch the “time to 80%” readout — with r fixed at 0.56/day you can solve for the required P₀ (≈13 730 cells/cm²), so yes, it is possible.

Problem 2 — Predator-prey system with logistic prey

dx/dt = x(1 − x/100) − 2.5xy,   dy/dt = −y + 0.25xy   (units: thousands of individuals; time in weeks). This is a predator-prey model (y benefits from x, x is harmed by y): if x goes extinct y starves; if y goes extinct x grows logistically to its carrying capacity of 100 (100 000).

Equilibrium points & Jacobian stability (as asked in the assignment)

Point (x*, y*)Eigenvalues of JacobianClassification
(0, 0)λ = 1, −1Saddle — unstable
(100, 0)λ = −1, 24Saddle — unstable (carrying capacity is not stable once predators exist)
(4, 0.384)λ = −0.02 ± 0.98iStable spiral (complex eigenvalues, negative real part) — the limit spiral seen in the phase plots

≈4000 individuals of x sustain ≈384 individuals of y at coexistence. The inward spiral in the dx–x and dy–y plots is the signature of the complex eigenvalues with negative real part.

Problem 3 — Bacillus subtilis, Staphylococcus aureus & bacteriophage (stiff system)

Correct model (option 1):  db/dt = k₁b(1 − b/CC₁) − xbp,   ds/dt = k₂s(1 − s/CC₂ − mb/CC₂),   dp/dt = p(xb − n). Bacillus grows logistically and is preyed on by the phage; Staph is poisoned by bacitracin (the mb term); the phage needs Bacillus to replicate.

Stiffness demo: the assignment has you read about stiff ODEs — drag the Δt slider to the right (Δt > ~0.05 hr) and watch the Euler solution blow up into numerical garbage, then bring it back to 0.001 hr. With the default parameters the Bacillus and phage settle into predator-prey oscillations around b = n/x = 9×105, while the Staph population is wiped out by bacitracin. All-zero populations are an equilibrium, but not a stable one: add one Staph cell and it grows — so a small perturbation drives the system away.