Measles-ish SEIRS Models in Python
Model 1
We're going to explore how for an ODE-type model, with a constant birth rate (supply of new susceptibles), and initial conditions that are endemic measles-ish, we get a damped oscillator as output.
The periodicity and rate of damping would both be interesting to explore.
Cf. http://math.uchicago.edu/~shmuel/Modeling/Keeling%20and%20Rohani/chap%202.pdf. "An important issue for any dynamical system concerns the manner in which a stable equilibrium is eventually approached. Do trajectories undergo oscillations as they approach the equilibrium state or do they tend to reach the steady state smoothly? The SIR system is an excellent example of a 'damped oscillator,' which means the inherent dynamics contain a strong oscillatory component, but the amplitude of these fluctuations declines over time as the system equilibrates (Figure 2.5). Figure 2.6, shows how the period of oscillations (as determined by equation (2.23) in Box 2.4) changes with the transmission rate (β) and the infectious period (1/γ ). We note that (relative to the infectious period) the period of oscillations becomes longer as the reproductive ratio approaches one; this is also associated with a slower convergence toward the equilibrium." (Figures not shown)
42 / 50
2 / 10
Run to view results
Run to view results
You can easily play with different values of beta & birth rate and see how it varies the periodicity of the infectious curve and the rate at which it "damps". But the main takeaway here is that this type of model converges at a steady-state (in the time domain).
Questions
Run to view results
Model 2. CCS Quick Explorer
Here we create a toy SEIRS Endemic Measles-ish model with discrete number of individuals. We stop early upon elimination. Initially this was deterministic but we've added some stochasticity to avoid unhelpful artifacts that can emerge from a purely deterministic approach.
1 / 20
10 / 50
1000000 / 1000000
Run to view results
We expect to see that for sub-CCS population sizes we eliminate. For others we reach endemecity.
Depending on some of the values in our model, the epidemic will 'burn itself out' (eliminate) or persist. The most important values which determine that are beta, cbr, and population. For a given beta & cbr, there will be a threshold population. For example, with beta=2 and cbr=25, the threshold population for CCS appears experimentally to be about 375,000.
You can adjust those values yourself and see what you find.
Note that there is no stochasticity in the above model, which means we can repeatedly maintain endemecity at lower populations by going really "close to the line" during the low prevalence periods. Adding stochasticity will result in more frequent elimination, meaning the true CCS population threshold will be higher than what this toy example shows.
CCS Sweeps & Surface
Now let's run a sweep across a range of beta and cbr values of interest and see at what population we hit CCS.
Run to view results
Note that these values seem higher (for low CBR settings) than I've heard before.