MATLAB "The SIR Model"
Budget: £10 – £20 GBP
SIR model in the form of mass-approximation and network-based application.
Use the SIR simulator written in Matlab (SIR_sim.mlx) by Giovanni Valentini.
In this simulator, the model parameters are as follow:
% Model parameters
beta = 5*10^-9; % rate of infection
gamma = 0.3; % rate of recovery (try also 0.3/0.2/0.12/0.07)
delta = 0.0; % rate of immunity loss
N = 6*10^7; % Total population N = S + I + R
I0 = 10; % initial number of infected
T = 300; % period of 300 days
dt = 1/4; % time interval of 6 hours (1/4 of a day)
fprintf('Value of parameter R0 is %.2f',N*beta/gamma)
and the value of R0 is calculated by N*beta/gamma.
In this exercise, you will alter the value of R0 by simply changing gamma while keeping
N and beta the same.
Setting gamma to 0.3, 0.2, 0.12 and 0.07, you will obtain R0 equals to 1, 1.5, 2.5 and 4.28 respectively.
The simulator presents three sets of results:
The first two sets are obtained from the basic SIR model (with no immunity loss) with the first graph showing the number of individuals in the S, I and R groups over time. The second graph shows the rate in which infection increases.
The last graph shows the number of individuals in S, I and R groups with the loss of immunity after 60 days.
Run the simulator using the range of gamma value listed above. Refer to the relevant graphs you have obtained in Matlab here, and describe
a) how the spread of infection is altered by R0,
b) the effects of immunity loss.
Use the SIR simulator written in Matlab (SIR_sim.mlx) by Giovanni Valentini.
In this simulator, the model parameters are as follow:
% Model parameters
beta = 5*10^-9; % rate of infection
gamma = 0.3; % rate of recovery (try also 0.3/0.2/0.12/0.07)
delta = 0.0; % rate of immunity loss
N = 6*10^7; % Total population N = S + I + R
I0 = 10; % initial number of infected
T = 300; % period of 300 days
dt = 1/4; % time interval of 6 hours (1/4 of a day)
fprintf('Value of parameter R0 is %.2f',N*beta/gamma)
and the value of R0 is calculated by N*beta/gamma.
In this exercise, you will alter the value of R0 by simply changing gamma while keeping
N and beta the same.
Setting gamma to 0.3, 0.2, 0.12 and 0.07, you will obtain R0 equals to 1, 1.5, 2.5 and 4.28 respectively.
The simulator presents three sets of results:
The first two sets are obtained from the basic SIR model (with no immunity loss) with the first graph showing the number of individuals in the S, I and R groups over time. The second graph shows the rate in which infection increases.
The last graph shows the number of individuals in S, I and R groups with the loss of immunity after 60 days.
Run the simulator using the range of gamma value listed above. Refer to the relevant graphs you have obtained in Matlab here, and describe
a) how the spread of infection is altered by R0,
b) the effects of immunity loss.
Related categories:
Matlab and Mathematica
Algorithm
Electrical Engineering
Mathematics
Telecommunications Engineering