Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I came across the following image, which states:

$\pi$ Pi

Pi is an infinite, nonrepeating (sic) decimal - meaning that every possible number combination exists somewhere in pi. Converted into ASCII text, somewhere in that infinite string if digits is the name of every person you will ever love, the date, time and manner of your death, and the answers to all the great questions of the universe.

Is this true? Does it make absolutely any sense ?

share|cite|improve this question
This is unknown. All that is known about $\pi$ is that it is transcendental.… – picakhu Oct 18 '12 at 14:38
This is the assertion that $\pi$ is base $8$ normal. Whether it is true is not known. But it is known that "most" numbers are normal to every base. – André Nicolas Oct 18 '12 at 14:40
It's not just the assertion that $\pi$ is normal. It also asserts that it is normal because its expansions is infinite and nonrepeating. And that's just plain false. – Chris Eagle Oct 18 '12 at 14:41
What is certain, is that the 94 first digits of pi do indeed contain the answer to all the great questions of the universe – mivk Oct 18 '12 at 15:36
The assertion is strictly weaker than normality. It only says each string occurs once. This implies infinitely many occurrences but not equidistribution. – Erick Wong Oct 18 '12 at 17:44

13 Answers 13

up vote 466 down vote accepted

It is not true that an infinite, non-repeating decimal must contain ‘every possible number combination’. The decimal $0.011000111100000111111\dots$ is an easy counterexample. However, if the decimal expansion of $\pi$ contains every possible finite string of digits, which seems quite likely, then the rest of the statement is indeed correct. Of course, in that case it also contains numerical equivalents of every book that will never be written, among other things.

share|cite|improve this answer
I'll bet this answer is in there too. – LamonteCristo Oct 19 '12 at 2:02
@makerofthings7: Yes, a representation of the entire internet would be in there too. Every representation, in fact. – BlueRaja - Danny Pflughoeft Oct 19 '12 at 2:34
Why does it seem likely, that the decimal expansion of π contains every possible finite string of digits? – Alex Oct 19 '12 at 9:53
@Alex: there's no particular reason for the digits of $\pi$ to have any special pattern to them, so mathematicians expect that the digits of $\pi$ more or less "behave randomly," and a random sequence of digits contains every possible finite string of digits with probability $1$ by Borel's normal number theorem: – Qiaochu Yuan Oct 19 '12 at 16:52
@Mariano: Oh, there’s a book that someone ought to write: Borges in Asgard! :-) – Brian M. Scott Oct 21 '12 at 9:45

Let me summarize the things that have been said which are true and add one more thing.

  1. $\pi$ is not known to have this property, but it is expected to be true.
  2. This property does not follow from the fact that the decimal expansion of $\pi$ is infinite and does not repeat.

The one more thing is the following. The assertion that the answer to every question you could possibly want to ask is contained somewhere in the digits of $\pi$ may be true, but it's useless. Here is a string which may make this point clearer: just string together every possible sentence in English, first by length and then by alphabetical order. The resulting string contains the answer to every question you could possibly want to ask, but

  • most of what it contains is garbage,
  • you have no way of knowing what is and isn't garbage a priori, and
  • the only way to refer to a part of the string that isn't garbage is to describe its position in the string, and the bits required to do this themselves constitute a (terrible) encoding of the string. So finding this location is exactly as hard as finding the string itself (that is, finding the answer to whatever question you wanted to ask).

In other words, a string which contains everything contains nothing. Useful communication is useful because of what it does not contain.

You should keep all of the above in mind and then read Jorge Luis Borges' The Library of Babel. (A library which contains every book contains no books.)

share|cite|improve this answer
Nice reference! That's a fun read. – Manny Reyes Oct 18 '12 at 22:47
Thanks for the reference – Wildling Oct 19 '12 at 4:58
"So finding this location is exactly as hard as finding the string itself" - indeed, rather harder: if I know how long a message is, I have an upper bound on the inormation contained in the encoding. But I have no upper bound on the information needed to represent the index into any given normal number. – Charles Stewart Oct 19 '12 at 12:06
What if you layout all the sentences in order of usefulness? :P – naught101 Oct 21 '12 at 5:55
@didibus Not really, because natural language satisfies a form of Turing-completeness: you could just say "The answer to problem X is, in binary, one one zero one ..." and proceed to give a binary encoding of a description of your "improved" language followed by an encoding of the message itself. Thus any other Turing-complete language can be delivered in English (and most other natural languages in use). – Mario Carneiro Feb 5 '14 at 14:13

It is widely believed that $\pi$ is a normal number. This (or even the weaker property of being disjunctive) implies that every possible string occurs somewhere in its expansion.

So yes, it has the story of your life -- but it also has many false stories, many subtly wrong statements, and lots of gibberish.

share|cite|improve this answer
And you wouldn't believe the terrible spelling. – Scott Rippey Oct 18 '12 at 19:33
So you're saying that π is a bit like reddit? – Mark Byers Oct 19 '12 at 11:00
@MarkByers - +1million if I could :D. – xan Oct 19 '12 at 13:30
Another amazing example of how mathematicians use 'normal' to mean 'quite special'. – Syd Kerckhove Jan 9 '15 at 1:26
@SydKerckhove: It's normal in the sense that almost all numbers have this property. Numbers like 7 and 4/3 that lack this property are very rare indeed (though still infinite). – Charles Jan 30 '15 at 17:21

This is an open question. It is not yet known if $\pi$ is a normal number.

share|cite|improve this answer
or even disjunctive. – LarsH Oct 19 '12 at 19:57

According to Mathematica, when $\pi$ is expressed in base 128 (whose digits can therefore be interpreted as ASCII characters),

  • "NO" appears at position 702;

  • "Yes" appears at position 303351.

Given (following Feynman in his Lectures on Physics) that any question $A$ with possible answer $A'$ (correct or not) can be re-expressed in the form "Is $A'$ a correct answer to $A$?", and that such questions have either "no" or "yes" answers, this proves the second sentence of the claim--and shows just how empty an assertion it is. (As others have remarked, the first sentence--depending on its interpretation--is either wrong or has unknown truth value.)


pNO = FromCharacterCode[RealDigits[\[Pi], 128, 710]];
pYes = FromCharacterCode[RealDigits[\[Pi], 128, 303400]];
{StringPosition[pNO, "NO"], StringPosition[pYes, "Yes"]}

{{{{702, 703}}, {}}, {{{303351, 303353}}, {}}}

share|cite|improve this answer
Please advise: where does 'pi' or 'π' occur? – QED Oct 19 '12 at 2:53
Special thanks to you sir, for your example ! – Wildling Oct 19 '12 at 4:58
Is it true 'that any question A with possible answer A′ (correct or not) can be re-expressed in the form "Is A′ a correct answer to A?"' Does that reduce the "all the great questions of the universe" to some inferior subset? I don't know, just asking. – LarsH Oct 19 '12 at 9:56
@LarsH That's a good question--but it starts to push us more into philosophy than mathematics. This re-expression of every great question as a yes-no question requires that you accept that every such question does have a definite answer and that you also accept the Law of the Excluded Middle. – whuber Oct 19 '12 at 13:40
@Lars I was just riffing off Feynman, not quoting him. What he actually said is that there likely is a single equation describing all the laws of physics. As I recall, just collect all the basic equations of physical law (presumably finite in number), express them each in the form $u_i=0$, and then write $\sum_i |u_i|^2 = 0$. This trivial re-expression of things that look complicated into something superficially looking much simpler was my motivation for arguing all the great questions of life can be made into yes-no questions. – whuber Oct 19 '12 at 20:43

Whether or not it's true, it's absolutely useless.

Imagine finding your life story: a copiously documented and flawless recounting of every day of your life... right up until yesterday where it states that you died and abruptly reverts back to gibberish. If pi truly contains every possible string, then that story is in there, too. Now, imagine if it said you die tomorrow. Would you believe it, or keep searching for the next copy of your life story?

The problem is that there is no structure to the information. It would take a herculean effort to process all of that data to get to the "correct" section, and immense wisdom to recognize it as correct. So if you were thinking of using pi as an oracle to determine these things, you might as well count every single atom that comprises planet Earth. That should serve as a nice warm up.

share|cite|improve this answer
nb. if it is true, then you can justify any rambling, gibberish, or errors with the excuse, "I was just quoting pi". – Dan Burton Oct 18 '12 at 22:41
It has the use of getting people interested in mathematics (e.g. it motivated this question). – Douglas S. Stones Oct 19 '12 at 0:27
@DouglasS.Stones I agree, it does provoke interest in mathematics. – Wildling Oct 19 '12 at 5:03
It would also take about the same amount of information to specify the location that an arbitrary string starts in pi at as the string contains. – dan_waterworth Oct 19 '12 at 8:05
I doubt anybody expects to get any information about their life from π. It's just an interesting way to imagine infinity. – redbmk Oct 19 '12 at 17:22

In general it it not true that an "infinite non-repeating decimal" contains any sequence in it. Consider for example the number $0.01001000100001000001000000100000001...$.

However, it is not known if $\pi$ does contain ever sequence.

share|cite|improve this answer
It can't be known if ANY sequence contains all possible combinations of numbers, as that is infinite and unreachable. – Supuhstar Oct 21 '12 at 6:52
@Supuhstar unless the sequence is specifically defined with that in mind, like by concatenating numbers consecutively: $0.12345678910111213141516...$ – Robert Mastragostino Oct 22 '12 at 16:47

This is False. Claim: Infinite and Non-Repeating, therefore must have EVERY combination.

Counterexample: 01001100011100001111... This is infinite and non-repeating yet does not have every combination.

Just because something is infinite and non-repeating doesn't mean it has every combination.

Pi may indeed have every combination but you cant use this claim to say that it does.

share|cite|improve this answer

Challenge accepted. In the following file are the first 1,048,576 digits (1 Megabyte) of pi (including the leading 3) converted to ANSI (with assistance from the algorithm described in

share|cite|improve this answer
"SEX" occurs 3 times in that text ;) – Wildling Oct 21 '12 at 7:18
Also, "Joy" occurs thrice, and "sad" a whopping 11 times ! I guess the universe is trying to tell us something ! – Wildling Oct 21 '12 at 13:40
Pleasingly, this looks similar to a random executable file. – Mark Hurd May 7 at 14:50
@MarkHurd someone should try running it :3 – Supuhstar May 7 at 15:16
someone already ran it – Hernán Eche yesterday

I believe the statement could be worded more accurately. Given the reasonable assumption that PI is infinitely non repeating, it doesn't follow that it would actually incude any particular sequence.

Take this thought experiment as an analogy. Imagine you had to sit in a room for all eternity sayings words, without every ever uttering the same word twice. You would very soon find yourself saying very long words. But there's no logical reason why you should have to use up all the possible short words first. In fact you could systematically exclude the words "yes" or every word containing the letter "y", or any other arbitrary subset of the infinite set of possible words.

Same goes for digit sequences in PI. It's highly probably that any conceivable sequence can be found in PI if you calculate for long enough, but it's not guaranteed by the prescribed conditions.

share|cite|improve this answer

And even if your statement is true with $\pi$, it does not make $\pi$ special. If we hit a real number at random, with probability $1$ we will hit a normal number. That is "almost all" real number is like that. The set of not-normal numbers have Lebesgue measure zero.

share|cite|improve this answer
How do you know that the set of non-normal numbers is Lebesgue measurable? – celtschk Jul 12 '15 at 8:29

Yes and no. Yes, any non-repeating infinite sequence can be translated into an ascii representation of random gibberish, which will of course randomly contain everything. No, that isn't particularly amazing or useful, because whatever message you are looking for is also mistated and refuted an infinite number of times.

(For those that say that it isn't necessarily normal, that is unnecessary as the transformation into ascii can be as complex as you like in order to get the result you desire).

share|cite|improve this answer
If you allow arbitrarily complex encodings, you get the same result with 0 as with pi. – dhasenan Oct 19 '12 at 18:49
@dhasenan: that's not complex, that is just eliminating the value you are supposedly encoding and replacing it with a non-repeating infinite sequence. – jmoreno Oct 21 '12 at 22:58

That image contains a number of factual errors, but the most important one is the misleading assertion that irrationality implies disjunctiveness.

One can easily construct an non-disjunctive, irrational number. Let $ r = \sum_{n = 0}^\infty 2^{-n} \begin{cases} 1 & \text{if } 2 | n \\ s_n & \text{else} \end{cases} $ for any non-periodic sequence $ s_n \in \{0,1\} $.

It is not known whether $ \pi $ is, in fact, disjunctive (or even normal).

share|cite|improve this answer

protected by Qiaochu Yuan Oct 18 '12 at 22:30

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.