How do I plot 2 surf plots in different figures
Mostra commenti meno recenti
Hi,
I am trying to plot 2 different surf plots, however when I plot the second one it overwrites the first one. I need them both to be outputed as two separate figures. I have tried to use the figure command but it does not work, it keeps overwriting. Also, if use figure(1) and figure(2), it says that for figure(2) "Index exceeds the number of array elements (1)."
Here is what I have:
x = -2:0.1:2;
y = -2:0.1:2;
[x,y] = meshgrid(x, y);
U = (x.^2+y.^2).^0.5;
V = 4*del2(U);
figure
surf(x,y,U)
xlabel('x');ylabel('y');
title('Function Plot z = (x^2 + y^2)^0.5');
figure
surf(x,y,V)
figure;
xlabel('x');ylabel('y');
title('Laplacian Plot')
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Graphics Performance in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

