How to find degree of polynomial in Matlab?
Afficher commentaires plus anciens
Dear All, Good day! I am trying to find the degree of polynomial in MATLAB. I know it is possible in MuPAD by using degree(p). But couldn't find a way by using editor. Kindly help me on this. Thanks
2 commentaires
Walter Roberson
le 30 Déc 2013
How is the polynomial represented ?
Sohail
le 30 Déc 2013
Réponse acceptée
Plus de réponses (2)
The Matlab Spot
le 30 Déc 2013
Modifié(e) : The Matlab Spot
le 30 Déc 2013
0 votes
1 commentaire
Sohail
le 30 Déc 2013
Roger Stafford
le 30 Déc 2013
0 votes
Suppose you evaluate your polynomial, P(x), at a large number of equally-spaced values of x. Then if diff(P,n) exhibits a non-zero constant value (except of course for small round-off errors,) you can conclude that P has degree n. Moreover, that constant value is indicative of the coefficient of the highest degree term.
I would think however, that an inspection of whatever process is creating your polynomial should more easily tell you its degree.
Catégories
En savoir plus sur Number Theory dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!