Bifurcation diagram for discrete system using matlab code
Afficher commentaires plus anciens
The following plot I want to plot. I used the following code but the result is almost similar but I want to join the points as it is in the below picture. Please some one help me to plot this following picture.
The model is
x(n+1)=(a*x(n)+b*y(n)*exp(-y(n)))*exp(-x(n))
y(n+1)=x(n)
Initial conditions are x(1)=2.512424567, y(1)=2.512424567 and a=0.5 where bifurcation parameter b varies in [10,250]
Figure 1 (Correct one)
Figure 2 (My result which I want same as figure 1)


figure(1);clf(1);
global a;
a=0.5;
clear z;z=zeros(100,2); z(1,1)=2.512424567;z(1,2)=2.512424567;
Max=25; step=10; interval=Max*step;
for n=1:Max
b=step*n;
for k=1:1000
z(k+1,2)=(a*z(k,1)+b*z(k,2)*exp(-z(k,2)))*exp(-z(k,1));
z(k+1,2)=z(k,1);
end
plot(b*ones(500),z(501:1000,1),'ko-'); xlabel('b');ylabel('x(n)');
hold on
z(1,1)=2.512424567;z(1,2)=2.512424567
end
1 commentaire
Murtala Bello Aliyu
le 25 Août 2022
Hi Dr, please can you help me with any chaos*m file as I am new to Matlab. Thanks
Réponses (0)
Catégories
En savoir plus sur Assembly dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!