icon

Myths of maths: The Monty Hall problem

Chris Budd Share this page

Myths of maths: The Monty Hall problem

Chris Budd

This article is based on a talk in an ongoing Gresham College lecture series. You can see a video of the talk below.

The Monty hall problem is one of the most famous problems in mathematics and in its original form goes back to a game show hosted by the famous Monty Hall himself. The contestants on the game show were shown three shut doors. Behind one of these was a high value prize, such as a car. Behind the other two was a low value prize, such as a goat. If the contestants opened the correct door then they won the prize, otherwise they won nothing.

The contestants were then asked to choose a door, and to tell the host which door they had chosen. This door remained shut for the time being. The host then opened a different door to reveal a goat behind it. The contestants were then given a choice. They could stay with the door that they have chosen, or they could swap to the remaining unopened door. The door they finally ended up with was then opened, to reveal the prize car, or maybe just a goat.

The question is: should the contestant change their choice of door or not?

The accepted answer is "yes". In fact, by swapping doors you double your chances of winning the prize. This is surprising, which is why the problem has become so famous. This answer was given in the gambling film 21 and has also been advocated as a reason why you should make changes in your choice of love.

Three doors and a goat

Car or goat?

However, it turns out that the accepted answer is not always correct and is an example of loose thinking. The answer to whether you switch doors or not depends entirely upon the host (and to some extent the contestant) and what they know, or don't know.

First let's assume that the host knows behind which door the car is. When you, the contestant, have picked a door the host will always choose to open a door with a goat, and you know that this is the case. This is a reasonable assumption: if the host chose to open the door with the car, the game would be over. If you decide to stick with your door then you win if your initial guess was correct. The chance of this was 1/3 and the host opening a door with a goat doesn't change this: whatever your initial choice, they would always have responded accordingly, making sure they open a door with a goat. If you swap doors, then you win if your initial guess was wrong. The probability of this was 2/3, and again this probability hasn't changed by the host revealing a goat. What has changed, however, is the fact that this probability of winning is now tied solely to the third remaining door, the one you didn't pick initially and which the host didn't open.

This reasoning confirms the accepted answer to the Monty Hall problem: it pays to swap because your probability of winning is higher if you do.

But what if the host doesn't know themselves where the car is and opens a door at random after you have picked your door? The the fact that the door opened by the host reveals a goat does give you new information about your door. Since one door has been eliminated it is now more likely that the door you picked is the one with the car, and this extra likelihood is shared with the third door. The probability of your door concealing a car is now 1/2; the same as the other remaining door concealing the car. It now doesn't make a difference whether you swap or not.

Thus when confronted with a situation that reminds you of the Monty Hall problem, don't just assume that the best thing to do is embrace change. It all depends on the underlying assumptions on who knows what.

We can make the reasoning above more explicit using Bayes' theorem, which tells you how to work out the probability of an event A occurring given that an event B has occurred. In our example, we take A to be the event that the door you have picked has a car behind it and B the event that the host opens a door with a goat.

Bayes' theorem tells us that the probability A given B, which we write as P(A|B) is equal to

$$P(A|B)=\frac{P(B|A)P(A)}{P(B)}.$$ Now $P(A)$ in our example is the probability of you having picked the door with the car, so $P(A)=1/3$. If the host knows where the car is and always opens a door with a goat, then $P(B)=1$. What about $P(B|A)$? It's the probability the host opens a door with a goat given that you have picked the door with the car. Since the host always opens a door with a goat, irrespective of your choice, $P(B|A)=1$ as well. This means that $$P(A|B)=\frac{P(B|A)P(A)}{P(B)}=P(A)=1/3.$$ Therefore, the probability that the car is behind the door you haven't picked and the host hasn't opened, is $1-1/3=2/3$. If the host doesn't know where the car is and opens a door at random, then $P(B),$ the probability that the host opens a door with a goat, is equal to $2/3$. Since the host is not going to pick the same door as you, the probability $P(B|A)$ (that the host picks a door with a goat, given that you picked the door with the car) is equal to $1$: the host is bound to pick a goat since you have the car. In line with our reasoning above, Bayes' theorem now tells us that $$P(A|B)=\frac{P(A)}{P(B)}=\frac{1/3}{2/3}=1/2.$$

There is also another instance of this problem, which involves a mean host set on fooling you, who knows where the car is. The host banks on the fact that you know the usual answer to the Monty Hall problem. If you pick the door with the car (probability 1/3), the host will open a door with a goat and challenge you to swap doors. Of course you do, and end up with a goat with probability 1.

If you first choose a door with a goat (probability 2/3), then the host asks you to pick one of the other two doors which will then be eliminated from the choice of three. (No door will be opened by the host.) Having done that, you are then allowed to either stick with your original door or swap to the remaining door. In this case, there is a chance of 1/2 that the door you excluded was the one with the car, so whether you swap or not, your chance of getting a goat is 1/2.

Overall, with these rules the chance of getting a goat is $1/3 \times 1 + 2/3\times 1/2 = 2/3$. The mean host is likely to win!

(I am indebted to Rob Eastaway, the Director of Maths Inspiration, for telling me about this way of playing the Monty Hall problem.)



About the author

Chris Budd

Chris Budd.

This article is based on a talk in Budd's ongoing Gresham College lecture series (see video above). You can see other articles based on the talk here.

Chris Budd OBE is Professor of Applied Mathematics at the University of Bath, Vice President of the Institute of Mathematics and its Applications, Chair of Mathematics for the Royal Institution and an honorary fellow of the British Science Association. He is particularly interested in applying mathematics to the real world and promoting the public understanding of mathematics.

He has co-written the popular mathematics book Mathematics Galore!, published by Oxford University Press, with C. Sangwin, and features in the book 50 Visions of Mathematics ed. Sam Parc.

Read more about...

Comments

Permalink

If you first choose a door with a goat (probability 2/3), then the host asks you to pick one of the other two doors which will then be eliminated from the choice of three. (No door will be opened by the host.) Having done that, you are then allowed to either stick with your original door or swap to the remaining door. In this case, there is a chance of 1/2 that the door you excluded was the one with the car, so whether you swap or not, your chance of getting a goat is 1/2

I disagree with this part, the chances that you picked the wrong door right off the bat indicate that your chances would still be better to switch doors even if one of the two remaining doors was removed at random After your initial pick. Because your first pick was probably statistically not in your favor.

Permalink

Naw. He’s right like. Imagine it with like a hundred doors. 99 goats and a car.you pick one. Monty, not knowing where the car is, then, picks 98 doors and amazingly doesn’t get the car in any. Oof. If he did know you’d have changed straight away. But since he didn’t you’re very much in the ‘do I feel lucky’ situation and this is a 44 magnum that will ow your head clean off.

Permalink

There are twelve winning games. Six wins if the Player does not switch, six wins if the Player switches. I will list six examples: Game 1. Car Door A. Player Door A Monty opens door B . No switch. Win. Game 2. Car Door A Player Door A Monty opens door C . No switch. Win. Game 3. Car Door B Player Door B Monty opens door A . No switch. Win. Game 4. Car Door B Player Door B Monty opens door C . No switch. Win. Game 5. Car Door C Player Door C Monty opens door A . No switch. Win. Game 6. Car Door C Player Door C Monty opens door B . No switch. Win. Try it! List the six games that win from switching.