Plotting orbit diagram of this map (discrete dynamical system)

dynamical systemsMATLAB

I want to plot the orbit diagram of the system $x_{n+1}=x_n e^{r(1-x)(\frac{x}{0.2}-1)}$ for $0.3 <r<1$ and 8000 time steps which the last 300 are ploted with initial conditions $0.08,\; 0.44,\; 0.73,\; 0.76$ and $0.99$ in matlab. I wrote the following code but it doesn't work.

close all
clear all
avalues=0.3:0.01:0.9;
N=8000;
a=avalues;
x=0.08;
X=zeros(N,length(a));
for n=1:0.3*N
    x=x.*exp(a.*(1-x).*((x/0.2)-1));
    X(n,:)=x;
end

figure (9), hold on 
for n=.3*N:N
    x=x.*exp(a.*(1-x).*((x/0.2)-1));
    X(n,:)=x;
    plot(a,x,'.','MarkerSize',0.01)
    axis([0.3 0.9 0 1.4])
end
hold off

I was wondering if someone could help me about my problem.

Best Answer

It works. There are dots at the bottom of the graph, which are the orbit diagram: x_0 = 0.08

If $x_0 = 0.08$, then all trajectories tend to zero, which is shown in the figure above. If you take $x_0 = 0.78$, you can see a completely different picture:

enter image description here

Related Question