Why you should stop and taste the pi
On π-day, one mathematician explores our fascination with pi and asks why we obsessively compute its digits

Pi-day, the international day of mathematics, is celebrated on the 14th of March, so called for its American date short hand 3/14, the first three digits of π . Truncating π’s decimal expansion after the second decimal place (3.14) is sufficient to specify the date. With only 11 digits of π we can calculate the circumference of the earth from its radius with an error of just a millimetre. With 39 digits we can compute the circumference of a circle encompassing the whole of the known universe with an accuracy to within the radius of a hydrogen atom. The first 50 digits of π seem like they should be enough for most practical applications. But the current record calculation for the number of digits of π stands at 100,000,000,000,000 (one hundred trillion). Why do we insist on calculating π to ever-increasing numbers of digits?
One, perhaps prosaic, answer is that the calculation of π is a benchmark for supercomputing. The target of breaking the record for the number of digits calculated pushes developers to improve both hardware and software which ultimately has benefits in a diverse range of application areas from weather forecasting to protein folding.
The demand for more and more digits also pushes us in the mathematical search for new formulae for π; formulae that might make the computational calculations less intensive. So another part of the answer is to gain a deeper understanding of the number itself. To generate knowledge for knowledge’s sake and to satisfy our curiosity about this most famous mathematical constant.
Part of our enduring fascination with π comes from its perceived intrinsic relationship with the simple geometry of the natural world. From the ripples on the surface of water to the double-helices of DNA, π is deeply embedded in our reality. π has been found, by mathematicians and scientists, in the equations that govern the fundamental dynamics of the universe: Heisenberg uses π in his uncertainty principle of quantum mechanics; Einstein in his field equations of general relativity; and Kepler in his third law of planetary motion. There are many other applications of π in diverse fields such as probability theory, the physics of electromagnetism and the study of complex numbers to name but a few.
The history of π goes back millennia. It is thought that the Ancient Egyptians, Sumerians and Babylonian’s all had estimates of π accurate to one decimal place (although found by different methods). The bible also has a claim to an early approximation to π. The following passage can be found in the book of Kings relating to the construction of the ‘sea of cast bronze’ in the temple of Solomon: “And he made a molten sea of ten cubits from brim to brim: it was round all about ... a line of thirty cubits did compass it round about.” This estimate (π=3) is, however, notably worse than other available estimates at the time.
Other primitive fractional approximations to π include the well-known 22/7 (accurate to 2 decimal places and suggestive of an, as yet, unheralded British π-day on the 22nd of July) and the less well known 333/106 (accurate to 4 decimal places). However, these (and indeed any) fractional approximations of π suffer from a fundamental problem: the fact that π is irrational.
Pi is just one of an infinite group of numbers known as the irrationals. Its irrationality means that π can't be represented as a fraction (or the ratio of two integers (whole numbers) hence the name irrational). Furthermore, due to its irrationality, its decimal representation (3.14159…) is an infinitely long string of patternless numbers. The reason we put ellipses (…) at the end of the decimal representation of irrational numbers is because they aren't finished; they go on forever. We could write down more and more terms of their decimal representation and never get any closer to finishing the expression.
The irrationality of a number like π, much like irrationality in a person, relates to its unpredictability. There is no sequence of numbers in the decimal representation of an irrational number that repeats consistently, unlike for rational numbers. The fraction 1/7 has an infinitely long decimal representation: 0.142857142857. Although it goes on forever, like the irrational numbers, there is a repeating pattern in its digits which makes it rational, but we have to wait for the seventh decimal place before it starts to repeat.
Pi, however, has no such repetition in its expansion, no matter how far down the line you look. The digits in π’s decimal expansion appear random to all intents and purposes and if this randomness can be proved to be true there are potential applications in the construction of secure codes (for applications like the encryption of electronic communication) based on long sequences of random numbers. Tests on the use of π as a source of random numbers have shown that it performs comparatively well with some commercially available random number generators currently used in cryptography. But how can we be sure that π’s digits truly give a random sequence?
One way to get a handle on the randomness of the digits of π is by computing π to larger and larger numbers of decimal places in order to determine whether π truly is what is known as a ‘normal’ random number generator. In the familiar base-10 decimal number system, any single digit of a normal number occurs a tenth of the time, any two-digit combination occurs a hundredth of the time, and so on. Analysing the digits of π is akin to throwing a ten-sided die forever and counting how often each face comes up. Finding that the die is ‘fair’ is equivalent to finding that the digits of π are truly normal.
Since, by definition, we can never know an infinite number of π’s digits, let's consider the first million decimal places. Within these digits there are 99,959 zeros, 99,758 ones, 100,026 twos, 100,229 threes, 100,230 fours, 100,359 fives, 99,548 sixes, 99,800 sevens, 99,985 eights, and 100,106 nines. These approximately even numbers of occurrences of each digit provide fairly compelling evidence for the normality of the sequence, but are not conclusive. Despite the fact that approximately equal frequencies continue to hold, as we increase the number of digits under consideration to the known (100,000,000,000,000th digit) limit, we can still not prove conclusively that this will happen for infinitely many digits.
This isn't just a problem for π, but for all other irrational numbers, of which π is just the best-known. As yet, mathematicians have failed to definitively prove that even a single irrational number has this normality property. On an even simpler scale, mathematicians have yet to prove whether there are infinitely many occurrences of each of the digits in the infinite decimal expansion of π. It seems unlikely, but perhaps after we get to a certain point in the expansion there are no more nines.
The oft-quoted ‘infinite monkey theorem’ suggests that a monkey hitting keys at random for an infinitely long time will almost surely type a given text, such as the complete works of Shakespeare. Of course when the experiment was attempted in reality with six Celebes Crested Macaques their entire literary contribution over a month-long experiment was five pages of text consisting largely of the letter S.
The theorem is, of course, a metaphor for an infinitely long sequence of randomly generated letters. We could easily come up with a code which mapped π’s expansion to letters of the alphabet, turning the sequence into a series of letters. If the normality of π could be shown to be true, then in the infinite, non-terminating, non-repeating digits of π we would surely be able to find a sequence that corresponded to the complete works of Shakespeare or any other text you can think of. Who needs an infinity of monkeys when you have π?
This article is adapted from my BBC futures piece.
To lower the tone, the US calls today pi day because they use an irrational date format. Sorry.
333/106 gives four decimal places, but 355/113 gives six and is (for me at least) easier to remember.