Birthday Problem: Probability that at least two also share the same weekday, if weekday uniformly distributed and independent of birth date

birthdayprobabilityself-learning

Consider the following problem extension for the birthday problem: We now want know the probability that out of $n$ persons, at least two people were born on the same date and the same weekday (for example, both were born on the 02.01 and on a Tuesday). We also want to know for which $n$ that probability is great than $\frac{1}{2}$.

We can assume that birthdays and weekdays follow a uniform distribution (also, we can assume the absence of leap-years) and are independent events. That is, the probability to be born on a certain date is $\frac{1}{365}$ and to be born on a weekday is $\frac{1}{7}$.

Best Answer

You are looking for $$1 - \dfrac{(2555)_n}{2555^n} \ge \dfrac{1}{2}$$

where $$(2555)_n = (2555)(2554)\cdots (2555-n+1)$$

Plugging this into Wolframalpha gives $n \ge 59.7852$.

Testing this out:

$$1 - \dfrac{(2555)_{60}}{2555^{60}} \approx 0.50252$$

$$1- \dfrac{(2555)_{59}}{2555^{59}} \approx 0.49076$$

If the notation is confusing, another notation would be, the probability that every person has a distinct birthday and birth weekday is:

$$\left(\dfrac{2555}{2555}\right)\left(\dfrac{2554}{2555}\right)\cdots \left(\dfrac{2555-n+1}{2555}\right)$$

So, the probability that at least two people share both a birthday and a birth weekday is the complement of that:

$$1-\left(\dfrac{2555}{2555}\right)\left(\dfrac{2554}{2555}\right)\cdots \left(\dfrac{2555-n+1}{2555}\right) = 1-\dfrac{(2555)_n}{2555^n}$$

In Excel, you can use the following formulas:

$$\begin{array}{rl}\text{Cell A1:} & \text{Number of people} \\ \text{Cell B1:} & \text{Prob All Distinct} \\ \text{Cell C1:} & \text{Prob at least two share}\end{array}$$

This gives you column headers. Next, we want calculations:

$$\begin{array}{rl}\text{Cell A2:} & \text{=ROW()} \\ \text{Cell B2:} & \text{=(2555-ROW()+1)/2555} \\ \text{Cell C2:} & \text{=1-B2} \\ \text{Cell A3:} & \text{=ROW()} \\ \text{Cell B3:} & \text{=B2*(2555-ROW()+1)/2555} \\ \text{Cell C3:} & \text{=1-B3}\end{array}$$

Copy the formulas in cells $\text{A3:C3}$ to $\text{A3:A100}$. You will see that at 60 people, the probability in column $C$ is greater than $0.5$ for the first time.