AngouriMath
IntegerSquareRoot(System.Numerics.BigInteger)
Method (no overloads)
Summary
The integer square root, floored. The root of the top half of the bits, shifted
back, is right to a quarter of them; one Newton step from a value on either side
lands at or above the root ((r + n/r)/2 >= sqrt(n) ) with the error
squared, the next one squares it again, and the iteration then descends to the
floor and stops -- three divisions at the full width and three at a quarter of it,
where a power of two above the root took one division per bit of the exponent.
back, is right to a quarter of them; one Newton step from a value on either side
lands at or above the root (
squared, the next one squares it again, and the iteration then descends to the
floor and stops -- three divisions at the full width and three at a quarter of it,
where a power of two above the root took one division per bit of the exponent.
Angouri © 2019-2023 · Project's repo · Site's repo · Octicons · Transparency · 4378 pages online