Skip to main content

SEIR

The Susceptible-Exposed-Infected-Recovered model. Extends SIR with an exposed (latent) period before individuals become infectious.

Compartments

  • Susceptible: individuals who can be infected
  • Exposed: individuals who are infected but not yet infectious (latent period)
  • Infected: individuals who are currently infectious
  • Recovered: individuals who have recovered and are immune

Transitions

  • Susceptible → Exposed: mediated by transmission_rate and the number of Infected individuals
  • Exposed → Infected: spontaneous at incubation_rate
  • Infected → Recovered: spontaneous at recovery_rate

Parameters

Some parameters can be provided in multiple forms. For example, you can pass R0 instead of transmission_rate, incubation_period instead of incubation_rate, or infectious_period instead of recovery_rate, and they are automatically converted. If both forms are supplied, the rate form wins and the source is dropped silently. See calculated parameters for the conversion machinery.

ParameterStatusDefaultDescription
transmission_rateDefault0.3β\beta. Per-contact transmission rate.
R0Alternative to transmission_rateunsetBasic reproduction number. When passed, transmission_rate = R0 * recovery_rate / CONTACT_MATRIX_EIGENVALUE_ALL.
incubation_rateDefault0.2E → I rate.
incubation_periodAlternative to incubation_rateunsetDays from exposure to infectiousness. When passed, incubation_rate = 1 / incubation_period.
recovery_rateDefault0.1I → R rate.
infectious_periodAlternative to recovery_rateunsetDays infectious. When passed, recovery_rate = 1 / infectious_period.

Examples

Both examples below seed 0.1% of the population as Exposed at t=0 via an explicit initial_conditions block; the rest of the population starts in Susceptible. See Initial Conditions for other seeding options.

Rate form

curl -X POST https://epyscenario-api.isi.it/api/v1/simulations \
-H "Content-Type: application/json" \
-d '{
"model": {
"preset": "SEIR",
"parameters": {"transmission_rate": 0.3, "incubation_rate": 0.2, "recovery_rate": 0.1}
},
"population": {"name": "United_States"},
"simulation": {"start_date": "2024-01-01", "end_date": "2024-06-01", "Nsim": 10},
"initial_conditions": {
"method": "percentage",
"initial_percentages": {"Exposed": 0.1}
}
}'

Using R0 and period forms

curl -X POST https://epyscenario-api.isi.it/api/v1/simulations \
-H "Content-Type: application/json" \
-d '{
"model": {
"preset": "SEIR",
"parameters": {"R0": 2.5, "incubation_period": 5.0, "infectious_period": 10.0}
},
"population": {"name": "United_States"},
"simulation": {"start_date": "2024-01-01", "end_date": "2024-06-01", "Nsim": 10},
"initial_conditions": {
"method": "percentage",
"initial_percentages": {"Exposed": 0.1}
}
}'