Cube root approximation is somewhat of a black art. Some implementations manipulate the exponent bits of the floating-point number; i.e. they arrive at an initial approximation by dividing the exponent by 3. Cubic equations, which are polynomial equations of the third degree (meaning the highest power of the unknown is 3) can always be solved for their three solutions in terms of cube roots and square roots (although simpler expressions only in terms of square roots exist for all three solutions, if at least one of them is a rational number). If two of the solutions are complex numbers, then all three
Root of unity modulo n it is not a primitive root, then there would be some divisor ℓ of "k", with formula_57. In order to exclude this possibility, one has only to check for a few ℓ's equal "k" divided by a prime. That is, what needs to be checked is: Among the primitive "k"-th roots of unity, the primitive formula_23-th roots are most frequent. It is thus recommended to try some integers for being a primitive formula_23-th root, what will succeed quickly. For a primitive formula_23-th root "x", the number formula_30 is a primitive formula_25-th root of unity. If "k" does not divide formula_23,