Extracting square roots with pencil and paper is a dying art. If this final example inspires you to try your hand at some decimal values, enjoy yourself!
Here is the root \( \sqrt{100} = 10 \).
To start the computation, the digits of the
radicand are paired
off, shown here with commas.
The value \( 100 \) in binary is 01,10,01,00
.
The commas are an aid to organization. They have no
numerical significance.
1 0 1 0 1 0 ------------ ----- √ 01,10,01,00 √ 1,00 1 - 1 1 -1 -- -- 10_ 0 10 0 -- 100_ 10 01 - 10 01 ----- 00 00 00
At each step of the extraction, the mantra is, "double the root thus far and shift by another digit; then fill in the next digit of the root." In binary, we double a number by shifting it left one bit position. So the mantra becomes shift two bits to the left, with the last place to be occupied by the next digit of the root, which is either zero or one. The bit postion to be filled by the next bit of the square root is shown with an underscore, "_".
The idea behind this arcane process lies in a little bit of algebra. In the decimal form \[ (10 a + b)^{2} = 100 a^{2} + 20 a b + b^{2} \] where the latter two terms combine to be \[ (20 a + b) b \] In this expression \( a \) represents the digits of the root computed so far and \( b \) is the next digit. The \( 100 \) captures the pairing of the digits and the \( 20 a b \) illustrates the doubling, shifting by one digit, and inserting the next digit into to the term.
In binary, both doubling and shifting by a digit are one-bit shifts. The formula for the reduction term becomes \[ (4 a + b) b \]
To test your mettle, pick a six-bit number whose leading bit is
1
. You might try 100001
, for example.
Square it, checking your work, then compute the
square root. Express the number in decimal and try it in
decimal, too.