Program 2.1 Simple SIR model
Consider a “closed population” without demographics (no births, deaths, or migration). The scenario we have in mind is a large naive population into which a low level of infectious agent is introduced and where the resulting epidemic occurs sufficiently quickly that demographic processes are not influential. We also assume homogeneous mixing, whereby intricacies affecting the pattern of contacts are discarded, yielding βSI as the transmission term. Given the premise that underlying epidemiological rates are constant, we get the following SIR equations:
Parameters
β | is the transmission rate and incorporates the encounter rate between susceptible and infectious individuals together with the probability of transmission. |
γ | is called the removal or recovery rate, though often we are more interested in its reciprocal (1/γ) which determines the average infectious period. |
S(0) | is the initial proportion of the population that are susceptible. |
I(0) | is the initial proportion of the population that are infectious. |
All rates are specified in days.
Requirements.
All parameters must be positive, and S(0)+I(0) ≤ 1
Files
C++ Program, Python Program, Fortran Program, Parameters, MATLAB Code.