How to plot two different symbolic functions on the same figure?

I need to know how to plot two different symbolic functions on the same figure. The variable is x. In the 1st function x ranges from 0 to 0.9 and in the 2nd function x ranges from 0.9 to 1.8
I tried using the "hold" command in between two "ezplot" commands. but that didn't work. Maybe because the x range is different.

1 comentario

Joshua
Joshua el 3 de Mzo. de 2017
Editada: Joshua el 3 de Mzo. de 2017
Try using fplot where I randomly chose f1 and f2:
syms x;
f1=symfun(x,x);
f2=symfun(x^2,x);
fplot(f1,[0,0.9]);
hold on;
fplot(f2,[0.9,1.8]);

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre Creating, Deleting, and Querying Graphics Objects en Centro de ayuda y File Exchange.

Preguntada:

el 3 de Mzo. de 2017

Editada:

el 3 de Mzo. de 2017

Community Treasure Hunt

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

Start Hunting!

Translated by