# Sharing a birthday - what's wrong in my approach?

This is not really a homework problem. This is something I enjoy thinking about.

1. Homework Statement

How many people should there be in a group to have a 50% chance of at least two of them having the same birthday.
I know that there a many pages explaining how to solve this and the answer itself. But I wanted to develop my own way to figure this out.

## Homework Equations

The problem boils down to how many unique pairs or handshakes can be formed in the group. That is N x (N-1) / 2 .
Also, the probability that a pair has the same birthday is 1/365.

Therefore, I think I have solve the following equation for N
N x (N-1) = 365

## The Attempt at a Solution

The approximate value of N is 20. For N=20, I think the probability of having at least one pair with the same birthday is 52%. But according this Wikipedia page there has to be 23 people for a 50% probability in this case.

Clearly I am doing something wrong. Maybe assigning the 1/365 probability to every pair is not correct. I don't know.

mfb
Mentor
You can't add probabilities like that. Try to use the same approach to find when there is certainly a shared birthday and the problem should become obvious.
Similarly: 3 die rolls don't give you a 50% probability to roll a 1. The probability is a bit lower.

You calculated the number of people where we have on average 1/2 shared birthday.

Ray Vickson
Homework Helper
Dearly Missed
This is not really a homework problem. This is something I enjoy thinking about.

1. Homework Statement

How many people should there be in a group to have a 50% chance of at least two of them having the same birthday.
I know that there a many pages explaining how to solve this and the answer itself. But I wanted to develop my own way to figure this out.

## Homework Equations

The problem boils down to how many unique pairs or handshakes can be formed in the group. That is N x (N-1) / 2 .
Also, the probability that a pair has the same birthday is 1/365.

Therefore, I think I have solve the following equation for N
N x (N-1) = 365

## The Attempt at a Solution

The approximate value of N is 20. For N=20, I think the probability of having at least one pair with the same birthday is 52%. But according this Wikipedia page there has to be 23 people for a 50% probability in this case.

Clearly I am doing something wrong. Maybe assigning the 1/365 probability to every pair is not correct. I don't know.

The usual birthday problem looks at more than "pairs"; it asks for the probability that at least two people share a common birthday; perhaps three, or four, or more people share that same birthday. It does so by looking at the probability of no common birthdays, then taking its complement.

The problem of computing the probability that exactly one pair share a birthday (and no others do) is much harder.

Last edited:
PeroK
Homework Helper
Gold Member
2021 Award
This is not really a homework problem. This is something I enjoy thinking about.

1. Homework Statement

How many people should there be in a group to have a 50% chance of at least two of them having the same birthday.
I know that there a many pages explaining how to solve this and the answer itself. But I wanted to develop my own way to figure this out.

## Homework Equations

The problem boils down to how many unique pairs or handshakes can be formed in the group. That is N x (N-1) / 2 .
Also, the probability that a pair has the same birthday is 1/365.

Therefore, I think I have solve the following equation for N
N x (N-1) = 365

## The Attempt at a Solution

The approximate value of N is 20. For N=20, I think the probability of having at least one pair with the same birthday is 52%. But according this Wikipedia page there has to be 23 people for a 50% probability in this case.

Clearly I am doing something wrong. Maybe assigning the 1/365 probability to every pair is not correct. I don't know.

Your method is an approximation for low probabilities. Let's take an example of 3 people, A, B, C. What is the probability of a shared birthday?

Probability A & B share a birthday = 1/365
Probability A & C share a birthday = 1/365
Probability B & C share a birthday = 1/365

So, total probability is 3/365 = 0.008219

But, that's only an approximation to the correct answer, which is

Probability A & B do not share a birthday = 364/365
Probability that C does not share a birthday with A & B (given that A & B do not share a birthday) = 363/365

Probability that A, B, C all have different birthdays = (364/365)(363/365).

Probability that there is a shared birthday = 1 - (364/365)(363/365) = 0.008204

As you increase the number of people, the approximation becomes less accurate (as you've discovered for about 20 people).