Last verified · v1.0
Calculator · health
Sir Viral Infection Model Calculator
Model viral epidemic dynamics with the SIR framework. Input population size, R₀, and infectious period to simulate susceptible, infected, and recovered curves over time.
Inputs
SIR Model Output
—
Explain my result
Get a plain-English breakdown of your result with practical next steps.
The formula
How the
result is
computed.
Understanding the SIR Viral Infection Model
The SIR model divides a closed population of size N into three compartments: S (Susceptible), I (Infected), and R (Recovered/Removed). First formalized by Kermack and McKendrick in their landmark 1927 paper in the Proceedings of the Royal Society A, this framework remains the gold standard for modeling directly transmitted viral diseases and underpins nearly every modern infectious disease model in public health use today.
The Core Differential Equations
Three coupled ordinary differential equations govern the flow of individuals between compartments:
- dS/dt = −β(SI/N) — the rate at which susceptible individuals become infected through contact with infectious individuals
- dI/dt = β(SI/N) − γI — the net rate of change in the infected compartment, balancing new infections against recoveries
- dR/dt = γI — the rate at which infected individuals permanently recover or are removed from the transmission chain
The parameter β (beta) is the effective contact-transmission rate: the product of the average number of daily contacts and the per-contact probability of transmission. The parameter γ (gamma) is the recovery rate, equal to 1 divided by the mean infectious period in days. A 7-day infectious period yields γ = 0.143 per day; a 14-day period yields γ = 0.071 per day. Because S + I + R = N at all times, the system is fully determined by any two of the three equations.
The Basic Reproduction Number R₀
The most critical single output of any SIR analysis is the basic reproduction number: R₀ = β / γ. R₀ quantifies the average number of secondary cases generated by one infectious individual placed into a fully susceptible population. When R₀ exceeds 1 the epidemic grows exponentially; when R₀ falls below 1 the outbreak self-extinguishes. According to the CDC Principles of Epidemiology, R₀ is the primary threshold parameter for assessing epidemic potential and guiding interventions such as vaccination campaigns and contact tracing programs.
R₀ Reference Values for Common Viruses
- Measles: R₀ ≈ 12–18 — among the most transmissible pathogens ever documented
- SARS-CoV-2 (original Wuhan strain): R₀ ≈ 2.5–4
- Seasonal Influenza: R₀ ≈ 1.2–1.4
- Smallpox: R₀ ≈ 5–7
- Ebola (West Africa 2014 outbreak): R₀ ≈ 1.5–2.5
Herd Immunity Threshold
The SIR framework yields the herd immunity threshold (HIT) directly from R₀ using the formula: HIT = 1 − 1/R₀. For measles with R₀ = 15, approximately 93% of the population must be immune to halt sustained transmission. For seasonal influenza with R₀ = 1.3, roughly 23% immunity suffices. For SARS-CoV-2 with R₀ = 3, the threshold sits near 67%. These figures make the viral infection SIR calculator a foundational planning tool for vaccine coverage targets and outbreak containment strategy.
Interpreting the Epidemic Curve
Simulating the SIR model over time produces three time-series curves: S(t), I(t), and R(t). The epidemic peak — the moment of maximum simultaneous infections — occurs when dI/dt = 0, precisely when S/N equals 1/R₀. For a city of 1,000,000 people with R₀ = 2.5 and a 7-day infectious period, unmitigated spread generates a peak exceeding 150,000 simultaneous infections near day 70. The total attack rate — the fraction of the population ever infected across the full outbreak — is always less than 1 and is governed by the implicit transcendental equation derived from the model's conservation law, not simply 1 − 1/R₀.
Methodology and Sources
The mathematical foundation rests on the original derivation by Kermack and McKendrick (1927), further validated in Nature Methods: Mathematical models of epidemics (2020), and formalized at Wolfram MathWorld. The classical SIR model assumes a homogeneous closed population, uniform random mixing, and lifelong immunity upon recovery. Real outbreaks involve age structure, spatial heterogeneity, behavioral adaptation, and waning immunity — factors addressed by SEIR, SIRS, and age-stratified model extensions. Use SIR outputs as directional estimates and complement them with local surveillance data for operational public health decision-making.
Reference