September 2012
Intermediate to advanced
512 pages
12h 41m
English
By the “integer square root” function, we mean the function ⌊
⌋. To extend its range of application and to avoid deciding what to do with a negative argument, we assume x is unsigned. Thus, 0 ≤ x ≤ 232 – 1.
For floating-point numbers, the square root is almost universally computed by Newton’s method. This method begins by somehow obtaining a starting estimate g0 of
. Then, a series of more accurate estimates is obtained from
The iteration converges quadratically—that is, ...