<s>[INST] Factoring a quartic polynomial over the integers with roots that are not integers The quartic polynomial
$$
1728(x - 3) - x^2(12^2 - x^2)
$$
factors "nicely" as
$$
(x^2 - 12x + 72) (x^2 + 12x - 72) = (x^2 - 12x + 72)(x - 6\sqrt{3} + 6)(x + 6\sqrt{3} + 6) \, .
$$
(Note that $1728 = 3(24^2)$.)  How is this factorization obtained?
 [/INST] $$
\begin{align}
1728(x - 3) - x^2(12^2 - x^2) & = x^4 - 144 x^2 + 1728 x - 5184 \\
 & = x^4 - 12^2 x^2 + 12 \cdot 12^2 x - 36 \cdot 12^2 \\
 & = x^4 - 12^2(x^2 - 2 \cdot 6 \,x + 6^2) = \\
 & = x^4 - 12^2(x-6)^2 = \\
 & = \big(x^2 - 12(x-6) \big)\big(x^2 + 12(x-6)\big) = \cdots
\end{align}
$$
</s>