Graph function problem Incorrect values

2 visualizaciones (últimos 30 días)
Emilia
Emilia el 28 de Jul. de 2022
Comentada: Emilia el 28 de Jul. de 2022
Hello,
I have this function, If I want to produce a graph in the range of 0<x<50 it does not give a correct answer of y. Thanks for the helpers
x=1
y=-x.^3+3*x.^2+2*x-27
y =
-23
%%plot
x=[0:50];
y=-x.^3+3*x.^2+2*x-27;
plot(x,y)

Respuesta aceptada

Chunru
Chunru el 28 de Jul. de 2022
What's wrong?
x=[0:50];
y=-x.^3+3*x.^2+2*x-27;
plot(x,y)
  3 comentarios
Chunru
Chunru el 28 de Jul. de 2022
The y axis scale is x10^4. If you zoom in, you will see the correct value.
Emilia
Emilia el 28 de Jul. de 2022
Yes, you're right, I didn't notice. Thank you! :)

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre 2-D and 3-D Plots en Help Center y File Exchange.

Etiquetas

Productos

Community Treasure Hunt

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

Start Hunting!

Translated by