Monday, December 18, 2006

The Birthday paradox/problem


Did you know that if you are at a party with 23 people attending, then the probability that two people will share birthday is more than 50%!

I sometimes use this example as a way to show people that our intuitive reasoning with numbers can be quite wrong, and it really works, people shake their head in disbelief when I tell them this statistic. How can this be? To illustrate imagine that there are two people attending a party. There are 364 ways in which the second person will not have the same birthday as the first person. For the third person there are 363 days which are still not occupied. The formula that we get is that the probability that at least two people share the same birthday when there are three people attending is 1-(365*364*363)/(365*365*365) = about 0.01. If you do the same calculation but with 23 people p will be just above 0.5. The general formula is: 1 - (365)(364)(363)...(365 - N + 1)/(365)^N.

Doing this calculation with 40 persons will give you a probability of around 0.9 (see graph above)! Next time you are attending a party with 40 persons or more, why not make the safest bet ever... For more information on this problem as well as a birthday generator which lets you test these claims empirically, go to "http://www.mste.uiuc.edu/reese/birthday/default.html"

5 comments:

Z said...

.....what a tricky formula, tried to explain it to myself and did it backwards with an analogy:

If i drop 5 coins one after the other, the probability of getting the result "5 heads up" is 0.5x0.5x0.5x0.5x0.5 = 1/32

And then i compared it with your formula (bacwards: "probability of 5 people having birthdays on DIFFERENT dates") and it...sort of...sank in. Got it. :)

Heard a few other statistic results that amazed me through the years, and i've always tried to explain the actual reason to myself. It's helped me through these mysteries.

Charlotte Thérèse said...

Coolt!

Gillar såna här tankeexperiment säg gärna till ifall du skriver om fler framöver!

Charlotte

Charlotte Thérèse said...

Oops!

Hope it didn't matter that I wrote mainly in Swedish - I didn't notice it until afterwards....

Unknown said...

Hi
good notes!
if we want the probability of 3 persons of n persons haven,t same b'day ,what change should i do in the formula?! what 's the result?
thanks , im await for your recommendations!
cheers

Anonymous said...

When I was working on generic viagra labs, I made my birthday party in a disco, but work it's work and I just invite 2 people of the all department, why ? because I didn't really like the other people, they we're weird or I just don't like him and they know it, but they didn't care because they know how I am, work it's work and that's it.
Thanks