12.13.09

Digit frequency in pi

Posted in General at 2:14 pm by Steven

Hmmm, pi is a little bumpier than I thought. (It could just be that my statistical intuition is off, though.)

Each bar plot below represents the number of occurrences of a digit in the decimal expansion of pi. The y-axis is an index, and the frequency x is counted over the range of digits y*20 to y*20+400. I thought 400 would be a long enough length to make these graphs pretty flat. Higher lengths make it flatter, of course, but still not to the degree that seems ‘right’ to me.

I guess I could calibrate my perception by using a uniformly distributed sequence of digits…

Pi digit frequencies

Update: huh. I guess it is just me. Here’s the same sort of graph but with uniformly random digits (at least, assuming that RAND’s book, which I lazily selected as my source, is indeed uniform). Looks equally bumpy to me. Ah well, I’ll leave the post up as a reminder of my folly…

Random digit frequencies

1 Comment »

  1. Nicholas Gaul said,

    December 14, 2009 at 2:21 pm

    Sad to say, this is an instance where scientific intuition will simply fail you. There is a reason for this strange distribution–somewhere out there, someone is playing a role-playing or strategy game, either online or physically, and they meant to tap these number streams in place of clumsy rolls of the dice or other pseudo-random number generators. But the random number gods are not so easily fooled.

    The graph has the bumps it does because that distribution was necessary to punish the ambitions of some poor geek somewhere.

Leave a Comment