• Quick note - the problem with Youtube videos not embedding on the forum appears to have been fixed, thanks to ZiprHead. If you do still see problems let me know.

Monty Hall Problem

gnome said:
Actually, it's easy to pick a random integer between 1 and infinity.

Pick a random decimal number n between 0 and 1 (most random number generators do this) and your random integer is 1/n, rounded off.

Yes, this is valid. Just not uniformly distributed. It's easy to come up with probablity distributions over all the integers between 1 and infinity, and procedures for using them to pick a random integer. It's just not possible to define the uniform distribution on [1,infinity].

In your distribution, there is a 33% chance that you will come up with a number between 1/1.5 and 1, which means that there is a 33% chance that the number you pick will be equal to 1.
 
Epepke, why are you appointing yourself the arbitrer of true skeptical thinking when you got it wrong in the first place yourself?

You said "Actually, the ultimate result is that it's whatever Monty feels like doing at the time." which is of course wrong.

It may or may not depend on Monty's feelings, this is not clear in the question.

I fail to see why those who make one assumption are 'tards and those who make another assumption are true skeptics.
 
Yahweh revealed his code to solve the problem, let me reveal the code which I think defines the problem:

<PRE>
BOOLEAN monty_hall_problem(PARAM host_strategy, PARAM contestant_strategy,
BOOLEAN host_must_offer_choice, BOOLEAN host_might_reveal_car)
{
Integer winningdoor=nextRandomInteger(3);
Integer firstguess=nextRandomInteger(3);
Integer revealed_prize;
Integer finalguess=firstguess;
if (host_must_offer_choice OR
host_decides_to_offer_choice(winningdoor,
firstguess,host_strategy))
{
revealed_prize=openDoor(winningdoor,firstguess,
host_might_reveal_car);
if (revealed_prize==winningdoor) return LOSE;
if (contestant_switches(contestant_strategy) )
finalguess=anythingbut(firstguess,revealed_prize);
}
if (finalguess==winningdoor) return WIN;
return LOSE;
}
</pre>

Now if I were to ask what was the probability of this function returning WIN given that the contestant_switches function always returns TRUE then you would not be able to answer. It would depend on the results of the functions that are not given.

The true critical thinker would ask for the missing information to be supplied and not jump at one conclusion or the other.

I am prepared to confess I jumped at one conclusion, are the "it depends on the intentions of the host" crowd prepared to admit they jumped at the other?

(Incidentally, here are the results again of the program when it is run: )<table border=1>
<tr><td align=center colspan=5>Host Never Reveals Prize</td></tr>
<tr><td rowspan=2 valign=center>Contestant Strategy</td><td align=center colspan=4>Host Behaviour</td></tr>
<tr><td>Bad Monty</td><td>Fair Monty</td>
<td>Good Monty</td><td>Rules say offer change</td></tr>
<tr><td>1. Never switch even if offered</td>
<td>0.33</td><td>0.33</td><td>0.33</td><td>0.33</td></tr><tr><td>2. Toss a coin if offered</td>
<td>0.17</td><td>0.42</td><td>0.66</td><td>0.50</td></tr><tr><td>3. Always switch if offered</td>
<td>0.00</td><td>0.50</td><td>1.00</td><td>0.67</td></tr><tr><td align=center colspan=5>Host May Reveal Prize</td></tr>
<tr><td rowspan=2 valign=center>Contestant Strategy</td><td align=center colspan=4>Host Behaviour</td></tr>
<tr><td>Bad Monty</td><td>Fair Monty</td>
<td>Good Monty</td><td>Rules say offer change</td></tr>
<tr><td>1. Never switch even if offered</td>
<td>0.33</td><td>0.33</td><td>0.33</td><td>0.33</td></tr><tr><td>2. Toss a coin if offered</td>
<td>0.17</td><td>0.33</td><td>0.50</td><td>0.33</td></tr><tr><td>3. Always switch if offered</td>
<td>0.00</td><td>0.33</td><td>0.67</td><td>0.33</td></tr></table>
 
gnome said:
Actually, it's easy to pick a random integer between 1 and infinity.

Pick a random decimal number n between 0 and 1 (most random number generators do this) and your random integer is 1/n, rounded off.
If the machine has f fraction bits in its widest floating-point format, the largest number you're going to select with this algorithm is about 2^f.

~~ Paul
 
Robin said:
Epepke, why are you appointing yourself the arbitrer of true skeptical thinking when you got it wrong in the first place yourself?

You said "Actually, the ultimate result is that it's whatever Monty feels like doing at the time." which is of course wrong.

It may or may not depend on Monty's feelings, this is not clear in the question.

I fail to see why those who make one assumption are 'tards and those who make another assumption are true skeptics.

I already said that I've found empirically that it's impossible to explain this, and your response is a case in point. You're really grasping at very tiny straws so that you can believe I am wrong. Believe what you like. P.T. Barnum said, "never try to smarten up a chump." He was right.

I don't think of myself as an arbiter of skeptical thinking. I think of myself as a lifeform who occasionally preys on skeptics, taking advantage of their gullibility.
 
Epepke
P.T. Barnum said, "never try to smarten up a chump." He was right.

Thanks for the advice, I won't try to convince you anymore. I forgot it was "miss the point" week around here.
 
Ok apart from the self-confessed chumps out there does anybody else have trouble with this concept? One assumption here is no better than the other. Gnome had it right in the first place. One group are saying that the result depends on what the host wants - which assumes that the host does have a choice. Another group says 0.667 which assumes the host did not have a choice.

Of course it is quite interesting to explore the possibilities but critical thinking consists of clarifying the question, not going off and dreaming possible interpretations. As I have said if you can assume nothing then the possibilities of the original question to Marilyn are endless.
 
Robin, I see where you're coming from now. You're breaking up the problem into two cases:

1. Where Monty is forced by the rules to always offer a switch, and

2. Where the rules are open and Monty may or may not offer a switch.

You correctly claim that you're making an assumption if you assume case 1 or case 2.

The point I've been trying to make all along, though, is that from my perspective, I'm not making any assumption. I claim that the problem is vague and unsolvable not because I'm assuming case 2, but because I don't have enough information to distinguish whether we are in case 1 or case 2 in the first place.

That sums up my position.

One final thing. For those that think this position is overly pedantic, I'll remind you that many math "brain teasers" are founded on some detail or quirk in the language. For example, the old problem, "I have two coins in my pocket totalling 55 cents. One of them is not a nickel. What are the two coins?"
 
You're breaking up the problem into two cases:

1. Where Monty is forced by the rules to always offer a switch, and

2. Where the rules are open and Monty may or may not offer a switch.

You correctly claim that you're making an assumption if you assume case 1 or case 2.
But I further claim that saying "it depends on what the host wants" is assuming case 2 because in case 1 the host has no room for strategy.

However you are right in saying it is "vague and unsolvable".

Maybe it is closer to that other famous old brain teaser:

How do you get a condom on an elephant? (Hint, take the "e" 's out of "elephant" and the "f" out of "weigh").
 
Robin said:
But I further claim that saying "it depends on what the host wants" is assuming case 2 because in case 1 the host has no room for strategy.

However you are right in saying it is "vague and unsolvable".

Maybe it is closer to that other famous old brain teaser:
I see your point about the claim, "It depends on what the host wants." It would be better to claim, "It depends on the rules of the game, and whether or not Monty is required to offer the switch."

I don't think I've heard that one before; how do you get a condom on an elephant?
 
Cabbage said:
I don't think I've heard that one before; how do you get a condom on an elephant?

To be honest I don't know if this one works in the USA or anywhere outside GB and Australia. I will leave it for a while in case anyone else wants to get it.

You've got to use the hint: (Hint, take the "e" 's out of "elephant" and the "f" out of "weigh").

The strange thing is that overly analytical people never get it, they go on for ages going "don't tell me, I'll work it out"

But most people just point out to you the obvious point about the hint, see the trick and start laughing.
 
Robin said:
To be honest I don't know if this one works in the USA or anywhere outside GB and Australia. I will leave it for a while in case anyone else wants to get it.

You've got to use the hint: (Hint, take the "e" 's out of "elephant" and the "f" out of "weigh").

The strange thing is that overly analytical people never get it, they go on for ages going "don't tell me, I'll work it out"

But most people just point out to you the obvious point about the hint, see the trick and start laughing.

First, you get an Australian homo puffy boy.....the sort who is disposed to manipulate large mammals to a state of turgidity.

Homo says what?
 
How about this take on the general problem?

You have two possible situations... that Monty always offers a switch (in which case you improve your chances by switching)... or that Monty sometimes will not. (In which case your chances remain the same if you switch).

Without even knowing the likeihood of either possibility...

By switching, you are doing no worse (if Monty sometimes does not offer a switch), and possibly doing better (if Monty always offers a switch). So it's still better to switch.

:D
 
gnome said:
How about this take on the general problem?

You have two possible situations... that Monty always offers a switch (in which case you improve your chances by switching)... or that Monty sometimes will not. (In which case your chances remain the same if you switch).

Maybe Monty only gives you the choice if your original pick was the curtain with the car. You don't know that he doesn't, and it's unspecified in the problem. Where does that 50% go then?

Yes, yes. I know. I've determined empirically that there is a high likelihood that this concept is impossible to convey. And I'm missing the point, or I'm over the top, or I'm a goofball, or I'm wrong for suggesting it. Have a nice day, chumps.
 
The likelihood that Monty will offer you the switch isn't relevant. What is relevant is whether his offer is independent of whether your initial choice was correct.

If his offer is independent of whether your initial choice was correct then you should switch.

If his offer is not independent of whether your initial choice was correct then you can't determine whether you should switch unless you know _in what way_ his offer depends on your initial choice.

Maybe he wants to make you lose, in which case he only offers the switch if your initial choice is correct. Maybe he wants you to win, in which case he only offers the switch if your initial choice is incorrect. Maybe he has decided beforehand to offer you the switch with probably X if your initial choice is correct and with probability Y if your choice is incorrect. (Incidentally, the first two sentences of this paragraph are special cases of that). If you don't know what that probability is then you can't say whether it's best to switch.
 
Stick this in you Java Virtual Machine and run it!

In the app below we have two actors: Andy and Bob. Andy never switches and Bob always switches. Because of this, I've cheated a bit: Monty offers Bob the switch, but does not offer the same to Andy. Allthough Andy and Bob are playing with the same doors, they are ignorant of the other player's actions. Both players can win the car; it will count as a win for both.

If you're clueless as to what to do with the code below, I guess I could post a runnable, but I couldn't be bothered making one right now...

Note that the app will take a wee while to run, and you'll only see the currently running game.



import java.util.*;
import javax.swing.*;
import java.awt.*;

/**
* @author Pogo
*
*/
public class MainMonty extends JFrame implements Runnable {

private int nsw;//never switches: Andy

private int asw;//always switch: Bob

private Random rand;

private static final int MAX = 1000000;

private int getMonty(int car, int bob) {
if (car != 0 && bob != 0)
return 0;
if (car != 1 && bob != 1)
return 1;
if (car != 2 && bob != 2)
return 2;
return 42;
}

private int bobSwitch(int monty, int bob) {
if (monty == 0 && bob == 1)
return 2;
if (monty == 0 && bob == 2)
return 1;
if (monty == 1 && bob == 0)
return 2;
if (monty == 1 && bob == 2)
return 0;
if (monty == 2 && bob == 0)
return 1;
if (monty == 2 && bob == 1)
return 0;

return 42;
}

private String g(boolean g) {
if (!g)
return "Goat";
else
return "Car";
}

public void run() {
nsw = 0;
asw = 0;
rand = new Random();

setSize(300, 200);
JTextArea text = new JTextArea();
JScrollPane scroll = new JScrollPane(text);
scroll.setPreferredSize(new Dimension(1000, 800));
getContentPane().add(scroll);
setDefaultCloseOperation(EXIT_ON_CLOSE);
show();

for (int i = 0; i < MAX; i++) {
text.setText("");
boolean[] doors = { false, false, false };
int c = rand.nextInt(3);
doors[c] = true;
text.append("Game " + i + " on!\nDoors:\n" + g(doors[0]) + ", "
+ g(doors[1]) + ", " + g(doors[2]) + ".\n");

int andy = rand.nextInt(3);
int bob = rand.nextInt(3);
int monty = getMonty(c, bob);

text.append("Andy picks door " + (andy + 1)
+ " and Bob picks door " + (bob + 1) + "\n");
text.append("Monty opens door " + (monty + 1) + " for Bob\n");
bob = bobSwitch(monty, bob);
text.append("Bob switches to " + bob + "\n");

if (doors[andy]) {
text.append("Andy wins!\n");
nsw++;
}
if (doors[bob]) {
text.append("Bob wins!\n");
asw++;
}
if (i % 1000 == 0) {
System.gc();
setTitle(MAX - i + " games left");
}
}

setTitle("finished!");
text.append("andy won " + nsw + " out of " + MAX + " games.\n");
text.append("bob won " + asw + " out of " + MAX + " games.\n");

}

public static void main(String[] args) {
System.out.println("Playing the Monty Hall!");
new MainMonty().run();
}
}
 
Robin said:
But I further claim that saying "it depends on what the host wants" is assuming case 2 because in case 1 the host has no room for strategy.
No, because which case holds depends on what the hosts wants. Are you saying that the idea that the host has free will is an "assumption"?
 
Number Six said:
The likelihood that Monty will offer you the switch isn't relevant. What is relevant is whether his offer is independent of whether your initial choice was correct.


That is incisive. The probabilistic argument assumes independent variables.

I tried to explain this the third of four times I tried to explain the Monty Hall problem, and it didn't work then. It's nice to see someone grok it.
 

Back
Top Bottom