How can I change the axis limit while keeping the figure there, so that i can plot some other data on that figure?
1 次查看(过去 30 天)
显示 更早的评论
Hello all, I have been trying to see the trajectory of a point in julia set by first plotting the julia set as an image by the traditional escape velocity method and then plotting a point on the same curve, to see how they go to infinity, 0 or dance around.
Now the problem is that, when I plot the julia set as an image, the axis is turned to 0 to 300 and my complex numbers is -1+-1i to 1+1i so when i plot i cant see them as the way i want.
As a whole I want that when I plot a figure, i can extract that figure and paste it as is on a new axis and can then plot the new data on it.
I want to somehow change the axis to a new axis, while keeping the figure there without any change in it..
Here is the matlab code, I have been messing with..
figure;
hold on;
N =100
zMax = 1;
c = 0; %= 0.285+0.01i;
% julia
MAT=300;
mat=linspace(-zMax,zMax,MAT);
[MATx,MATy]=meshgrid(mat,mat);
Z=zeros(MAT,MAT);
M=zeros(MAT,MAT);
Z=MATx+i*MATy;
for k=1:MAT
for j=1:MAT
M(k,j)=escapeVelocity(Z(k,j),c,N);
end
end
imagesc(atan(0.1*M));
axis xy;
xlabel('Re(z)'); ylabel('Im(z)');
colorbar;
%Now the main probelm exist. Whenever I try to plot Z it plots according to
%previous image axis which is from 0 to 300.
Z0 = 0 + 1i;
Z=Z0;
for n= 1:N
plot ((Z,'*','LineWidth',4);
Z = Z^2 + c;
pause
end
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Line Plots 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!