For example, after some calculations to solve my problem, I get y=x^3.
How do I plot that function? I tried to do fplot(@(x) y, limits) but it doesn't work...any solution?
No products are associated with this question.
ezplot(@(x) x.^3, limits)
x = linspace(LowerLimit, UpperLimit, NumberofPoints); plot(x, x.^3)
Or more generally if you have a symbolic variable y that contains the expression,
f = matlabFunction(y, 'x');
x = linspace(LowerLimit, UpperLimit, NumberofPoints); plot(x, f(x))
Play games and win prizes!Learn more