Ask Uncle Colin: Computing $\sqrt{2}$
Dear Uncle Colin,
If I didn’t have a calculator and wanted to know the decimal expansion of $\sqrt{2}$, how would I be best to go about it?
Roots As Decimals - Irrational Constant At Length
Hi, RADICAL, and thanks for your message!
There are several options for finding $\sqrt{2}$ as a decimal (although why you’d want to know it beyond about three places, I have no idea).
One is the ‘long division’ method that @colinthemathmo has explained in more detail than I would ever care to, so I’ll just send you there if you’re interested in that.
But there are two other methods I would consider.
The binomial expansion
If you have a reasonable guess for the value of $R \approx \sqrt{n}$, you can find an improved guess by working out $R’ = R + \frac{n - R^2}{2R}$, which comes from the binomial expansion. For example, if you guessed that $\sqrt{2} \approx 1$, your second guess would be $1 + \frac{2 - 1}{2} = 1.5$, which is significantly closer.
You can repeat this process as often as you like: with $R = 1.5$, the next guess is $1.5 + \frac{2-\frac{9}{4}}{3} = \frac{3}{2} - \frac{1}{12}$. That’s $\frac{17}{12} \approx 1.4167$, which is still closer to the true value.
You can either work with fractions and do a great big long division at the end, or you can say (for example) “15 is my estimate for $\sqrt{200}$”, or “142 is my estimate for $\sqrt{20000}$” - which will converge more slowly, but may be less annoying.
Continued fractions.
With a litte bit of surd work, you can show that:
$\sqrt{2} = 1 + \br{\sqrt{2} - 1} = 1 + \frac{1}{1 + \sqrt{2}}$
But, you know that the $\sqrt{2}$ on the bottom of the last term can be written as $1 + \frac{1}{1 + \sqrt{2}}$, which would make the whole thing $1 + \frac{1}{2 + \frac{1}{1+\sqrt{2}}}$. That can be repeated again, and it turns out that:
$\sqrt{2} = \frac{1}{2 + \frac{1}{2 + \frac{1}{2 + …}}}$, following the same pattern forever. The more levels you expand the continued fraction to, the more accurate your result - the first few terms in the sequence are $1$, $\frac{3}{2}$, $\frac{7}{5}$, $\frac{17}{12}$, …
In fact, if you know that the $k$th term is $\frac{a}{b}$, the $(k+1)$th term is $\frac{a + 2b}{a+b}$, and a better approximation to $\sqrt{2}$.
Again, you can use this to generate an approximation as close to the answer as you would like!
Hope that helps,
- Uncle Colin
* Updated 2019-02-06 to correct LaTeX in title.