The Aleph Blog » Blog Archive » 11.0010010000111111011010101000100010000101101000110000100011010011


For fun, I decided to try running a test on the constant we call Pi in binary form [note headline].  Pi is the ratio of a circle’s circumference to its diameter.  It is many more things as well.  It is a unique number in mathematics.  As Linus said to Charlie Brown after meeting the kid named “Five,” “How about the name 3.14159?”  Charlie Brown says, “I think there are a lot of kids who would be named 3.14159.” (From memory, I could have botched it.)

I found on the web the first 2^15th power (32,768) binary digits for the “fractional” part of Pi. In decimal terms, it means Pi to a little more than 10,000 decimal places.

Pi is an irrational number.  That means it can’t be expressed as a fraction of two integers.  As such, in binary form, since the series does not terminate, the pattern of ones and zeroes should be random.  As such, we can do a “runs test” to see whether the number of runs is abnormal.  Too few runs: zeroes and ones alternate too frequently.  Too many runs: zeroes and ones do not alternate enough.

My expectation was that neither abnormality would occur.  But I had to follow the data to the conclusion.  As it the first 32,768 digits of Pi, it had too many runs, such that the probability of it being random was 1.26%.

I don’t know what to do with this, but my next experiment will be on the number e, 2.71828…

I’m good with math, but not great with it.  Advice is welcome…

General | RSS 2.0 |

4 Responses to 11.0010010000111111011010101000100010000101101000110000100011010011

  1. izimbra says:

    A guy name David Bailey does research on this topic and has a lot of papers you can look at:

    This Mathworld article on “Normal Numberss” references one of his papers from 1988:

    If this is the test you are applying – – you could post the numbers you obtained to see whether the problem is with you sequence of applying the test.

  2. mwilbert says:

    I’m afraid I am not able to figure out why you got the result you did, but I ran a Wald-Wolfowitz test in R (using the “wawotest” function) and 32770 bits of pi from

    I got a p value of .294, which is lower than I would have expected, but less disturbing.

  3. Steve Milos says:

    Hi David,

    As his superior says to Lawrence (Peter O’ Toole) in Lawrence of Arabia: “it is recognized that you have a funny sense of fun.” :)


David Merkel is an investment professional, and like every investment professional, he makes mistakes. David encourages you to do your own independent "due diligence" on any idea that he talks about, because he could be wrong. Nothing written here, at RealMoney, Wall Street All-Stars, or anywhere else David may write is an invitation to buy or sell any particular security; at most, David is handing out educated guesses as to what the markets may do. David is fond of saying, "The markets always find a new way to make a fool out of you," and so he encourages caution in investing. Risk control wins the game in the long run, not bold moves. Even the best strategies of the past fail, sometimes spectacularly, when you least expect it. David is not immune to that, so please understand that any past success of his will be probably be followed by failures.

Also, though David runs Aleph Investments, LLC, this blog is not a part of that business. This blog exists to educate investors, and give something back. It is not intended as advertisement for Aleph Investments; David is not soliciting business through it. When David, or a client of David's has an interest in a security mentioned, full disclosure will be given, as has been past practice for all that David does on the web. Disclosure is the breakfast of champions.

Additionally, David may occasionally write about accounting, actuarial, insurance, and tax topics, but nothing written here, at RealMoney, or anywhere else is meant to be formal "advice" in those areas. Consult a reputable professional in those areas to get personal, tailored advice that meets the specialized needs that David can have no knowledge of.

 Subscribe in a reader

 Subscribe in a reader (comments)

Subscribe to RSS Feed

Enter your Email

Preview | Powered by FeedBlitz

Seeking Alpha Certified

Top markets blogs award

The Aleph Blog

Top markets blogs Bull, Boards & Blogs

Blog Directory - Blogged

IStockAnalyst supporter

All Economists Contributor

Business Finance Blogs
OnToplist is optimized by SEO
Add blog to our blog directory.

Page optimized by WP Minify WordPress Plugin