# How Many Zeros in a Row are Possible in Pi?

**URL:** <https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562>\
**Category:** Factual Questions\
**Tags:** science-math\
**Created:** [September 21, 2024, 5:12pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562 "2024-09-21T17:12:42Z")\
**Posts on this page:** 20\
**Page:** 9

<div class="post-metadata">

**Author:** ![Lumpy](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/lumpy/32/446_2.png) [@Lumpy](https://boards.straightdope.com/u/Lumpy)\
**Post date:** [September 29, 2024, 7:01pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/161 "2024-09-29T19:01:11Z")

</div>

Okay, so monkeys in fact are extremely poor randomizers.

---

<div class="post-metadata">

**Author:** ![wolfpup](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/wolfpup/32/10618_2.png) [@wolfpup](https://boards.straightdope.com/u/wolfpup)\
**Post date:** [September 29, 2024, 7:03pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/162 "2024-09-29T19:03:06Z")

</div>

> [@DPRK](#):
>
> > [@Measure\_for\_Measure](#):
> >
> > Before reading this thread it had not occurred to me that pi, the square root of two, e, or functions of the same were random number generators. (
> 
> Since you can compute the digits, they are not in the least bit random.

But ISTM that there are different practical definitions of “random”, depending on the intended purpose.

One useful definition of “random” is statistical – that in a sufficiently long sequence of digits, every digit will appear with approximately the same frequency. If you accept that definition, then a deterministic algorithm like one that generates the digits of pi will have to be accepted as random.

The other definition is an operational one – you acknowledge that a particular process is generating digits in a way that is completely unpredictable. But if you accept that definition, then you have to accept as “random” a finite sequence of digits that has an extremely skewed distribution, like 50 zeroes in a row.

The statistical definition seems to me to be more useful for practical things like inputs to simulations.

---

<div class="post-metadata">

**Author:** ![Chronos](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/chronos/32/134_2.png) [@Chronos](https://boards.straightdope.com/u/Chronos)\
**Post date:** [September 29, 2024, 7:06pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/163 "2024-09-29T19:06:47Z")

</div>

> [@wolfpup](#):
>
> The other definition is an operational one – you acknowledge that a particular process is generating digits in a way that is completely unpredictable. But if you accept that definition, then you have to accept as “random” a finite sequence of digits that has an extremely skewed distribution, like 50 zeroes in a row.

If I have a “random number generator” that’s just generated 40 zeroes in a row, I can pretty confidently predict that the next ten digits will probably be zero, too.

Just like, if I have a “random number generator” that starts off by generating the numbers 3, 1, 4, 1, 5, 9, 2, 6, 5, 3, 5, then I can pretty confidently predict that the next number will be 8.

---

<div class="post-metadata">

**Author:** ![wolfpup](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/wolfpup/32/10618_2.png) [@wolfpup](https://boards.straightdope.com/u/wolfpup)\
**Post date:** [September 29, 2024, 7:12pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/164 "2024-09-29T19:12:03Z")

</div>

> [@Chronos](#):
>
> If I have a “random number generator” that’s just generated 40 zeroes in a row, I can pretty confidently predict that the next ten digits will probably be zero, too.

No, you can’t if you’ve accepted on the basis of solid evidence that the number generator is truly random – like for instance based on the rate of nuclear decay. In that case if it produces a sequence you think is statistically skewed, you can only attribute it to bad luck.

ETA: What I’m trying to say here is that you’re assuming that a truly random source will generate outputs (digits, or whatever) that are statistically random. This is self-evidently true over an arbitrarily long sequence, but may definitely not be true at all for any particular finite sequence.

---

<div class="post-metadata">

**Author:** ![ftg](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/ftg/32/2801_2.png) [@ftg](https://boards.straightdope.com/u/ftg)\
**Post date:** [September 29, 2024, 10:30pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/165 "2024-09-29T22:30:35Z")

</div>

My favorite approximations for converting large relative time scales also involves π:

π seconds is approximately a nano-century.

Apparently this is called Duff’s Rule.

---

<div class="post-metadata">

**Author:** ![Dr.Strangelove](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/dr.strangelove/32/6613_2.png) [@Dr.Strangelove](https://boards.straightdope.com/u/Dr.Strangelove)\
**Post date:** [September 29, 2024, 10:42pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/166 "2024-09-29T22:42:02Z")

</div>

> [@wolfpup](#):
>
> No, you can’t if you’ve accepted on the basis of solid evidence

There’s no evidence of any kind that is solid enough to exclude a 1/1040 probability of error.

Why all these zeroes? Oh, the wire to the radiation detector fell off.

---

<div class="post-metadata">

**Author:** ![Chronos](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/chronos/32/134_2.png) [@Chronos](https://boards.straightdope.com/u/Chronos)\
**Post date:** [September 29, 2024, 10:49pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/167 "2024-09-29T22:49:52Z")

</div>

> [@wolfpup](#):
>
> No, you can’t if you’ve accepted on the basis of solid evidence that the number generator is truly random – like for instance based on the rate of nuclear decay. In that case if it produces a sequence you think is statistically skewed, you can only attribute it to bad luck.

If I think I’ve set up a truly random experiment, and I get an output of 40 zeroes in a row from that experiment, then it’s vastly more likely that I’ve screwed up my experimental setup somehow than that those 40 zeroes are truly random.

---

<div class="post-metadata">

**Author:** ![Ynnad](https://avatars.discourse-cdn.com/v4/letter/y/4491bb/32.png) [@Ynnad](https://boards.straightdope.com/u/Ynnad)\
**Post date:** [September 29, 2024, 11:49pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/168 "2024-09-29T23:49:42Z")

</div>

If the last 40 numbers on a roulette table were red, would you bet on black because about time for it to show up or would you bet on red? Personally, I would bet on red.

---

<div class="post-metadata">

**Author:** ![Jasmine](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/jasmine/32/2964_2.png) [@Jasmine](https://boards.straightdope.com/u/Jasmine)\
**Post date:** [September 30, 2024, 11:27am UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/169 "2024-09-30T11:27:44Z")

</div>

> [@robby](#):
>
> Also, “you can’t possibly imagine”? [Argument from incredulity](https://en.wikipedia.org/wiki/Argument_from_incredulity) is a fallacy in informal logic.

I habitually use hyperbole for effect. LOL

---

<div class="post-metadata">

**Author:** ![Measure\_for\_Measure](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/measure_for_measure/32/557_2.png) [@Measure\_for\_Measure](https://boards.straightdope.com/u/Measure_for_Measure)\
**Post date:** [September 30, 2024, 6:06pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/170 "2024-09-30T18:06:07Z")

</div>

Let’s run with that. One of 10 digits will repeat 10 times once every billion tries. So Jasmine is saying she has difficulty visualizing one in a billion. She’s in good company I think.

That’s why we use math tools. I can’t possibly imagine 10^20, never mind 10^30. So I just pencil them out and let the math do the work. (10^30 is one ten billionth of 10^20, which is greater than 6 orders of magnitude, which is one million, which is near the edge of my visualization. So yeah, I let the math do the work - my imagination is hopeless.)

Let’s see. 1000 digits takes about 3 and half inches of scroll space (with 7 columns). So a billion digits would take 3.5 million inches of scroll space, or 55 miles using this Discourse GUI. That’s a lot of digits, and we’ve only filled up one gigabyte of memory (assuming each digit takes up one byte of space - yes this could be compressed, at least 30%, maybe 90% plus).

---

<div class="post-metadata">

**Author:** ![Dr\_Paprika](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/dr_paprika/32/3042_2.png) [@Dr\_Paprika](https://boards.straightdope.com/u/Dr_Paprika)\
**Post date:** [September 30, 2024, 6:17pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/171 "2024-09-30T18:17:32Z")

</div>

I can’t picture these numbers. But there are rough estimates that Earth, counting its beaches and deserts, has around 10^18 grains of sand. We need more maids with mops.

---

<div class="post-metadata">

**Author:** ![ftg](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/ftg/32/2801_2.png) [@ftg](https://boards.straightdope.com/u/ftg)\
**Post date:** [September 30, 2024, 8:10pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/172 "2024-09-30T20:10:02Z")

</div>

[Archimedes](https://en.wikipedia.org/wiki/The_Sand_Reckoner) came up with 10^63 grains of (somewhat tiny) sand to fill the Universe as he knew it. He had to come up with a way to express such large numbers.

Over 2000 years later we’re still griping about all the sand everywhere. (Unless you’re making concrete.)

---

<div class="post-metadata">

**Author:** ![wolfpup](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/wolfpup/32/10618_2.png) [@wolfpup](https://boards.straightdope.com/u/wolfpup)\
**Post date:** [September 30, 2024, 8:26pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/173 "2024-09-30T20:26:39Z")

</div>

> [@Ynnad](#):
>
> If the last 40 numbers on a roulette table were red, would you bet on black because about time for it to show up or would you bet on red? Personally, I would bet on red.

Hypotheses about 40 or 50 coincidental events in a row when the probability is 10% (the occurrence of a particular digit) or even 50% (red or black on a roulette wheel) are a bit hyperbolic because that’s fantastically unlikely if the events are truly random which is the assumption here – but nevertheless possible.

Given that assumption, what you seem to be saying is that you believe in what gamblers call a “hot streak”. Casinos love those guys! 😉

Humans are so notoriously drawn to seeing patterns that we see them even when they don’t exist. This is the appeal of “sure-fire” schemes to win lotteries that rely on an analysis of previous winning numbers.

---

<div class="post-metadata">

**Author:** ![Lumpy](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/lumpy/32/446_2.png) [@Lumpy](https://boards.straightdope.com/u/Lumpy)\
**Post date:** [September 30, 2024, 8:32pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/174 "2024-09-30T20:32:55Z")

</div>

If something has a probability of 1/ **n** , then the chance of it happening in **n** trials is 1/_ **e** _, or about 36%. So you’re never completely guaranteed to find a given string in a random real number’s expansion (until you do), although the odds get pretty favorable after a while.

ETA: or is it that the chance of it NOT happening is 1/_ **e** _? Now I’m confused…

---

<div class="post-metadata">

**Author:** ![DPRK](https://avatars.discourse-cdn.com/v4/letter/d/4491bb/32.png) [@DPRK](https://boards.straightdope.com/u/DPRK)\
**Post date:** [September 30, 2024, 8:40pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/175 "2024-09-30T20:40:55Z")

</div>

If the observations are more and more fantastically unlikely, it may be time to bet the wheel is biased. Usually it’s more subtle than always landing on red, though.

---

<div class="post-metadata">

**Author:** ![Pleonast](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/pleonast/32/1183_2.png) [@Pleonast](https://boards.straightdope.com/u/Pleonast)\
**Post date:** [September 30, 2024, 9:03pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/176 "2024-09-30T21:03:30Z")

</div>

Even after finding TREE(3) encoded in the digits of π, you’ve still only just started on the path to infinity.

---

<div class="post-metadata">

**Author:** ![Dr.Strangelove](https://sea3.discourse-cdn.com/straightdope/user_avatar/boards.straightdope.com/dr.strangelove/32/6613_2.png) [@Dr.Strangelove](https://boards.straightdope.com/u/Dr.Strangelove)\
**Post date:** [September 30, 2024, 10:04pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/177 "2024-09-30T22:04:28Z")

</div>

> [@wolfpup](#):
>
> if the events are truly random which is the assumption here

Why would I assume that when the very question is whether the source is truly random or not? There’s no such thing as a device or even mathematical concept that is immune to failure or error. 1/1040 is such an absurdly small number that almost any hypothesis is more likely, including the one where you’ve been singled out by hyper-advanced aliens that decided to screw with you in particular.

Gamblers have poor math skills in general but almost everyone has a poor grasp of clustering in random processes. You’d expect to land on the same color 7 times in a row after roughly 100 spins of the wheel. People find that surprising and it’s not too hard to see why people think that either there’s a “hot streak” going on or that the wheel is “due” to hit the other color (funny how a similar argument leads to opposite outcomes).

But 1040 is roughly _123_ spins of a wheel. That simply doesn’t happen. It’s evidence of something else.

The only reason I wouldn’t bet on a wheel that I’d witnessed do that is that I’d assume I’m being watched and “they” will flip the switch as soon as I place a bet!

---

<div class="post-metadata">

**Author:** ![Ynnad](https://avatars.discourse-cdn.com/v4/letter/y/4491bb/32.png) [@Ynnad](https://boards.straightdope.com/u/Ynnad)\
**Post date:** [September 30, 2024, 10:13pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/178 "2024-09-30T22:13:19Z")

</div>

> [@wolfpup](#):
>
> Given that assumption, what you seem to be saying is that you believe in what gamblers call a “hot streak”

Not at all. After 40 reds in a row I would believe the wheel is defective or has been deliberately rigged.

---

<div class="post-metadata">

**Author:** ![Ynnad](https://avatars.discourse-cdn.com/v4/letter/y/4491bb/32.png) [@Ynnad](https://boards.straightdope.com/u/Ynnad)\
**Post date:** [September 30, 2024, 10:19pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/179 "2024-09-30T22:19:51Z")

</div>

> [@Dr.Strangelove](#):
>
> The only reason I wouldn’t bet on a wheel that I’d witnessed do that is that I’d assume I’m being watched and “they” will flip the switch as soon as I place a bet!

**Dr.Strangelove** has the right approach though. The best course of action might be to go to a different casino.

---

<div class="post-metadata">

**Author:** ![Ynnad](https://avatars.discourse-cdn.com/v4/letter/y/4491bb/32.png) [@Ynnad](https://boards.straightdope.com/u/Ynnad)\
**Post date:** [September 30, 2024, 10:24pm UTC](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562/180 "2024-09-30T22:24:53Z")

</div>

Now I am thinking about a thought experiment with infinite monkeys and infinite roulette wheels. Then do it with actual live monkeys. That might be fun to watch.

[Previous page](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562.md?page=8)

[Next page](https://boards.straightdope.com/t/how-many-zeros-in-a-row-are-possible-in-pi/1007562.md?page=10)
