Saturday, September 1, 2007

Her Majesty Queen Elizabeth II, monkeys and probabilities

Give 256 color pencils and a piece of blank paper to a monkey. Teach him or her how to fill each square of the paper with a random color. What are the chances the monkey draws this portrait of the Queen of England?

I have been reading about probabilities as I am heading back to school next week. This image is represented by 300 columns and 361 lines. That's 108,300 squares or pixels. Each pixel is filled with one of the 256 colors described in the palette of colors below.

For every pixel our monkey has one chance to pick the right pen out of the 256 ones. Every time our monkey draws a pixel he or she has 255 chances out of 256 to ruin it - even if every prior pixels were by any luck all correct.

Probability = 1 / 256 * 1 / 256 * 1 / 256 ... for 108,300 times.
That's a really small value - extremely close to zero. That's one reason we haven't observed monkeys drawing the Queen of England till now.

No comments: