|
"Sanaa" wrote in message <jnesiu$81o$1@newscl01ah.mathworks.com>...
> Thanks a lot for your respond. I tried the command you wrote and I also tried to fix my code. First I got the error: Warning: axis limits too large
> I fixed the error but I don't get a 3-d picture! I only get dots...
>
> clear
> itermax=300;
> finalits=30;finits=itermax-(finalits-1);
> for ru=1:0.05:3;
> for a=0.01:0.05:1;
> x=zeros(1,itermax);
> x0=0.2;x1= 0.4;
> x(1)=x0;x(2)=x1;
> for i=2:itermax
> x(i+1)= -a*x(i)+ ru*x(i-1)*(1-x(i-1));
> end
> plot3(a*ones(finalits),ru*ones(finalits),x(finits:itermax),'.','MarkerSize',1)
> hold on
> end
> end
> fsize=15;
> set(gca,'XTick',1:0.5:2,'FontSize',fsize)
> set(gca,'YTick',0:0.2:1)
> set(gca,'ZTick',0:0.2:1)
> xlabel('ru','FontSize',fsize)
> ylabel('a','FontSize',fsize)
> zlabel('x','FontSize',fsize)
> hold off
> Any idea please?
> Thanks a lot and sorry for bothering you.
- - - - - - - - - - -
Based on your previous threads, Sanaa, you are apparently trying to get bifurcation diagrams for another mapping, this one with two parameters, a and ru. You are trying to illustrate this using 'plot3' to create a three dimensional picture of this bifurcation in which both a and ru are varied, but in my opinion this is a mistake. Even if you had no troubles with memory, all you would see is a bewildering mass of points which would be extremely difficult to interpret.
My suggestion is to set one of the parameters, perhaps a, to a constant and make a 2D diagram as ru varies. Also be sure to use dots for your plot points, not lines. Then repeat this for a series of diagrams as you vary a through some range of values. This is the only way you are ever going to produce plot images that are capable of being interpreted properly.
Roger Stafford
|