I'm looking for a way to rationalize a very ugly expression given by the code I pasted in. What do I mean by this? The expression is a solution to the zero locus of some polynomial. In my previous question Solving system of equations with Root I had a very simple expression and I can't generalize this solution to the new case. What I want to do: I want to get rid of the Roots and get an expression for zero locus of some polynomial. Let's say that $y=\textrm{my code}$ so,$y-\textrm{my code}=0$. I want to rationalize this expression to get rid of the roots and have algebraic expression given by the radicals looking like $a_1 y^1 + a_2 y^2 +...a^n y^n =0$, where $a_i$ are some coefficients dependent on x and $y^i$ is $i$-th power of y. It would be nice to have a solution that works for wider classes of those equations, not only the one I pasted in. How can one do that? Is there a function in Mathematica that can do such things? Long story short: I want to do the same thing as in my previous question but with much more complicated expression.
Root[x^9 +
x^7 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 - 12 x^2 +
6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 + 8 x^7) #1^6 + (-1 +
x + 7 x^2 - 7 x^3 - 8 x^4 + 45 x^5 + 45 x^6) #1^7 &, 3] -
3 x^7 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 - 12 x^2 +
6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 + 8 x^7) #1^6 + (-1 +
x + 7 x^2 - 7 x^3 - 8 x^4 + 45 x^5 + 45 x^6) #1^7 &,
3]^2 - 2 x^5 Root[-x^10 + (2 x^8 + 19 x^9 +
26 x^10) #1 + (x^6 + 20 x^7 + 35 x^8 - 40 x^9 -
64 x^10) #1^2 + (-2 x^4 + 3 x^5 + 12 x^6 - 85 x^7 -
129 x^8 + 32 x^9 + 32 x^10) #1^3 + (-x^2 + 10 x^4 -
43 x^5 - 80 x^6 + 123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 +
x^3 - 22 x^4 + 113 x^5 + 169 x^6 - 75 x^7 -
52 x^8) #1^5 + (1 - 12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 -
146 x^6 + 8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^3 +
3 x^5 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 - 12 x^2 +
6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 + 8 x^7) #1^6 + (-1 +
x + 7 x^2 - 7 x^3 - 8 x^4 + 45 x^5 + 45 x^6) #1^7 &, 3]^4 +
x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 - 12 x^2 +
6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 + 8 x^7) #1^6 + (-1 +
x + 7 x^2 - 7 x^3 - 8 x^4 + 45 x^5 + 45 x^6) #1^7 &, 3]^5 -
x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 - 12 x^2 +
6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 + 8 x^7) #1^6 + (-1 +
x + 7 x^2 - 7 x^3 - 8 x^4 + 45 x^5 + 45 x^6) #1^7 &,
3]^6 + (-6 x^8 Root[-x^10 + (2 x^8 + 19 x^9 +
26 x^10) #1 + (x^6 + 20 x^7 + 35 x^8 - 40 x^9 -
64 x^10) #1^2 + (-2 x^4 + 3 x^5 + 12 x^6 - 85 x^7 -
129 x^8 + 32 x^9 + 32 x^10) #1^3 + (-x^2 + 10 x^4 -
43 x^5 - 80 x^6 + 123 x^7 + 146 x^8) #1^4 + (-x +
6 x^2 + x^3 - 22 x^4 + 113 x^5 + 169 x^6 - 75 x^7 -
52 x^8) #1^5 + (1 - 12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 -
146 x^6 + 8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 -
8 x^4 + 45 x^5 + 45 x^6) #1^7 &, 3] +
x^5 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^2 -
3 x^6 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^2 +
x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^3 +
2 x^4 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^3 +
12 x^6 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^3 -
x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^4 -
3 x^2 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 -
6 x^4 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 +
3 x^2 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &,
3]^6) #1 + (15 x^7 Root[-x^10 + (2 x^8 + 19 x^9 +
26 x^10) #1 + (x^6 + 20 x^7 + 35 x^8 - 40 x^9 -
64 x^10) #1^2 + (-2 x^4 + 3 x^5 + 12 x^6 - 85 x^7 -
129 x^8 + 32 x^9 + 32 x^10) #1^3 + (-x^2 + 10 x^4 -
43 x^5 - 80 x^6 + 123 x^7 + 146 x^8) #1^4 + (-x +
6 x^2 + x^3 - 22 x^4 + 113 x^5 + 169 x^6 - 75 x^7 -
52 x^8) #1^5 + (1 - 12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 -
146 x^6 + 8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 -
8 x^4 + 45 x^5 + 45 x^6) #1^7 &, 3]^2 -
3 x^4 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^3 +
2 x^5 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^3 -
2 x^2 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^4 -
3 x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^4 -
18 x^5 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^4 +
3 x Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 +
2 x^2 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 +
6 x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 -
3 x Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^6 +
3 x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &,
3]^6) #1^2 + (-20 x^6 Root[-x^10 + (2 x^8 + 19 x^9 +
26 x^10) #1 + (x^6 + 20 x^7 + 35 x^8 - 40 x^9 -
64 x^10) #1^2 + (-2 x^4 + 3 x^5 + 12 x^6 - 85 x^7 -
129 x^8 + 32 x^9 + 32 x^10) #1^3 + (-x^2 + 10 x^4 -
43 x^5 - 80 x^6 + 123 x^7 + 146 x^8) #1^4 + (-x +
6 x^2 + x^3 - 22 x^4 + 113 x^5 + 169 x^6 - 75 x^7 -
52 x^8) #1^5 + (1 - 12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 -
146 x^6 + 8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 -
8 x^4 + 45 x^5 + 45 x^6) #1^7 &, 3]^3 +
3 x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^4 +
2 x^4 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^4 -
Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 + 45 x^5 +
45 x^6) #1^7 &, 3]^5 +
x Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 +
12 x^4 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 +
Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 + 45 x^5 +
45 x^6) #1^7 &, 3]^6 -
x Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^6 -
4 x^2 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &,
3]^6) #1^3 + (15 x^5 Root[-x^10 + (2 x^8 + 19 x^9 +
26 x^10) #1 + (x^6 + 20 x^7 + 35 x^8 - 40 x^9 -
64 x^10) #1^2 + (-2 x^4 + 3 x^5 + 12 x^6 - 85 x^7 -
129 x^8 + 32 x^9 + 32 x^10) #1^3 + (-x^2 + 10 x^4 -
43 x^5 - 80 x^6 + 123 x^7 + 146 x^8) #1^4 + (-x +
6 x^2 + x^3 - 22 x^4 + 113 x^5 + 169 x^6 - 75 x^7 -
52 x^8) #1^5 + (1 - 12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 -
146 x^6 + 8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 -
8 x^4 + 45 x^5 + 45 x^6) #1^7 &, 3]^4 -
x^2 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 -
3 x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^5 +
x Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^6 -
3 x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &,
3]^6) #1^4 + (-6 x^4 Root[-x^10 + (2 x^8 + 19 x^9 +
26 x^10) #1 + (x^6 + 20 x^7 + 35 x^8 - 40 x^9 -
64 x^10) #1^2 + (-2 x^4 + 3 x^5 + 12 x^6 - 85 x^7 -
129 x^8 + 32 x^9 + 32 x^10) #1^3 + (-x^2 + 10 x^4 -
43 x^5 - 80 x^6 + 123 x^7 + 146 x^8) #1^4 + (-x +
6 x^2 + x^3 - 22 x^4 + 113 x^5 + 169 x^6 - 75 x^7 -
52 x^8) #1^5 + (1 - 12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 -
146 x^6 + 8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 -
8 x^4 + 45 x^5 + 45 x^6) #1^7 &, 3]^5 +
x^2 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 +
20 x^7 + 35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 +
3 x^5 + 12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 -
12 x^2 + 6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 +
8 x^7) #1^6 + (-1 + x + 7 x^2 - 7 x^3 - 8 x^4 +
45 x^5 + 45 x^6) #1^7 &, 3]^6) #1^5 +
x^3 Root[-x^10 + (2 x^8 + 19 x^9 + 26 x^10) #1 + (x^6 + 20 x^7 +
35 x^8 - 40 x^9 - 64 x^10) #1^2 + (-2 x^4 + 3 x^5 +
12 x^6 - 85 x^7 - 129 x^8 + 32 x^9 +
32 x^10) #1^3 + (-x^2 + 10 x^4 - 43 x^5 - 80 x^6 +
123 x^7 + 146 x^8) #1^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) #1^5 + (1 - 12 x^2 +
6 x^3 + 21 x^4 - 115 x^5 - 146 x^6 + 8 x^7) #1^6 + (-1 +
x + 7 x^2 - 7 x^3 - 8 x^4 + 45 x^5 + 45 x^6) #1^7 &,
3]^6 #1^6 &, 1];
Edit: Example of an expression with the new problem: pastebin.com/uZLmJ6SF (I'm posting a link since the code as you can see is way too long) - I can't somehow resolve the issue of trivial solution. Why is it coming out this way? Function res
from the answer gives value 1.
Answer
Because the enormous expression in the question contains two levels of Root
functions, it can be represented as the solution of two polynomials in two variables, y
and an auxiliary variable, say, z
. With the expression designated s
for convenience, the two equations are readily derived, as follows. To obtain the first polynomial, extract the First
argument of the outer Root
, for instance by s // First
, replace the inner Root
by z
, and apply the expression to y
.
eq1 = ((s // First) /. Root[__] -> z)[y] == 0
(* x^9 + x^7 z - 3 x^7 z^2 - 2 x^5 z^3 + 3 x^5 z^4 + x^3 z^5 - x^3 z^6 +
x^3 y^6 z^6 + y^3 (-20 x^6 z^3 + 3 x^3 z^4 + 2 x^4 z^4 - z^5 + x z^5 +
12 x^4 z^5 + z^6 - x z^6 - 4 x^2 z^6) + y^5 (-6 x^4 z^5 + x^2 z^6) +
y (-6 x^8 z + x^5 z^2 - 3 x^6 z^2 + x^3 z^3 + 2 x^4 z^3 +
12 x^6 z^3 - x^3 z^4 - 3 x^2 z^5 - 6 x^4 z^5 + 3 x^2 z^6) +
y^4 (15 x^5 z^4 - x^2 z^5 - 3 x^3 z^5 + x z^6 - 3 x^3 z^6) +
y^2 (15 x^7 z^2 - 3 x^4 z^3 + 2 x^5 z^3 - 2 x^2 z^4 - 3 x^3 z^4 -
18 x^5 z^4 + 3 x z^5 + 2 x^2 z^5 + 6 x^3 z^5 - 3 x z^6 + 3 x^3 z^6) == 0 *)
To obtain the second polynomial, extract the inner Root
from s
, here with Cases
, and apply the result to z
.
eq2 = (Union@Cases[s, _Root, {4}])[[1, 1]][z] == 0
(* -x^10 + (2 x^8 + 19 x^9 + 26 x^10) z + (x^6 + 20 x^7 + 35 x^8 -
40 x^9 - 64 x^10) z^2 + (-2 x^4 + 3 x^5 + 12 x^6 - 85 x^7 -
129 x^8 + 32 x^9 + 32 x^10) z^3 + (-x^2 + 10 x^4 - 43 x^5 -
80 x^6 + 123 x^7 + 146 x^8) z^4 + (-x + 6 x^2 + x^3 - 22 x^4 +
113 x^5 + 169 x^6 - 75 x^7 - 52 x^8) z^5 + (1 - 12 x^2 + 6 x^3 +
21 x^4 - 115 x^5 - 146 x^6 + 8 x^7) z^6 + (-1 + x + 7 x^2 -
7 x^3 - 8 x^4 + 45 x^5 + 45 x^6) z^7 == 0 *)
Of course, this process introduces many more solutions. For instance, at x == 2
,
NSolve[{eq1, eq2} /. x -> 2, {y, z}] // Length
(* 42 *)
all but six of which are complex. The four smaller real solutions over the domain {x, 2, 10}
are given by
t = Transpose@Table[y /. NSolve[{eq1, eq2}, {y, z}, Reals], {x, 1.25, 10, .25}];
pt = ListLinePlot[t, DataRange -> {1.25, 10}, PlotRange -> {0, 8}]
This can be compared with the single curve, s
.
ps = Plot[s, {x, 1.25, 10}, PlotRange -> {{0, 10}, {0, 8}}]
which is identical to the lowest curve in the preceding plot.
Addendum: Reduction to a single seventh-order polynomial
As pointed out by Daniel Lichtblau in a comment below, z
can be eliminated between the two polynomials (as requested by the OP).
res = Resultant[First@eq1, First@eq2, z]
to produce a single but very lengthy forty-second order polynomial in y
. Plotting it
tr = Transpose@Table[y /. NSolve[res, y, Reals], {x, 1.25, 10, .25}];
ptr = ListLinePlot[tr, DataRange -> {1.25, 10}, PlotRange -> {0, 8}]
yields a plot identical to the first one above. Unexpectedly, I found that
fac = Factor[res];
splits res
into three factors, the first being x^47
, the third a thirty-fifth order polynomial, and the second
fac[[2]]
(* x^5 + 2 x^3 y + x y^2 - x^2 y^2 - 2 x^3 y^2 + 7 x^4 y^2 + 12 x^5 y^2 - y^3 - x y^3 +
6 x^2 y^3 + 5 x^3 y^3 - 14 x^4 y^3 - 4 x y^4 - 17 x^2 y^4 - 3 x^3 y^4 + 32 x^4 y^4 +
32 x^5 y^4 + 7 x y^5 + 7 x^2 y^5 - 44 x^3 y^5 - 64 x^4 y^5 + 14 x^2 y^6 + 26 x^3 y^6 -
x^2 y^7 *)
It is this factor that contains the solution associated with s
, as can be seen from
fs = Solve[fac[[2]] == 0, y];
ptf = Plot[Evaluate[y /. fs], {x, 1.25, 10}, PlotRange -> {{0, 10}, {0, 8}}]
in which the lower curve is identical to the curve for s
. Thus, f[[2]]
is the desired polynomial and is only seventh-order in y
.
Comments
Post a Comment