How to plot the function f(x)=x^3 - 4x^2 +1 for x∈[0,25]
57 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
x= 0:0.01:25. For y=x^3 - 4x^2 +1 your plot command will be variant of plot(x,y).
0 commentaires
Réponse acceptée
pfb
le 14 Avr 2015
You almost got it. Since x is a vector, you should use elementwise operators. not x^2 (what's the square of a vector?) but x.^2.
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur 2-D and 3-D Plots 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!