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.
quartic = expand((x-1)*(x-2)*(x-3)*(x-4))
But that polynomial can be trivially written as the product of two quadratic polynomials.
As you can see, Q1*Q2 must yield the same fourth degree polynomial. But is there any reason I could not have done this?
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.