Opening diffrent ezplot in a new/multiple window

2 vues (au cours des 30 derniers jours)
Dennis
Dennis le 20 Fév 2014
Commenté : Mischa Kim le 21 Fév 2014
Hello! I dont manage to open two diffrent ezplot in a new window for each of them. here the 2 functions: syms x y=1/20*x^2-6/25*x+1/(x^2+1) ezplot(y)
yprim=diff(y) ezplot(yprim)
Further on I red at Mathworks help :
ezplot(f,fign) displays the plot in the plot window with the number fign. The title of each plot window contains the word Figure and the number, for example, Figure 1, Figure 2, and so on. If the plot window with the number fign is already opened, ezplot overwrites the content of that window with the new plot.
So I tried ezplot(y,fign),ezplot(y,fig1),ezplot(y,fign 1),ezplot(y,fig 1), then I triead all variants with '' (like ezplot(y,'fign'). I tried ezplot(y,test1) ....I just dont know how to do it, please help. I want each plot in one window to compair them (but dont want them in one graph, cause it is not requestet in the assignment I am doing)
Thanks!!

Réponses (3)

Mischa Kim
Mischa Kim le 20 Fév 2014
Modifié(e) : Mischa Kim le 20 Fév 2014
Hello Dennis, put a figure command between each of the ezplot commmands.
Alternatively, try and see how you like this one:
syms x
y=1/20*x^2-6/25*x+1/(x^2+1)
yprim=diff(y)
subplot(2,1,1)
ezplot(y)
subplot(2,1,2)
ezplot(yprim)
  1 commentaire
Mischa Kim
Mischa Kim le 21 Fév 2014
Modifié(e) : Mischa Kim le 21 Fév 2014
As pointed out above, use the figure command.
syms x
y=1/20*x^2-6/25*x+1/(x^2+1)
yprim=diff(y)
figure
ezplot(y)
figure
ezplot(yprim)
Please use comments for follow-up comments and questions, not answers.

Connectez-vous pour commenter.


Dennis
Dennis le 21 Fév 2014
Ok thanks a lot, that works for 2 functions and they are displayed in one and the same window aove each other. Still need to know how to open each function in its own figure. The documentations sais it is possible as I wrote in the beginning, but it does not work for me.

Dennis
Dennis le 21 Fév 2014
Ok, somtimes it is kind of too easy :-) after the first ezplot you just type figure to open a new figure window for the next one. For example:
clear
syms f(x)
f=x^4 ezplot(f);
f1=diff(f)
figure
ezplot(f1);
f2=diff(f1)
figure
ezplot(f2)
  1 commentaire
Mischa Kim
Mischa Kim le 21 Fév 2014
Yep. See my first answer above.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Particle & Nuclear Physics dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by