This study employs an SIR model to simulate a viral epidemic in a town of 300,000, considering an infection rate of
0.6day
-1
s
and 5-day average infection duration. The model tracks susceptible, infected, recovered, and immune populations over time. Introducing treatment that shortens recovery to 1.25 days, we assess the effect of treatment initiation timing
(h)
. Notably, with
h1.6,
infections remain below 2, unlike
h1.5
This prompts inquiry into whether treatment alone (
R
0
<1)
halts transmission. Encouragingly,
h1.6
shows potential, suggesting the role of early treatment in controlling outbreaks.

Introduction

In the town of Duckburg, a viral epidemic has been detected. The town has a population of 300,000 individuals, all of whom are currently susceptible to the virus. The outbreak began with the identification of a single infected case.

Epidemiological Parameters :

◼
  • Infection Rate: The infection rate is estimated to be
    0.6day
    -1
    s
    , indicating that an infected person can transmit the virus to 60% of their susceptible contacts per day.
  • ◼
  • Infectious Period: On average, infected individuals remain contagious for 5 days.
  • ◼
  • Immunity: Upon recovery, individuals gain immunity and cannot be infected again.
  • Model the progression of the viral epidemic in Duckburg over a certain time period using a basic epidemiological model. Predict the number of susceptible, infected, recovered, and immune individuals at different time intervals.

    Model Assumptions:

    ◼
  • The town has a closed population with no births, deaths, or external migration during the observation period.
  • ◼
  • Contacts between individuals are random, and the infection spreads uniformly in the population.
  • ◼
  • The population is well-mixed, meaning that each individual has an equal chance of coming into contact with any other individual.
  • ◼
  • The infectiousness of an individual is constant throughout their infectious period.
  • ◼
  • Recovery results in full immunity without any loss of immunity over the observation period.
  • ◼
  • Remember that this is a simplified model, and real-world epidemics can be more complex due to factors like variations in transmission rates, population demographics, and behavioral changes. The model provides a basic framework to understand the dynamics of an epidemic in a closed population.
  • In[]:=
    Clear["Global`*"]
    In[]:=
    (*Parameters*)​​(*Recoveryrate*)​​γ=0.2;​​(*infectionrate*)​​β=0.6;​​(*FoI*)​​λ[t_]:=β*i[t]/n​​(*TotalPopulationSize*)​​n=300000;
    (*3monthsindays*)​​tMax1=(0.3*365);
    In[]:=
    (*Definethesystemofdifferentialequations*)​​eqns={​​s'[t]==-λ[t]*s[t],​​i'[t]==λ[t]*s[t]-γ*i[t],​​r'[t]==γ*i[t],​​s[0]==299999,​​i[0]==1,​​r[0]==0};
    In[]:=
    sol=NDSolve[eqns,{s,i,r},{t,0,tMax1}];
    In[]:=
    Plot[Evaluate[{s[t],i[t],r[t]}/.sol],{t,0,tMax1},PlotLegends->{"Susceptible","Infected","Recovered"},AxesLabel->{"Time","Population"},AxesLabel->{"Time","Population"},PlotStyle->{Blue,Red,Green}]
    Out[]=
    Susceptible
    Infected
    Recovered
    In[]:=
    Plot[Evaluate[{i[t]}/.sol],{t,0,tMax1},PlotLegends->{"Infected"},AxesLabel->{"Time","Population"},PlotStyle->{Red},PlotRange->All]
    Out[]=
    Infected
    Fortunately, a treatment for the virus has been developed. While the treatment doesn’t provide instant recovery, it accelerates the healing process. On average, individuals experience recovery after 1.25 days of treatment. It’s important to note that the treatment doesn’t influence the virus’s transmission dynamics. Treated individuals remain as infectious as those who are infected but not receiving treatment.
    Additionally, individuals begin receiving treatment approximately 4 days after contracting the virus. This delay between infection and treatment initiation should be considered in the model to capture the impact of the treatment on the epidemic's progression.
    In[]:=
    Clear["Global`*"]
    In[]:=
    (*Parameters*)​​(*Recoveryrate*)​​γ=0.2;​​(*infectionrate*)​​β=0.6;​​(*TotalPopulationSize*)​​n=300000;
    (*therateoftreatmentinitiation*)
    In[]:=
    h=0.25;
    (*therateofrecoveryaftertreatment*)
    gammat=0.8;
    (*FoI*)​​λ[t_]:=β*(i[t]+T[t])/n;
    In[]:=
    (*Definethesystemofdifferentialequations*)​​eqns={​​s'[t]==-λ[t]*s[t],​​i'[t]==λ[t]*s[t]-γ*i[t]-h*i[t],​​r'[t]==γ*i[t]+gammat*T[t],​​T'[t]==h*i[t]-gammat*T[t],​​s[0]==299999,​​i[0]==1,​​r[0]==0,​​T[0]==0};
    In[]:=
    (*3monthsindays*)​​tMax1=(0.3*365);
    In[]:=
    sol=NDSolve[eqns,{s,i,r,T},{t,0,tMax1}];
    In[]:=
    (*Plotthesolutions*)​​Plot[Evaluate[{s[t],i[t],r[t],T[t]}/.sol],{t,0,tMax1},PlotLegends->{"Susceptible","Infected","Recovered","Treated"},AxesLabel->{"Time","Population"},AxesLabel->{"Time","Population"},PlotStyle->{Blue,Red,Orange,Purple}]
    Out[]=
    Susceptible
    Infected
    Recovered
    Treated
    In[]:=
    Plot[Evaluate[{i[t]+T[t]}/.sol],{t,0,tMax1},PlotLegends->{"Infected +Treated"},AxesLabel->{"Time","Population"},PlotStyle->{Red},PlotRange->All]
    Out[]=
    Infected +Treated
    At the peak of the epidemic around 37600 are infected - this includes the 𝐼 as well as the 𝑇(treated) compartment.
    In[]:=
    prevalenceTable=Table[{i[t]+T[t]}/.sol,{t,0,90}];
    In[]:=
    (*Displaythetableofprevalencevaluesinaformattedtable*)TableForm[Transpose[{Range[0,90],prevalenceTable}],TableHeadings->{None,{"Day","Prevalence"}}]
    Out[]//TableForm=
    Day
    Prevalence
    0
    1.
    1
    1.41977
    2
    1.92713
    3
    2.58321
    4
    3.45011
    5
    4.60302
    6
    6.13926
    7
    8.18739
    8
    10.9184
    9
    14.56
    10
    19.4159
    11
    25.8905
    12
    34.5231
    13
    46.0319
    14
    61.3737
    15
    81.8222
    16
    109.072
    17
    145.377
    18
    193.729
    19
    258.098
    20
    343.739
    21
    457.595
    22
    608.802
    23
    809.336
    24
    1074.8
    25
    1425.37
    26
    1886.81
    27
    2491.62
    28
    3279.85
    29
    4299.52
    30
    5605.75
    31
    7257.9
    32
    9313.33
    33
    11816.6
    34
    14783.6
    35
    18181.3
    36
    21907.5
    37
    25778.
    38
    29531.9
    39
    32860.2
    40
    35458.1
    41
    37085.4
    42
    37615.1
    43
    37053.2
    44
    35524.3
    45
    33234.6
    46
    30424.8
    47
    27330.5
    48
    24154.6
    49
    21054.1
    50
    18138.2
    51
    15473.8
    52
    13093.2
    53
    11003.9
    54
    9196.2
    55
    7649.87
    56
    6339.3
    57
    5236.79
    58
    4314.88
    59
    3547.78
    60
    2912.01
    61
    2386.79
    62
    1954.04
    63
    1598.25
    64
    1306.23
    65
    1066.89
    66
    870.962
    67
    710.716
    68
    579.755
    69
    472.794
    70
    385.479
    71
    314.231
    72
    256.114
    73
    208.719
    74
    170.078
    75
    138.58
    76
    112.907
    77
    91.9859
    78
    74.9377
    79
    61.047
    80
    49.7297
    81
    40.5095
    82
    32.9981
    83
    26.8791
    84
    21.8945
    85
    17.8341
    86
    14.5265
    87
    11.8324
    88
    9.63779
    89
    7.85022
    90
    6.39417
    Considering this, the feasibility of achieving transmission interruption solely through treatment can be assessed. Is the pace of treatment initiation achievable to achieve the goal of breaking the transmission chain?
    Lets change the treatment initiation rate

    Conclusion

    CITE THIS NOTEBOOK

    Modeling Viral Outbreak and Treatment in a SIR Model for Duckburg​
    by Athanasios Paraskevopoulos​
    Wolfram Community, STAFF PICKS, August 31, 2023
    ​https://community.wolfram.com/groups/-/m/t/3002391