MATLAB Answers


how can i plot equation with more details

Asked by Berat Duman on 22 Mar 2019
Latest activity Commented on by Walter Roberson
on 23 Mar 2019
I have an equation and i want to plot the curve in x-y space.Display the equation on the graph. Display the location and the value of the roots. And i also want to write a text on it. How can i do it? THank you


Sign in to comment.




2 Answers

Answer by Walter Roberson
on 22 Mar 2019

plot() with xlabel(), ylabel(), title(). text() to write extra things. In some cases you might want to go as far as annotation('arrow') (though that can be a nuisance for various reasons.)


Sign in to comment.

Answer by Berat Duman on 22 Mar 2019

Thanks for your answer sir. I also want to show roots i think i cannot show this extra things with that commands


How would you like to show the roots?
want to show on the plot values of the roots of function
Yes, you said that.
Do you want to put markers at those locations, without any text?
Do you want to put an arrow pointing to the locations with text at the source of the arrows?
Do you want to put markers at those locations, with the descriptive text going into the legend?
Do you want to fill an area with a different background color to represent something about the roots?
Do you want to draw the edge of the plot color coded according to whether the slope is positive or negative, so the maxima and minima and saddle points would be at the places where the color changed?
Just saying that you want to "show" them on the plot does not give us enough information about what you are looking for.

Sign in to comment.