05
Deriving first-moment equations
A moment equation follows from stochastic event changes and rates; it is not obtained by averaging a deterministic equation informally.
A linear infection–removal process
Let \(I(t)\) change through
| Event | Change | Rate in state \(i\) |
|---|---|---|
| New infectious individual | +1 | \(\lambda i\) |
| Removal | −1 | \(\mu i\) |
This early-outbreak branching model ignores susceptible depletion so that the rates are linear.
Conditional expected change
Given \(I(t)=i\), over a short interval \(h\),
Divide by \(h\) and let \(h\) tend to zero:
Use linearity of expectation
Because the rate is linear in \(I\), the right-hand side contains only the first moment. The equation is closed.
Solution and interpretation
If \(\lambda>\mu\), the expected infectious population grows; if \(\lambda<\mu\), it declines. Positive expected growth does not rule out extinction in individual stochastic paths.
Interactive Python laboratory
Output
Run the code to see the result.
What was—and was not—assumed
The equation describes the exact first moment of this linear birth–death model. It is not a deterministic approximation to one trajectory. Its derivation used the stochastic transition rates and expectation. Nonlinear epidemic rates will introduce higher moments; lesson 07 explains that problem.
What this lesson adds
You can now derive a first-moment differential equation from event changes and rates, use conditional expectation and linearity, solve the closed linear equation and compare it with Monte Carlo evidence.