Milstein method for Stochastic SIR model - Mathlab program - Graph shows that deterministic not stochastic

clf
A=12;
la=0.01;
d=0.1;
ep=0.01;
mu=0.1;
r=2;
al=1;
k=0.1;
si= 0.01;
randn('state',1)
T = 300; Delta = 2^(-10); delta = Delta^2;
L = T/Delta; K = Delta/delta;
S = zeros(1,L+1);
I = zeros(1,L+1);
R = zeros(1,L+1);
S(1) = 60;
I(1) = 20;
R(1) = 20;
for n = 1:L
Winc1 = 0;
for k = 1:K
Winc1 = sqrt(delta)*randn;
end
S(n+1) = S(n) + (A-d*S(n)-((la*S(n)*I(n))/(1+k*I(n))))*Delta- ...
((si*S(n)*I(n))/(1+k*I(n)))*Winc1*sqrt(Delta)+...
0.5*si^2*((S(n)*I(n))/(1+k*I(n)))*Delta*(Winc1^2 - 1);
I(n+1) = I(n)+ Delta*(((la*S(n)*I(n))/(1+k*I(n)))-(d+ep+mu)*I(n)-
(r*I(n))/(1+al*I(n)))+...
((si*S(n)*I(n))/(1+k*I(n)))*Winc1*sqrt(Delta)+...
0.5*si^2*((S(n)*I(n))/(1+k*I(n)))*Delta*(Winc1^2 - 1);
R(n+1) = R(n) + (mu*I(n)+(r*I(n)/(1+I(n)*al))-d*R(n))*Delta;
end
subplot(231)
plot([0:Delta:T],S,'r-'), hold on
subplot(232)
plot([0:Delta:T],I,'g-')
subplot(233)
plot([0:Delta:T],R,'b-')
What can i do to get graph interms of stochastic increments. The given mathlab program graph does not include stochastic increments. May i know what term is missing in the above program. In out Stochastic SIR model:
S'(t) = (A-d*S(t)-((la*S(t)*I(t))/(1+k*I(t))))* dt -
((si*S(t)*I(t))/(1+k*I(t)))*dW(t);
I'(t) = (((la*S(t)*I(t))/(1+k*I(t)))-(d+ep+mu)*I(t)- (r*I(t))/(1+al*I(t)))*dt+...
((si*S(t)*I(t))/(1+k*I(t)))*dW(t);
R'(t) = (mu*I(t)+(r*I(t)/(1+I(t)*al))-d*R(t))*dt;
kindly help me.
I thank you.

3 个评论

Dear Sir/Madam,
Kindly help for the "Milstein method for Stochastic SIR model - Mathlab program - Graph shows that deterministic not stochastic" question.
thank you

请先登录,再进行评论。

回答(1 个)

I need Matlab code for Stochastic differential equations (SDDEs) via Euler-Maruyama numerical method, Milstein Scheme or Stochastics Runge-Kutta.
Note: Any method does not matter.
Example Logistc model or other models
where r is time delay
where a,b sigma are real number, T is terminianl time, r is time delay h(t) is initial function.
Thanks in Addvance
Ayoubi
t.ayoubi1985@gmail.com

1 个评论

This does not appear to be an Answer to what Rajasekar S P asked, and should have been a comment.
The volunteers do not appear to be familiar with SDDEs.
The SDDEs methods available from Mathworks appear to be listed at https://www.mathworks.com/help/finance/sde-objects.html#brg0w0_

请先登录,再进行评论。

类别

帮助中心File Exchange 中查找有关 Stochastic Differential Equation (SDE) Models 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by