We suddenly got hit with a barrage of π questions today. Turns out it’s not a coincidence.
π is defined, very humbly, as the ratio of the circumference of any circle to its diameter. From that definition alone it’s managed to worm its way into damn near every branch of math and physics. For example, did you know that ? It even shows up in the mathematical form of the vaunted Heisenberg Uncertainty Principle: .
But what’s often cited as the most exciting thing about π is that its decimal expansion, “3.14159…”, goes on forever without repeating. This isn’t really special to π. In fact this is the case with (effectively) all irrational numbers. But π is probably most people’s first exposure to the weirder realities of math, so it’s near and dear to a lot of hearts out there.
Q: Could the sequence of numbers making up the infinite expansion of Pi (or any other irrational number) be considered to make up an even random distribution? If not, how does it differ? If yes, couldn’t it be used when randomness is needed?
Mathematician: The digits of Pi are certainly not random, but its first few billion digits work well enough as random numbers for a lot of applications (i.e. it acts nicely as a source of pseudo random numbers).
Q: If it is true that Pi has all possible finite sequences, and the universe is finite, then then entire universe is somewhere described in the digits of Pi. Talk about your compression algorithms. “You can find a complete description of the universe, zip-encoded, starting at digit 10^120239234884840302929393482022039948393492039483940293849348203949384….”
Physicist: Assuming that decimal expansion of π (“3.1415…”) really is perfectly random, then yes; every possible finite description of the universe is encoded somewhere in the unending digits of π. That said, there isn’t actually any compression. If you think of any random number, for example, your 7 digit phone number, then the probability that any particular digit in π is the start of that particular string of 7 numbers is about 1 in 107. That means that, on average, you’ll have to go out about 107 digits to find a particular phone number. But to describe that “address” takes exactly 7 digits.
Point is, any sequence of numbers (may/probably) exist in π, but the description of where to find that sequence is effectively always as long as the string of numbers itself. Sometimes a little shorter, sometimes a little longer. In fact, try it yourself! So, if you want to find the string of numbers that describes an entire universe in detail, you’d need a computer about as big as that universe to hold the location of where that number starts in π.
Q: If we changed the math system away from a base 10 system could we find a system where π was not irrational?
Physicist: Rational numbers are numbers that can be expressed as one integer number over another, like ““. What’s not involved in that definition is the base of the numbers involved, and it turns out not to matter.
The decimal form of a rational number always repeats forever. It may take some fractions longer than others, and sometimes there’s a “settling down” period, but they always repeat. In fact, the longest a pattern can go before repeating is always at least a little less than the denominator of the fraction. Regardless of the base used. For example:
5/7 = 0.714285714285714285714285… repeats every 6 digits.
37/40 = 0.925000000… settles down, and then repeats every 1 digit.
2/3 = 0.6666666… repeats every 1 digit.
In binary you’d write “2/3″ as “10/11″ and its binary representation is 10/11 = 0.10101010101…., which repeats every 2 (still less than 3, isn’t that strange?).
Using geometric series, you can convert any repeating number, in any base, into a fraction. So anything with a repeating representation in decimal (base 10), binary (base 2), hexadecimal (base 16), whatever, can be written as one number over another (it’s a rational number). Conversely, if a number is not rational, it can never have a repeating representation in any base. It was difficult to prove the irrationality of π conclusively (for a couple thousand years), but we’ve known for about 250 years that π is definitely irrational, so there’s no way to write it in a way that repeats.