The "divide" and "average" method, and old-time method for approximating the square root of any positive number, can be formulated as

where 
 is the number whose square root we need to find.
Estimate the error in approximation as 

Repeat this loop until this 
 is less than or equal to the specified value.