Model Overview
For this app, we’ll use the basic compartmental SIR model. We allow for 3 different stages/compartments:
- S - uninfected and susceptible individuals
- I - infected and infectious individuals (note that these terms are often used interchangeably, but technically we are talking about someone who is infected and is infectious, i.e. can infect others)
- R - recovered/removed individuals. Those are individuals that do not further participate, either because they are now immune or because they died.
In addition to specifying the compartments of a model, we need to specify the dynamics determining the changes for each compartment. Broadly speaking, some processes increase the number of individuals in a given compartment/stage and other processes that lead to a reduction. Those processes are sometimes called inflows and outflows.
For our system, we specify the following processes/flows:
- Susceptible individuals (S) can become infected by infectious individuals (I) at some rate, b. This leads to the susceptible individual leaving the S compartment and entering the I compartment.
- Infected individuals recover and enter the recovered (R) compartment at some rate, g.
- Recovered individuals can lose immunity at rate w and return to the susceptible compartment.
- Natural births (into the S compartment at rate m) and deaths (from all compartments at rate n) are possible.
- The model allows a fraction of individuals to be vaccinated before the outbreak. Those individuals are moved into the R compartment before the start of the outbreak.
Model Implementation
The flow diagram and the set of equations which are used to implement this model are as follows:
\[S_{v} = (1-ef)S_0\] \[R_0 = efS_{v}\] \[\dot S =m - b SI - nS + wR\] \[\dot I = \ S I - g I - nI\] \[\dot R = g I - nR - wR\]
Here, S0 is the initial population of susceptibles, and Sv is the susceptible population after vaccination. Vaccinated individuals are moved to the R compartment before the start of the outbreak.