Write a quadratic equation function
古いコメントを表示
Hi all,
I've been writing a function to solve a quadratic equation of the form ax^2 + bx + c. It works for quadratics where there are two real roots, but I want it to display NA for one of the roots when there is a repeated root or NA for both when there are no real roots. Not sure if I have to use an if statement or an if else statement?
Thanks for any help!
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Quadratic Programming and Cone Programming についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!