Program that asks for a,b,c in a quadratic equation?
12 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I need to write a program that asks for a, b and c in the quadratic equation
ax^2 + bx + c = 0
... and then solve it with d = b^2 - 4ac and write it according to:
d < 0 --> no real root
d = 0 --> one double root: x=-b/2a
d > 0 --> two roots: x1 = -b-sqrt(d)/2a and x2 = -b+sqrt(d)/2a
______________
I am a complete rookie so a little help on this is very appreciated.
Thank you fellow matlab friends.
0 commentaires
Réponses (1)
Voir également
Catégories
En savoir plus sur Symbolic Math Toolbox 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!