How do I get the coefficients of a 9th order symbolic polynom without root on them?
3 views (last 30 days)
Show older comments
Hello,
I am using the symbolic toolbox to get the roots of a polynom order 9th. The symbolic solution that I am gettting from solve is the one below
(root(z^9 + (2*z^8*(a1*b3 + a2*b4 - a5*b2))/(a2*b3) + (z^7*(a1^2*b3^2 + a2^2*b4^2 + a5^2*b2^2 + 4*a1*a2*b3*b4 - 2*a1*a5*b2*b3 - 2*a2*a4*b2*b3 - 2*a2*a5*b1*b3 - 2*a2*a5*b2*b4))/(a2^2*b3^2) - (2*z^6*(- a1*a2*b4^2 - a4*a5*b2^2 - a1^2*b3*b4 - a5^2*b1*b2 - a2^2*b3*b5 + a1*a4*b2*b3 + a1*a5*b1*b3 + a2*a4*b1*b3 + a1*a5*b2*b4 + a2*a4*b2*b4 + a2*a5*b1*b4))/(a2^2*b3^2) + (z^5*(a1^2*b4^2 + a4^2*b2^2 + a5^2*b1^2 + 2*a2^2*b4*b5 - 2*a1*a4*b1*b3 + 4*a1*a2*b3*b5 - 2*a1*a4*b2*b4 - 2*a1*a5*b1*b4 - 2*a2*a4*b1*b4 + 4*a4*a5*b1*b2 - 2*a2*a5*b2*b5))/(a2^2*b3^2) + (z^4*(2*a4*a5*b1^2 + 2*a4^2*b1*b2 + a3^2*b2*b3 + 2*a1^2*b3*b5 - 2*a1*a4*b1*b4 + 4*a1*a2*b4*b5 - 2*a1*a5*b2*b5 - 2*a2*a4*b2*b5 - 2*a2*a5*b1*b5))/(a2^2*b3^2) + (z^3*(a4^2*b1^2 + a2^2*b5^2 + a3^2*b1*b3 + a3^2*b2*b4 + 2*a1^2*b4*b5 - 2*a1*a4*b2*b5 - 2*a1*a5*b1*b5 - 2*a2*a4*b1*b5))/(a2^2*b3^2) + (z^2*(2*a1*a2*b5^2 + a3^2*b1*b4 - 2*a1*a4*b1*b5))/(a2^2*b3^2) + (z*(a1^2*b5^2 + a3^2*b2*b5))/(a2^2*b3^2) + (a3^2*b1*b5)/(a2^2*b3^2), z, 2)*(- b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*b4))/(a3*b1*(a2*b1^4*b3 + a1*b2^4*b5 - a1*b1^3*b2*b3 - a2*b1^3*b2*b4 - a2*b1*b2^3*b5 + a1*b1^2*b2^2*b4))
I was wondering how I can just get the coefficients of this polynom without the word root, meaning a solution such as
[ 1, (2*(a1*b3 + a2*b4 - a5*b2))/(a2*b3), (a1^2*b3^2 + 4*a1*a2*b3*b4 - 2*a1*a5*b2*b3 + a2^2*b4^2 - 2*a2*a5*b2*b4 - 2*b1*a2*a5*b3 - 2*a4*a2*b2*b3 + a5^2*b2^2)/(a2^2*b3^2),...]
I have been using coeffs, but I have to remove manually the word root for each solution of my polynom and I would like to automatize this. Any hint of how I can get these coefficients?
Thanks in advance
0 Comments
Answers (1)
Walter Roberson
on 16 Sep 2019
children()
7 Comments
Walter Roberson
on 18 Sep 2019
syms a1 a2 a3 a4 a5 b1 b2 b3 b4 b5 z
expr = (root(z^9 + (2*z^8*(a1*b3 + a2*b4 - a5*b2))/(a2*b3) + (z^7*(a1^2*b3^2 + a2^2*b4^2 + a5^2*b2^2 + 4*a1*a2*b3*b4 - 2*a1*a5*b2*b3 - 2*a2*a4*b2*b3 - 2*a2*a5*b1*b3 - 2*a2*a5*b2*b4))/(a2^2*b3^2) - (2*z^6*(- a1*a2*b4^2 - a4*a5*b2^2 - a1^2*b3*b4 - a5^2*b1*b2 - a2^2*b3*b5 + a1*a4*b2*b3 + a1*a5*b1*b3 + a2*a4*b1*b3 + a1*a5*b2*b4 + a2*a4*b2*b4 + a2*a5*b1*b4))/(a2^2*b3^2) + (z^5*(a1^2*b4^2 + a4^2*b2^2 + a5^2*b1^2 + 2*a2^2*b4*b5 - 2*a1*a4*b1*b3 + 4*a1*a2*b3*b5 - 2*a1*a4*b2*b4 - 2*a1*a5*b1*b4 - 2*a2*a4*b1*b4 + 4*a4*a5*b1*b2 - 2*a2*a5*b2*b5))/(a2^2*b3^2) + (z^4*(2*a4*a5*b1^2 + 2*a4^2*b1*b2 + a3^2*b2*b3 + 2*a1^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2*a1*a5*b2*b5 - 2*a2*a4*b2*b5 - 2*a2*a5*b1*b5))/(a2^2*b3^2) + (z^3*(a4^2*b1^2 + a2^2*b5^2 + a3^2*b1*b3 + a3^2*b2*b4 + 2*a1^2*b4*b5 - 2*a1*a4*b2*b5 - 2*a1*a5*b1*b5 - 2*a2*a4*b1*b5))/(a2^2*b3^2) + (z^2*(2*a1*a2*b5^2 + a3^2*b1*b4 - 2*a1*a4*b1*b5))/(a2^2*b3^2) + (z*(a1^2*b5^2 + a3^2*b2*b5))/(a2^2*b3^2) + (a3^2*b1*b5)/(a2^2*b3^2), z, 2)^7*(2*a5*b2^2 - 2*a1*b2*b3 + a2*b1*b3 - 2*a2*b2*b4))/(a3*b1*(a2*b1^4*b3 + a1*b2^4*b5 - a1*b1^3*b2*b3 - a2*b1^3*b2*b4 - a2*b1*b2^3*b5 + a1*b1^2*b2^2*b4));
ch = children(expr);
ch2 = children(ch(2));
ch23 = children(ch2(3));
root_expr = ch23(1);
syms R9
newexpr = subs(expr, root_expr, R9);
[R9coeffs, R9vars] = coeffs(newexpr, R9, 'all');
R9coeffs = simplify(R9coeffs); %does not make a big difference
See Also
Categories
Find more on Financial Data Analytics in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!