Factorization of Polynomial with complex coefficients of the form $n^6-a$ into the form of $(n^2-a_1)(n^2-a_2)(n^2-a_3)$ In a textbook that I'm reading (in Complex Analysis) the following equation is presented
$n^6-8=(n^2-2)(n^2-2w)(n^2-2w^2)$
where $w$ is some root of order 3 of 1 (meaning $w^3=1$) (eg. $w=-\frac{1}{2} + \frac{\sqrt{3}}{2}i$).
I am wondering what formula / method can be used to factorize a polynomial with complex coefficients of the form
$n^6-a$
into the form of 
$(n^2-a_1)(n^2-a_2)(n^2-a_3)$
Thanks!

Hint:   $z^3-1 = (z-1)(z-w)(z-w^2)\,$, then let $\,z = n^2/2\,$ or, in general, $\,z=n^2/\sqrt[3]{a}\,$.
