Unity coefficient in symbolic polinomial
7 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Miguel Perez Andrade
am 5 Jul. 2018
Beantwortet: Star Strider
am 6 Jul. 2018
Hello,
When working with symbolic polynomials, they are always expressed in the form
a_n*s^n+...a_1*s+a_0
is there a way to express the polynomial in the form
a_n*(s^n+...a_1'*s+a_0')
a_i'= a_i/a_n
I would find this useful as I'm working with transfer functions, and with lots of expressions it's time-consuming to make the factorization by hand. Thanks!
0 Kommentare
Akzeptierte Antwort
Star Strider
am 6 Jul. 2018
This is one approach:
syms x s
f = 5*x^3 - 3*x^2 + 2*x - 1;
polynrm = @(p,v) vpa(poly2sym(poly(roots(sym2poly(p))), v));
a = polynrm(f,s)
a =
s^3 - 0.6*s^2 + 0.4*s - 0.2
This creates an anonymous function you can use to normalise the polynomials. The first argument is the polynomial, and the second is the variable you want to express it in.
This obviously only works with numeric coefficients. I could not find specific functions, or function options, to do this.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Polynomials finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!