Let the proportions of a population who are susceptible, infected and removed or recovered (now immune) be s(t), i(t), r(t) respectively. Then the SIR compartmental model can be written:
where t denotes time, β is the rate at which an infected individual infects others and α the rate of recovery/death. The last equation is not needed as s(t) + i(t) + r(t) = 1. The basic reproduction number R 0 = β/α. This model is simplistic, e.g. because it assumes exponentially-distributed dwell times in the compartments and ignores differences in behaviour arising from demographics. However, this model is more than a 'toy' model, and can be used to make quite useful predictions of the course of of epidemics. For example, for SIR models, a final size relation can be derived, which is a nonlinear equation for s ∞ , the proportion who remain uninfected when the epidemic is over. Starting with a susceptible population, the formula is
A feature of diseases such as influenza and those caused by coronaviruses such as SARS, MERS and COVID-19, is that individuals practice social distancing to reduce the contact rate β. If R 0 could be reduced below unity, an epidemic would fade away and could be got rid of, but except in a small isolated community some virus would always remain, and when social distancing was relaxed, the epidemic would begin anew. However, as the rate of growth of the number infected is (R 0 − 1)α, decreasing R 0 slows the epidemic, and reduces the percentage infected.
In this article a simple model of social distancing is introduced. Yu et al (2017) describe such models. What is novel here is that the proportion infected i(t) can be found in terms of s(t), and so a final-size equation can be derived, plus the peak proportion of the population infected. Such formulae may help planners trying to slow the epidemic to reduce peak demand on health services while preventing the total shutdown of industry.
The contact rate β is replaced by β(t) = β/(1 + γi(t)). Hence the contact rate decreases as infection levels rise, and increases again as they fall. As infection level i(t) tends to zero, we regain the regular SIR model, so R 0 is unchanged.
The function i(t)/(1 + γi(t)) is a Hill function. Many other functions could be used here, but with the Hill function an analytic solution is possible.
The new model is thus: 
The model is a reasonable model of behaviour, because numbers dying daily will be widely known, which is a slightly-lagged proxy for i(t). Hence individuals have the information on which to act. Government-mediated social distancing may also approximate the situation of reactive distancing. Figure 2 shows the evolution of proportions infected for the model with γ = 0 and γ = 20.
Dividing the model equations, we have
where a factor of i(s) has been cancelled out. Rearranging,
Writing x = ln(s), we have that
This is an ordinary differential equation for i(x), which can be solved by standard methods. These are: solve the homogeneous equation to get the complementary function, find the particular integral using for example the D-operator method, and find the unknown constant multiplying the complementary function by requiring that i = 0 when s = 1. This yields
where we have transformed back from x to s. When γ = R 0 the solution method fails, and the equation becomes
Solving this, we obtain
In general, the final-size equation for s ∞ , the number never infected, can now be found by setting i(t) = 0. Then
Equation (4) can be solved numerically for s ∞ using for example the Newton-Raphson method of iteration, and converges quickly. For the special case, (s − 1)/R 0 = s ln s. Also of interest is the peak proportion infected. Setting di/ ds = 0 in (1) yields i max = R 0 γ (s max − 1/R 0 ), and substituting in (2) gives the nonlinear equation
This can be solved on taking logarithms, when As γ → 0 we regain s max = 1/R 0 . As γ → ∞, the left-hand side of (4) goes to zero as s ∞ < 1. Then s ∞ → 1/R 0 , the minimum number to give herd immunity and bring the epidemic to an end. Thus extreme reactive social distancing gives the minimum number of infections possible, whilst necessarily prolonging the duration of the epidemic.
For the special case, s = exp(−(1 − 1/R 0 )) and i max = s − 1/R 0 . These special-case solutions can be found either from (3) or by using L'Hospital's rule. Figure 3 shows s ∞ and i max plotted against γ.
Finally, from (5), as γ → ∞, the effective reproduction number at peak infection R 0 /(1 + γi max ) → 1.
An epidemic model with reactive social distancing has been described, for which the final number of infections and the peak infection proportion can be found analytically. Unlike a fixed reduction in contact rate, reactive social distancing allows the epidemic to complete and not restart when distancing is relaxed. In the limit that γ → ∞ the number left uninfected decreases to 1/R 0 . How could this model be used as a planning aid when the value of γ is unknown? The model or a more sophisticated one could be formally or informally fitted to data and the effective value of γ estimated. That would give the likely course of the epidemic. One could then see how much more (or less) social distancing would be required for the optimal outcome that balances mortality and pressure on health services against economic disruption.