Monday, March 8, 2010

The problem of the four 2's

I am basing today's entry on an entry I saw in another blog: Kolipakkam's Is there a PAM Dirac amongst us?  This in turn was brought to my attention by my colleague and good friend B Sankararaman of The Valley School.


A type of puzzle frequently seen is:
  • Using exactly four $2$'s (no less and no more), make the number $5$ (or $6$ or $10$ or $50$ any other given number).
Or:
  • Using exactly four $4$'s (no less and no more), make the number $5$ (or $6$ or $10$ or $50$ any other given number).
Or:
  • Using the digits $1$, $9$, $4$, $7$ exactly once each (no less and no more), make the number $5$ (or $6$ or $10$ or $50$ any other given number).
Obviously one can make an unlimited number of such puzzles. A popular pastime is to do this while on the road, using the license plate number of the car or bus just ahead of you. Or one can use it to set an exercise for one's students, using the digits of a particular year. This can be a lot of fun at, say, the 7th or 8th standard level.


Here I will make some remarks on the first problem (where we try to make the successive positive integers using just four $2$'s). A lot of fun can be had generating the answers:
  • $$1 = \frac{2}{2} \times \frac{2}{2}$$
  • $$2 = \frac{2}{2} + \frac{2}{2}$$
  • $$3 = 2^2 - \frac{2}{2}$$
  • $$4 = 2^2 \times \frac{2}{2}$$
  • $$5 = 2^2 + \frac{2}{2}$$
  • $$6 = 2 + 2 + \sqrt{2 \times 2}$$
  • $$8 = 2^2 + 2^2$$
  • $$9 = \left(2 + \frac{2}{2}\right)^2$$
One can go on like this, generating the positive integers one after another (but note that we skipped the entry for $7$). At some point one is bound to ask, 
  • Can this go on for ever? Can we express every integer using precisely four $2$'s? Or are there some integers for which the representation cannot be found?
Unfortunately this problem has been solved once for all! - there is a simple algorithm which yields the answer for every positive positive integer $n$. Here is how it works. Let
\[x = 2^{1/2^n}.\]
Note that $x$ depends on $n$, and can be written using just one $2$ and $n$ square root signs:
\[x = \sqrt{\sqrt{\sqrt{ \cdots \sqrt{2}}}},\]
with $n$ square root signs nested inside each other. By taking logarithms to base $2$ we get:
\[\log_2 x = \frac{1}{2^n}.\]
Inverting this relation we get $2^n = 1/\log_2 x$, and hence:
\[2^n = \log_{x} 2.\]
Now take logarithms to base $2$ yet again; we get:
\[n = \log_2 \left( \log_{x} 2 \right).\]
Now putting in the expression we had for $x$ (recall that it used just one $2$ and $n$ square root signs), we get an expression for $n$ using just three $2$'s!

For example, for $n = 5$ we have:
\[5 = \log_2 \left( \log_{\sqrt{\sqrt{\sqrt{\sqrt{\sqrt{2}}}}}} 2 \right).\]
And for $n = 7$:

\[7 = \log_2 \left( \log_{\sqrt{\sqrt{\sqrt{\sqrt{\sqrt{\sqrt{\sqrt{2}}}}}}}} 2 \right).\] 
Wow!


Note that this solution uses just three $2$'s. But we can very easily convert this to a solution using four $2$'s by (wastefully) writing one of the $2$'s using two $2$'s, say as $\sqrt{2 \times 2}$.


I am told that this solution was given by the great physicist Paul Dirac (who in spirit was a mathematician rather than a physicist; or maybe I should say that he liked to think of the world in purely mathematical terms rather than in physical terms). The story is told more fully in the blog I referred to above (Kolipakkam's Is there a PAM Dirac amongst us?). Do have a look at it.


Why do I call this "unfortunate"? Well, you don't have to take that seriously! On the one hand, Dirac's solution is neat and beautiful. At the same time it is always a matter of regret when a problem gets solved so completely that there is nothing for anyone to add any more ...! Would you agree?

No comments:

Post a Comment