Computing cube roots using bit level hacks

Some time back, I was working on some primality testing algorithms in the FLINT ulong_extras module (the Brillhart-Lehmer-Selfridge test to be precise). It required computing the cube root of the integer being tested. While implementing it, I realized that the ulong_extras module was missing a cube root function.…