The Monty Hall Problem is a great example to demonstrate Bayesian Updating with Discrete Priors.

## Monty Hall Problem

The monty hall problem is based on a TV show in which one could either win a car or nothing. The participant was presented three doors. Behind one was a car, behind the others were goats. After the participant had chosen a door, Monty Hall opened one of the other doors. Behind that door was always a goat, as he couldn’t open the one with the car behind. The participant was then asked if he wants to stick with his initial choice or if he wants to switch.

The question behind that problem is relatively simple. Should he stay or switch?

## The Simple Answer

The simple answer is that the participant should switch as his probability to win is then twice as high than when he wouldn’t switch. That is because the only way to win without switching is when he chooses the right door with his first choice. As there are three doors each with equal probability to be the winning door, the probability of choosing the right door with the first choice is . On the other hand the participant chooses with a probability of a goat first and Monty Hall then opens the other “goat door”. So when the participant switches he has the car with a probability of 1. The total probability of winning given that he’s switched is therefore .

## Bayesian Method

We wouldn’t be we when we wouldn’t try to prove that the probability of winning given that he’s switched is . We will do this with the help of Bayesian Updating.

**The Model**

Important is that our model is appropriate. We model the monty hall problem as following:

- Let Event A be that we choose door 1 and the goat is behind door 1
- Let Event B be that Monty Hall shows a goat behind door 2

We then want to know the probability that we choose door 1, Monty Hall shows a goat behind door 2 and the car is indeed behind door 1. Or, like always, mathematically:

P(A|B)

The Bayes’ Theorem says that:

The Probability for P(A) is easy to calculate as the probability that the car is behind door one is . The Probability for P(B|A) is similar easy as Monty Hall has two options when the car is behind door 1. He can either choose door 2 or door 3. So the probability that he chooses door 2 is . The more difficult part is to calculate P(B). We remember that: . We already calculated the first part:

But consists of two parts, as the car can either be behind door 2 or door 3.

If the car is behind door 2, event B will never happen so we have:

and

If the car is behind door 3, event B will certainly happen as Monty Hall has to choose door 2 if we’ve chosen door 1 and the car is behind door 3. We therefore have:

and

We then have:

If we know apply the Bayes’ Theorem we have:

The probability that the car is behind our door one given that Monty Hall showed a goat behind door two is therefore . The only door left except of our door one is door three so the probability of winning with door three given that Monty Hall showed a goat behind door two is . Switching to door three gives us therefore twice the probability of winning our dream car. We can summarise all of that again in a table:

prior | likelihood | unnormalised posterior | posterior | |

Car is behind door 1 | ||||

Car is behind door 2 | o | o | 0 | |

Car is behind door 3 | 1 | |||

Total | 1 | 1 |