how factor a polynomial into 2 quadratics?

24 views (last 30 days)
hi I have a 4th order polynomial like so
mypolynomial = x^4 +a*x^3 + b*x^2 + c*x + d == 0
I now want to factorise this into 2 quadratic equations, as either quadratic equation contains the natural frequency and damping of a certain flight mode of an aircraft. Is there a way to do this? I have tried the 'factor' function, and also tried
collect(mypolynomial, x^2)
however this just returns the original fourth order polynomial. The equation i wish to obtain looks something like this
(x^2 + A*x + B)(x^2 + C*x + D) = 0
where the upper case coefficients are not the same as the lower case coefficients in 'mypolynomial'.
Any help is appreciated, thanks!

Accepted Answer

John D'Errico
John D'Errico on 15 Nov 2021
Edited: John D'Errico on 15 Nov 2021
You cannot uniquely factor a 4th degree polynomial into such a pair of quadratics. You may think that you can, but it is provably impossible to do so, and a simple counter-example is sufficient to show why.
syms x
quartic = expand((x-1)*(x-2)*(x-3)*(x-4))
quartic = 
But that polynomial can be trivially written as the product of two quadratic polynomials.
Q1 = expand((x-1)*(x-2))
Q1 = 
Q2 = expand((x-3)*(x-4))
Q2 = 
expand(Q1*Q2)
ans = 
As you can see, Q1*Q2 must yield the same fourth degree polynomial. But is there any reason I could not have done this?
Q1 = expand((x-1)*(x-3))
Q1 = 
Q2 = expand((x-2)*(x-4))
Q2 = 
expand(Q1*Q2)
ans = 
So we have completely different quadratic factors. There is indeed no unique way to write such a 4th degree polynomial. This is no different from saying that an integer like 210 = 2*3*5*7, can be written in any of the forms 6*35 = 10*21 = 15*14. There is no unique factorization possible. The same idea applies to polynomials.
All that you can do is to find all 4 roots, then you could pair them up in any order you wish, Whatever makes you happy. This would suffice:
xroots = solve(mypolynomial,'maxdegree',4);
Or, if the coefficients of your polynomial are all numerical values, then you can use vpasolve.
xroots = vpasolve(mypolynomial);
In some cases, your roots MAY pair naturally up into pairs of complex conjugate roots. But that still does not give you a unique factorization.
  4 Comments

Sign in to comment.

More Answers (0)

Tags

Products

Community Treasure Hunt

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

Start Hunting!