Martin Guy, June 1985

after

C. Woo

Mr Woo's algorithm on a decimal abacus is a follows:

Put 1 bead up on the leftmost column. This is worth 1 unit.

Subtract 1 unit from the MSP (Most Significant Pair of columns) as if they represented a number from 1 to 99.

Add two to the one on the left to make three.

If there are still three worth left in the MSP, subract three from it and add another two to the workspace to make five.

Carry on the cycle of subtracting the value of the workspace from the MSP and adding two to the workspace each time you could.

The last time you subtract the workspace from the MSP, just add one, not two.

Now multiply the workspace by ten and add one.

Move the MSP market two columns to the right.

Iterate.

When you have got down to the last two columns, if the original number was an exact square, the last subtraction should exactly wipe out the residue of the original number. If not, there is your remainder.

To get the root value, add a final one to the workspace, and divide it by two. There's your square root.