Calculus 2First Differential Equations

The Logistic Equation

dP/dt = rP(1 − P/K) models growth with a limit.

Not started Jump to practice

The model $\frac{dP}{dt} = rP$ predicts endless exponential growth. Real populations run out of food or room and level off. The logistic equation builds that limit in, and you can solve it with separation of variables and partial fractions.

Why it works

Let the growth rate per individual, $\frac{1}{P}\frac{dP}{dt}$, start at $r$ when the population is small and fall in a straight line to 0 when $P$ reaches a carrying capacity $K$: $\frac{1}{P}\frac{dP}{dt} = r\left(1 - \frac{P}{K}\right)$. That gives $$\frac{dP}{dt} = rP\left(1 - \frac{P}{K}\right).$$ Reading the right side: it is 0 at $P = 0$ and $P = K$ (equilibria); positive between them, so the population rises toward $K$; negative above $K$, so it falls back. As a function of $P$ it is a downward parabola, largest at $P = \frac{K}{2}$: that is where growth is fastest.

Key idea

$\frac{dP}{dt} = rP\left(1 - \frac{P}{K}\right)$ has the solution $$P(t) = \frac{K}{1 + Ae^{-rt}}, \qquad A = \frac{K - P_0}{P_0}.$$ Equilibria: $P = 0$ and $P = K$. Growth is fastest when $P = \frac{K}{2}$.

Where the formula comes from

Separate: $\frac{dP}{P(1 - P/K)} = r\,dt$. Partial fractions give $$\begin{aligned} &\frac{1}{P(1 - P/K)} \\ &= \frac{K}{P(K - P)} \\ &= \frac{1}{P} + \frac{1}{K - P}. \end{aligned}$$ Integrate: $\ln|P| - \ln|K - P| = rt + C$, so $\frac{P}{K - P} = Be^{rt}$. Solving for $P$ gives $P = \frac{K}{1 + Ae^{-rt}}$ with $A = \frac{1}{B}$, and $t = 0$ gives $A = \frac{K - P_0}{P_0}$.

Worked example: Solving a logistic model

Solve $\frac{dP}{dt} = 0.5P\left(1 - \frac{P}{100}\right)$ with $P(0) = 20$.
  1. $K = 100$, $r = 0.5$, and $A = \frac{100 - 20}{20} = 4$.
  2. $P(t) = \frac{100}{1 + 4e^{-0.5t}}$.
  3. Check: $P(0) = \frac{100}{5} = 20$, and $P(t) \to 100$ as $t \to \infty$.

Answer: $P(t) = \frac{100}{1 + 4e^{-0.5t}}$

Logistic solutions with $K = 10$: from below they rise in an S-shape and level off at 10; from above they fall to 10. The slopes are steepest along $P = 5$.

Worked example: When is growth fastest?

For the model above, when is the population growing fastest?
  1. Fastest growth happens at $P = \frac{K}{2} = 50$.
  2. Solve $\frac{100}{1 + 4e^{-0.5t}} = 50$: $1 + 4e^{-0.5t} = 2$, so $e^{-0.5t} = \frac{1}{4}$.
  3. $t = \frac{\ln 4}{0.5} = 2\ln 4 \approx 2.77$.

Answer: $t = 2\ln 4 \approx 2.77$

Worked example: Reading K from an expanded form

A population follows $\frac{dP}{dt} = 0.03P - 0.0001P^{2}$. Find $r$ and $K$.
  1. Factor out $0.03P$: $$\begin{aligned} &0.03P\left(1 - \frac{0.0001}{0.03}P\right) \\ &= 0.03P\left(1 - \frac{P}{300}\right). \end{aligned}$$
  2. So $r = 0.03$ and $K = 300$.

Answer: $r = 0.03$, $K = 300$

Common mistake

Using $A = \frac{K}{P_0}$ instead of $A = \frac{K - P_0}{P_0}$. With $K = 100$, $P_0 = 20$ that gives $A = 5$ and $P(0) = \frac{100}{6} \ne 20$. Quick check: put $t = 0$ into your formula; you must get $P_0$ back.

Practice

Pass with 3 right answers, the last 2 in a row. Each right answer earns 3 XP.

Loading practice…

Builds on

Leads to

Sources and further reading

  • OpenStax Calculus Volume 2, Section 4.4: The Logistic Equation
  • Paul’s Online Math Notes (Lamar University), Calculus II: Modeling with Differential Equations
@teddyrookbook GitHub