πKNOWS Blog Relax Sign in

Is pi random, or is the future written in it?

If pi contains every string of digits, then the numbers of yesterday, of today and of tomorrow are already in it. Is that randomness, or was it all arranged beforehand? We took a list of 1,589 recorded numbers, kept in the order they arrived, found them in the first 3 trillion digits of pi, and ran 1,392 tests looking for the trace of an arrangement. This article tells the whole study, in plain words and in pictures.

Map of the first 3 trillion digits of pi wound into 30 turns like a galaxy, with 4,643 points of light where the recorded numbers appear
The first 3 trillion digits of pi, wound into 30 turns like a galaxy and seen at a tilt. Each point of light is a place where one of the 1,589 recorded numbers appears, 4,643 places in all.

Yesterday, today and tomorrow are already in pi

Start with dates. Write a date as 8 digits, the day first, then the month, then the year, and look for that string in the first 10 billion digits of pi. The three dates below belong to the past, the present and the future: the day Apollo 11 landed on the Moon, the day this article was written, and the first day of the year 2100. The table gives where each string first appears and how many times it appears:

DateDigitsFirst placeTimes
20/07/196920071969112,562,207129
06/12/20260612202621,745,640108
01/01/2100010121002,568,965124

The first day of 2100 has not come, yet its string is already in the first 10 billion digits of pi 124 times, and it was there before anyone had computed a single digit of pi. Nor is it just these three dates: every string of 8 digits appears at least 50 times in the first 10 billion digits (see does pi contain every number). So every day of history, and every day to the end of the year 9999, already has its place on the map.

Search 01012100

Longer numbers lie farther out, but they are there too. The main part of this article uses 1,589 recorded numbers of 12 digits each. Read to around digit 6.33 trillion of pi, and every one of the 1,589 has appeared at least once.

This is where many people feel a chill. If tomorrow's number is already there, was the future written in advance?

Being there is not the same as being foretold

There are three reasons why a number being in pi says nothing by itself.

Pi holds the opposite too

The date 01/01/2100 is in pi, and so is 02/01/2100, like every other day. If the right outcome of an event is in pi, every wrong outcome is there too, and none of them is marked. Robert Lucky wrote in IEEE Spectrum that for every truth you find in pi you also find its opposite, and that a random sequence carries no information.

To point at the place you must already know the number

The longer the string, the farther away its first place, and the number that gives that place is about as long as the string itself. The string of 12 digits below sits at a position that is also 12 digits long:

DigitsLengthFirst place
010121008 digits2,568,965
012345678910 digits17,387,594,880
99999999999912 digits897,831,316,556

Pi is like a library that holds every book that could be written, tomorrow's newspaper included, but has no catalog. To find that newspaper you must already be holding it. The map can answer "where is this number". It cannot answer "which number is coming".

Nobody has proved that pi contains everything

Pi is only sure to contain every string if it is a normal number, and that has not been proved. As Scientific American explains, every measurement on trillions of digits agrees with it, but agreeing is not a proof.

What an arrangement would leave behind

So the question worth asking is not whether a number is in pi. It is this: is there anything about how recorded numbers lie in pi that differs from made up numbers? If there were an arrangement, it would have to show somewhere:

And if it is random, then on all four points recorded numbers must look just like made up ones. That is what we put to the test.

How we tested

The map

We treat pi as a galaxy of digits: the first 3 trillion digits after the decimal point, wound into 30 turns of 100 billion digits each, as in the picture at the top. Later the galaxy was extended to 10 trillion digits. The digits come from the 100 trillion digits that Google published; the first 10 billion match the ones we computed ourselves, digit for digit.

The signals

The data is the project's list of 1,589 numbers. Each number is a line of 12 digits, and the list keeps the order in which they arrived, from the oldest to the newest. We call each number a signal, and each spot where it appears in pi a place. This article does not say where the numbers come from, because the tests do not need it: they only need a list that existed beforehand, that has an order, and that is used whole, with no line left out.

Three groups to compare with

A signal is only worth noticing if it differs from things that are not signals. So each measurement is compared with the control group that fits it, out of three:

What counts as unusual

For each test we ask: if only chance were at work, how rare would a gap this size be? Rarer than 1 time in 20, and the test is marked as unusual. But with 1,392 tests, chance alone produces about 70 unusual results. So one unusual result means nothing. To count as a finding, a result has to pass two gates: clear a much harder bar, one that takes into account how many tests were run in its group; then show up again on digits nobody has looked at.

Rules written down first

The later rounds of tests and every retest had their list of tests, their thresholds and their way of reading the result written down before running. The plans of the retests were also stored with a hash, so that nobody could change them after seeing the numbers, and each retest could be run exactly once. And to know how sensitive the tests are, we planted fake patterns in the data. For example, just 8 signals standing next to each other, or one digit taking 14% instead of 10% at a fixed position, is enough for the tests to catch.

The numbers arrive on chance's schedule

Any string of 12 digits appears 3 times on average in 3 trillion digits, and has about a 5% chance of not appearing at all. For 1,589 strings, chance predicts about 4,767 places and about 79 strings missing.

The real signals have 4,643 places, and 76 signals are missing. The places are a little fewer than predicted, but not to an unusual degree: chance alone gives a gap like that about 7 times in 100. Sorted by how many times they appear, the signals follow the shape chance predicts:

How many times each of the 1,589 signals appears in 3 trillion digitsEach gold bar counts the signals found exactly that many times. The blue bar is what chance predicts for any 1,589 strings of 12 digits.
Real signalsChance predicts
0200400600signals0 times: 76 signals. Chance predicts 79.1.760 times: 76 signals. Chance predicts 79.1.7901 times: 241 signals. Chance predicts 237.3.2411 times: 241 signals. Chance predicts 237.3.23712 times: 404 signals. Chance predicts 356.0.4042 times: 404 signals. Chance predicts 356.0.35623 times: 352 signals. Chance predicts 356.0.3523 times: 352 signals. Chance predicts 356.0.35634 times or more: 516 signals. Chance predicts 560.5.5164 times or more: 516 signals. Chance predicts 560.5.5614+times found in the first 3 trillion digits

The two columns farthest off are 2 times, 404 against 356, and 4 times or more, 516 against 561. This shape was not itself put to a test. The two numbers that were tested are the total of places and the count of missing signals, and neither is unusual.

Then we worked out ahead of time: if chance alone is at work, extending the galaxy to 10 trillion digits has a 93% chance of turning up all 76 missing signals. After reading 7 trillion more digits, all 76 showed up, the last one around digit 6.33 trillion.

The farther you read, the more signals are thereHow many of the 1,589 signals have appeared at least once by each point. The blue line is the schedule chance predicts for any string of 12 digits.
Real signalsChance predicts
05001,0001,500signals found so farBy 0.1 trillion digits: 132 signals. Chance predicts 151.By 0.2 trillion digits: 252 signals. Chance predicts 288.By 0.3 trillion digits: 382 signals. Chance predicts 412.By 0.4 trillion digits: 484 signals. Chance predicts 524.By 0.5 trillion digits: 594 signals. Chance predicts 625.By 0.6 trillion digits: 667 signals. Chance predicts 717.By 0.7 trillion digits: 764 signals. Chance predicts 800.By 0.8 trillion digits: 831 signals. Chance predicts 875.By 0.9 trillion digits: 900 signals. Chance predicts 943.By 1.0 trillion digits: 964 signals. Chance predicts 1,004.By 1.1 trillion digits: 1,012 signals. Chance predicts 1,060.By 1.2 trillion digits: 1,055 signals. Chance predicts 1,110.By 1.3 trillion digits: 1,111 signals. Chance predicts 1,156.By 1.4 trillion digits: 1,157 signals. Chance predicts 1,197.By 1.5 trillion digits: 1,194 signals. Chance predicts 1,234.By 1.6 trillion digits: 1,235 signals. Chance predicts 1,268.By 1.7 trillion digits: 1,268 signals. Chance predicts 1,299.By 1.8 trillion digits: 1,304 signals. Chance predicts 1,326.By 1.9 trillion digits: 1,341 signals. Chance predicts 1,351.By 2.0 trillion digits: 1,351 signals. Chance predicts 1,374.By 2.1 trillion digits: 1,383 signals. Chance predicts 1,394.By 2.2 trillion digits: 1,401 signals. Chance predicts 1,413.By 2.3 trillion digits: 1,419 signals. Chance predicts 1,430.By 2.4 trillion digits: 1,432 signals. Chance predicts 1,445.By 2.5 trillion digits: 1,450 signals. Chance predicts 1,459.By 2.6 trillion digits: 1,465 signals. Chance predicts 1,471.By 2.7 trillion digits: 1,483 signals. Chance predicts 1,482.By 2.8 trillion digits: 1,491 signals. Chance predicts 1,492.By 2.9 trillion digits: 1,503 signals. Chance predicts 1,502.By 3.0 trillion digits: 1,513 signals. Chance predicts 1,510.By 3.1 trillion digits: 1,520 signals. Chance predicts 1,517.By 3.2 trillion digits: 1,529 signals. Chance predicts 1,524.By 3.3 trillion digits: 1,534 signals. Chance predicts 1,530.By 3.4 trillion digits: 1,540 signals. Chance predicts 1,536.By 3.5 trillion digits: 1,544 signals. Chance predicts 1,541.By 3.6 trillion digits: 1,547 signals. Chance predicts 1,546.By 3.7 trillion digits: 1,554 signals. Chance predicts 1,550.By 3.8 trillion digits: 1,558 signals. Chance predicts 1,553.By 3.9 trillion digits: 1,561 signals. Chance predicts 1,557.By 4.0 trillion digits: 1,563 signals. Chance predicts 1,560.By 4.1 trillion digits: 1,566 signals. Chance predicts 1,563.By 4.2 trillion digits: 1,568 signals. Chance predicts 1,565.By 4.3 trillion digits: 1,572 signals. Chance predicts 1,567.By 4.4 trillion digits: 1,573 signals. Chance predicts 1,569.By 4.5 trillion digits: 1,574 signals. Chance predicts 1,571.By 4.6 trillion digits: 1,577 signals. Chance predicts 1,573.By 4.7 trillion digits: 1,579 signals. Chance predicts 1,575.By 4.8 trillion digits: 1,580 signals. Chance predicts 1,576.By 4.9 trillion digits: 1,581 signals. Chance predicts 1,577.By 5.0 trillion digits: 1,583 signals. Chance predicts 1,578.By 5.1 trillion digits: 1,583 signals. Chance predicts 1,579.By 5.2 trillion digits: 1,584 signals. Chance predicts 1,580.By 5.3 trillion digits: 1,585 signals. Chance predicts 1,581.By 5.4 trillion digits: 1,586 signals. Chance predicts 1,582.By 5.5 trillion digits: 1,586 signals. Chance predicts 1,583.By 5.6 trillion digits: 1,586 signals. Chance predicts 1,583.By 5.7 trillion digits: 1,586 signals. Chance predicts 1,584.By 5.8 trillion digits: 1,586 signals. Chance predicts 1,584.By 5.9 trillion digits: 1,586 signals. Chance predicts 1,585.By 6.0 trillion digits: 1,586 signals. Chance predicts 1,585.By 6.1 trillion digits: 1,588 signals. Chance predicts 1,585.By 6.2 trillion digits: 1,588 signals. Chance predicts 1,586.By 6.3 trillion digits: 1,588 signals. Chance predicts 1,586.By 6.4 trillion digits: 1,589 signals. Chance predicts 1,586.By 6.5 trillion digits: 1,589 signals. Chance predicts 1,587.By 6.6 trillion digits: 1,589 signals. Chance predicts 1,587.By 6.7 trillion digits: 1,589 signals. Chance predicts 1,587.By 6.8 trillion digits: 1,589 signals. Chance predicts 1,587.By 6.9 trillion digits: 1,589 signals. Chance predicts 1,587.By 7.0 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.1 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.2 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.3 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.4 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.5 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.6 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.7 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.8 trillion digits: 1,589 signals. Chance predicts 1,588.By 7.9 trillion digits: 1,589 signals. Chance predicts 1,588.By 8.0 trillion digits: 1,589 signals. Chance predicts 1,588.By 8.1 trillion digits: 1,589 signals. Chance predicts 1,589.By 8.2 trillion digits: 1,589 signals. Chance predicts 1,589.By 8.3 trillion digits: 1,589 signals. Chance predicts 1,589.By 8.4 trillion digits: 1,589 signals. Chance predicts 1,589.By 8.5 trillion digits: 1,589 signals. Chance predicts 1,589.By 8.6 trillion digits: 1,589 signals. Chance predicts 1,589.By 8.7 trillion digits: 1,589 signals. Chance predicts 1,589.By 8.8 trillion digits: 1,589 signals. Chance predicts 1,589.By 8.9 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.0 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.1 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.2 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.3 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.4 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.5 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.6 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.7 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.8 trillion digits: 1,589 signals. Chance predicts 1,589.By 9.9 trillion digits: 1,589 signals. Chance predicts 1,589.By 10.0 trillion digits: 1,589 signals. Chance predicts 1,589.3 trillion1,5136.33 trillionall 1,589246810trillion digits read

Look closely at the chart above: early on, the gold dots run slightly below the blue line. In the first 1.3 trillion digits the signals have 1,968 places, against 2,066 predicted. Having seen that, we treated each stretch read afterwards as a new test. The next three stretches, up to 3 trillion, gave 2,675 places against 2,701, and the 7 trillion digits after that gave 11,150 against 11,123. The shortfall did not come back.

No signal arrived suspiciously early, and none stayed hidden for good. We also checked every string with the same shape as the signals, millions of them: at 10 trillion digits, 99.996% of them had appeared, just what chance predicts. Having a place in pi does not make a recorded number any different from a made up one.

The path has no direction

Put the signals in time order, then join the first place of each signal to the first place of the next, and you get a path of 1,512 steps across the map. If someone were leading the way, the path would lean one way. It leans no way at all:

Which way the path turns from one signal to the next1,512 steps on the map, sorted into eight directions. The blue rim is the same signals in shuffled order, the average of 5,000 shuffles.
Real orderShuffled order
185 steps this way. In shuffled order: 184.0.185183 steps this way. In shuffled order: 195.9.183204 steps this way. In shuffled order: 193.3.204181 steps this way. In shuffled order: 182.5.181185 steps this way. In shuffled order: 184.4.185195 steps this way. In shuffled order: 195.8.195184 steps this way. In shuffled order: 193.2.184195 steps this way. In shuffled order: 182.9.195

We tried many other ways to catch a route:

No words, colors or music around the places

The piknows site shows the digits of pi as letters, as colors and as music. We used those same views, and many others, to see whether anything readable lies around the places of the signals, always compared with the places of control strings.

On words that turn up in pi by chance, see also is there a message in pi.

Using pi to guess the next number

This is the test closest to the question about the future. We replayed history: going from the oldest signal to the newest, and at each step, before the next signal was revealed, rules had to guess where in the galaxy it would be, using only the signals already revealed. In all, 1,579 steps and 62 rules: keep going straight, turn again by the same angle, head for the most crowded spot, build a triangle from the last three places, read the digits right after a place as an address, and even a model that learns from the signals already revealed.

Each guess gets a score from 0 to 100. A score of 0 is a perfect guess, 50 is what a place picked blindly gets. The average score of the whole replay was 49.3 measuring distance in digits, 50.5 measuring on the map and 49.8 measuring by angle. All three are the level of a blind pick.

After that we gathered every way of guessing into one scoreboard of 174 ways, including ways that guess the next 12 digits straight from the earlier signals, without going through pi:

174 ways of guessing the next signal, and their scoresA score of 0 is a perfect guess, 50 is what a place picked blindly gets. All 174 huddle around 50: the lowest is 47.5, the highest 52.3.
010203040ways of guessingScore from 47.0 to under 47.5: 1 ways.Score from 48.0 to under 48.5: 2 ways.Score from 48.5 to under 49.0: 11 ways.Score from 49.0 to under 49.5: 33 ways.Score from 49.5 to under 50.0: 35 ways.Score from 50.0 to under 50.5: 35 ways.Score from 50.5 to under 51.0: 26 ways.Score from 51.0 to under 51.5: 14 ways.Score from 51.5 to under 52.0: 13 ways.Score from 52.0 to under 52.5: 4 ways.50: blind pick← better guessworse guess →484950515253average score of each way

None reached the threshold set beforehand. Just knowing the common shape of the signals already gets 4 of the 12 digits right on average; no way that uses the time order or the position in pi beat that. Running the same scoreboard on two other genuine lists with the same shape as the signals gave the same result.

Six times a pattern in pi seemed to appear

This study was not always quiet. Six times a result cleared even the hard bar, the one that takes into account the number of tests in its group. The most striking was this.

Among the 62 guessing rules is one that turns again by the same angle as the step before. The place it points to is no closer to the real place than a blind pick. But the 12 digits at that place have colors like the real signal slightly more often than chance: 6,073 cells against 5,877. Chance alone gives a gap like that about 1 time in 16,000. We shuffled the order of the signals 50,000 times, and not once did it reach that level.

Then we measured again, one single time, on the next 3 trillion digits, digits nobody had looked at: 5,923 against 5,855. Only about a third of the gap was left, and chance alone produces a gap like that about 1 time in 11. The other five results did not hold up either:

Five times a pattern seemed to appear, and what happened on new digitsThe open ring is the gap when first seen, set to 100%. The solid dot is the same gap in the final test: written down beforehand, run once, on digits nobody had looked at. The line at 0 is no gap at all.
When first seenOn new digits
−50%0%50%100%Guess colorsGuess colors: on new digits, 35% of the first gap remained.35%Neighbor linkNeighbor link: on new digits, −54% of the first gap remained.−54%Adjacent turnAdjacent turn: on new digits, 15% of the first gap remained.15%Column shadeColumn shade: on new digits, 27% of the first gap remained.27%8 note echo8 note echo: on new digits, 0% of the first gap remained.0%share of the first gap that remained

No result held up in its final test. Those tests rule out gaps as large as the ones first seen; they do not rule out much smaller ones.

The lesson here is bigger than pi. Had we stopped at the first look, we would have had five discoveries to publish. New data is the only thing that tells a pattern from a stroke of luck.

Adding it up: 1,392 tests

Sort every test into eight groups by what it looked for, then count the unusual results in each group:

1,392 tests, sorted by what they looked forEach bar counts the tests in a group that came out unusual. The blue mark is how many unusual results luck alone produces: 1 test in 20.
Unusual, measuredUnusual by luck alone
0102030Place, directionPlace, direction: 157 tests, 5 unusual. Luck alone: about 8.Place, direction: 157 tests, 5 unusual. Luck alone: about 8.5Letters, wordsLetters, words: 620 tests, 16 unusual. Luck alone: about 31.Letters, words: 620 tests, 16 unusual. Luck alone: about 31.16Colors, shadesColors, shades: 92 tests, 4 unusual. Luck alone: about 5.Colors, shades: 92 tests, 4 unusual. Luck alone: about 5.4Codes, musicCodes, music: 55 tests, 1 unusual. Luck alone: about 3.Codes, music: 55 tests, 1 unusual. Luck alone: about 3.1SurroundingsSurroundings: 100 tests, 6 unusual. Luck alone: about 5.Surroundings: 100 tests, 6 unusual. Luck alone: about 5.6Guessing rulesGuessing rules: 357 tests, 18 unusual. Luck alone: about 18.Guessing rules: 357 tests, 18 unusual. Luck alone: about 18.18Hide and catchHide and catch: 6 tests, 1 unusual. Luck alone: about 0.Hide and catch: 6 tests, 1 unusual. Luck alone: about 0.1RetestsRetests: 5 tests, 0 unusual. Luck alone: about 0.0tests with an unusual result
GroupTestsUnusualLuck alone
Place and direction1575about 8
Letters and words62016about 31
Colors and shades924about 5
Codes and music551about 3
Surroundings1006about 5
Guessing rules35718about 18
Hide and catch61under 1
Retests50under 1
Total1,39251about 70

Surroundings are the digits standing around each place and the link between two signals in a row. Hide and catch is the test that mixes the signals in among strings of the same shape, then sees whether a model can find them again. Retests are the measurements on new digits described above. Each group gathers every round of tests of its kind, so it is larger than the numbers given in the sections above. The letters and words group, for instance, holds the 545 letter tests already described, plus the rounds that read letters down the list and in six writing systems.

51 unusual results in 1,392 tests, where chance alone gives about 70. The tests are not independent of each other, so nothing more can be read from 51 being smaller than 70. What can be read is this: no group has clearly more unusual results than chance gives, and every result that ever cleared the hard bar met its end in the section above.

So is pi random or arranged?

The digits of pi are not random in the sense of being thrown like dice. They are fixed: the trillionth digit was what it is before anyone computed it, and always will be. In that sense everything in pi is already there, tomorrow's number included.

But being there is not the same as being arranged for us. An arrangement that had anything to do with the real world would have to make recorded numbers differ from made up ones somewhere: arriving sooner, moving with a direction, carrying words, or being guessable. In 3 trillion digits, then 10 trillion when needed, across 1,392 tests, we found no trace that held up.

The answer we draw is this: the digits of pi are fixed by mathematics, but toward this list of recorded numbers they behave just like random ones. The map holds yesterday, today and tomorrow in exactly the way it holds every day that will never happen, and it does not say which is real.

This agrees with other measurements of the digits themselves. In 2005 Purdue University announced a study by the physicist Ephraim Fischbach and a coauthor that compared about the first 100 million digits of pi with about 30 software random number generators. They found pi to be a good source of randomness, though not always the best, and saw no patterns or correlations in the digits. On this site, the first 10 billion digits also give each digit 10% of the total, to within 0.0007%.

What this study cannot say

Two tests written down beforehand are still waiting. They can only run when new signals arrive, because only numbers that did not exist when the rules were written are truly independent of everything already looked at.

Look for a number in pi yourself

You can try the first part of the story yourself: type a date, a phone number or any number and see where it lies in the first 10 billion digits of pi. A date of 8 digits is sure to be there. A number of 10 digits, such as a phone number, has about a 63% chance of being there. Being there does not mean the number was written for you, but seeing it among the digits of pi is still a pleasure. To find a birthday, see is your birthday in pi.

Frequently asked questions

Is pi random?

The digits of pi are fixed by mathematics, not produced at random. But in the tests of this study they behave like random digits: 1,392 tests on 3 trillion digits gave 51 unusual results, where chance alone produces about 70.

Is the future already in pi?

Tomorrow's date, written as 8 digits, is certainly in pi, like every other day, including days on which nothing happens. Pi does not say which number is real: to find the place of a number you must already know the number.

Is there a pattern in the digits of pi?

This study found no pattern that held up. Six times a pattern seemed to appear. Five did not hold up in their final test on new digits, and one was a flaw of the test.

Can pi be used to predict anything?

Not in this study. 174 ways of guessing the next number, most of them from the places of the earlier numbers in pi, all scored around 50, the level of a blind pick.

Is every number of 12 digits in pi?

It has not been proved, but the measurements point that way. All 1,589 recorded numbers in the study have appeared, the last one around digit 6.33 trillion, on the schedule chance predicts.