How to plot bifurcation with Delay Differential equations?

조회 수: 11 (최근 30일)
Kitipol Jankaew
Kitipol Jankaew 2020년 11월 14일
댓글: Priya Verma 2024년 3월 26일
I want to draw the bifurcation diagram for the model.
All parameters are positve constant.
The value of parameters are as:
A1 = 0.8463, A2 = 0.6891, K = 1.2708, beta1 = 0.4110, beta2 = 0.1421,
The diagram are vary tau from 68 to 72 in steps of 0.001. For inital conditions X(0) = 0.26 and Y(0) = 0.58.
Please ansers me for Matlab code to plot the bifurcation diagrams.
  댓글 수: 7
kaushik dehingia
kaushik dehingia 2021년 2월 11일
이동: Dyuman Joshi 2024년 3월 15일
Can anyone share the Bifurcation diagram code for a delayed system? I t will be very helpful for me.
kaushik dehingia
kaushik dehingia 2021년 2월 11일
Can anyone share me the bifurcation code?

댓글을 달려면 로그인하십시오.

채택된 답변

Alan Stevens
Alan Stevens 2020년 11월 17일
How about the following for your loop (it assumed you have defined tau earlier in the file):
for j=1:N+1
if t(j)<=tau
xd = x(1);
yd = y(1);
else
d = ceil((t(j)-tau)/h);
xd = x(d);
yd = y(d);
end
t(j+1)=t(j)+h;
%tempx(j+1)=tempx(j)+h;
%tempy(j+1)=tempy(j)+h;
k1x=fx(t(j), x(j), y(j));
k1y=fy(t(j), xd, yd, y(j));
%k1y=fy(t(j), x(j), y(j), tempx(j), tempy(j));
k2x=fx(t(j)+h/2, x(j)+h/2*k1x, y(j)+h/2*k1y);
k2y=fy(t(j)+h/2, xd+h/2*k1x, yd+h/2*k1y, y(j)+h/2*k1y);
%k2y=fy(t(j)+h/2, x(j)+h/2*k1x, y(j)+h/2*k1y, tempx(j)+h/2*k1x, tempy(j)+h/2*k1y);
k3x=fx(t(j)+h/2, x(j)+h/2*k2x, y(j)+h/2*k2y);
k3y=fy(t(j)+h/2, xd+h/2*k2x, yd+h/2*k2y, y(j)+h/2*k2y);
%k3y=fy(t(j)+h/2, x(j)+h/2*k2x, y(j)+h/2*k2y, tempx(j)+h/2*k2x, tempy(j)+h/2*k2y);
k4x=fx(t(j)+h, x(j)+h*k3x, y(j)+h*k3y);
k4y=fy(t(j)+h, xd+h*k3x, yd+h*k3y, y(j)+h*k3y);
%k4y=fy(t(j)+h, x(j)+h*k3x, y(j)+h*k3y, tempx(j)+h*k3x, tempy(j)+h*k3y);
x(j+1)=x(j)+h/6*(k1x+2*k2x+2*k3x+k4x);
y(j+1)=y(j)+h/6*(k1y+2*k2x+2*k3y+k4y);
end
  댓글 수: 20
ibtissam benamara
ibtissam benamara 2021년 6월 20일
this is not my question, i undersand why you use (1,end-50:end);
the question why you will take x(i,:)=y(i,:), consequetly, it will give the same figure for the two species, this not true;
Akanksha Rajpal
Akanksha Rajpal 2022년 1월 30일
Your code really helped, but I was wondering if we can use similar coding if we want to extend the work to two delays? I tried that but it was showing error.
If you could help me regarding this and provide a code for this example only where the delay residing in X and Y are tau1 and tau2 respectively.

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

Priya Verma
Priya Verma 2024년 3월 15일
In question, the denominator term is define in first delay variable term. Why are you all this term is defining in second delay term.
i. e. fy =@(t,x,y) A2*x*y/(1+y)-b2*y; in this denominator term is (1+y) .....?
A2*xd*yd/(1+yd)-b2*y; in this denominator term is (1+yd) .....?
please, explain...!
  댓글 수: 21
Priya Verma
Priya Verma 2024년 3월 26일
Is there any code, package, etc to fit the parameter values of dde?
Priya Verma
Priya Verma 2024년 3월 26일
or find tau value according to model?

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

제품


릴리스

R2019a

Community Treasure Hunt

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

Start Hunting!

Translated by