Roots function is solving eigth order polynomial equation as fifth order.

1 次查看(过去 30 天)
I have an equation :
Using coeffs(), i get their coefficients, flip them left to right and then use roots() function to get its zeroes.
But, when , coeffs() function gives coeffs of non-zero terms only,
that is, for fliplr(coeffs(fn)) = [a,c,e,g,i]
So, when I put this coeffs() solution in roots(), it considers it as fifth order polynomial.
How can I get around this problem?

采纳的回答

Steven Lord
Steven Lord 2019-9-14
Specify the 'All' option in your call to coeffs to return all the coefficients, even those that are 0.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Polynomials 的更多信息

标签

产品


版本

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by