# Estimating $e$

Here at the Flying Colours Maths Blog, we’re never afraid to answer the questions on everyone’s lips - such as, why is $\left(1 + 9^{-4^{7\times 6}}\right)^{3^{2^{85}}}$ practically the same as $e$?

When I say ‘practically the same’, I mean… well. 20-odd decimal places of $\pi$ are enough to get the circumference of the universe to within a hair’s breadth. This approximation for $e$ is correct to - according to @aap03102 - 18,457,734,525,360,901,453,873,570 decimal places (although he’s at pains to say he hasn’t checked them all). This is a particularly neat (if impractical) approximation, because it uses each digit from 1 to 9 exactly once. (The approximation is due to Richard Sabey - for more details, see Erich Friedman’s marvellous Math Magic site.)

### Why does it work?

It’s actually quite simple: one definition of $e$ is the limit of $\left(1 + \frac 1 n\right)^n$, as $n$ goes to infinity. So, plugging a large value of $n$ gives a good approximation to $e$ - and that’s exactly what we do here. The clever bit is finding a two ways of expressing a large number with different digits!

The large $n$ Sabey found was $3^{2^{85}}$, which is enormous compared to the numbers even the Mathematical Ninja habitually uses - the number of *digits* that number has, has 26 digits.

And all of them are the same as the digits in $9^{4^{7\times6}}$. Why’s that? Well, starting at the top, $4^{7\times6}$ is the same as $4^{42}$ or $2^{84}$. Nine is obviously $3^2$, so we’ve got $(3^2)^{(2^{84})}$, which is $3^{2^{85}}$, just like we wanted.

### OK… but how do we know how accurate it is?

Now, *that’s* an interesting question! What’s the difference between the approximation and $e$? Of course, you can just stick it in your calc… oh wait. No, no you can’t. Your calculator will tell you, quite reasonably, that the difference is 0, because it doesn’t deal with numbers that tiny.

However, we can do some tricks. Let’s call our approximation $E$:

$E = \left(1 + \frac{1}{n}\right)^n$ - and take logs: $\ln (E) = n \ln (1 + 1/n)$

We’ve got an expansion for $\ln(1+x) = x- \frac {x^2}{2} + …$, so:

$\ln(E) = n\left[ \frac{1}{n} - \frac{1}{2n^2} + …\right] = \left[1 - \frac{1}{2n} + …\right]$

And that means $\ln \left( \frac{E}{e} \right) = \ln(E) - \ln(e) \simeq -\frac{1}{2n}$

Or, better yet: $\frac{E}{e} \simeq e^{\frac{-1}{2n}} \simeq 1 - \frac{1}{2n}$, for large $n$ - and here, $n$ is very large indeed.

So, finally, we can say $e - E \simeq \frac{e}{2n} = \frac{e}{2 \times 3^{2^{85}}}$. That’s a very small number - but how small? To find out how many zeros it starts with - in other words, how many decimal places the number is correct to - we can take logarithms base 10.

$\log_{10}(e-E) \simeq \log_{10}(e) - \log_{10}(2) - \log_{10}\left(3^{2^{85}}\right)$

I don’t know $\log_{10}(e)$ off the top of my head - I think it’s somewhere about 0.4 ((It’s actually 0.434)) - and $\log_{10}(2)$ is pretty much bang on 0.3, but they’re both irrelevant compared to the last one: we’ve got $-2^{85} \log_{10}(3)$. $2^{85} \log_{10}(3)$ has 26 digits. The whole thing works out to 18,457,734,525,360,901,453,873,570, which is exactly what @aap03102 said!

* Thanks to @christianp and @opettajaH for pointing out some LaTeX issues, corrected 2014-09-29.

* Further link and LaTeX corrections made 2014-09-30, 2016-10-25 and 2018-05-24.