You are viewing the historical archive of The Philosophy Forum.
For current discussions, visit the live forum.
Go to live forum

Mathematical Conundrum or Not? Number Six

Jeremiah June 29, 2018 at 16:27 20800 views 1160 comments Logic & Philosophy of Mathematics
Not sure I can find another conundrum that will generate as much discussion as our last one; however, it is time to move on.

So this one is called the Two Envelopes Paradox and this is how it goes:

You are playing a game for money. There are two envelopes on a table.
You know that one contains $X and the other $2X, [but you do not
know which envelope is which or what the number X is]. Initially you
are allowed to pick one of the envelopes, to open it, and see that it
contains $Y . You then have a choice: walk away with the $Y or return
the envelope to the table and walk away with whatever is in the other
envelope. What should you do?


What should you do?

Comments (1160)

Michael June 29, 2018 at 16:58 ¶ #192170
By £2X do you mean twice what’s in the other envelope?
Jeremiah June 29, 2018 at 17:11 ¶ #192181
Michael June 29, 2018 at 17:29 ¶ #192192
OK, so the initial answer is that it doesn’t matter as there’s a 50% chance of having picked the more valuable envelope and switching doesn’t change the odds.

The paradox supposedly arises when you consider that switching into the more valuable envelope doubles your winnings, whereas switching into the less valuable envelope halves your winnings, so there’s more to gain than there is to lose, and as each is equally likely, switching is the better choice.
Michael June 29, 2018 at 17:49 ¶ #192200
As a bet it seems like a 2:1 payout? You have £10. You bet £5 on heads. If you win you get £15 back. And you're betting on a coin toss. Is that right?
Jeremiah June 29, 2018 at 18:47 ¶ #192214
Reply to Michael

I am not sure that is quite right, as you have added information that was not in the OP. In your example you have a starting amount that is known, but in our case you don't know your starting amount.

You could have X or 2X. If you have X and you switch then you get 2X but lose X so you gain X; so you get a +1 X. However, if you have 2X and switch then you gain X and lose 2X; so you get a -1 X.

Michael June 29, 2018 at 19:42 ¶ #192217
Quoting Jeremiah
I am not sure that is quite right, as you have added information that was not in the OP. In your example you have a starting amount that is known, but in our case you don't know your starting amount.


You bet [math]$\frac{x}{2}[/math] on heads. If you win you get [math]$\frac{3x}{2}[/math] back. The odds of winning are [math]\frac{1}{2}[/math].
Michael June 29, 2018 at 19:46 ¶ #192218
Quoting Jeremiah
You could have X or 2X. If you have X and you switch then you get 2X but lose X so you gain X; so you get a +1 X. However, if you have 2X and switch then you gain X and lose 2X; so you get a -1 X.


The amount you have is [math]$x[/math]. The other envelope contains either [math]$2x[/math] or [math]$\frac{x}{2}[/math]. If it's [math]$2x[/math] then you gain [math]$x[/math] by switching. If it's [math]$\frac{x}{2}[/math] then you lose [math]$\frac{x}{2}[/math] by switching.
Jeremiah June 29, 2018 at 19:55 ¶ #192219
Reply to Michael You just said the same exact thing I did, as it can only be half X if you start with 2X. Which still results with a -1 X.

Jeremiah June 29, 2018 at 19:57 ¶ #192220
Your expected gain and loss is tied to the uncertainty of what you start with.
Michael June 29, 2018 at 20:02 ¶ #192222
Quoting Jeremiah
You just said the same exact thing i did


It's not. Mine is closer to how one would understand it were we to look in the envelope before deciding.

If we open the envelope and see £10 then we know that the other envelope contains either £5 or £20. By switching there's a 50% chance of losing £5 and a 50% chance of gaining £10. Switching seems like the better option.

Am I right with this reasoning? If so, why would not looking first make a difference? The odds are 50% that the other envelope contains twice as much whether we look or don't.
Jeremiah June 29, 2018 at 20:06 ¶ #192225
Quoting Michael
It's not. Mine is closer to how one would understand it were we to look in the envelope before deciding.


It is the same thing, the math comes out exactly the same.

Michael June 29, 2018 at 20:11 ¶ #192226
Quoting Jeremiah
It is the same thing, the math comes out exactly the same.


It's not the same thing.

I'm saying that if I have £10 then I either lose £5 by switching or gain £10.

You're saying that if I have £10 and the other envelope contains £5 then I lose £5 by switching and that if I have £5 and the other envelope contains £10 then I gain £5 by switching.

Notice that in my example it's better to switch whereas in your example it isn't.
Michael June 29, 2018 at 20:13 ¶ #192227
So there are two different ways to describe the situation, each leading to a different conclusion:

1. I have [math]$y[/math] and the other envelope contains either [math]$2y[/math] or [math]$\frac{y}{2}[/math].

2. Either I have [math]$x[/math] and the other envelope contains [math]$2x[/math] or I have [math]$2x[/math] and the other envelope contains [math]$x[/math].
Jeremiah June 29, 2018 at 20:17 ¶ #192228
Quoting Michael
I'm saying that if I have £10 then I either lose £5 by switching or gain £10.


There are two possibilities in this case either X = 5 or X = 10

Case one X = 5

If you have 2X and switch then you are left with 5 bucks. You had 10 and now you have 5. You got a -X.

Case two X = 10

If you have X and switch then you are left with 20 bucks. You had 10 and now you have 20. You got a +X.

Exactly what I said before.
Michael June 29, 2018 at 20:27 ¶ #192229
Reply to Jeremiah

Your reasoning is:

I have £10. If X is 5 then I lose £X by switching. If X is 10 then I gain £X by switching.

So it's either -£X or +£X. This is symmetrical.

My reasoning is:

I have £10. If X is 5 then I lose £5 by switching. If X is 10 then I gain £10 by switching.

So it's either -£5 or +£10. This is not symmetrical.
Jeremiah June 29, 2018 at 20:33 ¶ #192232
Quoting Michael
My reasoning is:

I have £10. If X is 5 then I lose £5 by switching. If X is 10 then I gain £10 by switching.

So it's either -5 or +10. This is not the same.


Look here:

Quoting Jeremiah


Case one X = 5

If you have 2X and switch then you are left with 5 bucks. You had 10 and now you have 5. You got a -X.

Case two X = 10

If you have X and switch then you are left with 20 bucks. You had 10 and now you have 20. You got a +X.

Exactly what I said before.



Case one X = 5. You lose 5 bucks.

You had 10 and now you have 5. Means you lost 5 and in that case X = 5. Therefore you got a -X.

Case two X = 10. You gain 10 bucks.

You had 10 and now you have 20. Means you gained 10 and in that case X=10. Therefore you got a +X

The same outcome as you.

You have to understand that X is a variable.
Jeremiah June 29, 2018 at 20:43 ¶ #192234
The fact that X is a variable is what makes this different, as even if you know the amount in one envelope you still don't know if that amount it is X or 2X. So I guess the question is: Does the new information of an amount shift the odds at all, given that you still don't know if it is X or 2X?
Michael June 29, 2018 at 20:47 ¶ #192236
Quoting Jeremiah
Case one x = 5. You lose 5 bucks.

You had 10 and now you have 5. Means you lost 5 and in that case X = 5. Therefore you got a -X.

Case two x = 10. You gain 10 bucks.

You had 10 and now you have 20. Means you gained 10 and in that case X=10. There you got a +X

The same outcome as you.


Yes, and the X that you lose is £5 and the X that you gain is £10. Therefore, there's more to gain than there is to lose.
Jeremiah June 29, 2018 at 20:51 ¶ #192237
Reply to Michael Only if you have X.
Michael June 29, 2018 at 21:03 ¶ #192240
Quoting Jeremiah
Only if you have X.


Obviously you'll only win if you have X. My point is that by switching there's a 50% chance of gaining an extra £10 and a 50% chance of losing £5. Those odds favour a switch.
Michael June 29, 2018 at 21:14 ¶ #192242
Here's a program to show what I mean:

<?php

$switch = $no_switch = 0;

for ($i = 1; $i <= 1000000; ++$i)
{

// Our envelope contains £10
$chosen = 10;

// The other envelope contains either £5 or £20
$other = random_int(0, 1) ? 5 : 20;

// If we switch
$switch += $other;

// If we don't switch
$no_switch += $chosen;

}

echo 'Switch: £' . number_format($switch) . PHP_EOL;
echo 'No Switch: £' . number_format($no_switch);


http://sandbox.onlinephpfunctions.com/code/b1d89ae10c4c5a8c3988bcf1112bb0b4f4ed8254

The result after 1,000,000 games:

Switch: £12,500,795
No Switch: £10,000,000
Baden June 29, 2018 at 21:38 ¶ #192253
Reply to Michael
Two envelopes are e.g. 5 (X) and 10 (2X) - Pick 10(2X) and switch get X - But if you've already picked 2X you cannot get 2(2X). There is no 4X (20). That's no longer a possibility. Once you pick once, you eliminate either a double or a halving. Your array presumes three possibilities 5, 10, and 20. That contradicts the description in the OP. Right?
Jeremiah June 29, 2018 at 21:39 ¶ #192254
Reply to Baden

Ya, I am moving that way, I am working on it now.
Michael June 29, 2018 at 21:41 ¶ #192256
Quoting Baden
Two envelopes are e.g. 5 (X) and 10 (2X) - Pick 10(2X) and switch get X - But if you've already picked 2X you cannot get 2(2X). There is no 4X (20). That's no longer a possibility. Once you pick once, you eliminate either a double or a halving. Your array presumes three possibilities 5, 10, and 20. That contradicts the description in the OP. Right?


If your envelope contains £10 then the other envelope contains either £5 or £20 (picked at random for each game).
Baden June 29, 2018 at 21:51 ¶ #192261
Reply to Michael

If the envelope contains 10 then the original pair must have been either A(5 and 10) or B(10 and 20) according to the OP description. If it was A(5 and 10) then switching gives you 5. There is never any possibility of 20. If it is B(10 and 20) there is never any possibility of 5. The only combinations given that you have a 10 are A or B. Therefore picking 10 is incompatible with both a possibility of 5 and of 20.

Therefore your program which presumes it is is incompatible with the OP.
Jeremiah June 29, 2018 at 21:58 ¶ #192265
Reply to Michael

I don't think that is quite the right way to look at this.

Let's try mapping this out and go back to our cases which I hope we are on the same page now.

Quoting Jeremiah


Case one X = 5

If you have 2X and switch then you are left with 5 bucks. You had 10 and now you have 5. You got a -X.

Case two X = 10

If you have X and switch then you are left with 20 bucks. You had 10 and now you have 20. You got a +X.


Let's call case one L and case two K. Where L is the event you start with 2X and K is the event you start with X. These are two different events.

You open it up and see you have 10 bucks:

In the event of L if you switch then you gain -X, which in this case is a loss of 5 bucks. If you don't switch then you gain 0.

In the event of K if you switch then you gain +X, which is gain of 10. If you don't switch then you gain 0.

These are two different events.

Now let's do it in the 1/2 terms.

In the event of L you get -1/2X, which would be a loss of 5 bucks. If you don't switch then you gain 0.

In the event of K if you switch you get 2X, which would be a gain of 10 bucks. If you don't switch then you gain 0.










Michael June 29, 2018 at 22:07 ¶ #192268
Reply to Baden

There are two equally likely scenarios (say the experimenter tosses a coin to determine which scenario to set up):

1. One envelope contains £10 and the other envelope contains £5.
2. One envelope contains £10 and the other envelope contains £20.

I open my envelope and find £10.

There's a 50% chance that the other envelope contains £5, and so a 50% chance that if I switch then I lose £5 (I did have £10, now I have £5).

There's a 50% chance that the other envelope contains £20, and so a 50% chance that if I switch then I gain £10 (I did have £10, now I have £20).

So switching gives me a 50% chance of gaining £10 and a 50% chance of losing £5. There's more to gain by switching than there is to lose.
Michael June 29, 2018 at 22:11 ¶ #192270
Quoting Jeremiah
In the event of L if you switch then you gain -X, which in this case is a lose of 5 bucks. If you don't switch then you gain 0.

In the event of K if you switch then you gain +X, which is gain of 10. If you don't switch then you gain 0.


So by switching you either lose £5 or you gain £10 (each equally likely). There's more to gain by switching than there is to lose. Therefore it's better to switch.
Baden June 29, 2018 at 22:17 ¶ #192273
Reply to Michael

Not sure if you saw my edit:

The only combinations given that you have a 10 are A or B. Therefore picking 10 is incompatible with both a possibility of 5 and of 20. Therefore your program which presumes it is is incompatible with the OP.

Quoting Michael
So switching gives me a 50% chance of gaining £10 and a 50% chance of losing £5. There's more to gain by switching than there is to lose.


No, you never get to that position. Switching gives you a 100% chance of gaining £10 iff you are in scenario two and 100% of losing £5 iff you are in scenario one. You can never be in both. That's impossible by the time you get to seeing the £10. The fact that you don't know which scenario you are in needs to be separated out from the actual possibilities available to you at that time which are dependent on the reality of the scenario that applies at that time.
Michael June 29, 2018 at 22:24 ¶ #192276
Quoting Baden
Therefore picking 10 is incompatible with both a possibility of 5 and of 20.


I don't know what you mean by this.

No, you never get to that position. Switching gives you a 100% chance of gaining £10 iff you are in scenario two and 100% of losing £5 iff you are in scenario one. You can never be in both. That's impossible by the time you get to seeing the £10. The fact that you don't know which scenario you are in needs to be separated out from the actual possibilities available to you at that time which are dependent on the reality of the scenario that applies at that time.


I don't accept this interpretation of probability. Say you toss a coin and if it's heads you put a blue ball in a box and if it's tails you put a red ball in a box. You give me the box and ask me to guess if it's blue or red (and I know the rules).

According to your reasoning, all I can say is that if it was heads then there's a 100% chance of a blue ball and if it was tails then there's a 100% chance of a red ball.

Whereas I'd say that there's a 50% chance of a blue ball and a 50% chance of a red ball.

But we can amend the OP to account for your kind of interpretation. You say that you are going to toss a coin and if it's heads then you will put £5 in an envelope and if it's tails then you will put £20 in an envelope. You give me the option of buying this envelope for £10 before you toss the coin. What should I do? I would buy the envelope, because there's a 50% chance of me gaining £10 and a 50% chance of me losing £5, so there's more to gain than lose.
Jeremiah June 29, 2018 at 22:29 ¶ #192278
Reply to Michael

Recall that event L is when you start with 2X and event K is when you start with X

Since we don't know which it is upon seeing the money we will consider this an uninformative prior and give each a fair 50% likelihood. Then our sample space is [K,L]

In the event of L our expected gain loss sample space is [-X, 0]

In the event of K our expected gain loss sample space is [X,0]

That is the same even if you go the 1/2 route.

Let's try running a simulation on that structure.


K <- c("X",0)
L <- c("-X",0)
q <- c(K,L)
w <- sample(q, 10000, replace = TRUE)
sum(w == "X")
sum(w == "-X")
sum(w == 0)


The Result are:

x: 2528
-x: 2510
0: 4962
```
Michael June 29, 2018 at 22:30 ¶ #192279
Quoting Jeremiah
In the event of L our expected gain loss sample space is [-X, 0]

In the event of K our expected gain loss sample space is [X,0]


Which is:

In the event of L our expected gain loss sample space is [-5, 0]

In the event of K our expected gain loss sample space is [10,0]

So there's more to gain by switching than there is to lose.
Jeremiah June 29, 2018 at 22:31 ¶ #192280
Reply to Michael

You are forgetting that X is a variable.
Michael June 29, 2018 at 22:31 ¶ #192281
Quoting Jeremiah
You are forgetting that X is a variable.


No I'm not, hence why I'm saying it's 5 in some situations and 10 in others.
Jeremiah June 29, 2018 at 22:32 ¶ #192282
Reply to Michael

X is an unknown, so you can't treat it as a known.
Jeremiah June 29, 2018 at 22:33 ¶ #192284
At any rate I think the probability of me going to get something to eat is very high at this time.
Michael June 29, 2018 at 22:35 ¶ #192285
Quoting Jeremiah
X is an unknown, so you can't treat it as a known.


I'm not treating it as known. I'm saying that there's more to gain than there is to lose. I don't need to know what X is to know that if I have £10 then by switching I am equally likely to gain £10 as to lose £5.
Michael June 29, 2018 at 22:49 ¶ #192288
Quoting Jeremiah
Let's try running a simulation on that structure.

K <- c("X",0)
L <- c("-X",0)
q <- c(K,L)
w <- sample(q, 10000, replace = TRUE)
sum(w == "X")
sum(w == "-X")
sum(w == 0)

The Result are:

x: 2528
-x: 2510
0: 4962
```


I don't know R, but from what I can gather that's just selecting an outcome at random and showing that the number of times you win is equal to the number of times you lose? That's not in question. What I'm saying is that the amount you win is greater than the amount you lose.

We've established that where X is gained, X = 10 and where X is lost, X = 5.

So the 2,528 gains amounts too £25,280 (the initial £10) + £25,280 (the gain) = £50,560 and the 2,510 losses amounts to £25,100 (the initial £10) - £12,550 (the loss) = £12,550.

So that's a total of £63,110 for switching compared to £49,620 for not switching.

And if we even it out to x: 2,500, -x: 2,500, 0: 5,000 we get £50,000 for not switching and £62,500 for switching. This is the same x1.25 figure that my result gave for switching.
noAxioms June 29, 2018 at 23:05 ¶ #192295
Quoting Michael
If we open the envelope and see £10 then we know that the other envelope contains either £5 or £20. By switching there's a 50% chance of losing £5 and a 50% chance of gaining £10. Switching seems like the better option.
Might as well just not even bother looking in the first envelope then, and pick the second one from the start. Looking at the contents seems not to affect this decision. This tells me it doesn't matter if you switch.

My solution is to switch only if the amount in the envelope is an odd number.
Michael June 29, 2018 at 23:06 ¶ #192296
Quoting noAxioms
My solution is to switch only if the amount in the envelope is an odd number.


Genius. :lol:
Jeremiah June 29, 2018 at 23:21 ¶ #192301
Quoting Michael
I don't know R, but from what I can gather that's just selecting an outcome at random and showing that the number of times you win is equal to the number of times you lose?.


That is because mine is set up correctly while yours is set up incorrectly. You are adding up sums of known numbers. Where mine is adding up an unknown, because X is an unknown.


Quoting Michael
We've established that where X is gained, X = 10 and where X is lost, X = 5.


You are letting your examples confuse you once more. What we have establish is that -X and X are equally likely to occur. If X = 5 then that is -5 or 5. If X = 10 then that is -10 or 10. If X = 15456783134.1346854654 then that is -15456783134.1346854654 or 15456783134.1346854654. That is what it means to be an unknown variable. What you are suggesting is that for each X there are two possible outcomes, and well that does not fit the definition of a function. You are not considering that L and K are independent events and that -X and X are conditional events.

|-X| = |X|, which means -X cannot equal -5 while at the same time X is equal to 10, as |-5| does not equal |10|. If X = 10 then -X=-10 and if X= 5 then -X=-5.

I really don't know many more different ways I can say this.
Michael June 29, 2018 at 23:33 ¶ #192307
Quoting Jeremiah
You are letting your examples confuse you once more. What we have establish is that -X and X are equally likely to occur. If X = 5 then that is -5 or 5. If X = 10 then that is -10 or 10. If X = 15456783134.1346854654 then that is -15456783134.1346854654 or 15456783134.1346854654. That is what it means to be an unknown variable. What you are suggesting is that for each X there are two possible outcomes, and well that does not fit the definition of a function. You are not considering that L and K are independent events and that -X and X are conditional events.


You explained the scenario yourself:

Quoting Jeremiah
Let's call case one L and case two K. Where L is the event you start with 2X and K is the event you start with X. These are two different events.

You open it up and see you have 10 bucks:

In the event of L if you switch then you gain -X, which in this case is a loss of 5 bucks. If you don't switch then you gain 0.

In the event of K if you switch then you gain +X, which is gain of 10. If you don't switch then you gain 0.


We play 5,000 games. 2,500 of those games are case L and 2,500 of those games are case K. Assuming we switch, the only possible outcome for case L is a loss of £5 and the only possible outcome for case K is a gain of £10. Our total earnings for these 5,000 games is £62,500. Whereas if we don't switch then our total earnings is £50,000. Switching is more profitable.
Baden June 29, 2018 at 23:34 ¶ #192308
Reply to Michael

Whether you benefit by switching or not is dependent on what envelope you just chose, which must be Envelope X or Envelope 2X where X is a given sum of money. So, switching can only ever take you from Envelope X to Envelope 2X (+X) or from Envelope 2X to X (-X).

Let X=10.

If you choose Envelope X then you get 10 and switching gains you ten. If you choose Envelope 2X then you get 20 and switching loses you 10.

The same applies for all X.
Michael June 29, 2018 at 23:37 ¶ #192310
Quoting Baden
Let X=10.

If you choose Envelope X then you get 10 and switching gains you ten. If you choose Envelope 2X then you get 20 and switching loses you 10.


Let the amount in my envelope = £10.

If I chose Envelope X then I get £10 and switching gains me £10. If I chose Envelope 2X then I get £10 and switching loses me £5.
Baden June 29, 2018 at 23:41 ¶ #192312
Reply to Michael

No. 20 and 5 are incompatible possibilities given you've already chosen an envelope. 20=4(5). There is no 4X.
Michael June 29, 2018 at 23:44 ¶ #192314
Quoting Baden
No 20 and 5 are incompatible possibilities given you've already chosen an envelope. 20=4(5). There is no 4X.


I still don't know what you mean by this.

I'll put it another way:

Let the amount in my envelope = £10.

If X = 10 then I have £10 and switching gains me £10. If X = 5 then I have £10 and switching loses me £5.
Baden June 29, 2018 at 23:47 ¶ #192316
Reply to Michael
I don't understand why you don't understand. There is no point in this scenario after an envelope is chosen where X( £5) and 4X(£20) are compatible possibilities. The second choice (to switch) is dependent on the first, which limits you to Envelope X or Envelope 2X.
Michael June 29, 2018 at 23:49 ¶ #192317
Quoting Baden
There is no point in this scenario after an envelope is chosen where X( £5) and 4X(£20) are compatible possibilities.


I don't understand why you're saying that X is 5. We don't know what X is. All we know is that there's £10 in my envelope. The other envelope either has £5 or has £20, depending on whether my £10 envelope is Envelope X or Envelope 2X.
Baden June 29, 2018 at 23:57 ¶ #192319
Reply to Michael

There can never be a possible spread from £5 to £20 given that you've chosen an envelope already. Given that you've already chosen and you've chosen only either X or 2X, switching can only take you from X to 2X(+X) or from 2X to X(-X). So no matter what X is you can only gain or lose that X by switching.
Baden June 29, 2018 at 23:59 ¶ #192321
@Michael I'll leave it for now as we're coming at it from different angles. I think you are treating the first and second event as independent and I am treating them as dependent (the second dependent on the first). Maybe someone else has a more formal way of putting that.
Michael June 30, 2018 at 00:00 ¶ #192322
Reply to Baden

If my £10 envelope is Envelope X then switching to Envelope 2X gains me £10.
If my £10 envelope is Envelope 2X then switching to Envelope X loses me £5.

Yes, it's true that in the first case it's a gain of X and in the second case it's a loss of X, but in the first case X is 10 and in the second case X is 5, so it's wrong to say that the gain and loss are equivalent.

There's more to gain than there is to lose by switching.
Baden June 30, 2018 at 00:16 ¶ #192324
Reply to Michael

Take any given pair of envelopes X+2X
Let X=10 (for example)
If you choose Envelope X you see £10 and switching to Envelope 2X gains you £10
If you choose Envelope 2X you see £20 and switching to Envelope X loses you £10.

Should you switch? As there is a 50% chance you have already chosen Envelope X and a 50% chance you have already chosen Envelope 2X, it doesn't matter.
Michael June 30, 2018 at 00:23 ¶ #192328
Reply to Baden We work with what we know, and what we know is that our chosen envelope has £10. Therefore we can't consider the possibility that X is 10 and that our chosen envelope is 2X. The only thing we can consider is:

If my £10 envelope is Envelope X then switching to Envelope 2X gains me £10 and if my £10 envelope is Envelope 2X then switching to Envelope X loses me £5.
Baden June 30, 2018 at 00:52 ¶ #192334
Reply to Michael

We know the chosen envelope has £10 in your scenario and we also know that one of the envelopes contained an amount X and one of the envelopes contained an amount 2X, and therefore we know we can only move from X to 2X or from 2X to X by switching. Therefore we know we have a 50% chance of gaining X by switching and a 50% chance of losing X by switching and that therefore there is no point in switching.

You're using X to refer to both the X in the scenario where switching gets you less and in the scenario where switching gets you more. But given any given amount you see in front of you after already choosing an envelope, those are not the same X.
Baden June 30, 2018 at 01:33 ¶ #192353
So, you have 10. But only one scenario applies to your choice, either the one where you lose by switching in which case X is five and 2X is 10, or you gain by switching in which X is 10 and 2X is 20. You can't be in both scenarios at the same time and X has a different value in both, so your calculation fails.
andrewk June 30, 2018 at 02:59 ¶ #192397
Quoting Jeremiah
What should you do?

It depends on my utility function U. Utility functions map one's wealth to levels of 'utility', ie satisfaction. They are generally assumed to be monotonically increasing and concave down.

The expected dollar gain from switching after observing the envelope contains $X is positive, as it is 0.5 (2X - X) + 0.5 (X/2 - X) = 0.25 X

However the expected gain in utility from switching is

(0.5 U(W + 2X) + 0.5 U(W + X/2)) - U(W + X)

where W is my wealth prior to receiving the envelope.

This may be positive or negative, depending on the slope and curvature of the utility function U in the interval between S+X/2 and W+2X. If the slope is high and curvature is strong, expected utility will be maximised by not switching, otherwise by switching.

I'd draw a diagram, only I'm no good at doing that on a web page. But if you draw a few diagrams yourself, hopefully you'll see what I mean.
Andrew M June 30, 2018 at 06:56 ¶ #192476
Quoting Jeremiah
What should you do?


The expected value of each envelope is $(X + 2X)/2 = $3X/2 = $1.5X. You should be indifferent between switching or not.

However consider this variation. If you choose an envelope, and then the other envelope is emptied and randomly filled with either half or double the amount of the envelope you chose, then the expected value of the other envelope is $(X/2 + X*2)/2 = $5X/4 = $1.25X. Since $1.25X > $X, you should switch.
Michael June 30, 2018 at 08:01 ¶ #192488
Quoting Baden
So, you have 10. But only one scenario applies to your choice, either the one where you lose by switching in which case X is five and 2X is 10, or you gain by switching in which X is 10 and 2X is 20. You can't be in both scenarios at the same time and X has a different value in both, so your calculation fails.


So if X is 5 then I lose £5 by switching and if X is 10 then I gain £10 by switching. Nowhere am I saying that it's both 5 and 10 at the same time, so I don't understand your objection.

I'm just saying that there's a 50% chance that I'm in situation 1 (X is 5) and a 50% chance that I'm in situation 2 (X is 10). Switching is effectively betting on a coin toss, but with a 2:1 payout (I lose £5 if I lose and win £10 if I win).
Michael June 30, 2018 at 09:06 ¶ #192493
Quoting Baden
We know the chosen envelope has £10 in your scenario and we also know that one of the envelopes contained an amount X and one of the envelopes contained an amount 2X, and therefore we know we can only move from X to 2X or from 2X to X by switching. Therefore we know we have a 50% chance of gaining X by switching and a 50% chance of losing X by switching and that therefore there is no point in switching.



The issue is that in using this variable X you're hiding the inequality. This is your argument above:

A1. I have £10.
A2. If I have 2X then I lose X by switching.
A3. If I have X then I win X by switching.
A4. There's a 50% chance of winning X and a 50% chance of losing X by switching.
A5. Therefore there's no benefit to switching.

Now replace the variable with the actual value:

B1. I have £10.
B2. If I have 2X then I lose £5 by switching.
B3. If I have X then I win £10 by switching.
B4. There's a 50% chance of winning £10 and a 50% chance of losing £5 by switching.
B5. Therefore there's a benefit to switching.

You're conflating different values of X when comparing the expected gain and loss. A5 is an invalid inference because it treats a win of X and a loss of X as symmetrical which is wrong because the X you win is greater than the X you lose.
andrewk June 30, 2018 at 11:07 ¶ #192537
Quoting Andrew M
The expected value of each envelope is $(X + 2X)/2 = $3X/2 = $1.5X. You should be indifferent between switching or not.

It looks like you're assuming the player's utility function is the identity function, which would be unusual and unrealistic. Even if we assume that, the quoted calculation doesn't take account of all the available information. There is new information, which is the known dollar value in the opened envelope. That changes the utility calculation.
Jeremiah June 30, 2018 at 15:38 ¶ #192572
Reply to Michael

You are saying if you switch then you have 50% chance for 1/2X and a 50% for 2X and your argument is centered around expected gain. Which you claim is in favor of switching.

Algebraically your expected value can be expressed as such:

1/2(x/2)+1/2(2x) = (5x)/4

Now let's try thinking about this when we know the contents of both envelopes and we are just flipping a fair coin to determine the envelope selection.

Let's say envelope A contains 5 bucks and envelope B contains 10 bucks.

Under your claim if we get A initially then the other envelope either has 2.50$ or 10$.

Under your claim if we get B initially then the other envelope has 5$ or 20$.

See how that can't work, as 2.50$ and 20$ are not even possible outcomes.











Jeremiah June 30, 2018 at 15:48 ¶ #192574
What we have to do is average the expected returns between the two cases.

1/2(5) + 1/2(10) = 7.50 the mid point between 5 and 10. Therefore there is no difference in switching.
Michael June 30, 2018 at 15:59 ¶ #192577
Reply to Jeremiah Knowing more information changes the probabilities.

If you toss a coin and I see that it landed heads then I will say that the probability that it landed heads is 100%.
If you toss a coin and I don't see the result then I will say that the probability that it landed heads is 50%.

So your example of knowing the contents of both envelopes isn't at all analogous the example of only knowing what's in the one we have.
Jeremiah June 30, 2018 at 16:01 ¶ #192578
Reply to Michael

The algebra already showed that you are wrong in more ways than one and so does a real world example. You are not averaging your expected returns over the two possible cases.
Michael June 30, 2018 at 16:09 ¶ #192581
Quoting Jeremiah
You are not averaging your expected returns over the two possible cases.


That's exactly what I did here and here. If in each game we see that we have £10 we win more by switching than by not switching.
Jeremiah June 30, 2018 at 16:11 ¶ #192583
Reply to Michael

Your math and code is wrong, and it has been shown as wrong several time. Pointing to your incorrect math does not prove you right.
Jeremiah June 30, 2018 at 16:14 ¶ #192584
One can only explain things so many different ways. I could keep rephrasing the same thing over and over, but as much fun as that it is, it gets tiring.
Deleted User June 30, 2018 at 16:35 ¶ #192590
This user has been deleted and all their posts removed.
BlueBanana June 30, 2018 at 17:35 ¶ #192602
The intuitive solution is that the bigger the amount in your envelope is, the more likely it is to be the one with 2X.
unenlightened June 30, 2018 at 20:40 ¶ #192618
Quoting Michael
There's more to gain than there is to lose by switching.


Quoting BlueBanana
The intuitive solution is that the bigger the amount in your envelope is, the more likely it is to be the one with 2X.


So the paradox arises because in practice there is a range of X. The lower bound is the smallest denomination of currency, and the upper bound is something less than half all the money in the world.

In practice the bounds are tighter, because the psychology department, or the entertainment industry has a budget, and also needs to make the bet a bit interesting. If the envelope contains less than £5, who really gives a fuck. If it is happening on a regular basis, the upper bound is- hundreds, maybe thousands, depending. So intuition has accessed extra information that mathematics is not privy to.

If there were no upper limit, it would always be a good bet to switch, but there must be a limit.

Imagine a slightly different game. You get an envelope with X, and then you can choose another envelope from 2, with 'double it' and 'halve it'. Then it is clear that whatever X is, it's a good bet to take a second envelope. No paradox.
Andrew M June 30, 2018 at 21:42 ¶ #192633
Quoting andrewk
It looks like you're assuming the player's utility function is the identity function, which would be unusual and unrealistic. Even if we assume that, the quoted calculation doesn't take account of all the available information. There is new information, which is the known dollar value in the opened envelope. That changes the utility calculation.


Yes it does. But considering myself, my utility function would be roughly linear for the amounts being talked about here (around $20). Which is to say, I would accept an offer of $1 to either switch or keep since my expected gain from doing so would be $1.
Andrew M June 30, 2018 at 22:24 ¶ #192636
Quoting Michael
That's exactly what I did here and here. If in each game we see that we have £10 we win more by switching than by not switching.


As Jeremiah points out, your code doesn't reflect the problem in the OP. Before an envelope is picked, the expected value of each envelope is the same. That doesn't change when you choose an envelope and find it has $10 in it. The expected value of the other envelope is also $10 and so the expected gain from switching is $0.

To see this, suppose you do the experiment 100 times where you always switch. 50 times (on average) you choose the $2X envelope and switch to $1X. So you earn $50X. 50 times you choose the $X envelope and switch to $2X. So you earn $100X. In total, you earn $150X.

Now you do the same experiment 100 times where you never switch. 50 times you choose the $2X envelope and don't switch. So you earn $100X. 50 times you choose the $1X envelope and don't switch. So you earn $50X. In total, you earn $150X.

So the expected value in both sets of experiments is the same.

The experiment you're modeling with your code is where the second envelope is emptied and randomly filled with either half or twice the amount of the first chosen envelope amount. In which case you should switch.
Michael June 30, 2018 at 22:45 ¶ #192643
Quoting Andrew M
To see this, suppose you do the experiment 100 times where you always switch. 50 times (on average) you choose the $2X envelope and switch to $1X. So you earn $50X. 50 times you choose the $X envelope and switch to $2X. So you earn $100X. In total, you earn $150X.

Now you do the same experiment 100 times where you never switch. 50 times you choose the $2X envelope and don't switch. So you earn $100X. 50 times you choose the $1X envelope and don't switch. So you earn $50X. In total, you earn $150X.


Like Baden you're conflating different values of X.

Given a starting envelope of $10, if 50 times I have the 2X envelope and don't switch then I earn $500 and if 50 times I have the X envelope and don't switch then I earn $500. In total I earn $1,000.

Given a starting envelope of $10, if 50 times I have the 2X envelope and switch then I earn $250 and if 50 times I have the X envelope and switch then I earn £1,000. In total I earn $1,250.

In your example you're adding 50X to 100X and getting 150X despite the fact that the X in 50X has a different value to the X in 100X, and so such an addition is wrong (or at least misleading as it generates a third value of X).
Michael June 30, 2018 at 22:57 ¶ #192645
To make this clearer:

50 times (on average) you choose the $2X envelope and switch to $1X. So you earn $50X.


Here, X = 5.

50 times you choose the $X envelope and switch to $2X. So you earn $100X.


Here, X = 10.

In total, you earn $150X.


The only way to make sense of this, given that you've added 50X where X = 5 to 100X where X = 10 is to say that X = 8.333...

50 times you choose the $2X envelope and don't switch. So you earn $100X.


Here, X = 5.

50 times you choose the $1X envelope and don't switch. So you earn $50X.


Here, X = 10.

In total, you earn $150X.


The only way to make sense of this, given that you've added 100X where X = 5 to 50X where X = 10 is to say that X = 6.666...

So, again, the amount you win is 1.25x greater when you switch, which is what my program showed.
andrewk July 01, 2018 at 00:03 ¶ #192654
Quoting Andrew M
As Jeremiah points out, your code doesn't reflect the problem in the OP. Before an envelope is picked, the expected value of each envelope is the same.

It's necessary to distinguish between two cases, which is whether we know the distribution of X, ie the distribution for the lower of the two values.

If we don't know the distribution then we don't even know whether there is an expected value of the amount in either envelope. For instance, if the amount put in the envelope is a random draw from the Cauchy distribution, there is no expected value (the relevant integral for the Cauchy distribution does not converge).

If we do know the distribution, and it has an expected value, then it is correct that our expected value is the same for both envelopes. But that changes when we see the amount in the envelope, because that tells us where we are in the distribution. Say we know the distribution of the smaller amount X is uniform on [1,2]. Then if the amount we see is in [1,2] we know it is the smaller amount and we should switch. On the other hand if the amount is in [2,4] we know it is the larger amount and should not switch.

In the absence of knowing the distribution of X, any calculations based on expected values prior to opening the envelope are meaningless and wrong. Since the claimed paradox relies on such calculations, it dissolves.
Andrew M July 01, 2018 at 07:59 ¶ #192714
Quoting Michael
Like Baden you're conflating different values of X.


No, but I can make the same argument using concrete amounts (see below).

Quoting Michael
Given a starting envelope of $10


You can't assume you have a starting envelope of, for example, $10, and that the other envelope has either $5 or $20. That doesn't reflect the problem as specified in the OP.

The OP instead assumes that you have two envelopes of, for example, $10 and $20, and that you randomly choose one of them. So half the time, the starting envelope would have $10 and half the time the starting envelope would have $20.

Over 100 runs with a switching strategy, you would switch from the $20 to the $10 envelope 50 times (earning $500) and switch from the $10 to the $20 envelope 50 times (earning $1000) for a total of $1500.

Over 100 runs with a keeping strategy, you would keep the $20 envelope 50 times (earning $1000) and keep the $10 envelope 50 times (earning $500) for a total of $1500.

So you earn $1500 (on average) on either strategy.
Andrew M July 01, 2018 at 08:02 ¶ #192718
Quoting andrewk
In the absence of knowing the distribution of X, any calculations based on expected values prior to opening the envelope are meaningless and wrong.


The Wikipedia entry uses the expected value being the same for both envelopes as their simple resolution. Do they have that wrong, in your view?
andrewk July 01, 2018 at 08:34 ¶ #192726
Reply to Andrew M Interesting. The problem is different. Unlike in the OP, in the Wiki case, the envelope has not been opened before the option to swap. So the player has no new information in the wiki case. I think their analysis in the Simple Case is wrong, because it assumes the existence of an expected value that may not exist, but I think the conclusion that there is no reason to switch may in spite of that error be correct in that case, but not in this one.
Michael July 01, 2018 at 09:35 ¶ #192737
Quoting Andrew M
You can't assume you have a starting envelope of, for example, $10, and that the other envelope has either $5 or $20.


Why not? I've opened the envelope and seen that I have $10. That's in the rules as specified in the OP. And knowing the rules of the game I know there's a 50% chance that the other envelope contains $5 and a 50% chance that the other envelope contains $20.

Quoting Andrew M
The OP instead assumes that you have two envelopes of, for example, $10 and $20, and that you randomly choose one of them. So half the time, the starting envelope would have $10 and half the time the starting envelope would have $20.

Over 100 runs with a switching strategy, you would switch from the $20 to the $10 envelope 50 times (earning $500) and switch from the $10 to the $20 envelope 50 times (earning $1000) for a total of $1500.

Over 100 runs with a keeping strategy, you would keep the $20 envelope 50 times (earning $1000) and keep the $10 envelope 50 times (earning $500) for a total of $1500.

So you earn $1500 (on average) on either strategy.


So in your example you've considered repeating the game using the same value envelopes and say that half the time $10 is picked and half the time $20 is picked whereas in my example I've considered repeating the game using the same starting envelope and say that half the time the other envelope contains $5 and half the time the other envelope contains $20.

Is there some rule of statistics that says that one or the other is the proper way to assess the best strategy for a single instance of the game (where you know that there's $10 in your envelope)?

I would have thought that if we want to know the best strategy given the information we have then the repeated games we consider require us to have that same information, and the variations are in the possible unknowns – which is what my example does.
andrewk July 01, 2018 at 11:49 ¶ #192746
It occurs to me that, on my understanding of the two main interpretations of probability, and assuming no knowledge of the prior distribution of the lower amount, a Bayesian interpretation can take the approach that, on seeing $10 in the envelope, the expected winnings from switching envelopes is $2.50, but a Frequentist interpretation does not provide any approach at all - it denies the correctness of a probabilistic calculation of the winnings: the winnings are either $10 or -$5, and whichever one it is, is certain - no partial probabilities.

Sounds like a good reason to be a Bayesian.
Jeremiah July 01, 2018 at 12:09 ¶ #192748
Quoting Michael
So your example of knowing the contents of both envelopes isn't at all analogous the example of only knowing what's in the one we have.


What you are overlooking with the real world example is that my algebraic model reflected it exactly and all from the same information you confined your model to. The real world example showed that my algebra and probability model correctly predicted what would be actual. However, your approach created a model that does not reflect reality at all. The goal of probability is to accurately model reality. We test our probability models by either simulating a real situation or actually using them. In this test my model passed while your model failed.







Jeremiah July 01, 2018 at 12:15 ¶ #192750
Reply to andrewk

This has nothing to do with Classical vs. Bayesian. This is about treating X as an unknown, even after you see the contents of the first envelope. If you trust the algebra it leads you to a model that correctly reflects a real world case. The fallacy is an algebraic one.

Besides you shouldn't be a Bayesian or Frequentist, you should do both.
Jeremiah July 01, 2018 at 12:21 ¶ #192753
Reply to andrewk

I picked this version to generate more discussion. I think this version of the problem forces more conflict of ideas, which in turn generates more discussion.
Jeremiah July 01, 2018 at 12:33 ¶ #192757
Quoting andrewk
In the absence of knowing the distribution of X, any calculations based on expected values prior to opening the envelope are meaningless and wrong. Since the claimed paradox relies on such calculations, it dissolves.


Not true.

Even after seeing the first envelope you still don't know which case you are in, you could have 2X or X, you also don't know what case the other envelope is in, it could be 2X or X. This is also ture before you take your first peak. The fact is opening the envelope does not give us the vaule of X. So if you switch you switch to the same unknown. The errors is in treating X as a known after you open the the first envelope.

In both cases our expected value then is:

1/2(X) + 1/2(2X) = 1/2X+X.

Which is the mid point between X and 2X.

Jeremiah July 01, 2018 at 12:41 ¶ #192758
If you follow the algebra it leads you to a solution which reflects a real world situation and when it comes to modeling probability this should be the goal.
Srap Tasmaner July 01, 2018 at 14:19 ¶ #192781
Reply to Michael
Is there a sort of de dicto/de re problem here in how we think about the probabilities? That is, is there a difference between these?

(1) In repeated trials, about half the time participants pick the larger envelope.
(2) In repeated trials, about half the time the envelope participants pick is the larger.

Suppose the experiment in fact only has envelopes containing $2 and $4. Participants will pick each about half the time, averaging a take of $3.

Your approach is to reason from (2) once the envelope is open. Thus, seeing $2, you reason that half the time this value is the smaller and half the time it is the larger. But this is just false. About half the time participants pick $2 and half the time they pick $4; there is no case in which $2 is the larger value.

You're right that seeing $2 tells you the possibilities are {1,2} and {2,4}. But on what basis would you conclude that about half the time a participant sees $2 they are in {1,2}, and half the time they are in {2,4}? That is the step that needs to be justified. I think you're imagining a table something like this:

{1,2} {2,4}
Big 1/4 1/4
Small 1/4 1/4

and those are your chances of being in each situation. But there are not two random events or choices here; there is only one. You are re-using the choice between larger and smaller as the relative frequency of {1,2} and {2,4}. For all you know, {1,2} could be a hundred times more likely than {2,4}. In my version here, {1,2} has a chance of 0, and {2,4} a chance of 1.
Michael July 01, 2018 at 14:38 ¶ #192783
Quoting Srap Tasmaner
But there are not two random events or choices here; there is only one. You are re-using the choice between larger and smaller as the relative frequency of {1,2} and {2,4}. For all you know, {1,2} could be a hundred times more likely than {2,4}. In my version here, {1,2} has a chance of 0, and {2,4} a chance of 1.


But what probabilities does the person in the experiment give to {1, 2} and {2, 4}, given his envelope of $2? He can give them a probability of 0 and 1 respectively if he knows that one envelope contains $2 and the other envelope contains $4, but he doesn't know this. The only information he has is that 1) one envelope contains twice as much as the other and 2) his envelope contains $2. Surely in lieu of any evidence to suggest that one of {1, 2} and {2, 4} is more likely he should consider their probabilities equal?

Or does it make a difference if he knows beforehand that the experimenter has flipped a fair coin to determine which of {1, 2} and {2, 4} is to be used?
Srap Tasmaner July 01, 2018 at 15:48 ¶ #192790
Quoting Michael
Or does it make a difference if he knows beforehand that the experimenter has flipped a fair coin to determine which of {1, 2} and {2, 4} is to be used?


If you know this is the procedure, then you know the distribution. You don't, so you don't.

Quoting Michael
Surely in lieu of any evidence to suggest that one of {1, 2} and {2, 4} is more likely he should consider their probabilities equal?


I wish I could answer this question. Does the principle of indifference justify the use of uninformative priors like this? I have a hunch that someone really good at this sort of thing could show why even the uninformative prior does not lead directly to your conclusion. I am not that person.

All I can say is that in this case it leads to a mistaken belief that switching is better.
Jeremiah July 01, 2018 at 16:25 ¶ #192796
Quoting Srap Tasmaner
could show why even the uninformative prior does not lead directly to your conclusion.


I already did. Recall that my initial algebraic model was based on all the same information as Michael and I used an uninformative prior, and my approach leads to an expected value of 1/2(X) + 1/2(2X) = 1/2X+X. My initial approach modeled the real world example accurately, all based on the same information and situation as Michael.

Quoting Jeremiah
You could have X or 2X. If you have X and you switch then you get 2X but lose X so you gain X; so you get a +1 X. However, if you have 2X and switch then you gain X and lose 2X; so you get a -1 X.



Quoting Jeremiah
Recall that event L is when you start with 2X and event K is when you start with X

Since we don't know which it is upon seeing the money we will consider this an uninformative prior and give each a fair 50% likelihood. Then our sample space is [K,L]

In the event of L our expected gain loss sample space is [-X, 0]

In the event of K our expected gain loss sample space is [X,0]

That is the same even if you go the 1/2 route.

Let's try running a simulation on that structure.

K <- c("X",0)
L <- c("-X",0)
q <- c(K,L)
w <- sample(q, 10000, replace = TRUE)
sum(w == "X")
sum(w == "-X")
sum(w == 0)

The Result are:

x: 2528
-x: 2510
0: 4962
```





Jeremiah July 01, 2018 at 16:32 ¶ #192798
The tick to this problem is trusting the algebra over your eyes, which makes it less than intuitive. In this case the new information you receive can actually mislead you, but if you follow the math it leads you down the right path.
Srap Tasmaner July 01, 2018 at 17:13 ¶ #192808
Quoting Jeremiah
I already did.


So you did.

But if we try to model this from the participant's point of view, we don't use X at all; we use Y. Then the expected gain loss sample spaces are [-Y/2, 0] and [2Y, 0], aren't they? That's @Michael's problem.

I'm tempted to think @andrewk's point is relevant here: how do we know Y/2 and 2Y are even in the distribution? We know that Y is, and that Y is either X or 2X, but we have no way of knowing which, and we don't know anything about the distribution of X.

I agree that the algebra works and is correct. Is the objection to Michael's approach not the assignment of the prior but simply that he is using sample spaces he cannot justify using?
Srap Tasmaner July 01, 2018 at 18:08 ¶ #192815
The other way to put this is that after learning the envelope has Y in it, we know that either Y/2 or 2Y are in the distribution, but we cannot know which, and this is no different from learning that we have either X or 2X.
Baden July 01, 2018 at 18:16 ¶ #192820
Reply to Srap Tasmaner

I think the objection is that his approach is an error of reason. It's specified that the contents of the envelopes are X and 2X. So whatever value you see has to be either X and the smaller amount (in which case switching only gives you a larger amount of X+X)) or 2X and the larger amount (in which case switching only gives you the smaller amount of 2X-X). @Micheal tries to use maths to break those logical connections creating erroneous possibilities that lead to imaginary gains.
Srap Tasmaner July 01, 2018 at 18:29 ¶ #192825
Quoting Baden
erroneous possibilities that lead to imaginary gains


Ah, philosophy, your generosity is but an illusion!

So the way to do cases here goes:
If Y = X, then ...
If Y = 2X, then ...
and it's okay to treat each of these as having a 1/2 chance. Then we get @Jeremiah's simple algebra.
Jeremiah July 01, 2018 at 18:32 ¶ #192826
Quoting Srap Tasmaner
But if we try to model this from the participant's point of view


Up until I introduced the real world example, we both were looking at as if we were participates. Michael and I were looking at the same problem in the same context based on the same information.

Quoting Srap Tasmaner
we use Y. Then the expected gain loss sample spaces are [-Y/2, 0] and [2Y, 0], aren't they?


He was looking at it as 2X or X/2. Using Y does not change anything at all as there are still two possible values for Y and that is Y=X or Y=2X. You don't change anything by using Y, the algebra would still come out the same way. By the definition of a function it has to and if it doesn't then you did something wrong.

Quoting Srap Tasmaner
I'm tempted to think andrewk's point is relevant here:


It is binary, either it is X or 2X. So if one really needs to use a distribution as a sampling model then use a Bernoulli distribution, with alpha equal to one and beta equal to one as your priors. That is if you want to use a statistical nuke as a fly swatter. It is over the top and completely uncalled for.

Quoting Srap Tasmaner
Is the objection to Michael's approach not the assignment of the prior but simply that he is using sample spaces he cannot justify using?


Michael's error is not treating X as an unknown variable in accordance to the definition of a function. You have to trust the algebra and established proofs/definitions more than your intuition.

When he saw the 10 bucks he forgot to consider the uncertainty of his starting position and rewrote the values of Y to Y=X and Y=X/2. Then he creates two possible cases on known values of X. However the 10 bucks does not give us the value of X, as we still don't know if our starting point is 2X or X.
Baden July 01, 2018 at 18:33 ¶ #192827
Reply to Srap Tasmaner

I'm sure if I knew more about the details of the maths, I'd be able to see enough subtleties to allow me to be confused about this. But I'll leave it to the experts, of which I am definitely not one, and just remain confused about the confusion. :D
Srap Tasmaner July 01, 2018 at 18:39 ¶ #192831
Reply to Jeremiah
Thanks for spelling it all out. I think I've got it now.
Jeremiah July 01, 2018 at 19:11 ¶ #192854
It is an interesting problem nonetheless.

Let me see if I can sum it up more simply.

You have two envelopes, A and B.

There are two possible amounts for the contents of the two envelopes either X or 2X. You don't know which is which.

We'll call amount X case R, and and amount 2X case S.

You are handed envelope A.

Before you open it, you know that A could be case R or it could be case S. You have no clue which it is, so as an uninformative prior you give each case a 50% likelihood.

Now for the tricky part, you open envelope A and see it has 10 bucks in it.

Intuitively this seems like new information which would call for you to update your prior; however, it still does not tell you if are you in case R or case S. You don't know if that is 10=X or 10=2X. So in truth you can't really update your prior, as your prior was based on the uncertainty of being in case R or case S.

So your prior stands.

You consider swapping. You look at envelope B and realize it could be in case R or case S. You don't know which, so just as before you give it an uninformative prior and you give each case a 50% likelihood.

Now you could swap, but really probabilistically it changes nothing as your initial uncertainty would still stand. You would just trade the uncertainty of A for the uncertainty of B which is the same uncertainty. And the math? Well the math is indifferent to all options. So the decision to swap really comes down to if you feel lucky or not.



andrewk July 01, 2018 at 22:22 ¶ #192913
Quoting Jeremiah
Not true.

You said this in reply to my pointing out that arguments based on expected values prior to opening an envelope are wrong because we don't even know if there is an expected value. To rebut that, you need to show that there is an expected value, eg that we can be confident the lower amount X is not drawn from a Cauchy distribution.

Yet in your answer you have not addressed this at all.

What exactly is it then, that you think is Not True?
andrewk July 01, 2018 at 22:24 ¶ #192914
Quoting Jeremiah
I picked this version to generate more discussion. I think this version of the problem forces more conflict of ideas, which in turn generates more discussion.

It was a good choice. In the version in wikipedia it is easy, and uncontroversial, to conclude that there is no reason to switch. Not so in this case.
andrewk July 01, 2018 at 22:47 ¶ #192919
Quoting Jeremiah
There are two possible amounts for the contents of the two envelopes either X or 2X. You don't know which is which

This is not well-defined. It needs re-stating to make it unambiguous. Here are some options.

(1) A number X is drawn from a distribution f. A second number N is drawn from the Bernoulli distribution with parameter 0.5 (think of a coin flip). If N=1 (2) the amount X is placed in envelope 1 (2) and 2X is placed in envelope 2 (1). None of f, N or X are known to the player.

Note that this includes as a special case the setup where X is a fixed number known to the game operators, but not to the player. In that case the distribution f is just the uniform distribution on interval [X,X].

(2) Same as (1) but the player knows f.

In case 1, the player needs to assume a prior distribution as her guess of f. From then on, the calculation is the same, and it will use the known (case 2) or assumed (case 1) distribution f. The answer of whether expected winnings are increased by switching will depend on the slope and curvature of the PDF of f at the value that is observed when the envelope is opened.

From what I can see by attempts above, the assumption has been made implicitly that f is a uniform continuous distribution on the interval from 0 to some very high number such as the total of all banknotes in the world. That means the slope and curvature of the PDF at the value observed is zero.

Note the distribution must be continuous, which means that rather than banknotes, there must be an IOU specifying a real number that will be paid. If it was discrete, which is necessary if the envelope contains banknotes, then if the value was an odd multiple of the smallest currency unit, we'd know we have the smaller-valued envelope.

I suspect that even with that sparse, uniform distribution assumption, one might be able to make some inference. For instance, if the amount seen is very small, I suspect the Bayesian probability that it is the lower of the two amounts may be more than 0.5. But I've not thought about that much and it could be wrong.
Jeremiah July 01, 2018 at 23:29 ¶ #192927
Reply to andrewk Reply to andrewk

No one said a probability density curve was used to select X. And it won't matter anyway, as X is a real positive value, 2X will always be greater than X, the midpoint will always be 1/2X+X, and your possible outcomes will always be either 2X or X. This has nothing at all to do with distributions. Also the expected value being calculated is not of the density curve, it is the expected value of your take from the contents of the envelopes.

Statistics is simply not designed for a problem like this; it is better to just use basic mathematics. Statistics is for analyzing data.
andrewk July 02, 2018 at 00:38 ¶ #192954
Quoting Jeremiah
This has nothing at all to do with distributions.

That is not consistent with your use of the term 'expected value' in the following:
Quoting Jeremiah
In both cases our expected value then is:

1/2(X) + 1/2(2X) = 1/2X+X.

Which is the mid point between X and 2X.

'Expected value' only has meaning in the context of a probability distribution.
Jeremiah July 02, 2018 at 01:18 ¶ #192974
Reply to andrewk

Well technically this is a probability distribution: 1/2(X) + 1/2(2X). 50% is distributed to X and 50% is distributed to 2X.

But what you are talking about is a probability density curve, which is also a probability distribution, but one we would use in estimating parameters of a population from sample data. Typically we shorten the reference by just calling them distributions, but yes you are right, they are all technically distributions. However, your uses of probability density curves is still misplaced.
andrewk July 02, 2018 at 01:54 ¶ #192986
Reply to Jeremiah
Well technically this is a probability distribution: 1/2(X) + 1/2(2X). 50% is distributed to X and 50% is distributed to 2X.

That distribution is (1) unknown, as X is unknown and (2) not appropriate for estimating expected gains from switching, since it does not use all the available information after the envelope has been opened. The expected gains from switching, in the absence of any knowledge of how X was selected, is as @Michael calculated it earlier. But the question in the OP does not explicitly ask for expected gains from switching. It just asks 'should you switch?'. What is supposed to be the metric used to determine whether to switch?
Jeremiah July 02, 2018 at 02:39 ¶ #193006
Quoting andrewk
That distribution is (1) unknown,


It is not unknown at all, as I just laid it out for you, and as I already pointed out 1/2X+X reflected the expected gains from the real world example.

I have come to the conclusion that you just spit out jargon but you really have no clue what you are talking about. I actually came to that conclusion several threads ago. I don't think you understand the concept of a probability distribution and, in relation to statistics, I don't think you know what those density curves are for.

andrewk July 02, 2018 at 02:44 ¶ #193008
Quoting Michael
[Jeremiah's] reasoning is:

I have £10. If X is 5 then I lose £X by switching. If X is 10 then I gain £X by switching.

So it's either -£X or +£X. This is symmetrical.

The conclusion of symmetry is incorrect, because X is £5 in the first case and £10 in the second case. So we can't say that there's no difference because we lose X in one case and gain X in the other.
That would be like saying that if I have two £1 coins in my pocket and a big hole in the pocket it makes no difference whether I take one of the coins out and put it in another, non-holy pocket, because in both cases I lose everything in the holy pocket.

Doing this approach correctly, we use conditional probabilities to calculate the gain G from switching as follows:

E[G] = 0.5 * E[G | X= 5] + 0.5 * E[G | X= 10] ] . . . . . . . . . . . (0)

= 0.5 * E[-X | X= 5] + 0.5 * E[+X | X= 10] . . . . . . . . . . . (1)
= 0.5 * E[-5 | X= 5] + 0.5 * E[+10 | X= 10] . . . . . . . . . . . (2)
= 0.5 * (-5) + 0.5 * (+10) . . . . . . . . . . . (3)
= £2.50 . . . . . . . . . . . . (4)

So this approach, when done correctly, reaches the same conclusion that you did - that the expected winnings are increased by switching.
andrewk July 02, 2018 at 02:46 ¶ #193011
Quoting Jeremiah
I don't think you understand the concept of a probability distribution and, in relation to statistics, I don't think you know what those density curves are for

You've found me out. Please don't tell my employers that, or I'll lose my job.
Jeremiah July 02, 2018 at 02:47 ¶ #193012
Reply to andrewk

Not buying it, as you have displayed a large lack of comprehension here.
Srap Tasmaner July 02, 2018 at 03:23 ¶ #193025
Reply to andrewk
This whole approach is wrong though, isn't it? You know that you had a 1/2 chance of picking the envelope with the larger amount. That's just not the same as the amount in the envelope, which you will know once you open it, having a 1/2 chance of being the larger amount.
Snakes Alive July 02, 2018 at 05:59 ¶ #193041
This is a fun puzzle – I took a crack at it.

Let X be the amount as in the statement of the puzzle. Let Y be the amount revealed in the first envelope.

There are two possible states in which one can be after the revelation: either Y = X (you have pulled the lesser envelope, and the other has twice as much), or Y = 2X (you have pulled the greater envelope, and the other has half as much).

There are also two actions: stay, and switch.

We can then construct the average expected winnings from each move, based on each of the two states, in a 2 x 2 table:

User image

Each of the four cells represents an outcome of the move made based on the corresponding state (states on the horizontal, moves on the vertical). In each case, the value is expressed in terms of both X and Y.

Assuming that there is a 50% chance that one is in either of the two states, we can get the average expected winnings for each move by halving the value given by that move in each state, then adding these two together.

What's interesting is that the results look different depending on whether you express the average result in terms of X or Y.

For Y:

Switch: .5(2Y) + .5(.5Y) = Y + .25Y
= 1.25Y

Stay: .5 Y + .5Y
= Y

Thus, expressed in terms of Y, the greater average output is had by switching, since 1.25Y > Y, regardless of the value of Y.

For X:

Switch: .5(2X) + .5X = X + .5X
= 1.5X

Stay: .5X + .5(2X) = .5X + X
= 1.5X

Thus, expressed in terms of X, both moves have the same average output.

––––

So what's going on? How can the output be equal, but not equal, for the two actions?

It turns out there is an illusion in the way the problem was set up with respect to Y: there is no single value of a variable Y that can be defined independently of X, and then placed next to it in proportion (as either equal to it, or double it). Where Y is the number you drew in the first envelope, such a variable is already defined in terms of X: it is only possible to draw X, or 2X. The illusion results from thinking of 'the value of what I drew' as some distinct variable Y, when this is not the case. This in turn leads to the illusion that one can calculate the average expected return based on this new value, 'what I drew,' and conclude that switching allows a better return on 'what one drew.'

But what you drew is simply either X or 2X in the first place. There are thus two possible situations: either you drew X, or you drew 2X. And there are two possible moves: switch, or stay. Now let's draw the real table, defined this time in terms of the only variable there is, X:

User image

This table simply eliminates the illusory Y (not a well-defined value independent of X to begin with), and we see that as before, switching has no effect on average expected output.

––––

The take-away message is that there is no such thing as a value of 1.25Y, averaged across the two possible situations, because there is no such single value Y that is the same across said situations, since you don't know whether you're drawn the greater or lesser envelope. X, by contrast, is a value we can refer to coherently across both situations, and cast in these terms, it becomes obvious that switching is ineffectual. The illusion comes in thinking that the de dicto description 'what I drew' is equivalent de re to some single numerical value across possible situations, and it is not.
andrewk July 02, 2018 at 06:17 ¶ #193043
Reply to Srap Tasmaner Are you saying that you have reservations about my corrected version set out in that post? It is a fairly straightforward calculation based on conditional expectations, for the two possibilities. Is there a particular part of it that concerns you?
Michael July 02, 2018 at 06:29 ¶ #193046
Quoting andrewk
The conclusion of symmetry is incorrect, because X is £5 in the first case and £10 in the second case.


Were you just using my post as a launching pad or were you actually addressing me? Because the rest of my post said exactly this.
Andrew M July 02, 2018 at 09:06 ¶ #193069
Quoting andrewk
Interesting. The problem is different. Unlike in the OP, in the Wiki case, the envelope has not been opened before the option to swap. So the player has no new information in the wiki case. I think their analysis in the Simple Case is wrong, because it assumes the existence of an expected value that may not exist, but I think the conclusion that there is no reason to switch may in spite of that error be correct in that case, but not in this one.


Before choosing, there is no reason to prefer one envelope to the other. On choosing an envelope and learning the amount in it, there is still no reason to prefer one envelope to the other. So there is no reason to switch.

However if on opening the first envelope, the second envelope were then emptied and randomly filled with either half or twice the amount of the first envelope then the expected value of the second envelope would be (X/2 + X*2)/2 = 1.25X. So the player should switch.

Operationally, they are two different scenarios (requiring different strategies).
Andrew M July 02, 2018 at 09:35 ¶ #193077
Quoting Michael
Why not? I've opened the envelope and seen that I have $10. That's in the rules as specified in the OP. And knowing the rules of the game I know there's a 50% chance that the other envelope contains $5 and a 50% chance that the other envelope contains $20.


The problem is that you use the $10 starting amount to generate the random half ($5) or double ($20) amount for the second envelope. That is equivalent to emptying the second envelope and refilling it with half or double the amount of the first chosen envelope. Which doesn't reflect the rules in the OP.

Quoting Michael
Is there some rule of statistics that says that one or the other is the proper way to assess the best strategy for a single instance of the game (where you know that there's $10 in your envelope)?


It's that the switching strategy gains nothing if the starting envelope was randomly chosen and the amount of the second envelope remains unchanged. Whereas switching would be correct if the second envelope amount was randomly decided on the basis of the first chosen envelope amount.

Quoting Michael
I would have thought that if we want to know the best strategy given the information we have then the repeated games we consider require us to have that same information, and the variations are in the possible unknowns – which is what my example does.


The problem is making the randomizing element dependent on the first chosen envelope amount instead of simply as the choice of the envelope.
Michael July 02, 2018 at 10:18 ¶ #193081
Quoting Andrew M
The problem is making the randomizing element dependent on the first chosen envelope amount instead of simply as the choice of the envelope.


I'm just doing this:

1. We pick an envelope at random
2. There's a 50% chance that my envelope is the X envelope and a 50% chance that my envelope is the 2X envelope.
3. I open my envelope and see £10
4. From 2 and 3, there's a 50% chance that my £10 envelope is the X envelope and a 50% chance that my £10 envelope is the 2X envelope.
5. From 4, there's a 50% chance that the other envelope contains £20 and a 50% chance that the other envelope contains £5.

We seem to agree on 1-3, but you disagree with 4 and/or 5?
andrewk July 02, 2018 at 10:18 ¶ #193082
Quoting Andrew M
On choosing an envelope and learning the amount in it, there is still no reason to prefer one envelope to the other. So there is no reason to switch.

That claim is not consistent with the following formal calculations from my earlier post:
Quoting andrewk
we use conditional probabilities to calculate the expected value of the gain G from switching [after seeing 10 pounds in the first envelope] as follows:

E[G] = 0.5 * E[G | X= 5] + 0.5 * E[G | X= 10] ] . . . . . . . . . . . (0)

= 0.5 * E[-X | X= 5] + 0.5 * E[+X | X= 10] . . . . . . . . . . . (1)
= 0.5 * E[-5 | X= 5] + 0.5 * E[+10 | X= 10] . . . . . . . . . . . (2)
= 0.5 * (-5) + 0.5 * (+10) . . . . . . . . . . . (3)
= £2.50 . . . . . . . . . . . . (4)

which say that, after opening the first envelope and finding 10 pounds in it, the expected gain from switching is 2 pounds fifty.

I have numbered the steps from 0 to 4. Which step(s) do you not believe?
Jeremiah July 02, 2018 at 11:49 ¶ #193102
Reply to andrewk

Do you realize that expected gain is an average between gains and losses? It is stuff like this that makes me doubt your vague claim about your employment.




Srap Tasmaner July 02, 2018 at 11:54 ¶ #193103
Reply to andrewk Reply to Michael
If you could prove that always switching is the best strategy over the long term, doesn't that amount to proving that you are more likely to have chosen the smaller envelope? Why doesn't that bother you?

Quoting Michael
4. From 2 and 3, there's a 50% chance that my £10 envelope is the X envelope and a 50% chance that my £10 envelope is the 2X envelope.


This is false. Whether the amount in your envelope is the smaller or the larger of the pair offered you is not a matter of chance. Whether you choose that envelope is.
Michael July 02, 2018 at 11:56 ¶ #193106
Quoting Srap Tasmaner
This is false. Whether the amount in your envelope is the smaller or the larger of the pair offered you is not a matter of chance. Whether you choose that envelope is.


So you're saying that before I look I can say that there's a 50% chance that my envelope is envelope X but after looking I can't?
Srap Tasmaner July 02, 2018 at 12:04 ¶ #193108
Quoting Michael
So you're saying that before I look I can say that there's a 50% chance that my envelope is envelope X but after looking I can't?


Suppose X = 1.

You pick an envelope. On opening it, you find $2. You have chosen the 2X envelope but you don't know it.

Does that mean there is a 1/2 chance that X = 2?

No. X = 1. It's just not true that half the time 2 = 1 and half the time it doesn't.

Your not knowing whether you have the X or the 2X envelope doesn't change anything.
Michael July 02, 2018 at 12:10 ¶ #193109
Reply to Srap Tasmaner

This doesn't address my question.

After having picked an envelope, but before looking, would I be right in saying that there's a 50% chance that my envelope is envelope X?

After having picked an envelope, and after looking, would I be right in saying that there's a 50% chance that my envelope is envelope X?

I would say "yes" to both. You seem to want to say "no" to the second, but what about the first?
Michael July 02, 2018 at 12:13 ¶ #193111
Quoting Srap Tasmaner
Suppose X = 1.

You pick an envelope. On opening it, you find $2. You have chosen the 2X envelope but you don't know it.

Does that mean there is a 1/2 chance that X = 2?

No. X = 1. It's just not true that half the time 2 = 1 and half the time it doesn't.

Your not knowing whether you have the X or the 2X envelope doesn't change anything.


This is misleading reasoning.

Compare:

1. I flip a coin and hide the result. I ask you for the probability that it is heads. You say 50%.

2. I flip a coin and hide the result. Suppose it landed tails. I ask you for the probability that it is heads. You say 50%.

In this second case, are you saying that half the times heads = tails? Of course not.

Even if it landed tails (unknown to you) you're still right to say that there's a 50% chance that it landed heads, and even if I picked the 2X envelope (unknown to me) I'm still right to say that there's a 50% chance that I picked the X envelope.
Michael July 02, 2018 at 12:18 ¶ #193113
Quoting Srap Tasmaner
If you could prove that always switching is the best strategy over the long term, doesn't that amount to proving that you are more likely to have chosen the smaller envelope? Why doesn't that bother you?


We're not saying that you're more likely to have chosen the smaller envelope. We're saying that the amount you can win by switching is greater than the amount you can lose. If I have £10 in my envelope then I will either lose £5 or gain £10. There's twice as much to gain as there is to lose. And given that there's a 50% chance of picking the smaller envelope, there's an even chance of winning. That's a 2:1 payout.
Michael July 02, 2018 at 12:38 ¶ #193116
Quoting Michael
That's a 2:1 payout.


Regarding this, and the example of repeated games, consider betting twice on a coin toss with a 2:1 payout, but in the first game you bet £10 and in the second game you bet £20.

If we win one and lose one then we break even. This is exactly what happens if we play two Two Envelope games with a £10 and £20 envelope and always switch (assuming we get one in the first game and the other in the second game).

So I think the example of repeating the game is misleading. What we want to know is, given this single game, is it better to switch or not to switch? And with the coin toss, is it better to bet or not to bet?

I'd say it's better to bet on a coin toss with a 2:1 payout.
BlueBanana July 02, 2018 at 13:54 ¶ #193123
Quoting Michael
1. We pick an envelope at random
2. There's a 50% chance that my envelope is the X envelope and a 50% chance that my envelope is the 2X envelope.
3. I open my envelope and see £10
4. From 2 and 3, there's a 50% chance that my £10 envelope is the X envelope and a 50% chance that my £10 envelope is the 2X envelope.


False, learning the amount changes the odds. There is no way to choose those two amounts of money in such a way that any amount is as likely to be X or 2X.
Snakes Alive July 02, 2018 at 14:11 ¶ #193124
Quoting Michael
I'm just doing this:

1. We pick an envelope at random
2. There's a 50% chance that my envelope is the X envelope and a 50% chance that my envelope is the 2X envelope.
3. I open my envelope and see £10
4. From 2 and 3, there's a 50% chance that my £10 envelope is the X envelope and a 50% chance that my £10 envelope is the 2X envelope.
5. From 4, there's a 50% chance that the other envelope contains £20 and a 50% chance that the other envelope contains £5.


Check my previous post – I explained why this reasoning is fallacious.
Michael July 02, 2018 at 14:19 ¶ #193125
Quoting Snakes Alive
Check my previous post – I explained why this reasoning is fallacious.


Which step does it show to be wrong? Presumably it must be 2), 4), or 5)?
Snakes Alive July 02, 2018 at 14:23 ¶ #193126
Reply to Michael There is no step that's wrong – what's wrong is that in order to use this reasoning to provide an average based on a ratio of the amount drawn from the first envelope, you have to average a single variable ("how much I drew" = Y) across two distinct situations, as if this value would be the same across them as an independent variable (so that I average 1.25 Y by switching). But it isn't. How much you drew is definable only in terms of X, which switches in the two scenarios: in one scenario, it's 5, and in the other it's 10. So it's only coherent to calculate the average based on the odds in terms of X, since Y (how much you drew) is a variable dependent on X. If you do this, you'll see that the average payout is 1.5X, whether you switch or not.

Did you read the post? I can do another one working through your example specifically.
Michael July 02, 2018 at 14:24 ¶ #193127
Quoting Snakes Alive
There is no step that's wrong


So the premises are true and the inferences are valid but the argument isn't sound? That doesn't work.
Snakes Alive July 02, 2018 at 14:25 ¶ #193128
Reply to Michael No, your conclusion doesn't establish what you want it to (that switching is more profitable).
Michael July 02, 2018 at 14:33 ¶ #193130
Quoting Snakes Alive
No, your conclusion doesn't establish what you want it to (that switching is more profitable).


What do you mean by switching being more profitable? I'm certainly not saying that if you switch then you will earn more money, because I accept that one could lose £5.

I'm also not saying that you're more likely to make a profit, because I accept that the chance of winning is equal to the chance of losing.

All I am saying is that this single game has a 2:1 payout with an even chance of winning.
Snakes Alive July 02, 2018 at 14:35 ¶ #193131
Reply to Michael What I am saying is that as a strategy, switching does not increase your chances of earning more money, regardless of how many times the game is played. Your average earnings are the same regardless of whether you switch or not, and regardless of how many times the game is played.

If as a player my goal is to get as much money as possible, the two strategies are indifferently effective.
Michael July 02, 2018 at 14:40 ¶ #193133
Quoting Snakes Alive
What I am saying is that as a strategy, switching does not increase your chances of earning more money regardless of how many times the game is played.


Neither am I.

Your average earnings are the same regardless of whether you switch or not, and regardless of how many times the game is played.


And this is misleading. Again, consider the case of betting on a coin toss with a 2:1 payout, but half the bets are £10 and half the bets are £20. On average you will break even.

But take one game in isolation? You have a 2:1 payout with an even chance of winning. That's a bet worth making.

So in our case, I have £10 and the other envelope contains either £5 or £20. There's an even chance of winning, but the payout is 2:1. Obviously like the coin toss if we play again and our envelope has £20 then we stand to break even, but like the coin toss the best (switch) in a single game is worth making.
Snakes Alive July 02, 2018 at 14:41 ¶ #193134
Quoting Michael
But take one game in isolation? You have a 2:1payout with an even chance of winning. That's a bet worth making.

So in our case, I have £10 and the other envelope contains either £5 or £20. There's an even chance of winning, but the payout is 2:1.


This reasoning is fallacious. Did you read the post?
Michael July 02, 2018 at 14:45 ¶ #193135
Quoting Snakes Alive
This reasoning is fallacious. Did you read the post?


Yes, and you haven't explained how the reasoning is fallacious. In fact you agreed that my premises were true and the inferences are valid, the final inference being "there's a 50% chance that the other envelope contains £20 and a 50% chance that the other envelope contains £5".

If there's a 50% chance that the other envelope contains £20 and a 50% chance that the other envelope contains £5, then switching my £10 envelope gives me a 2:1 payout with an even chance of winning.
Snakes Alive July 02, 2018 at 14:49 ¶ #193136
Reply to Michael The post explains why this reasoning is fallacious.

The fallacy is that there is some value, X, determined in each case. You are acting as if there is an independent variable Y, viz. what you drew first, and that switching will get you either .5Y or 2Y, and so on average the "bet" is worth taking, since your average payout is then 1.25Y.

This is fallacious, because there is no such variable: Y is defined in terms of X (either it is X, or 2X), and across the two scenarios you're averaging, the value of Y changes. Hence, there is no single value of Y across the two situations, and the value 1.25Y is a chimera.

If you define Y in terms of X, this illusion disappears. Thus, as you said, you either drew X or 2X. Therefore, there's a 50% chance that switching gets you X, and a 50% chance that it gets you 2X. Likewise if you stay. The average payout for either is 1.5X. Switching does not offer favorable odds.
Michael July 02, 2018 at 14:52 ¶ #193137
Quoting Snakes Alive
The fallacy is that there is some value, X, determined in each case. You are acting as if there is an independent variable Y, viz. what you drew first, and that switching will get you either .5Y or 2Y, and so on average the "bet" is worth taking, since your average payout is then 1.25Y.

This is fallacious, because there is no such variable: Y is defined in terms of X (either it is X, or 2X), and across the two scenarios you're averaging, the value of Y changes. Hence, there is no single value of Y across the two situations, and the value 1.25Y is a chimera.


I'm not talking about averages at all. I explained why this is misleading with the example of betting on a coin toss with a 2:1 payout, but where you bet £10 half the time and £20 half the time. On average you will break even, but if we just consider a single game then a 2:1 payout with an even chance of winning is a bet worth making.

So, again, my only conclusion is this:

If there's a 50% chance that the other envelope contains £20 and a 50% chance that the other envelope contains £5, then switching my £10 envelope gives me a 2:1 payout with an even chance of winning. This is a bet worth making.
Snakes Alive July 02, 2018 at 14:53 ¶ #193138
Quoting Michael
On average you will break even, but if we just consider a single game then a 2:1 payout with an even chance of winning is a bet worth making.


This cannot be.
Michael July 02, 2018 at 14:54 ¶ #193140
If you define Y in terms of X, this illusion disappears. Thus, as you said, you either drew X or 2X. Therefore, there's a 50% chance that switching gets you X, and a 50% chance that it gets you 2X. Likewise if you stay. The average payout for either is 1.5X. Switching does not offer favorable odds.


Like others you're conflating different values of X. Given that I know that I have £10:

Thus, as you said, you either drew X or 2X. Therefore, there's a 50% chance that switching gets you X (£5), and a 50% chance that it gets you 2X (£20). Likewise if you stay. The average payout for either is (£12.5).
Snakes Alive July 02, 2018 at 14:56 ¶ #193141
Reply to Michael The value of X is fixed prior to the decision. Your reasoning switches the value of X across the two scenarios.
Michael July 02, 2018 at 15:01 ¶ #193142
Quoting Snakes Alive
This cannot be.


Yes it can. We bet twice on a coin toss with a 2:1 payout. Half the time we bet £10, half the time we bet £20. We'd expect to break even. We switch envelopes with a 2:1 payout. Half the time we have the £10 envelope and half the time we have the £20 envelope. We'd expect to break even.
Snakes Alive July 02, 2018 at 15:14 ¶ #193144
Reply to Michael No.

If there is a 2:1 payout on a coin toss, then the bet is always worth taking, regardless of the amount bet, and one will not break even on average.

But this is getting far away from the main topic anyway.

What remains true is that there is no benefit to switching, either in the one case or across cases.

Srap Tasmaner July 02, 2018 at 15:19 ¶ #193145
Reply to Michael
I modified your simulation.

<?php

$switch = $no_switch = 0;

for ($i = 1; $i <= 1000000; ++$i)
{

// set X
$X = random_int(1, 100);

// randomly select whether you get the X or the 2X
$choice = random_int(0, 1) ? 1 : 2;

// if you swap, you get the other one, duh
$swap = 1 + $choice % 2;

// If we switch
$switch += $X * $swap;

// If we don't switch
$no_switch += $X * $choice;

}

echo 'Switch: £' . number_format($switch) . PHP_EOL;
echo 'No Switch: £' . number_format($no_switch);


Run it here.

Heh - the $choice line is funny. I've never written PHP before.
Michael July 02, 2018 at 15:28 ¶ #193146
Quoting Snakes Alive
Your reasoning switches the value of X across the two scenarios.


So does yours. Here was your argument:

There's a 50% chance that switching gets you X, and a 50% chance that it gets you 2X. Likewise if you stay. The average payout for either is 1.5X.

But you're forgetting that I know that I have £10. If there's a 50% chance that switching gets me X then my £10 is 2X, and so "getting X" is getting £5. And if there's a 50% chance that switching gets me 2X then my £10 is X, and so "getting 2X" is getting £20. The X in "getting 2X" has a different value to the X in "getting X", and so you can't add them together this way.
Jeremiah July 02, 2018 at 15:42 ¶ #193149
Reply to Michael

The very definition of probability is the frequency of occurrences over repeated random events.

The first time is no different than the 10,000th time. We could set this up 10,000 different times, bring in 10,000 different people so that each event is a "first" time and it still would not reflect your model.

Michael July 02, 2018 at 15:47 ¶ #193152
Quoting Jeremiah
The very definition of probability is the frequency of occurrences over repeated random events.


That's the frequentist's interpretation.

Although I don't understand what this has to do with my argument. I'm not saying that you're more likely to win if you switch. I'm saying that switching offers a 2:1 payout with an even chance of winning, and so is a good bet to make.
Michael July 02, 2018 at 15:51 ¶ #193153
Reply to Srap Tasmaner That doesn't model the case we're considering, which is that we know we have £10. This goes back to what I was saying here:

So in your example you've considered repeating the game using the same value envelopes and say that half the time $10 is picked and half the time $20 is picked whereas in my example I've considered repeating the game using the same starting envelope and say that half the time the other envelope contains $5 and half the time the other envelope contains $20.

Is there some rule of statistics that says that one or the other is the proper way to assess the best strategy for a single instance of the game (where you know that there's $10 in your envelope)?

I would have thought that if we want to know the best strategy given the information we have then the repeated games we consider require us to have that same information, and the variations are in the possible unknowns – which is what my example does.
Snakes Alive July 02, 2018 at 15:57 ¶ #193155
Reply to Michael No.

The value of X is fixed. The two possibilities you consider must treat X as the same. You don't know what X is; but you do know that whatever it is, it does not change across the two scenarios you are considering. Your fallacious reasoning assumes that it does.

The shoe is on the other foot; you are assuming that the amount drawn, say 10, is constant in terms of X across both considered scenarios. This is not the case.
Snakes Alive July 02, 2018 at 15:59 ¶ #193157
Quoting Michael
That doesn't model the case we're considering, which is that we know we have £10.


The value that you get from the first envelope is irrelevant.
Michael July 02, 2018 at 16:09 ¶ #193160
Quoting Snakes Alive
No.

The value of X is fixed. The two possibilities you consider must treat X as the same. You don't know what X is; but you do know that whatever it is, it does not change across the two scenarios you are considering. Your fallacious reasoning assumes that it does.


The amount in my envelope is also fixed. So as the amount in my envelope is fixed to £10 and if X is fixed to 10 then it would be false to say that there's a 50% chance of switching into X and a 50% chance of switching into 2X. We can only say that there's a 100% chance of switching into 2X (or if X is fixed to 5 then a 100% chance of switching into X).

But this isn't a model that we as participants can use. We don't know the value of X. The only information available to us is:

1. There's a 50% chance that my envelope is envelope X, and
2. My envelope contains £10.

You've accepted these premises. And from these we must infer:

3. There's a 50% chance that the other envelope contains £5 and a 50% chance that the other envelope contains £20.

And you've accepted this as a valid inference. So it is as I said: a 2:1 payout with an even chance of winning. That's a good bet to make.
Snakes Alive July 02, 2018 at 16:15 ¶ #193161
Quoting Michael
The amount in my envelope is also fixed. So as the amount in my envelope is fixed to £10 and if X is fixed to 10 then it would be false to say that there's a 50% chance of switching into X and a 50% chance of switching into 2X. We can only say that there's a 100% chance of switching into 2X (or if X is 5 then a 100% chance of switching into X).


No.

We're talking about epistemic possibilities. There are two, equipossible: first, that you have drawn X, and second, that you have drawn 2X. While you know how much you have drawn, you don't know whether this is X or 2X.

Hence, there is a 50% chance of your having drawn each, and a 50% chance of switching into the other, if you decide to switch. This is the same opportunity that not switching gives you.

Quoting Michael
3. There's a 50% chance that the other envelope contains £5 and a 50% chance that the other envelope contains £20.


This conclusion does not show what you want it to. From this, it does not follow that switching is advantageous. For if the other envelope contains 5, you have drawn 2X, and if it contains 20, you have drawn X. In either case, your average output as a proportion of X is 1.5. This is the same as if you had not switched.
Michael July 02, 2018 at 16:18 ¶ #193162
Quoting Snakes Alive
While you know how much you have drawn, you don't know whether this is X or 2X.

Hence, there is a 50% chance of your having drawn each, and a 50% chance of switching into the other, if you decide to switch.


That's exactly what I've said.

There's a 50% chance that my £10 envelope is envelope 2X, so a 50% chance of a switch getting me £5.

There's a 50% chance that my £10 envelope is envelope X, so a 50% chance of a switch getting me £20.

This is the same opportunity that not switching gives you.


In terms of probability, sure, but not earnings. The average of the above is £12.50, but the average of not switching is £10.00.
Snakes Alive July 02, 2018 at 16:21 ¶ #193163
Quoting Michael
In terms of probability, sure, but not earnings. The average of the above is £12.50, but the average of not switching is £10.00.


I demonstrated that this is fallacious in my longer post above. It falsely assumes that the amount drawn is a variable independent of X. It is not.
Michael July 02, 2018 at 16:22 ¶ #193164
Quoting Michael
There's a 50% chance that the other envelope contains £5 and a 50% chance that the other envelope contains £20.


Quoting Snakes Alive
This conclusion does not show what you want it to. From this, it does not follow that switching is advantageous.


Yes it does. It shows that there's a 2:1 payout with an even chance of winning. How is that not advantageous?
Snakes Alive July 02, 2018 at 16:26 ¶ #193166
Quoting Michael
Yes it does. It shows that there's a 2:1 payout with an even chance of winning. How is that not advantageous?


The payout is on average 1.5X. This is the same payout that not switching affords.

When betting the odds, all variables are independent. That is not the case here.
Michael July 02, 2018 at 16:29 ¶ #193168
Quoting Snakes Alive
The payout is on average 1.5X. This is the same payout that not switching affords.


How do you get that?

If we play that game 100 times and switch then 50 times I win £20 and 50 times I win £5. That's £1,250.

If we play that game 100 times and I don't switch then 100 times I win £10. That's £1,000.
Snakes Alive July 02, 2018 at 16:37 ¶ #193169
Reply to Michael In order to reason this way, we must hold X constant for each case. If we played 100 times, where X = 10 in each game, then switching 50 times will net us on average 15 per game, thus 1500. This is the same payout as it we didn't switch at all, switched 75 times, or any other combination of switching or not switching.

The fallacy is that instead of holding constant X, you are holding constant the amount drawn, and acting as if this variable is independent of X.
Michael July 02, 2018 at 16:47 ¶ #193171
Reply to Snakes Alive I’m talking about the specific situation where I have £10 and there’s a 50% chance that the other envelope contains £5 and a 50% chance that the other envelope contains £20. This offers a 2:1 payout with an even chance of winning, and so is an advantageous bet.

The fact that a second bet with the same envelopes but a different initial pick would offset any winnings doesn’t change this. As a single bet that first bet is worth making.
Snakes Alive July 02, 2018 at 16:51 ¶ #193172
Reply to Michael The number of bets made is irrelevant.
Michael July 02, 2018 at 16:53 ¶ #193174
Reply to Snakes Alive Then forget about averages and just consider a single game. There’s a 50% chance of winning £10 and a 50% chance of losing £5. Is it advantageous to bet? I say yes.
Snakes Alive July 02, 2018 at 17:06 ¶ #193175
Reply to Michael That's not the game being played. There is no bet of an independent amount that returns half or double at equal rates. The amount seen first is itself already a function of X.
Michael July 02, 2018 at 17:21 ¶ #193177
Reply to Snakes Alive It is the game. I know that there’s £10 in my envelope. There’s a 50% chance that the other envelope contains £5 and a 50% chance that it contains £20. You’ve agreed with this. So switching has a 50% chance of winning me £10 and a 50% chance of losing me £5.
Srap Tasmaner July 02, 2018 at 17:35 ¶ #193181
Quoting Michael
That doesn't model the case we're considering, which is that we know we have £10.


It models it precisely. Your knowing what's in one envelope does not change what's in the other envelope.

Here's an example.

Suppose for a given trial, X = 12. There's an envelope with 12 in it and another with 24.

Suppose you pick the one with 12 and look at it. Y = 12. We'll call the amount in the other envelope Z. You reason, quite correctly, that

(1) Y = 12 ? . Z = 6 ? Z = 24

This is absolutely true because Z = 24.

Suppose you picked the 24 envelope. Y = 24. You reason, quite correctly, that

(2) Y = 24 ? . Z = 12 ? Z = 48

This is absolutely true because Z = 12.

What you have to accept is that for each trial there are only 2 values in the space. In the example above, Z = 6 = X/2 is not actually a possibility; Z = 48 = 4X is not actually a possibility. You can choose between 12 and 24 as many times as you like and you will never, ever get either 6 or 48. Your thinking they are possibilities does not make them so.
Michael July 02, 2018 at 17:41 ¶ #193183
Quoting Srap Tasmaner
It models it precisely. Your knowing what's in one envelope does not change what's in the other envelope.

Here's an example.

Suppose for a given trial, X = 12. There's an envelope with 12 in it and another with 24.

Suppose you pick the one with 12 and look at it. Y = 12. We'll call the amount in the other envelope Z. You reason, quite correctly, that

(1) Y = 12 ? . Z = 6 ? Z = 24

This is absolutely true because Z = 24.

Suppose you picked the 24 envelope. Y = 24. You reason, quite correctly, that

(2) Y = 24 ? . Z = 12 ? Z = 48

This is absolutely true because Z = 12.

What you have to accept is that for each trial there are only 2 values in the space. In the example above, Z = 6 = X/2 is not actually a possibility; Z = 48 = 4X is not actually a possibility. You can choose between 12 and 24 as many times as you like and you will never, ever get either 6 or 48. Your thinking they are possibilities does not make them so.


So let's say I flip a coin and it lands heads, but I hide the result from you. How would you model the probability that you will win with a guess of tails? You might say 50%, but then I counter with: "But suppose it's heads. Then you'll never win, no matter how many times you guess tails."

That's just a ridiculous response.

Our models only work with what we know. In your case, you only know that a fair coin has a 50% chance of landing heads. In my case, I only know that there's a 50% chance of my envelope being envelope X and that my envelope contains £10.

What we know are the constants. What we don't know are the variables.
Srap Tasmaner July 02, 2018 at 17:53 ¶ #193186
Reply to Michael
Not going to get dragged into some other scenario with you.

You are in effect demanding that I figure out what's wrong with your analysis and explain it to you. I'd love to. I'd love to have your help doing just that, once you admit that my analysis shows yours is wrong, even if we're neither of us quite sure why.

It is a simple fact that what's in the other envelope does not change, and that each envelope has one of two values.
Snakes Alive July 02, 2018 at 17:53 ¶ #193187
I'm trying to think of a new way to explain the fallacy being committed, but I think I've hit a roadblock (not in the matter itself – I understand it, but am not sure how to explain it, given that the above hasn't worked).

Here is as blunt as I can put it.

In deciding that switching is a "good bet," you must average the amount gained (lost) from switching across two situations. This requires you to take the value of what you picked first (say 10) as constant across those two situations, so that you can determine how much you would get as a portion of this (double, or half). The problem is that if you do this, then you are changing the value of X across the two situations, and treating things as if there is one epistemic possibility, say that X = 5, and another, say that X = 10. While this is on one sense so (and is reflected already in saying it the way I've put it: that you may have either drawn X or 2X), the problem comes when you try to use this changed value to average the two situations.

You can't do this, since it presumes there are two epistemic possibilities, each of which has a distinct value for X. This is not so: we know a priori that whatever X is, it is fixed. Hence the epistemic possibilities appropriately described are that, given some value X, with we have drawn that, or double that. They are not that given we have drawn Y, the true value of X is either double that or equal to that. This is fallacious, since it sneaks into our epistemic space two distinct values for X, across which we compare the value of Y as if it were an independent variable. Hence the illusion that we are 'getting' 1.25Y on average, as I explained in my first post.

––––

This conceptual explanation seems to be getting us nowhere, so I wonder if another tack might work. First is the empirical: when the game is modeled, this demonstrates that you are wrong. Multiple trials show the two strategies converging. Hence, you should be able to appreciate that there is an error in your reasoning in fact, though you can't pinpoint it.

Another way to go might be to devise other ways of framing the problem that demonstrate how thinking that a switching strategy is beneficial is absurd. For instance, if we always switched, then which envelope we picked first to look at would always determine which we chose (viz. the other one). But then, looking at 1 would result in picking 2, and looking at 2 would result in picking 1. In either case, what we picked would be advantageous given what we looked at. But then, this leads to the absurd conclusion that beginning with either envelope to look at (and hence de facto picking whichever envelope) is equally advantageous. All switching does is change which envelope is picked; the switcher is thus committed both to thinking that switching is advantageous and indifferent.
Srap Tasmaner July 02, 2018 at 17:56 ¶ #193188
Quoting Snakes Alive
All switching does is change which envelope is picked; the switcher is thus committed both to thinking that switching is advantageous and indifferent.


That's clever.
Srap Tasmaner July 02, 2018 at 18:07 ¶ #193190
Here's a new version that also calculates the average payouts as ratios to X.
Jeremiah July 02, 2018 at 18:10 ¶ #193191
Reply to Michael

That is not a Classical statistics interpretation. Classical statistics is based on using estimated variance.

However, while we are on this topic, there are five steps in the Baysian method. The last step in a Baysian method is to check your model against the data. It requires empirical verification.
Jeremiah July 02, 2018 at 18:20 ¶ #193193
If you simulated a data set for the two envelopes, then did a Classical analysis and a Baysian analysis they would both come out to the same solution.

Even, and this is important, if your prior was a loss of 5 and a gain of 20. The MCMC chain would drag the misleading prior back on track to reflect the data. A Baysian method is not an excuse to skip empirical verification.

Michael July 02, 2018 at 19:31 ¶ #193204
Quoting Snakes Alive
The problem is that if you do this, then you are changing the value of X across the two situations, and treating things as if there is one epistemic possibility, say that X = 5, and another, say that X = 10. While this is on one sense so (and is reflected already in saying it the way I've put it: that you may have either drawn X or 2X), the problem comes when you try to use this changed value to average the two situations.

You can't do this, since it presumes there are two epistemic possibilities, each of which has a distinct value for X. This is not so: we know a priori that whatever X is, it is fixed.


When you average it you change the value of the first envelope chosen, despite the fact that the question is "what should I do, given that I have £10 in my envelope?".

These are incompatible premises:

1. X = 10 (or X = 5)
2. My envelope contains £10
3. There's a 50% chance of winning X and a 50% chance of losing X.

You have to pick from 1 and 3 or 2 and 3, and given that the situation I'm modelling is my current situation where my envelope contains £10, I opt for 2 and 3.

Although you could pick 1 and 2 and abandon 3, but then that leaves us with:

4. There's a 100% chance of winning X (or a 100% chance of losing X).

So we conclude that switching is advantageous (or sticking is advantageous).

Multiple trials show the two strategies converging.


That's because although it's a 2:1 payout with an even chance of winning the bet when you lose is twice as big as the bet when you win. Obviously you're going to break even. It would be like flipping a coin and hiding the result (heads) and having one person bet £10 on heads and another £20 on tails and offering them both a 2:1 payout. It's an advantageous bet for both people (given that they don't know the result or about each other's offer), despite the fact that the average payout is £0.
Michael July 02, 2018 at 20:00 ¶ #193207
So with this in mind I have a new strategy for repeated games. You switch on your first game and then in subsequent games only if your chosen envelope is less than or equal to half the maximum seen.

http://sandbox.onlinephpfunctions.com/code/7c601c1099f15ea278eb6ccb4922e6c96b7ca644

<?php

$switch = $no_switch = $max_2x = 0;

for ($i = 1; $i <= 10000; ++$i)
{

// Ensure that all envelopes are even and not double an odd number
$x = random_int(1, 100) * 4;

$envelopes = [$x, $x * 2];

$choice = $envelopes[$key = random_int(0, 1)];

$other = $envelopes[(int) !$key];

$no_switch += $choice;

if (

!$max_2x
||
$choice <= $max_2x / 2

)
{
$switch += $other;
}

else
{
$switch += $choice;
}

$max_2x = max($other, $choice, $max_2x);

}

echo 'Gain: ' . (($switch / $no_switch) - 1);


Surprise surprise, there's a gain of .25.
Snakes Alive July 02, 2018 at 20:16 ¶ #193210
Quoting Michael
That's because although it's a 2:1 payout with an even chance of winning the bet when you lose is twice as big as the bet when you win. Obviously you're going to break even. It would be like flipping a coin and hiding the result (heads) and having one person bet £10 on heads and another £20 on tails and offering them both a 2:1 payout. It's an advantageous bet for both people (given that they don't know the result or about each other's offer), despite the fact that the average payout is £0.


There is some misunderstanding here. The number of trials is irrelevant to the effectiveness of the strategies. If multiple trials cause you to break even on average, so will one.

Also, a 2:1 payout would be getting $30 on a win and nothing on a loss, after betting $10.
Michael July 02, 2018 at 20:21 ¶ #193211
Quoting Snakes Alive
Also, a 2:1 payout would be getting $30 on a win and nothing on a loss, after betting $10.


Yes, so we bet £5 of our £10 and if we win we get £15 back (+£5 left over = £20) and if we lose we get £0 back (+£5 left over = £5).
Michael July 02, 2018 at 20:45 ¶ #193214
Quoting Snakes Alive
There is some misunderstanding here. The number of trials is irrelevant to the effectiveness of the strategies. If multiple trials cause you to break even on average, so will one.


Then why does this work?
Snakes Alive July 02, 2018 at 20:47 ¶ #193215
Reply to Michael It works because you limited the selection of numbers to below 400, and so funneled the choice to switching only when lower numbers relative to that range appear. This is not a feature of the original example, and if there were no a priori range from which the values were chosen, the strategy would have no benefit.
Michael July 02, 2018 at 21:01 ¶ #193219
Quoting Snakes Alive
It works because you limited the selection of numbers to below 400, and so funneled the choice to switching only when lower numbers relative to that range appear. This is not a feature of the original example, and if there were no a priori range from which the values were chosen, the strategy would have no benefit.


There's always going to be a maximum because there's a finite number of games. One (or more) of them is going to have the highest randomly selected X.

And my strategy doesn't require knowing that 400 (or whatever) is the maximum. The choice is determined by prior envelopes, not by some limit as to what can possibly be selected.
Snakes Alive July 02, 2018 at 21:04 ¶ #193221
Reply to Michael I would prefer not to get into this topic, because it's off-subject and the errors made here are strictly orthogonal to the errors driving the original misconception.

But it doesn't matter if there's a finite number of games, or how many games there are. What matters is you baked a hard limit into the selection of X. Wherever X can be at most, say 400, then one knows a priori never to switch when what one sees in the envelope >400 (since these can only be the 2X).

It doesn't matter that the strategy doesn't require knowing. Wherever there is some limit, albeit unknown, the strategy will funnel you towards figuring out what that limit is.

The strategy relies on something not present in the original example, and so is irrelevant.
Michael July 02, 2018 at 21:49 ¶ #193235
Reply to Snakes Alive

So you're saying that if there is no maximum then my switching strategy wouldn't make a difference, whereas if there is a maximum then my switching strategy as modeled above does offer a benefit?

I'd have thought that this is true only if there are diminishing returns as the number of possible X envelopes increases (as the limit approaches infinity?), but as far as I can tell there isn't. There's always a gain of .25. Although the most I can test up to is 9,223,372,036,854,775,807, so what do I know?
andrewk July 02, 2018 at 22:23 ¶ #193241
Quoting Srap Tasmaner
If you could prove that always switching is the best strategy over the long term, doesn't that amount to proving that you are more likely to have chosen the smaller envelope? Why doesn't that bother you?

There is no long term in this setup. There is a single offering. If we want to consider a long series of such activities, it needs to be set up precisely, and that has not been done. A number of crucial conditions will need to be specified, such as whether X is always the same and if not, how it varies from one play to the next. The best strategy will vary according to how those conditions are set up.

In any case, a setup with repeated plays is a completely different probability space, and does not entail anything for this one, or vice versa.

I'm going to reprise my proof, because three pages have been added and so far nobody seems to have attempted to point out an invalid step in it:

Quoting andrewk
we use conditional probabilities to calculate the gain G from switching as follows, where the envelope we looked in contained £10:

E[G] = 0.5 * E[G | X= 5] + 0.5 * E[G | X= 10] ] . . . . . . . . . . . (0)

= 0.5 * E[-X | X= 5] + 0.5 * E[+X | X= 10] . . . . . . . . . . . (1)
= 0.5 * E[-5 | X= 5] + 0.5 * E[+10 | X= 10] . . . . . . . . . . . (2)
= 0.5 * (-5) + 0.5 * (+10) . . . . . . . . . . . (3)
= £2.50 . . . . . . . . . . . . (4)
Michael July 02, 2018 at 22:42 ¶ #193245
Quoting andrewk
If we want to consider a long series of such activities, it needs to be set up precisely, and that has not been done. A number of crucial conditions will need to be specified, such as whether X is always the same and if not, how it varies from one play to the next. The best strategy will vary according to how those conditions are set up.


Such as this?
Snakes Alive July 02, 2018 at 23:07 ¶ #193249
Reply to Michael This isn't relevant to the question anyway. The switching strategy you're discussing has nothing to do with the OP.
Snakes Alive July 02, 2018 at 23:08 ¶ #193250
Quoting andrewk
If we want to consider a long series of such activities, it needs to be set up precisely, and that has not been done. A number of crucial conditions will need to be specified, such as whether X is always the same and if not, how it varies from one play to the next. The best strategy will vary according to how those conditions are set up.


This isn't relevant. It simply doesn't understand the crux of the puzzle.
Michael July 02, 2018 at 23:13 ¶ #193253
On a related note there's this. Apparently one can use something called "Cover’s switching strategy" even if there is no upper bound for the amount that can be placed in the envelope. It's too technical for me, so I don't know how it compares to my strategy.
A Christian Philosophy July 02, 2018 at 23:19 ¶ #193254
Sorry, late for the party, here is my 2 cents. I agree with Michael.

Decision Theory is ?[(amount of gain) x (probability of gain)] + ?[(amount of loss) x (probability of loss)]
There is no loss because the game is free.
Choices are: (1) Pick Envelop 1 containing $Y, or (2) Pick Envelop 2.

Decision (1) = Y x 100% = Y
Decision (2) = 2Y x 50% + Y/2 x 50% = 1.25Y or 5/4Y
Decision (2) is better than Decision (1).
Jeremiah July 02, 2018 at 23:21 ¶ #193255
Reply to andrewk That is far from a proof and the only thing it displayed is your lack of understanding of what expected gains are.
Jeremiah July 02, 2018 at 23:28 ¶ #193256
Expected gains are an average over the long run. Probability is the frequency of occurrences of repeated random events and that includes only possible outcomes.
Jeremiah July 02, 2018 at 23:33 ¶ #193259
If you have to limit your number of trials to leverage your prior then you are essentially doing the equivalence of p-hacking.
Srap Tasmaner July 02, 2018 at 23:57 ¶ #193267
Reply to andrewk Reply to Michael

You are presented with two envelopes, one valued at X and one valued at 2X; the average value of an envelope is 3X/2.

You choose an envelope, and do not look at the contents. You are asked if you would like to swap.

Your envelope has a definite value, call it Y.

If you have the larger of the two envelopes, the value of the other envelope is Y/2; the average value of an envelope is then (Y + Y/2)/2 = 3Y/4.

If you have the smaller of the two envelopes, the value of the other envelope is 2Y; the average value of an envelope is then (Y + 2Y)/2 = 3Y/2.

It is absurd that the average value should change depending on which of the two envelopes you have, therefore they must be equal:

3Y/2 = 3Y/4
6Y = 3Y
6 = 3

Hmmm. Let's go back.

If you have the larger of the two envelopes, then
  • Y = 2X;
  • the other envelope has Y/2 = X;
  • the average value of an envelope is 3Y/4 = 3X/2.


If you have the smaller of the two envelopes, then
  • Y = X;
  • the other envelope has 2Y = 2X;
  • the average value of an envelope is 3Y/2 = 3X/2.


Since Y is defined to be whatever is in the envelope you selected, then Y has a different value depending on which envelope you selected. It is not a constant, as X is. And therefore you cannot, after all, set the average values equal to each other: the LHS Y has one value and the RHS Y has another. X ? 2X.

Neither can you make this calculation:
If I have the larger valued envelope, I risk losing only Y/2 by switching, while if I have the smaller valued envelope I stand to gain Y. Y has two different values in this sentence. By definition.


Now suppose you are allowed to look, so you learn, say, that Y = 10. Won't that prevent the problem of Y changing values? It will be 10 in every equation.

Suppose Y = 10. Then either 10 = X, or 10 = 2X. Where before we had equations with two unknowns, now we have equations with one.

Suppose you reason as follows:
If I have the larger envelope, then the other has 5 and the average value of an envelope is 7.5.
If I have the smaller, then the other has 20 and the average value of an envelope is 15.

(It is prima facie absurd that the average value of an envelope changes depending on whether you have the larger or the smaller of the two.)

The only way this can be is if our only remaining unknown, X, changes its value depending on whether I have the larger or the smaller envelope. Since we have fixed Y, which was defined to change depending on your choice, we are forced to make X vary with your choice in order to preserve the equations. But X is a constant. Unknown, but a constant.


So what is the right way to reason, once you know that Y = 10? The simple answer is, don't. You haven't learned anything you can act on. It will turn out X = 5 or X = 10, but Y = 10 does not help you figure that out, and there is no way to calculate using Y = 10 that does not force X to vary with your choice of envelope, which is absurd.
Srap Tasmaner July 03, 2018 at 00:00 ¶ #193269
Quoting andrewk
A number of crucial conditions will need to be specified, such as whether X is always the same and if not, how it varies from one play to the next. The best strategy will vary according to how those conditions are set up.


My version of Michael's sim was intended to be quite simple. I imagined it as the question being offered once to 2 x 10^6 participants, half of whom switch and half of whom don't. Then we aggregate the results to compare the two strategies.

What's wrong with this?
andrewk July 03, 2018 at 00:17 ¶ #193273
Reply to Srap Tasmaner We could get into a discussion of what's wrong with it, but we'd be discussing the wrong thing. Computer programs - with very few exceptions like dedicated theorem-proving programs, which is a very niche area - can only ever be used to do calculations and generate intuitions. They cannot prove anything. To do that we need to use mathematics, which is what my proof does. If we stray away from mathematics, we just end up trading word salads, which is what most of this thread is.

If the computer program has any valid insights, it should be able to be expressed as a mathematical proof, that is presented as a series of numbered formal propositions, each being either a premise or else having a justification as to how it can be deduced from one or more previous propositions in the sequence. If you can produce such a proof, I promise to engage with it.

And here is mine. I haven't written out the justifications for the steps yet because most of them are obvious, so I'll wait until somebody engages it and challenges a line, before taking the trouble to write out the justification for it.

We use conditional probabilities to calculate the gain G from switching as follows, where the envelope we looked in contained £10:

E[G] = 0.5 * E[G | X= 5] + 0.5 * E[G | X= 10] ] . . . . . . . . . . . (0 - Premise)
= 0.5 * E[-X | X= 5] + 0.5 * E[+X | X= 10] . . . . . . . . . . . (1)
= 0.5 * E[-5 | X= 5] + 0.5 * E[+10 | X= 10] . . . . . . . . . . . (2)
= 0.5 * (-5) + 0.5 * (+10) . . . . . . . . . . . (3)
= £2.50 . . . . . . . . . . . . (4)

Srap Tasmaner July 03, 2018 at 00:18 ¶ #193275
Reply to andrewk
X does not vary. You are wrong from the start.
Snakes Alive July 03, 2018 at 00:19 ¶ #193276
You can literally just check this by performing it live. Empirically, the switching strategy doesn't help. The running of the program simply does the performance, and demonstrates this.

Thus we need to start with the recognition that switchers are empirically just wrong. Whether they know the error they've committed is irrelevant.
andrewk July 03, 2018 at 00:23 ¶ #193278
Reply to Srap Tasmaner That is a coherent response. Whether you realised it or not, you have sided with the Frequentist approach, and a Frequentist will indeed reject my calculations, saying that there are no probabilities for values of X.

I am a Bayesian, so the calculation is valid for me.

I would love to explore the Frequentist alternative, but nobody has so far (to my knowledge) offered a formal presentation of it - the Frequentist counterpart to my Bayesian calculation.

My current expectation is that there is no Frequentist alternative, because one cannot use any probability distributions at all. But I would be delighted to be shown to be wrong. I suggest you (implore you to?) have a go at writing a formal argument from the Frequentist perspective, in which none of the items are treated as random variables.
Snakes Alive July 03, 2018 at 00:28 ¶ #193279
Reply to andrewk I already provided a refutation for this, actually, in my first long post. Several people have repeated this or something similar, but it's fallacious. Can you read that post and get back to me?

Your error, BTW, is having the two situations are that X = 5 or that X = 10. The correct way to think about it is that in one case, you've drawn X, and in the other, 2X.

I can spell out why what you've posted here is equivalent to what I went over in the long post, but I don't want to if you understand anyway.

Probability distributions are irrelevant.
Jeremiah July 03, 2018 at 00:32 ¶ #193280
Reply to andrewk I doubt you could even explain the differences.
Jeremiah July 03, 2018 at 00:44 ¶ #193282
Classical and Bayesian analyses are both methods of statistics. Statistics is a data science, as in the analysis of data. They are not used or fit for simple probability problems like this one. Furthermore, as a science, they are empirically based, both of them.
andrewk July 03, 2018 at 01:04 ¶ #193285
Quoting Snakes Alive
Your error, BTW, is having the two situations are that X = 5 or that X = 10

Good, so you are challenging line 0 of my proof.

Why do you think it is an error? Do you not agree that, if I open the envelope and see 10, the possibilities are that X=5 or that X=10, and that I have no reason to favour one over the other?

The fact that one can think of it another way is neither here nor there. If you want to challenge this line of analysis, you need to find a flaw in it, not just say 'the correct way to think about it is this other way...'

BTW I tried to read your first post a day or so ago, but the embedded images were corrupted, so it was not comprehensible. If that has been fixed, by all means post a link (I don't know where in this long thread it is now) and I'll have another look.
Snakes Alive July 03, 2018 at 01:07 ¶ #193286
Reply to andrewk Here is the post:

https://thephilosophyforum.com/discussion/comment/193041

It explains why averaging expected outcome over situations with respect to the amount you drew as constant doesn't work.
andrewk July 03, 2018 at 01:08 ¶ #193287
Reply to Michael Indeed. You have written a program with repeated plays that shows it is best to switch, and Srap appears to have written one that is only slightly different and shows that it makes no difference. That corroborates my contention that if one wishes to make an argument based on repeated plays, the devil will be in the detail of the set-up of the system of repeated plays, and changing the tiniest detail can change the result.
andrewk July 03, 2018 at 01:10 ¶ #193288
Reply to Snakes Alive I'm afraid the table(s) is(are) still not showing. It may be a conflict between my system and the web-site.

Perhaps you could enter the table as text rather than an embedded image.
Srap Tasmaner July 03, 2018 at 01:13 ¶ #193290
Quoting andrewk
You have written a program with repeated plays that shows it is best to switch, and Srap appears to have written one that is only slightly different and shows that it makes no difference.


They are completely different. Michael is allowing participants access to the results of the trials so far performed. This is completely different, and of no relevance to this thread.
andrewk July 03, 2018 at 01:21 ¶ #193293
Reply to Srap Tasmaner I regard all computer simulations as irrelevant to the question at hand. The question is one of mathematics, and must be addressed by mathematics, not programming.
andrewk July 03, 2018 at 01:42 ¶ #193296
Quoting Srap Tasmaner
If I have the larger envelope, then the other has 5 and the average value of an envelope is 7.5.
If I have the smaller, then the other has 20 and the average value of an envelope is 15.

(It is prima facie absurd that the average value of an envelope changes depending on whether you have the larger or the smaller of the two.)

Not if it is in two different games, which is what is happening here.

In the first case, the game has envelopes with 5 and 10 in them, average 7.5, and I got the larger envelope.
In the second case, the game has envelopes with 10 and 20 in them, average 15, and I got the smaller envelope.

What has changed is not just whether I have the larger envelope, but also what the games-mistress has put in the envelopes. So of course the average is different.
Srap Tasmaner July 03, 2018 at 02:05 ¶ #193300
Reply to andrewk
What is the probability that the envelopes presented to you are valued at 5 and 10? (P(X = 5).)

What is the conditional probability that the envelopes presented to you are valued at 5 and 10, given that you chose the 10? (P(X = 5 | Y = 10).)

That's what you need to calculate. How will you do it?
andrewk July 03, 2018 at 02:11 ¶ #193302
Reply to Srap Tasmaner The first question is about the prior distribution of X. My understanding is that most posters are assuming this is unknown to the player, and I have gone along with that. So the probability cannot be estimated.

The second question is about conditional probabilities. Given I know I have 10, the two possibilities that are open to me are 5, 10 and 10, 20, and I have no basis on which to distinguish between the two. So, being a Bayesian, I make the probabilities equal at 0.5. That approach is embedded in line 0 of the proof:

Proof: We use conditional probabilities to calculate the gain G from switching as follows, where the envelope we looked in contained £10:

E[G] = 0.5 * E[G | X= 5] + 0.5 * E[G | X= 10] ] . . . . . . . . . . . (0)
= 0.5 * E[-X | X= 5] + 0.5 * E[+X | X= 10] . . . . . . . . . . . (1)
= 0.5 * E[-5 | X= 5] + 0.5 * E[+10 | X= 10] . . . . . . . . . . . (2)
= 0.5 * (-5) + 0.5 * (+10) . . . . . . . . . . . (3)
= £2.50 . . . . . . . . . . . . (4)

I have no idea what a Frequentist would do.

Srap Tasmaner July 03, 2018 at 03:05 ¶ #193308
Quoting andrewk
the two possibilities that are open to me


What does that mean? You know one of them must be in the distribution of X, but you don't know which. Are you claiming to know that both are in the distribution?
Jeremiah July 03, 2018 at 03:15 ¶ #193311
Deleting my post doesn't make you right.
andrewk July 03, 2018 at 03:15 ¶ #193312
Quoting Srap Tasmaner
What does that mean? You know one of them must be in the distribution of X, but you don't know which

I mean that I know my envelope has 10 and that the other envelope has either 5 or 20.

I don't know what you mean by 'one of them must be in the distribution of X'.
Srap Tasmaner July 03, 2018 at 03:18 ¶ #193313
Reply to andrewk
One of them must be a possible value of X. Not necessarily both.
andrewk July 03, 2018 at 03:19 ¶ #193314
Reply to Srap Tasmaner Sorry, still not following you. One of what?
Jeremiah July 03, 2018 at 03:20 ¶ #193315
Fraud.
Srap Tasmaner July 03, 2018 at 03:21 ¶ #193316
Reply to andrewk
Sorry, yes, I mean Y = 10 ? . X = 5 ? X = 10.

You know that at least one of 5 and 10 are possible values of X. Do you know that both are?
andrewk July 03, 2018 at 03:30 ¶ #193320
Reply to Srap Tasmaner I would say yes I do. I feel a discussion over the meaning of 'possible' may be approaching, but let's see where this goes.
Srap Tasmaner July 03, 2018 at 03:33 ¶ #193321
Reply to andrewk
I just don't understand how you know that.
andrewk July 03, 2018 at 03:35 ¶ #193322
Reply to Srap Tasmaner To me, to say 'B is possible' means 'I would not be astonished if I discovered B to be the case'.

If I have 10 and somebody opens the other envelope, I will be astonished neither if it contains 5 nor if it contains 20. I would however be astonished - or think the games mistress has deceived me - if it contained 100, or any other number except 5 or 20.
Srap Tasmaner July 03, 2018 at 03:38 ¶ #193323
Reply to andrewk
That's more answer than I'm asking for. What in the rules of the game or in the knowledge you have acquired (i.e., that Y = 10) assures you that the games mistress includes both 5 and 10 in the sample space for X? Maybe a tenner is the smallest bill she has.
andrewk July 03, 2018 at 03:44 ¶ #193326
Reply to Srap Tasmaner It's not about the games mistress's sample space. She doesn't have one. She has two amounts that she has always intended to put into the envelopes. It's about my sample space, which consists of the events that I cannot rule out based on my knowledge to date.

That knowledge - based on seeing 10 in my envelope - allows me to rule out every other event (an event being a particular sum being in the other envelope) except for 5 and 20. So that's my sample space - just two events.
Srap Tasmaner July 03, 2018 at 03:46 ¶ #193327
Reply to andrewk
I must to bed. Cheers.
andrewk July 03, 2018 at 03:48 ¶ #193328
Dormez bien, mon ami.
Jeremiah July 03, 2018 at 12:00 ¶ #193390
Quoting andrewk
That knowledge - based on seeing 10 in my envelope - allows me to rule out every other event (an event being a particular sum being in the other envelope) except for 5 and 20. So that's my sample space - just two events.


Based on your knowledge you know that the sample space has to follow the algebraic form of [X,2X],and you know by the definition of a sample space, that your sample space can only contain possible outcomes (or at least I hope you do).

Therefore your sample space could never be [5,20], as it does not follow the form of [X, 2X]. Your sample space could be [5,10] or [10,20] but there is no way you can mathematically justify a sample space of [5,20] as it is not consistent with [X,2X].



Jeremiah July 03, 2018 at 12:30 ¶ #193397
Quoting andrewk
I have no idea what a Frequentist would do.


Flip a coin.

A simple random sample, which is what Classical statistics is based on, is a subset of a population which is obtained by a process which gives all sets of n distinct items in a population an equal chance of being selected. There are two n distinct items, so they would flip a coin.

Both Classical and Bayesian approach uses a random process to make selections from a sample space. Bayesian methods combine their prior with random samples from a sample distribution to create posterior distributions. Then they make their assessments off the posterior distributions.
Michael July 03, 2018 at 12:55 ¶ #193403
Quoting Jeremiah
Based on your knowledge you know that the sample space has to follow the algebraic form of [X,2X],and you know by the definition of a sample space, that your sample space can only contain possible outcomes (or at least I hope you do).

Therefore your sample space could never be [5,20], as it does not follow the form of [X, 2X]. Your sample space could be [5,10] or [10,20] but there is no way you can mathematically justify a sample space of [5,20] as it is not consistent with [X,2X].


[X, 2X] is our sample space for both envelopes, but given that we know that there's £10 in our envelope, what's our sample space for the other envelope?
BlueBanana July 03, 2018 at 15:08 ¶ #193426
What if there are two people and each time both are randomly given an envelope. Is it then beneficial for both to switch the envelopes? So each of them gets more than half of the money on average.

What if these two people then put the money back together and distribute it in new envelopes? Do they by switching the envelopes again keep infinitely increasing the amount of money?
Jeremiah July 03, 2018 at 15:41 ¶ #193430
Reply to Michael
You just said it yourself the sample space for both is X and 2X.

It went over this right here:

https://thephilosophyforum.com/discussion/comment/192854

Also, it should be made clear that an uninformative prior is a Classical apporach. A Baysian approach with an uninformative prior is philosophically the same apporach as a Classical apporach. Baysian divergence is when it introduces an informative prior.
Michael July 03, 2018 at 15:42 ¶ #193432
Quoting Jeremiah
You just said it yourself the sample space for both is X and 2X.


Yes, and then I asked you what the sample space is for the other envelope, given that your envelope contains £10.
Jeremiah July 03, 2018 at 15:44 ¶ #193434
Reply to Michael You read it too fast and understood too little. I very clearly and fully addressed your concern.
Michael July 03, 2018 at 15:48 ¶ #193435
Quoting BlueBanana
What if there are two people and each time both are randomly given an envelope. Is it then beneficial for both to switch the envelopes?


I have flipped a coin and know the result. I will let you bet on it with a 2:1 payout if you win. However, I decide how much you have to bet, and only after you tell me your guess (although you're free to back out if the bet is too high).

Should you bet?
Michael July 03, 2018 at 15:55 ¶ #193436
Quoting Jeremiah
You read it too fast and understood too little. I very clearly and fully addressed your concern.


Clearly not clearly enough, as I didn't understand it. What is the sample space of the other envelope?
BlueBanana July 03, 2018 at 16:00 ¶ #193437
Quoting Michael
I have flipped a coin and know the result. I will let you bet on it with a 2:1 payout if you win. However, I decide how much you have to bet, and only after you tell me your guess.

Should you bet?


I don't understand how this is supposed to be comparable or relevant to the envelope paradox. Are you the person opening the other envelope or the person organizing the test?

Both people know the amount in their envelope. Let's say they can both choose the same envelope but can't communicate with each other. What should they choose? Always choosing the envelope of the other person can't be beneficial unless A+B?B+A.
Michael July 03, 2018 at 16:04 ¶ #193438
Quoting BlueBanana
I don't understand how this is supposed to be comparable or relevant to the envelope paradox.


The point is that it's an advantageous bet, even though I will ask you to bet £20 if you guess wrong and another person £10 if he guesses right, so that the average payout is £0.
BlueBanana July 03, 2018 at 16:07 ¶ #193440
Reply to Michael As you've stated it, it's not an advantageous bet if you have to bet twice as much when you lose.
BlueBanana July 03, 2018 at 16:11 ¶ #193441
Let's say you put the two envelopes on a table, and randomly choose to put one on the left side and the other on the right side. You can each time open the one on the left and then switch to the right one. If this is beneficial, you can just choose the right one each time without checking the amount on the left envelope.

If that's not absurd enough, you can do the same reasoning for the left envelope.
Michael July 03, 2018 at 16:15 ¶ #193442
Quoting BlueBanana
As you've stated it, it's not an advantageous bet if you have to bet twice as much when you lose.


I offer you a fixed amount of £20 whether you pick the winner or the loser. It's just that if you pick the loser then I will offer someone else who picks the winner a £10 bet.
BlueBanana July 03, 2018 at 16:28 ¶ #193443
Reply to Michael Can the participant be certain they're the person getting the fair chance? The person betting £10 will always win and the person betting £40 will always lose.
Michael July 03, 2018 at 16:53 ¶ #193445
Reply to BlueBanana Everyone gets a fair chance. What’s the difference between me offering you a £20 bet regardless of your choice and me offering you a £20 bet only if you pick the loser? The different bets is just about balancing my books. For the participants it’s still just a 50% chance with a 2:1 payout.
BlueBanana July 03, 2018 at 17:49 ¶ #193447
Reply to Michael You can't balance your books with £20 bets with 50% chance of 2:1 payout and £10 bets with certain wins so clarify the system in your example.

Quoting Michael
It's just that if you pick the loser then I will offer someone else who picks the winner a £10 bet.


And if I pick the winner you lose £40, so I assume you also offer someone who picks the loser a £40 bet, right?

Quoting Michael
For the participants it’s still just a 50% chance with a 2:1 payout.


True, but notice that you can't make profit out of betting in this system. Taking part in it still isn't profitable.
Michael July 03, 2018 at 18:23 ¶ #193453
Quoting BlueBanana
True, but notice that you can't make profit out of betting in this system. Taking part in it still isn't profitable.


You keep thinking about it as what would happen if you play repeatedly. I'm just talking about playing a single game. There's a 50% chance of winning and the payout is 2:1. It doesn't matter that my potential winnings are offset by someone else losing after betting twice as much or that my potential losses are offset by someone else winning after betting half as much. We can play the game and not even consider anybody else being involved.
BlueBanana July 03, 2018 at 18:55 ¶ #193461
Quoting Michael
There's a 50% chance of winning and the payout is 2:1.


Only if you're the person betting £20. And that's fine as a thought experiment of its own but it doesn't relate to the envelope paradox. You don't know whether the amount of money in your envelope is the amount of money that has 50% chance of winning with 2:1 payout.
Snakes Alive July 03, 2018 at 18:56 ¶ #193462
While I think the problem has been adequately solved by the responses in this thread, it's fascinating to see how persistent these sorts of 'transcendental illusions' are. Even reasoning in the simplest cases, we often simply cannot see past some heuristic we usually use to solve problems, convinced they apply to some case in which they do not, and there often appears to be no easy way to demonstrate to people that they are in the grip of such an illusion.

A warning to all those who want to use such logical heuristics to do metaphysics about 'big' questions! If you can't get a toy problem about two envelopes right...
Snakes Alive July 03, 2018 at 18:57 ¶ #193463
Quoting Michael
You keep thinking about it as what would happen if you play repeatedly. I'm just talking about playing a single game.


This is so bizarre to me. The amount of games doesn't matter, everyone keeps telling you this, but you're still convinced it is, and I can't figure out why.
Michael July 03, 2018 at 19:08 ¶ #193467
@BlueBanana Every amount has a 50% chance of winning for a 2:1 payout. It’s just that, like every after-the-fact bet, the result is prior to the bet.

It doesn’t matter if my £20 bet on tails even when it’s actually heads is the only bet or if there’s also a £10 bet on heads. It’s 50% for a 2:1 payout.

It seems that the real issue is that you seem to disagree with me on how to interpret after-the-fact betting.
BlueBanana July 03, 2018 at 19:16 ¶ #193469
Quoting Michael
Every amount has a 50% chance of winning for a 2:1 payout.


That's not how it works in the paradox. You need to end up even. Otherwise you're implying the amount of money combined in the envelopes doesn't equal the amount of money combined in the envelopes.

The envelopes are identical. Learning the amount of money in one of them is not relevant information, as can be seen in the table example, and in what happens when there're two people, each checking one envelope.
Srap Tasmaner July 03, 2018 at 19:41 ¶ #193477
Suppose the envelopes on offer contain $10 and $20. You pick one.

If your envelope contains $10, then you will be offered the chance to buy the remaining envelope for $10. To you this looks like an envelope with an average value of $12.50. You swap and get $20.

If your envelope contains $20, then you will be offered the chance to buy the remaining envelope for $20. To you this looks like an envelope with an average value of $25. You swap and get $10.

This is very strange. @Snakes Alive noted that your initial choice is a matter of indifference because whichever envelope you pick, there's a story you can tell yourself to justify swapping. (Half these stories are damned lies.) @BlueBanana noted that if two players take an envelope each, they'll both want to trade.

I see three possibilities here:

(1) There is a flaw somewhere in the way @Michael and @andrewk recommend we should estimate the value of the remaining envelope. If there is, it's not exactly obvious.

(2) @Michael and @andrewk are right about the expected value of the other envelope, and this is a genuine paradox. (What they're wrong about is thinking swapping works, since it's really obvious that it does not and cannot.)

(3) @Michael and @andrewk have part of the right analysis, but something more is needed.

(2) has to be avoided at all cost, I'd say.
Michael July 03, 2018 at 20:47 ¶ #193497
Quoting Srap Tasmaner
(2) Michael and @andrewk are right about the expected value of the other envelope, and this is a genuine paradox. (What they're wrong about is thinking swapping works, since it's really obvious that it does not and cannot.)


The issue is that there’s an expected[/I] gain for each game [i]individually but that because each game that actually gains is offset by an equivalent game that actually loses, the actual (and expected) gain for all games collectively is 0.
Snakes Alive July 03, 2018 at 20:50 ¶ #193500
Quoting Srap Tasmaner
(1) There is a flaw somewhere in the way Michael and @andrewk recommend we should estimate the value of the remaining envelope. If there is, it's not exactly obvious.


I have tried to clarify why this is, but apparently it hasn't worked. But I don't have another method of expositing it. I expect that some way of making yet another distinction, perhaps between epistemic and metaphysical possibility, may make it work, so the probability table can be drawn up again, and the fallacy made obvious to everyone.
Snakes Alive July 03, 2018 at 20:52 ¶ #193503
Reply to Michael Nope. If you were right, the expected return for any number of plays, 1 or a million, should always be 1.25 the amount drawn. Number of plays is irrelevant.
Andrew M July 03, 2018 at 21:31 ¶ #193521
Quoting Michael
I'm just doing this:

1. We pick an envelope at random
2. There's a 50% chance that my envelope is the X envelope and a 50% chance that my envelope is the 2X envelope.
3. I open my envelope and see £10
4. From 2 and 3, there's a 50% chance that my £10 envelope is the X envelope and a 50% chance that my £10 envelope is the 2X envelope.
5. From 4, there's a 50% chance that the other envelope contains £20 and a 50% chance that the other envelope contains £5.

We seem to agree on 1-3, but you disagree with 4 and/or 5?


I disagree that the 50% chance can be assumed. If the sample space is finite, then there is a non-zero chance that the $10 amount is the maximum amount. If it is, the actual gain from swapping will always be negative. Accounting for both the minimum and maximum amounts exactly cancels out the 1.25X expected gain for other amounts.

For an infinite sample space, assuming 50% chance and conditioning on any specific amount will always conclude a 1.25X expected gain (the grass always appears greener on the other side). Yet unconditionally, there is no reason to prefer either envelope. That again implies that the 50% chance assumption is mistaken. A higher probability weighting (say 2/3 or a graded weighting) for lower amounts (or perhaps for amounts closer to 1) may bring agreement, but I haven't checked the math.

Quoting andrewk
I have numbered the steps from 0 to 4. Which step(s) do you not believe?


See above per the 50% chance assumption.
Michael July 03, 2018 at 21:35 ¶ #193522
Reply to Snakes Alive

1. There's a 50% chance that I have envelope X and a 50% chance that I have envelope 2X.
2. I have £10.
3. Therefore, there's a 50% chance that the other envelope contains £5 and a 50% chance that the other envelope contains £20.

You've accepted this as sound.

The expected return is worked out using the equation:

[math]\begin{align} E[R] = \sum_{i=1}^n R_iP_i \end{align}[/math]

So, given the conclusion above:

[math]\begin{align} E[R] = \frac{1}{2} \cdot 5 + \frac{1}{2} \cdot 20 = 12.5 \end{align}[/math]

Now, the counter to this, as explained here, is:

Expected value in B = 1/2 ( (Expected value in B, given A is larger than B) + (Expected value in B, given A is smaller than B) )

If we then take the sum in one envelope to be x and the sum in the other to be 2x the expected value calculations becomes:

Expected value in B = 1/2 (x + 2x)


However, consider that we know that there's £10 in our envelope (A):

Expected value in B = 1/2 ( (Expected value in B, given 10 is larger than B) + (Expected value in B, given 10 is smaller than B) )

So plug in the expected values, given that A is 10:

Expected value in B = 1/2 (5 + 20)

This can't be written as B = 1/2 (x + 2x) without conflating different values of x.
Snakes Alive July 03, 2018 at 21:37 ¶ #193524
Reply to Michael We've already been over all this, I'm afraid. We would need a new way of looking at things to move forward, and this doesn't provide it.
andrewk July 03, 2018 at 22:05 ¶ #193531
Quoting Srap Tasmaner
(3) Michael and @andrewk have part of the right analysis, but something more is needed.

Quoting Andrew M
I disagree that the 50% chance can be assumed. If the sample space is finite, then there is a non-zero chance that the $10 amount is the maximum amount.

I agree with both of these. The point about the maximum possible amount has been made before, but has been lost in the length of the thread. I mentioned it somewhere early on, and in the interests of simplicity, declined to probe further because (1) I thought digging into it would have required some fancy notation like integral signs, and I couldn't remember how to invoke latex on this site (Edit: I see from the above that Michael has mastered it) and (2) I was pretty confident it would not make a material difference.

But given the continuing uncertainty I'll have a go. If nothing else, it should be able to bring out the intrinsically Bayesian nature of the calculation, which I think is camouflaged in the simplified versions discussed so far. Explicitly recognising a maximum possible value of X is part of recognising a prior distribution for X, that is then used in a Bayesian calculation.

I'll revert if I can either get latex to work, or manage to write the full-Bayesian calc without it.
Michael July 03, 2018 at 22:12 ¶ #193533
Quoting andrewk
I thought digging into it would have required some fancy notation like integral signs, and I couldn't remember how to invoke latex on this site (Edit: I see from the above that Michael has mastered it)


Ironically, I coped your code from here and amended it as required.
Srap Tasmaner July 03, 2018 at 22:18 ¶ #193535
Quoting andrewk
The point about the maximum possible amount has been made before, but has been lost in the length of the thread. I mentioned it somewhere early on, and in the interests of simplicity, declined to probe further because (1) I thought digging into it would have required some fancy notation like integral signs, and I couldn't remember how to invoke latex on this site and (2) I was pretty confident it would not make a material difference.


And I asked you last night about the minimum possible value of X. Your response then was that what matters is not what might or might not be put in the envelope, but whether you the player have reason to exclude a given value.
Srap Tasmaner July 03, 2018 at 22:23 ¶ #193537
Quoting Michael
This can't be written as B = 1/2 (x + 2x) without conflating different values of x.


You just write it as [math]\small B = \cfrac{\cfrac{y}{2} + 2y}{2}[/math].

[math]\small y[/math] is whatever's in the envelope in your hand, whether you've looked at it or not. Looking makes no difference.
Jeremiah July 03, 2018 at 22:25 ¶ #193538
Reply to Michael

Feigning ignorance does not resolve the conflict. As I have said many times over, the sample space of the other envelope is [X,2X]. That is not that hard to grasp, and since I don't believe you are an idiot, I am forced to conclude you feigning ignorance as a way to avoid this conflict.


Let's review some definitions here:

If A and B are sets, then A is called a subset of B if, and only if, every element of A is also an element of B.


A sample space is the set of all possible outcomes of a random process or experiment. An event is a subset of a sample space.


Discrete Mathematics, An Introduction to Mathematical Reasoning, By Susanna S. Epp

Do you understand that these are not my definitions? They are established definitions that may be used in formal proofs.

Let's call the two envelopes A and B. Now envelope A could have X or A could have 2X and likewise B could have X or B could have 2X. Those are all the possible outcomes so by the definition of a sample space our sample space is [A,B] where A is the set [X,2X] and B is the set [X,2X], which means our sample space could also be written as [[X,2X],[X,2X]].

Did you follow that? They are sets in a set. In this case the elements of our sample space are the set [X, 2X]. So that means since your proposed solution does not follow the format of [X,2X] then, by the definition of a subset, it cannot be a subset of either A or B.
Michael July 03, 2018 at 22:28 ¶ #193539
Quoting Srap Tasmaner
You just write it as [math]\small B = \cfrac{\cfrac{y}{2} + 2y}{2}[/math].

[math]\small y[/math] is whatever's in the envelope in your hand.


Yeah, which is [math]\small B = \cfrac{\cfrac{10}{2} + 2*10}{2} = 12.5[/math], hence the .25 gain.
Michael July 03, 2018 at 22:32 ¶ #193540
Quoting Jeremiah
As I have said many times over, the sample space of the other envelope is [X,2X].


And there's £10 in my envelope. So what are the possible values of X where the sample space of the other envelope is [X, 2X]? It can't be 10, because 10 can't be in the sample space of the other envelope, and it can't be 5 because 10 can't be in the sample space of the other envelope.

Given that there's £10 in my envelope, then the sample space of the other envelope must be [5, 20], which means that it isn't [X, 2X]. It must be [Y/2, 2Y].
Jeremiah July 03, 2018 at 22:33 ¶ #193541
Reply to Michael


Your sample space becomes:

[[10=X,10=2X],[10=X,10=2X]].

Edit* This post contains an error see the next page for clarification.
Srap Tasmaner July 03, 2018 at 22:34 ¶ #193542
Quoting Michael
[Y, Y/2].


That's [math]\small \{ \cfrac{y}{2},2y\}[/math].
Michael July 03, 2018 at 22:35 ¶ #193543
Reply to Srap Tasmaner Yes, sorry, typo.
Michael July 03, 2018 at 22:45 ¶ #193548
Quoting Jeremiah
Your sample space becomes:

[[10=X,10=2X],[10=X,10=2X]].


Remember what you said earlier:

Quoting Jeremiah
Therefore your sample space could never be [5,20], as it does not follow the form of [X, 2X]. Your sample space could be [5,10] or [10,20] but there is no way you can mathematically justify a sample space of [5,20] as it is not consistent with [X,2X].


Now look how you've contradicted yourself. Because a), in using [10=X,10=2X] you have different values of X, and b) in using [10=X,10=2X] you entail that the other envelope must be [5, 20], given that my [10=X,10=2X] envelope is 10.
Jeremiah July 03, 2018 at 22:57 ¶ #193552
Reply to Michael

Ya, jumped the gun there and made a mistake myself (unlike you I am able to admit that). However, if you going to use my argument to justify your position, my argument, that you referenced there, still completely counters your statement of [5,20] and proves you 100% wrong. By using my argument as proof you have just admitted that you are wrong.

The sample space still would be [[X,2X],[X,2X]].

Which would be consistent with what I said here:

Quoting Jeremiah
Intuitively this seems like new information which would call for you to update your prior; however, it still does not tell you if are you in case R or case S. You don't know if that is 10=X or 10=2X. So in truth you can't really update your prior, as your prior was based on the uncertainty of being in case R or case S.





Michael July 03, 2018 at 22:57 ¶ #193553
Quoting Jeremiah
Ya, jumped the gun there and made a mistake myself (unlike you I am able to admit that). However, if you going to use my argument to justify your position, my argument, that you referenced there, still completely counters your statement of [5,20] and proves you 100% wrong. By using my argument as proof you have just admitted that you are wrong.


I'm saying you contradicted yourself, not that your latest (or first) argument is right.
Jeremiah July 03, 2018 at 22:59 ¶ #193554
Reply to Michael

I already admitted to the mistake, then corrected my position. You just get into rapid fire mode and you miss half of what is being said.
Jeremiah July 03, 2018 at 23:03 ¶ #193555
Reply to Michael

This right here does not go away simply because I miss defined a sample space in a different post. This is still true and proves you wrong. It is still something you have yet to actually address.

Quoting Jeremiah
Let's review some definitions here:

If A and B are sets, then A is called a subset of B if, and only if, every element of A is also an element of B.

A sample space is the set of all possible outcomes of a random process or experiment. An event is a subset of a sample space.

Discrete Mathematics, An Introduction to Mathematical Reasoning, By Susanna S. Epp

Do you understand that these are not my definitions? They are established definitions that may be used in formal proofs.

Let's call the two envelopes A and B. Now envelope A could have X or A could have 2X and likewise B could have X or B could have 2X. Those are all the possible outcomes so by the definition of a sample space our sample space is [A,B] where A is the set [X,2X] and B is the set [X,2X], which means our sample space could also be written as [[X,2X],[X,2X]].

Did you follow that? They are sets in a set. In this case the elements of our sample space are the set [X, 2X]. So that means since your proposed solution does not follow the format of [X,2X] then, by the definition of a subset, it cannot be a subset of either A or B.


andrewk July 03, 2018 at 23:03 ¶ #193556
Quoting Srap Tasmaner
And I asked you last night about the minimum possible value of X. Your response then was that what matters is not what might or might not be put in the envelope, but whether you the player have reason to exclude a given value.

Are you sure that was me? It doesn't sound familiar, but maybe I've just forgotten. Can you link the exchange?

FWIW I'm imagining X can be any real number above zero, so there is no minimum value. In order to make that possible, the envelope has to contain an IOU to the value of some real number, not notes and coins, otherwise the min poss value is one penny.

My attempted full Bayesian calc is surprising so far. Assuming a prior distribution for X of uniform on (0,L] for some large L, I'm getting an expected gain from switching, given an observation of y in the envelope, of (5/8)y, which is more than the y/4 from previous calculations. Needless to say, I'm reviewing it fairly critically.
Srap Tasmaner July 03, 2018 at 23:06 ¶ #193557
Quoting andrewk
Are you sure that was me? It doesn't sound familiar, but maybe I've just forgotten. Can you link the exchange?


Quoting Srap Tasmaner
What in the rules of the game or in the knowledge you have acquired (i.e., that Y = 10) assures you that the games mistress includes both 5 and 10 in the sample space for X? Maybe a tenner is the smallest bill she has.


Quoting andrewk
It's not about the games mistress's sample space. She doesn't have one. She has two amounts that she has always intended to put into the envelopes. It's about my sample space, which consists of the events that I cannot rule out based on my knowledge to date.

That knowledge - based on seeing 10 in my envelope - allows me to rule out every other event (an event being a particular sum being in the other envelope) except for 5 and 20. So that's my sample space - just two events.


Michael July 03, 2018 at 23:14 ¶ #193559
Quoting Jeremiah
Let's call the two envelopes A and B. Now envelope A could have X or A could have 2X and likewise B could have X or B could have 2X. Those are all the possible outcomes so by the definition of a sample space our sample space is [A,B] where A is the set [X,2X] and B is the set [X,2X], which means our sample space could also be written as [[X,2X],[X,2X]].


Then we have:

1. My envelope could be envelope X
2. My envelope could be envelope 2X
3. My envelope contains £10.
4. From 1 and 3, the other envelope could be envelope 2X and contain £20
5. From 2 and 3, the other envelope could be envelope X and contain £5

This is valid.

And just as we can model my envelope using the sample space [X, 2X], despite the fact that in doing so we're positing two different possible values of X (either 10 or 5), we can also model the other envelope using the sample space [X, 2X], despite the fact that in doing so we're positing two different possible values of X (either 5 or 10).
Snakes Alive July 03, 2018 at 23:20 ¶ #193564
Quoting Michael
we can also model the other envelope using the sample space [X, 2X], despite the fact that in doing so we're positing two different possible values of X (either 5 or 10).


Ah, but that's exactly what we can't do. This was the original fallacy (back in my first post).
Michael July 03, 2018 at 23:22 ¶ #193566
Quoting Snakes Alive
Ah, but that's exactly what we can't do.


This is valid and the first three premises are true.

1. My envelope could be envelope X
2. My envelope could be envelope 2X
3. My envelope contains £10
4. From 1 and 3, the other envelope could be envelope 2X and contain £20
5. From 2 and 3, the other envelope could be envelope X and contain £5
Snakes Alive July 03, 2018 at 23:24 ¶ #193567
Reply to Michael Still not getting it.
Snakes Alive July 03, 2018 at 23:28 ¶ #193569
Modeling the sample space as [X, 2X] where X changes values doesn't work. This is because, although you don't know which value X is, you do know that the metaphysically possible outcomes relative to which you have to aggregate to determine your average expected winnings do not have different values for X. To say that you might have 5 or 20 in the other envelope is the same as to say that you might have drawn X or 2X. Your mistake is reifying the amount you've drawn into a new amount, compared to which you can average your expected winnings across two situations. This absurdly commits you to the possibility that it is possible that X has two values (not that there are two possible values that X could be epistemically, which is already recorded by your ignorance of whether you've drawn X or 2X).
Michael July 03, 2018 at 23:41 ¶ #193572
Quoting Snakes Alive
To say that you might have 5 or 20 in the other envelope...


Which is all I'm saying.

My envelope has £10, so:

1. If my envelope is envelope X then the other envelope is envelope 2X and has £20.
2. If my envelope is envelope 2X then the other envelope is envelope X and has £5.

Given each antecedent is equally likely (and the only options), each consequent is equally likely (and the only options). Therefore my sample space for the other envelope is [£5, £20].
Snakes Alive July 03, 2018 at 23:44 ¶ #193574
Reply to Michael It can't be, since neither 5 nor 20 is half the other. Therefore this is not a possible sample space (as said above).

Your error is switching the value of X between situations over which you average. This can't be, since there is some value X determined by the envelopes: it is therefore not possible to average possible outcomes over two distinct values for X. It is "epistemically possible" that the other envelope has 5 or 20, but your knowledge that the value of X is fixed prevents you from averaging over the distinct values in this way, because the real outcomes over which you average in making your decision are to switch or not to switch, and your switching or not cannot change the value of X. You're confusing two epistemic possibilities with the possibilities over which your calculation ought to range.
Srap Tasmaner July 04, 2018 at 00:01 ¶ #193579
Reply to Snakes Alive
The idea is this:

You begin knowing only that one of the envelopes on offer is worth twice the other.

Upon drawing an envelope, if you designate its value ('Y'), or learn its value (£10), you have learned that the the pair of envelopes on offer included one of value Y. You do not know whether Y = X or Y = 2X.

Thus there are two possible candidate pairs of envelopes: [Y/2, Y], and [Y, 2Y].

Now your uncertainty is not which of the envelopes originally in front of you was larger, but which pair of envelopes you picked an envelope of value Y from.

(You start thinking you'll get either the larger or the smaller of the pair in front of you. Once you've drawn, you imagine the smaller possibility as the larger of a smaller pair of envelopes, and similarly the larger becomes the smaller of a larger pair of envelopes.)

If you designate the unpicked envelope's value as Z, there are two possible systems of linear equations:

[math]\small 3x - y - z = 0[/math]
[math]\small \phantom{3x-} \frac{1}{2}y - z = 0[/math]

and

[math]\small 3x - y - z = 0[/math]
[math]\small \phantom{3x -}2y - z = 0[/math]

It's all perfectly consistent. In the first you find that Z = X, and Y = 2X. (This is the smaller pair and the envelope you drew is the bigger there.) In the second, Z = 2X, and Y = X. (This is the bigger pair, and your envelope is the smaller.)

Snakes Alive July 04, 2018 at 00:06 ¶ #193580
Reply to Srap Tasmaner Yeah, we've covered all this already. The pro-switcher posts are saying the same thing over and over.
Jeremiah July 04, 2018 at 00:10 ¶ #193582
Reply to Michael

What you are saying is the equivalence of suggesting 2+2 =5. You can't setp outside the definitions simply because they are an inconvenience you, as then you are no longer doing math.

You need to follow the same steps, list all the possible outcomes and stick with the definitions.

Now let's work through this:

Remember the definition of our sample space is [A,B] where A is the set [X,2X] and B is the set [X,2X]. We'll call this sample space 1.

You open A and it has 10 bucks, but you don't know if that is 10=X or 10=2X so A is still defined as [X,2X]. If A is X then B is 2X and if A is 2X then B has to be X. So B is still defined as [X,2X]. That part remains the same.

So we have two cases here and have no clue which one we are in. Earlier I defined these cases as amount X case R, and and amount 2X case S. We have a lot of variables flying around so let's try to be consistent here.

Now that we have listed all possible outcomes we can define our sample space as [R,S], well call this sample space 2.

Now remember by our definitions an event is a subset of our sample space.

In event R X=10 and since in event R B must be 2X then B = 20.

So the sample space of event R is [10,20].

In event S 10=2X and since in event S B must be X then B= 5.

So the sample space of event S is [5,10]. (order does not matter)

So our sample space, which we named as sample space 2, is [R,S] where R is the set [10,20] and S is the set [5,10] or we can express it as [[10,20],[5,10]]


This is no different than any other math, we need to break it down and follow it step by step.



Michael July 04, 2018 at 00:13 ¶ #193584
Quoting Snakes Alive
It can't be, since neither 5 nor 20 is half the other. Therefore this is not a possible sample space (as said above).


The sample space is the set of all possible outcomes. If there's £10 in my envelope then there are only two possible outcomes; either the other envelope contains £5 or the other envelope contains £20. So the sample space of the other envelope, given my envelope of £10, is [£5, £20]. This assertion that the sample space of the other envelope must have one value twice as big as the other is false.

The problem is that you're making this argument, where the value of X is fixed, and concluding that the sample space of the other envelope is [X, 2X] with a fixed value of X:

1. If my envelope is envelope X then the other envelope is envelope 2X
2. If my envelope is envelope 2X then the other envelope is envelope X

But this is incompatible with our third premise (which I brought up before):

3. My envelope contains £10.

If my envelope contains £10 then the X in "my envelope is envelope X" is 10 and the X in "my envelope is envelope 2X" is 5.

Quoting Snakes Alive
Your error is switching the value of X between situations over which you average. This can't be, since there is some value X determined by the envelopes: it is therefore not possible to average possible outcomes over two distinct values for X. It is "epistemically possible" that the other envelope has 5 or 20, but your knowledge that the value of X is fixed prevents you from averaging over the distinct values in this way, because the real outcomes over which you average in making your decision are to switch or not to switch, and your switching or not cannot change the value of X. You're confusing two epistemic possibilities with the possibilities over which your calculation ought to range.


I don't know why you keep bringing up averages.
Snakes Alive July 04, 2018 at 00:15 ¶ #193585
Quoting Michael
I don't know why you keep bringing up averages.


The way that you determine whether a move is worth taking is by calculating the average expected gain from making that move.
Michael July 04, 2018 at 00:18 ¶ #193586
Quoting Jeremiah
You open A and it has 10 bucks, but you don't know if that is 10=X or 10=2X so A is still defined as [X,2X]

If A is X then B is 2X and if A is 2X then B has to be X.

So B is still defined as [X,2X].


If A is X and A is 10 then B is 20. If A is 2X and A is 10 then B has to be 5.

Can B still be defined as [X, 2X]?

Either way it has to be defined as [5, 20].
Snakes Alive July 04, 2018 at 00:22 ¶ #193588
Another angle:

Suppose A is a switcher: he always picks one envelope to see, and then chooses the other to claim.

Suppose B is a stayer: he always picks one envelope, and then claims it.

For both A and B, which envelope they take is determined by which one they pick to see. Therefore, both A and B have two moves available: pick envelope 1 (A does this by choosing 2 to see, B by choosing 1 to see), or pick envelope 2 (done mutatis mutandis).

Therefore, the exact same moves are available to A and B, and they can both be commanded to do the exact same move given a random sample of pairs of envelopes.

According to the switching advocate, A's strategy is superior, despite performing the very same move in each case as B. This is absurd.
Jeremiah July 04, 2018 at 00:23 ¶ #193589
Quoting Michael
Can B still be defined as [X, 2X]?


Your possible outcomes for A is 2X or X. In the outcome that A=X then B=2X, in the outcome that A=2X then B=X. So yes, it seems, B has two possible outcome of either X or 2X.
Michael July 04, 2018 at 00:25 ¶ #193590
Quoting Jeremiah
Your possible outcomes for A is 2X or X. In the outcome that A=X then B=2X, in the outcome that A=2X then B=X. So yes, it seems, B has two possible outcome of either X or 2X


And did you read the rest?

If A is X and A is 10 then B is 20. If A is 2X and A is 10 then B has to be 5.

Therefore B has to be defined as [5, 20].
Snakes Alive July 04, 2018 at 00:25 ¶ #193591
Another way of putting this is that the strategy of switching, and of staying, are the exact same strategy. In each case, one simply picks one of the two envelopes to open. Seeing what is in one of the envelopes is simply a red herring: even on the switcher's account (since we ought to switch no matter what the value seen is), it does nothing.

There are in fact no two distinct strategies at all. Therefore, it is absurd to claim that one is superior, since they are identical.
Jeremiah July 04, 2018 at 00:30 ¶ #193592
Reply to Michael

Did you read the rest of my post?

Quoting Jeremiah
So we have two cases here and have no clue which one we are in. Earlier I defined these cases as amount X case R, and and amount 2X case S. We have a lot of variables flying around so let's try to be consistent here.

Now that we have listed all possible outcomes we can define our sample space as [R,S], well call this sample space 2.

Now remember by our definitions an event is a subset of our sample space.

In event R X=10 and since in event R B must be 2X then B = 20.

So the sample space of event R is [10,20].

In event S 10=2X and since in event S B must be X then B= 5.

So the sample space of event S is [5,10]. (order does not matter)

So our sample space, which we named as sample space 2, is [R,S] where R is the set [10,20] and S is the set [5,10] or we can express it as [[10,20],[5,10]]


The math definitively proves you wrong. This is not a matter of opinion, you are just flat out wrong.
Jeremiah July 04, 2018 at 00:31 ¶ #193593
I don't know why I waste my education and time.
Michael July 04, 2018 at 06:34 ¶ #193679
Quoting Jeremiah
Did you read the rest of my post?


Yes. You said:

1. A is 10.
2. If A is X then B is 2X
3. If A is 2X then B is X.
4. The sample space for B is [X, 2X]

But you're conflating different values of X:

1. A is 10
2. If A is X then B is 2X, where X = 10
3. If A is 2X then B is X, where X = 5
4. The sample space for B is [X where X = 5, 2X where X = 10]

One element is four times as big as the other. It's a sample space of [5, 20].
Jeremiah July 04, 2018 at 06:57 ¶ #193687
Quoting Michael
But you're conflating different values of X:


No, that is what you are doing. You can't just drop the 10, it is still a possible outcome, as you don't know which 10 you are in. The sample space is [[10,20],[5,10]]. How are you eliminating both 10s and combining the two sets? You have to mathematically justify all of this.
Michael July 04, 2018 at 07:13 ¶ #193695
I drop 10 because it’s in my envelope. Therefore it cannot be in the other envelope.
Jeremiah July 04, 2018 at 07:18 ¶ #193701
Reply to Michael Which 10 are you dropping 10=X or 10=2X? Also like I said I want to see the math.
Michael July 04, 2018 at 07:24 ¶ #193703
I’m not dropping either of those. I’m dropping 10 as an outcome for the other envelope given that it’s in mine.

I’m saying that if 10 = X then the other (2X) envelope contains £20 and if 10 = 2X then the other (X) envelope contains £5.

If my envelope contains £10 then the other envelope contains either £5 or £20.
Jeremiah July 04, 2018 at 07:26 ¶ #193704
Reply to Michael

The sample space is [[10,20],[5,10]]. Notice how there are two 10s. Now show me the math which allows you to eliminate both of them.
andrewk July 04, 2018 at 07:39 ¶ #193705
Reply to Srap Tasmaner I'm still not sure I understand your question. You've asked about the minimum possible value of X. Do you mean the minimum that I think is possible for X, given that I've just observed Y in the envelope? That minimum is Y/2.

Or do you mean the minimum amount I could imagine having been chosen for X, without my having opened the envelope? I'm pretty sure I already answered that (but the answer has been buried somewhere amongst all the posts since then), and said that the amount cannot be zero or less, so there is no minimum, but 0 is the infimum.

If you mean something other than that, can you clarify and I'll try to answer it? Thanks.

In the meantime, I'm finding some interesting things with my Bayesian calcs, but the answers keep on changing - probably cos I'm scribbling it on scrappy bits of paper, in between meetings, and I keep losing them. Hopefully I'll come up with something coherent and stable and can report it here.
Srap Tasmaner July 04, 2018 at 12:55 ¶ #193778
You are shown two envelopes and told one is twice the value of the other. You are then offered the following choice: you may

(a) choose one envelope and keep its contents; or
(b) take both envelopes, open neither, and give back one of your choosing; or
(c) take both envelopes, open one of your choosing, and give back either the unopened envelope or the contents of the one you opened.

If X is the smaller of the two envelope values, your expected gain is 3X/2, no matter which of these procedures you follow.
andrewk July 06, 2018 at 10:16 ¶ #194309
I've finally found time to work out my full Bayesian analysis of the problem. For those that are interested, it is here. Non-Bayesians may not like it, because it takes the standard Bayesian approach of using a probabilistic distribution for unknown parameters, even when the person setting the parameter did not do so probabilitistically. But if we reject that approach we'll have to reject an enormous part of modern statistical techniques.

The essence is that the information gained by looking at the amount in the envelope allows one to refine one's prior distribution for the possible values of X - the lower of the two amounts. When the observed amount is low the expected gain will be positive and when it is high it will be negative. The note shows how to calculate these expectations based on the prior distribution adopted for X.

In the simplest case, where our prior for X is a uniform distribution on (0,L], where we might choose L as say half the entire budget of the game show, the result is that we should not switch if the observed amount y is greater than L, because it must be the doubled amount. But otherwise we should switch, and the expected gain from doing so is y/2. This is greater than the y/4 expected gain that was discussed above. I think that may have something to do with the fact that we remove the losses that would occur from switching when y>L, thereby increasing the expected gains when we do switch.

I will include some graphs I made if I can work out a way to get latex to cooperate on that. It worked last time I tried that, but not today.
Any observations or comments, @Michael? @Srap Tasmaner?
Srap Tasmaner July 06, 2018 at 18:45 ¶ #194374
Reply to andrewk
I looked at your work, but I only really followed page 1 — I'm learning as I go here.

I take it you're just trying to apply known techniques to the problem as presented, as if we don't know the right answer. I'll be curious to see how that comes out, but it's not how I understand our situation.

Here is my understanding of the issue (using X, Y, and U as you do). There are two natural ways to calculate the expected value of switching:

(a) E(U - Y) = P(Y = X)(2X - X) + P(Y = 2X)(X - 2X) = X/2 - X/2 = 0

(b) E(U - Y) = P(Y = X)(2Y - Y) + P(Y = 2X)(Y/2 - Y) = Y/2 - Y/4 =Y/4

There are two questions:

(Q1) Why do the two methods (a) and (b) give different results?
(Q2) Why does method (a) give the right answer and method (b) the wrong answer?

I tried fooling around with pre-labeling the envelopes L and R, so that we have two sample spaces, one for the loading of the envelopes [L = 2R, R = 2L] and one for our choice [Y = L, Y = R]. Removes a little ambiguity but that's about it. (For instance, instead of just saying P(Y = 2X) = 1/2, we can P(Y = L)P(L = 2R) + P(Y = R)P(R = 2L) = 1/2.) So far it just gives me new ways of fleshing out method (a). I can work through this and find no way of producing the method (b) approach, but I don't think it solves the puzzle just to say, "Doing it the right way avoids doing it the wrong way." The whole point is to figure out exactly what's wrong with the wrong way. Why doesn't it reduce to doing it the right way?

Edit: typo in (b).
andrewk July 06, 2018 at 21:18 ¶ #194400
Reply to Srap Tasmaner The difference between these two is not mysterious. Calculation (a) is done from the point of view of the game host, who knows the value of X, and so can treat it as a constant. In this problem X is known and Y is unknown.

Calculation (b) is done from the point of view of the player, for whom X is an unknown, and hence must be treated as a random variable, if any calculation is to be done at all. In this problem Y is known and X is unknown. It's in a sense the reverse (a).

The calculations give different answers because they are different probabilistic scenarios - just as your calculation on the outcome of a coin I toss will be different from the calc I do when I've already looked at the toss result.

Each calc is correct for the perspective to which it pertains.

I'll have another go at inserting the graphs today.
Srap Tasmaner July 06, 2018 at 22:28 ¶ #194418
Reply to andrewk
No.

I think it's debatable whether anyone needs to "know" the amounts in the envelopes for the [x,2x] approach to work. If a machine sets the values, you'll be saying we have probabilities "from its point of view". And, okay, whatever, but we're just making the terminology fit now; there's no epistemic situation for the machine, or not one we're interested in.

More importantly, the value of the selected envelope need not be known to you the agent. Simply designating whatever as Y and then doing your calculations in terms of Y is enough to get absurdity. (If you condition your choice on expected value, you end up in an endless loop.)

And furthermore everyone knows the two envelopes have the same expected value and switching is a pointless strategy.
andrewk July 07, 2018 at 00:15 ¶ #194455
Quoting Srap Tasmaner
Simply designating whatever as Y and then doing your calculations in terms of Y is enough to get absurdity.

I haven't seen any genuine absurdities in the thread so far. Assertions of absurdity, yes, but not real ones.

In general, it's best to avoid arguments based on 'absurdity'. If we did that, we wouldn't have quantum mechanics, and so no computers. Best stick to 'contradiction' as the grounds for rejecting a premise.

I have a particularly strong aversion to arguments based on absurdity because they are beloved of Christian fundamentalist apologists like William Craig, who argue that 'absurdities' - by which they just mean something a bit surprising - arise from not believing the fundamentalist dogma. Which is no reason for us to adopt their dogma, because the world is a very surprising place.
Quoting Srap Tasmaner
More importantly, the value of the selected envelope need not be known to you the agent.

If we don't open the envelope then the calculation is completely different and in this case only coincidentally gives the same result. This is what is called a Numéraire issue. Changing the numéraire in terms of which a profit is calculated can create a profit out of nothing, or reduce a profit to zero. This is an important principle in derivative pricing.

Say I buy a (troy) ounce of gold for $1000, the price then goes up to $2000 per ounce. In dollars I have made $1000 profit, but in ounces of gold I have made no profit, because I had 1 oz before and I still have 1 oz. I can convert that zero ounces profit to dollars by multiplying by the gold price of $2000/oz, and I still get $0. How can my profit be both $1000 and $0? Because the two calculations use different numéraires, so they are fundamentally fdifferent calculations. Conversely, If I put the $1000 in bank account and earn $1 interest while the price of gold goes from $1000 up to $2000. Then with dollars as a numéraire my profit is $1 but with oz of gold as numéraire I have gone from 1 oz equiv to $1001/2000 $/oz = 0.5005 oz, so I've made a loss of 0.4995 oz, which is equivalent to $999.

The moral is - changing numéraire can change the answer, even if you subsequently convert the result back into the units of the original numéraire. When you open the envelope and look at what's inside, your numéraire is dollars. When you don't open it your numéraire is 'value of contents of the first envelope', ie Y. So it's a different calculation that can validly have a different result.

There's another numéraire we can use, which is X, the unknown amount of the lower-valued IOU. Using that as numéraire, the expected gain is zero, whereas when we use dollars as a numéraire, the expected gain is positive.

BrianW July 07, 2018 at 00:46 ¶ #194461
I would return the envelope and pick the other. Whether I get more or less, at least, I would have eliminated curiosity because there would be no more uncertainty.
Jeremiah July 07, 2018 at 00:46 ¶ #194462
Quoting Srap Tasmaner
I'm learning as I go here.


These are the lecture notes from one of my professors, which should give you some idea of what Bayesian statistics is suppose to look like.

http://www.math.montana.edu/ahoegh/teaching/stat491/notes/index.html




Srap Tasmaner July 07, 2018 at 00:51 ¶ #194464
Quoting andrewk
When you open the envelope and look at what's inside, your numéraire is dollars. When you don't open it your numéraire is 'value of contents of the first envelope', ie Y. So it's a different calculation that can validly have a different result.


I'm still not seeing it. We've done to death the example of finding £10 and you calculate an expected gain of £2.50. Or you can do a generic calculation and show an expected gain of £Y/4, for any value of Y.

Quoting andrewk
In general, it's best to avoid arguments based on 'absurdity


Then let's go with "inconsistency": given such a pair of envelopes, you can readily construct a pair of arguments that tell you each has a higher expected value than the other. I would prefer finding that such arguments are invalid.
Srap Tasmaner July 07, 2018 at 00:51 ¶ #194465
Reply to Jeremiah
Cool, thanks.
andrewk July 07, 2018 at 02:46 ¶ #194487
Quoting Srap Tasmaner
Then let's go with "inconsistency": given such a pair of envelopes, you can readily construct a pair of arguments that tell you each has a higher expected value than the other. I would prefer finding that such arguments are invalid.

Those results are both correct, and it's because each is done from the point of view of observing that envelope - two opposite points of view. It's analogous to how two spaceships travelling at half the speed of light relative to one another both measure time as going more slowly in the other spaceship. That 'feels' inconsistent but when you dig into it, trying to locate and fix the inconsistency, you find there isn't one.
Quoting Srap Tasmaner
I'm still not seeing it. We've done to death the example of finding £10 and you calculate an expected gain of £2.50. Or you can do a generic calculation and show an expected gain of £Y/4, for any value of Y.

That's right, in this case using either dollars or the value of Y as numéraire gives the same result - an expected gain equal to Y/4. That's why I said 'can' rather than 'does'. But using X as numéraire gives a different result - an expected gain of zero. It really is worth spending the time to come to grips with the numéraire concept. It has many more important applications than just in probability.

Also, the Bayesian calculation now has the graphs in. I think they look rather nice.

Snakes Alive July 07, 2018 at 03:42 ¶ #194496
You can't use Y as a value defined independently of X and average across possibilities using that value.
Srap Tasmaner July 07, 2018 at 04:01 ¶ #194509
Quoting Snakes Alive
You can't use Y as a value defined independently of X


Something is wrong with the way Y is being used, clearly, but I'm not sure this is it. You can get the (b) method out of the (a) method just by substituting the possible value of Y in terms of X. (And you can fix (b), if you start mistakenly there, by substituting to get (a).)
Snakes Alive July 07, 2018 at 04:17 ¶ #194511
Reply to Srap Tasmaner Yeah, I realized this after writing my original post, but I don't have a good way to exposit the issue. I suspect that epistemic and metaphysical possibilities are being confused in some inappropriate way.

That is, given some fixed value of X (and we know there to be some such), it is not metaphysically possible for the unopened envelope to be 'either 5 or 20' (read as an exhaustive disjunction), since neither of these is twice the other (and so this is inconsistent with what we know to be metaphysically so, that the unopened envelope is either X or 2X, for some X, while 5 and 20 are not X and 2X for any X), and so our knowledge of the situation should bar this space of possibilities, since our knowledge that this is metaphysically impossible should rule out our averaging over this epistemic space as regards our outcomes.
andrewk July 07, 2018 at 04:55 ¶ #194520
Quoting Snakes Alive
it is not metaphysically possible for the unopened envelope to be 'either 5 or 20' (read as an exhaustive disjunction), since neither of these is twice the other (

Can you justify that 'since'? There is no justification provided in the sentence in which it occurs, because the words following it have no logical relation to the words before it. It sounds like you're saying that, having observed 10 in the envelope, you now believe that the other envelope might contain some amount other than 5 or 20. If that's not what you're saying, what are you saying?

Also, what is 'metaphysically possible' and how does that differ from 'possible'?
andrewk July 07, 2018 at 07:26 ¶ #194539
Quoting Snakes Alive
You can't use Y as a value defined independently of X and average across possibilities using that value.

We agree on that. Y and X are interdependent. That's why I define Y as

[math]\quad\quad\quad\quad\quad Y = X\cdot (1+B)[/math]

where B is a Bernoulli random variable with probability 0.5, that is independent of X. B is independent of X, but Y is not.
Snakes Alive July 07, 2018 at 07:27 ¶ #194540
Quoting andrewk
It sounds like you're saying that, having observed 10 in the envelope, you now believe that the other envelope might contain some amount other than 5 or 20.


No. The point is that it is not a possibility that the exhaustive disjunctive possibilities of what's contained in the other envelope are 5 and 20. This is because it's known already that for some X, the amount in the other envelope is X or 2X. But 5 and 20 are not X and 2X for any value of X. Thus it cannot be that the exhaustive disjunctive possibilities are these, and cannot be that in determining the average expected value of switching, we average across those possibilities, since our knowledge state rules out this way of setting things up.
Snakes Alive July 07, 2018 at 07:29 ¶ #194541
Reply to andrewk If you define Y in this way, then there are two possible states: you have drawn X (where B = 0), or you have drawn 2X (where B = 1). Now eliminate the Y altogether, do the calculation, and you'll see that your expected value is 1.5X regardless of whether you switch or not.
andrewk July 07, 2018 at 07:30 ¶ #194542
Quoting Snakes Alive
The point is that it is not a possibility that the exhaustive disjunctive possibilities of what's contained in the other envelope are 5 and 20.

What do you mean by 'exhaustive disjunctive possibilities'?
Quoting Snakes Alive
it's known already that for some X, the amount in the other envelope is X or 2X. But 5 and 20 are not X and 2X for any value of X
That's all correct, but is not inconsistent with my note. Nowhere does it say that 5 and 20 are X and 2X, given we have seen that Y=10. Rather, we know that X is either 5 or 10, so either

  • we have X in the envelope we opened, so that X = Y = 10; OR
  • X is in the other envelope, so we have Y = 2X = 10 and X=5 is in the other envelope.



Snakes Alive July 07, 2018 at 07:35 ¶ #194544
Quoting andrewk
What do you mean by 'exhaustive disjunctive possibilities'?


Exhaustive disjunctive possibilities are those that are mutually exclusive and jointly exhaustive, viz. those that form a partition over the space of possible outcomes.

Quoting andrewk
That's all correct, but is not inconsistent with my note. Nowhere does it say that 5 and 20 are X and 2X, given we have seen that Y=10. Rather, we know that X is either 5 or 10, so either

we have X in the envelope we opened, so that X = Y = 10; OR
X is in the other envelope, so we have Y = 2X = 10 and X=5 is in the other envelope.


No, this doesn't work. If you define Y in terms of X, then everything you write with Y can (must) be rewritten in terms of X. Do this and the illusion that Y is a value you can average over multiple situations disappears. You are acting like Y is some other value that you can now double or half in terms of what you draw. But it is not: it is, for some fixed X, either X or 2X. It follows that whatever the hidden amount is, the two possibilities over which we average must be such that one is double the other. 5, 20 violates this and so cannot be what we average over – it is not consistent with the way the problem is set up, because we know there is some value of X fixed at the time of the choosing of the two envelopes, and the only possibilities are that the hidden amount is either X or 2X, regardless of what amount you look at in one envelope. The fact that you even see one envelope at all is a complete red herring, only thrown into the problem to seduce you into making this very fallacy.
andrewk July 07, 2018 at 07:37 ¶ #194545
Quoting Snakes Alive
Now eliminate the Y altogether, do the calculation, and you'll see that your expected value is 1.5X regardless of whether you switch or not.

Quoting Snakes Alive
If you define Y in terms of X, then everything you write with Y can (must) be rewritten in terms of X.

Eliminating Y is making X the numéraire. That's why you need to address the numéraire issue, as explained in this post. When we use X as numéraire, the expected gain from switching is zero units of X, but when the numéraire is dollars, it is a gain.
Snakes Alive July 07, 2018 at 07:40 ¶ #194547
Reply to andrewk You can't use dollars in that way.

You've agreed that Y must be defined in terms of X. X is fixed. Therefore, Y = 2X, or Y = X. It simply doesn't matter what the dollar value of Y is. What you want to do is on the one hand agree that Y is defined in terms of X, and agree that there is some fixed value of X, such that X and 2X are the values of the envelopes, and calculate expected utility solely in reference to Y (a dollar amount) not expressed in terms of X. You cannot do this. If you do, you will be averaging over situations with respect to which X is different in each. But you cannot average over outcomes in which X is different, for we know that X has a fixed value, and so whatever it is, it must remain constant over the outcomes that we use to average.

You are being misled by naming a variable. Just replace Y with its definition in terms of X, which you must do anyway since that's how you've defined it, and the illusion disappears.
andrewk July 07, 2018 at 07:44 ¶ #194549
Quoting Snakes Alive
You've agreed that Y must be defined in terms of X. X is fixed.

That doesn't prevent us from modelling our uncertainty about it by representing it as a random variable. In Bayesian analysis we model a fixed, unknown population parameter like X as a random variable from an assume distribution we call the 'prior'. We then use new information to update that distribution to a more accurate 'posterior distribution'.

I did say when presenting the Bayesian analysis that people who don't accept Bayesian methods won't agree.
Snakes Alive July 07, 2018 at 07:46 ¶ #194552
Reply to andrewk This has nothing to do with whether an analysis is Bayesian or not. Your error is a basic conceptual one.

This is reflected in the fact that you are empirically wrong about the results of actually playing the game.
andrewk July 07, 2018 at 07:47 ¶ #194554
Reply to Snakes Alive I suspect you are basing that claim on some computer simulation. Firstly, a computer simulation cannot prove anything in probability theory. Secondly, if it even suggests what you believe it does, I am convinced it contains an inappropriate assumption. Present your code and we can discuss it.
Snakes Alive July 07, 2018 at 07:48 ¶ #194555
Reply to andrewk If you play the game, switching on average will not afford you any gains. You predict it will. You are wrong.
andrewk July 07, 2018 at 07:50 ¶ #194556
Reply to Snakes Alive What evidence do you have for that claim? By all means present it and we can discuss it.
Snakes Alive July 07, 2018 at 07:56 ¶ #194558
Reply to andrewk The prior simulations demonstrated this.

If you don't accept that, literally just go out and play the game. Do trials where one person always switches, and another never does, giving them randomized values for X. The switcher will not receive 1.25 times the money on average that the non-switcher does.
Srap Tasmaner July 07, 2018 at 08:02 ¶ #194562
Reply to Snakes Alive
Btw, I added some functionality to the simulation andrew doesn't like. Counts some more stuff on each run just for extra confirmation of what's going on:

Number of trials: 500,000

Switch take: 187,394,381,897
Switch payout ratio: 1.4996906679464
Switch fails: 250,148
Total gain by switching: 62,439,025,501
Percentage of total: 0.33319582406328
Total loss by switching: 62,516,330,895

No Switch take: 187,471,687,291
No switch payout ratio: 1.5003093320536

Half the time you get X and win by switching to 2X; half the time you got 2X and lose by switching to X. Over a decent number of trials, your net gain is zilch.
andrewk July 07, 2018 at 08:04 ¶ #194566
Reply to Snakes Alive That is correct, but has no bearing on the problem. The problem asks about the player's expectation, not the game host's expectation, which is what the procedure you suggest would reflect.
Snakes Alive July 07, 2018 at 08:07 ¶ #194570
Reply to andrewk No, the problem asks what you should do.
andrewk July 07, 2018 at 08:11 ¶ #194573
Reply to Snakes Alive I covered that on the first page, but that was before you joined the discussion. What the player 'should do' depends on her utility function, and none of the analysis to date has addressed the question of utility functions. Implicitly, they have assumed the utility function is the identity function, rather than the usual concave-down assumption, which reduces the problem to the player selecting the option from which she expects the highest gain, based on the available information.
Srap Tasmaner July 07, 2018 at 08:16 ¶ #194574
Quoting andrewk
reduces the problem to the player selecting the option from which she expects the highest gain, based on the available information.


From the OP:

You are playing a game for money.


Did you think something else was relevant? Really? Like what?
andrewk July 07, 2018 at 08:17 ¶ #194575
Reply to Srap Tasmaner I don't understand how your question relates to the quote. Can you elaborate?
Srap Tasmaner July 07, 2018 at 08:17 ¶ #194576
Reply to andrewk
Suppose I am a player and I accept your analysis. Suppose also the envelopes are helpfully labeled L and R. Time for me to choose.

I consider L. But whatever value L has, R has 5/4 of that value. So I consider R. But whatever value R has, L has 5/4 of that value. So I consider L again.

Is there a third option besides:
(1) the two envelopes have the same expected value;
(2) one has a higher expected value than the other.
andrewk July 07, 2018 at 08:19 ¶ #194577
Quoting Srap Tasmaner
But whatever value L has, R has 5/4 of that value. So I consider R. But whatever value R has, L has 5/4 of that value. So I consider L again.

I don't believe that description correctly represents the analysis.
Srap Tasmaner July 07, 2018 at 08:20 ¶ #194578
Reply to andrewk
I'll rephrase.

Did you imagine that players might have some other goal besides maximizing their monetary gain?
Snakes Alive July 07, 2018 at 08:21 ¶ #194579
Reply to andrewk This just isn't relevant. Assuming that one wants to make the most money on average, the puzzle remains, and that is clearly the point of the OP. You are missing the point.
Srap Tasmaner July 07, 2018 at 08:22 ¶ #194580
Quoting andrewk
I don't believe that description correctly represents the analysis.


Your reasons?
andrewk July 07, 2018 at 08:22 ¶ #194581
Reply to Srap Tasmaner Yes, I imagine they would aim to maximise their expected increase in utility, not their expected monetary gain.

So for instance if the envelope contains $1m and there's something I desperately want that costs $750,000, but nothing much I want that costs between $1m and $2m, I would be silly to swap, because my loss of utility on halving my winnings is greater than my gain in utility from doubling them.

But I am happy to go along with the implicit assumption that has been made by all commenters, that the player's utility function is the identity function.
andrewk July 07, 2018 at 08:29 ¶ #194584
Reply to Snakes Alive If the distinction between 'maximise expected winnings' and 'what she should do' is irrelevant (which it is if we accept the implicit assumption that utility=identity, which I've said several times now that I'm prepared to do) it's hard to see why you devoted this post to emphasising the distinction.

Further, my detailed analysis adopts that implicit assumption by asking how the player can maximise her expected winnings, not what she 'should do'.
andrewk July 07, 2018 at 08:31 ¶ #194585
Reply to Srap Tasmaner It bears no resemblance to the analysis. For a start the analysis is about expectations, and your statement doesn't mention them. If you believe it fairly represents the analysis, the onus is on you to justify that belief.
Snakes Alive July 07, 2018 at 08:39 ¶ #194588
Reply to andrewk Holy shit, fine, so we're on the same page now. So respond to the initial points now that this pointless tangent is over.
andrewk July 07, 2018 at 08:42 ¶ #194589
Reply to Snakes Alive Do you have another question? If so, what is it?
Snakes Alive July 07, 2018 at 08:43 ¶ #194591
Reply to andrewk How do you respond to the fact that your analysis is empirically wrong?
andrewk July 07, 2018 at 08:44 ¶ #194594
Reply to Snakes Alive I don't answer questions based on false premises. Have you stopped beating your wife?
Snakes Alive July 07, 2018 at 08:47 ¶ #194595
Reply to andrewk Will someone, or will they not, get more money on average as a result of choosing the switching strategy, as opposed to choosing the not-switching strategy?
andrewk July 07, 2018 at 08:51 ¶ #194596
Reply to Snakes Alive It's a meaningless question. 'on average' is not a meaningful statistical concept. We can only meaningfully talk in terms of expected values. The expected values depend on the distributions of the random variables, and those distributions will depend on the information available to the person that is forming the expectation.
Snakes Alive July 07, 2018 at 08:54 ¶ #194597
Reply to andrewk If you run eight billion trials, giving equal values of X for each trial to each player, will the switcher and non-switcher converge roughly on the same payout?
andrewk July 07, 2018 at 08:54 ¶ #194598
Reply to Srap Tasmaner I did my best to read your code. Although I don't speak much PHP I think I can see what it's doing. It appears to me that it does not reflect the information available to the player because it treats X as a variable uniformly distributed over the range from 1 to num_trials whereas, once the player has seen the amount Y in the first envelope, they have narrowed the possibilities for X down to two possible values: Y or Y/2. So if that interpretation is correct I would say the code does not reflect the player's expectations.
andrewk July 07, 2018 at 08:56 ¶ #194599
Reply to Snakes Alive As described in the post immediately above, that setup does not reflect the player's knowledge and expectations.
Snakes Alive July 07, 2018 at 08:56 ¶ #194600
Reply to andrewk Can you answer the question?
andrewk July 07, 2018 at 09:00 ¶ #194601
Reply to Snakes Alive The question is ill-defined. To answer it, you'd have to specify your algorithm, which you have not done. If we take srap's PHP program as the algorithm, the expected value of the winnings from the switching and non-switching strategy would be the same but, as I've pointed out twice now, that simulation does not reflect the information available to the player. All it tells you is that, if you know what X is, a strategy of switching has the same expected reward as a strategy of not switching. But the player doesn't know what X is, so it doesn't reflect the problem.
andrewk July 07, 2018 at 09:01 ¶ #194602
I have to go to bed now. I'll look in again tomorrow if time permits.
Snakes Alive July 07, 2018 at 09:02 ¶ #194603
Reply to andrewk It is not ill-defined. The game described is one we can actually go out and play. I am asking about if we actually go out and play the game, what will actually happen? Will switching get me more money on average?
Michael July 07, 2018 at 09:23 ¶ #194610
Quoting Snakes Alive
No. The point is that it is not a possibility that the exhaustive disjunctive possibilities of what's contained in the other envelope are 5 and 20. This is because it's known already that for some X, the amount in the other envelope is X or 2X. But 5 and 20 are not X and 2X for any value of X. Thus it cannot be that the exhaustive disjunctive possibilities are these...


I went over this with Jeremiah.

We have £10 in our envelope. Our envelope is either X or 2X. If our envelope is X then the other envelope is 2X and if our envelope is 2X then the other envelope is X. Therefore the other envelope is either X or 2X. But it is wrong to infer from this that of the possible values in the other envelope, one is twice as big as the other, and that's because our two antecedents (and so consequences) use two different values of X, and your interpretation of the conclusion conflates them.

If our £10 envelope is X then X is 10 and the 2X envelope contains £20. If our £10 envelope is 2X then X is 5 and the X envelope contains £5. Therefore if our £10 envelope is either 2X or X then the other envelope contains either £5 or £20.

Given the premise "my envelope contains £10", the subsequent premise "my envelope is either X or 2X" is identical to the premise "X is either 10 or 5". Your argument doesn't seem to recognize this.
Srap Tasmaner July 07, 2018 at 09:32 ¶ #194612
Quoting andrewk
once the player has seen the amount Y in the first envelope, they have narrowed the possibilities for X down to two possible values: Y or Y/2. So if that interpretation is correct I would say the code does not reflect the player's expectations.


And in every single case, whatever the value of Y, the player will choose to switch. I model the results of switching, which are quite clearly the same as not switching, contradicting the player's stated reason for switching, namely the expectation of gain. No such expectation is fulfilled. Half the time switching is a mistake for the most obvious possible reasons.
Michael July 07, 2018 at 12:16 ¶ #194659
Quoting Jeremiah
And I proved that you are 100% wrong.


You didn't.

What's the value of X where:

1. Envelope A contains £10
2. Envelope B contains either X or 2X
Jeremiah July 07, 2018 at 12:21 ¶ #194662
Quoting andrewk
As described in the post immediately above, that setup does not reflect the player's knowledge and expectations.


None of us has yet to actually play this game; as such, we reflect the player's knowledge and expectations.
Jeremiah July 07, 2018 at 12:37 ¶ #194666
Quoting andrewk
It's a meaningless question. 'on average' is not a meaningful statistical concept. We can only meaningfully talk in terms of expected values. The expected values depend on the distributions of the random variables, and those distributions will depend on the information available to the person that is forming the expectation.


The definition of a statistic is. . . .

A statistic is any quantity that can be calculated from the observed data.


. . . the word mean when referring to an average calculated over an entire population. A mean is therefore a parameter. When referring to the average in a sample--which is both a statistics and estimate of the population mean--. . .


The Statistical Sleuth, A course in Methods of Data Analysis. By Ramsey/Schafer

Quoting Statistics How To
The expected value of a random variable is just the mean of the random variable.
.

Michael July 07, 2018 at 13:05 ¶ #194669
Quoting Jeremiah
You open A and it has 10 bucks, but you don't know if that is 10=X or 10=2X so A is still defined as [X,2X]. If A is X then B is 2X and if A is 2X then B has to be X. So B is still defined as [X,2X]. That part remains the same.


I addressed this.

If A is X then X is 10 and B is 2X = £20.
If A is 2X then X is 5 and B is X = £5.

You're conflating different values of X when you define B as [X, 2X] and say that of the possible amounts, one must be twice as big as the other.

It's B: [X where X = 5, 2X where X = 10] to compare with A: [X where X = 10, 2X where X = 5].
Jeremiah July 07, 2018 at 13:19 ¶ #194673
Reply to Michael

This is a rerun. . . .

R and S are mutually exclusive events.
Michael July 07, 2018 at 13:26 ¶ #194675
Quoting Jeremiah
R and S are mutually exclusive events.


I know. When I say that envelope B contains either £5 or £20 I'm saying that either R or S is the case.

Whenever we have a sample space (e.g. [H, T] for a coin toss) we're dealing with mutually exclusive events, so I have no idea what you're trying to get at here.
Michael July 07, 2018 at 13:29 ¶ #194677
If there's £10 in my envelope then either X = 10 and the other envelope contains £20 or X = 5 and the other envelope contains £5. We assign a probability of 50% to each event. This is how the Bayesian does his analysis, as shown by @andrewk.
Snakes Alive July 07, 2018 at 18:04 ¶ #194761
Reply to Michael What do you think about the empirical outcome of switching? Does it help?

That is, if you were actually to play the game (say over a huge number of trials), would you try switching every time in hopes of getting more money? Do you think it would work?
Michael July 07, 2018 at 18:23 ¶ #194764
Quoting Snakes Alive
That is, if you were actually to play the game (say over a huge number of trials), would you try switching every time in hopes of getting more money?


I'd switch conditionally as explained here to reap the .25 gain.
Snakes Alive July 07, 2018 at 18:37 ¶ #194767
Reply to Michael Your reasoning suggests that you ought to switch unconditionally.
Srap Tasmaner July 07, 2018 at 18:37 ¶ #194768
Quoting Michael
I'd switch conditionally as explained here to reap the .25 gain.


It is absolutely true that in iterated play you can learn stuff about the sample space and its distribution, and that you can develop strategies that build on this knowledge, even simple strategies like using an arbitrary cut-off will work.

Cool article here.

I just don't think of the paradox itself this way.
Snakes Alive July 07, 2018 at 18:38 ¶ #194769
Reply to Srap Tasmaner Yeah, the effectiveness of the conditional switching strategy is a red herring that is irrelevant to the puzzle, so I didn't want to touch it. The thing to address now is that this strategy is not even actually what's recommended by Michael's position. If he is right, you ought to switch no matter what.
Michael July 07, 2018 at 18:40 ¶ #194771
Quoting Snakes Alive
Yeah, the effectiveness of the conditional switching strategy is a red herring that is irrelevant to the puzzle, so I didn't want to touch it. The thing to address now is that this strategy is not even actually what's recommended by Michael's position. If he is right, you ought to switch no matter what.


If I'm right about what? That if there's £10 in my envelope then either X = 10 and the other envelope contains £20 or X = 5 and the other envelope contains £5, and that each is equally probable? Or that from this we can deduce an expected return of £2.50 from switching, given that Expected Return = SUM (Return[sub]i[/sub] * Probability[sub]i[/sub]) = (10 * 0.5) + (-5 * 0.5)?
Srap Tasmaner July 07, 2018 at 18:44 ¶ #194773
Reply to Snakes Alive
Honestly this take on the problem is far more interesting than the "paradox" and of real-world use. I'd rather be thinking about that.

But it's also clear to me there's a conceptual muddle in the argument for switching in the non-iterative case, so I can't get past that.
Jeremiah July 07, 2018 at 18:48 ¶ #194774
Reply to Michael

Expect for one to be possible the other one has to be impossible and therefore can not be included in the same sample space as possible outcomes. R and S are mutually exclusive events.
Michael July 07, 2018 at 18:51 ¶ #194775
Reply to Jeremiah What are you talking about? Heads and tails are mutually exclusive outcomes for a coin toss, yet the sample space for the outcome of a coin toss is [Heads, Tails].
Jeremiah July 07, 2018 at 18:56 ¶ #194776
Reply to Michael

You claim the sample space is [5,20]

The sample space is defined as all possible outcomes, but for 5 to be a possible outcome then 20 must be an impossible outcome. For 20 to be a possible outcomes 5 must be a impossible outcome. Therefore by the definition of a sample space your sample space cannot be [5,20].

Jeremiah July 07, 2018 at 19:04 ¶ #194777
Quoting Srap Tasmaner
But it's also clear to me there's a conceptual muddle in the argument for switching in the non-iterative case, so I can't get past that.


There is no point in even approaching probability and expected returns without properly defining the sample space. As if that is not right, the rest of it won't be right.
Jeremiah July 07, 2018 at 19:29 ¶ #194781
We define A and B as: If A=Y=X then B=2X or if A=Y=2X then B=X, where Y is the amount you see opening envelope A and X is the unknown amount originally selected by the facilitator.

My claim is then that the only possible outcomes for B is X or 2X.

Proof:

For all of Y, Y is a positive real number, such that Y=X or Y=2X, where X is some positive real number.

You are handed A and you see Y inside.

There are two cases here:

Case One

A=Y=X

By definition of A and B if A=Y=X then B=2X therefore B=2X

Case Two

A=Y=2X

By definition of A and B if A=Y=2X then B=X therefore B=X.

Those are the only two possible cases for B therefore by the definition of a sample space the sample space for B is [X,2X]

------

Notice how that is for all of Y. A very important concept. Also notice how it says "where X is some positive real number." It absolutely does not matter how X was selected.




Michael July 07, 2018 at 19:49 ¶ #194783
Quoting Snakes Alive
Stop repeating this, we get what the argument is, you've said it 5,000 times.


And it's not clear to me which part you disagree with, so I was hoping you could clarify the problematic step:

1. There's £10 in my envelope
2. My envelope is either X or 2X
3. X is either 10 or 5
4. If X is 10 then the other envelope contains £20
5. If X is 5 then the other envelope contains £5
6. It is equally probable that X is 10 and that X is 5
7. Expected Return = SUM (Return[sub]i[/sub] * Probability[sub]i[/sub])
8. Expected Return = (10 * 0.5) + (-5 * 0.5) = 2.5
Jeremiah July 07, 2018 at 20:39 ¶ #194790
Reply to Michael
Quoting Jeremiah
Jeremiah
1k
We define A and B as: If A=Y=X then B=2X or if A=Y=2X then B=X, where Y is the amount you see opening envelope A and X is the unknown amount originally selected by the facilitator.

My claim is then that the only possible outcomes for B is X or 2X.

Proof:

For all of Y, Y is a positive real number, such that Y=X or Y=2X, where X is some positive real number.

You are handed A and you see Y inside.

There are two cases here:

Case One

A=Y=X

By definition of A and B if A=Y=X then B=2X therefore B=2X

Case Two

A=Y=2X

By definition of A and B if A=Y=2X then B=X therefore B=X.

Those are the only two possible cases for B therefore by the definition of a sample space the sample space for B is [X,2X]

------

Notice how that is for all of Y. A very important concept. Also notice how it says "where X is some positive real number." It absolutely does not matter how X was selected.


Michael July 07, 2018 at 21:02 ¶ #194793
Quoting Jeremiah
You are handed A and you see Y inside.

There are two cases here:

Case One

A=Y=X

By definition of A and B if A=Y=X then B=2X therefore B=2X

Case Two

A=Y=2X

By definition of A and B if A=Y=2X then B=X therefore B=X.

Those are the only two possible cases for B therefore by the definition of a sample space the sample space for B is [X,2X]


You are handed A and you see £10 inside.

There are two cases here:

Case One

A=10=X

By definition of A and B if A=10=X then B=2X therefore B=20

Case Two

A=10=2X

By definition of A and B if A=10=2X then B=X therefore B=5.

Those are the only two possible cases for B therefore by the definition of a sample space the sample space for B is [5,20]

Like every time previously you're conflating different values of X. You can see it from your own antecedents: in case one, X = 10; in case 2, X = 5.
Michael July 07, 2018 at 21:12 ¶ #194795
Reply to Jeremiah

So just tell me in actual numbers the possible amounts in the other envelope if my envelope contains £10. If I switch, how much money could I walk away with? I say either £5 or £20. What do you say?
Jeremiah July 07, 2018 at 21:37 ¶ #194806
Reply to Michael


Quoting Jeremiah
We define A and B as: If A=Y=X then B=2X or if A=Y=2X then B=X, where Y is the amount you see opening envelope A and X is the unknown amount originally selected by the facilitator.

My claim is then that the only possible outcomes for B is X or 2X.

Proof:

For all of Y, Y is a positive real number, such that Y=X or Y=2X, where X is some positive real number.

You are handed A and you see Y inside.

There are two cases here:

Case One

A=Y=X

By definition of A and B if A=Y=X then B=2X therefore B=2X

Case Two

A=Y=2X

By definition of A and B if A=Y=2X then B=X therefore B=X.

Those are the only two possible cases for B therefore by the definition of a sample space the sample space for B is [X,2X]


Michael July 07, 2018 at 21:51 ¶ #194814
Reply to Jeremiah Replace Y with 10 and you get B = 20 in case 1 and B = 5 in case 2.
Jeremiah July 07, 2018 at 21:53 ¶ #194816
Reply to Michael

We define A and B as: If A=Y=X then B=2X or if A=Y=2X then B=X, where Y is the amount you see opening envelope A and X is the unknown amount originally selected by the facilitator.

My claim is then that the only possible outcomes for B is X or 2X.

Proof:

For all of Y, Y is a positive real number, such that Y=X or Y=2X, where X is some positive real number.

You are handed A and you see Y inside.

There are two cases here:

Case One

A=Y=X

By definition of A and B if A=Y=X then B=2X therefore B=2X

Case Two

A=Y=2X

By definition of A and B if A=Y=2X then B=X therefore B=X.

Those are the only two possible cases for B therefore by the definition of a sample space the sample space for B is [X,2X]
Michael July 07, 2018 at 21:55 ¶ #194818
Reply to Jeremiah Repeating yourself doesn't make the conclusion go away. If Y is 10 then in case one B = £20 and in case two B = £5.
Jeremiah July 07, 2018 at 21:56 ¶ #194819
Reply to Michael We define A and B as: If A=Y=X then B=2X or if A=Y=2X then B=X, where Y is the amount you see opening envelope A and X is the unknown amount originally selected by the facilitator.

My claim is then that the only possible outcomes for B is X or 2X.

Proof:

For all of Y, Y is a positive real number, such that Y=X or Y=2X, where X is some positive real number.

You are handed A and you see Y inside.

There are two cases here:

Case One

A=Y=X

By definition of A and B if A=Y=X then B=2X therefore B=2X

Case Two

A=Y=2X

By definition of A and B if A=Y=2X then B=X therefore B=X.

Those are the only two possible cases for B therefore by the definition of a sample space the sample space for B is [X,2X]
Srap Tasmaner July 08, 2018 at 01:58 ¶ #194871
@Michael, @andrewk

Nothing here that @Jeremiah and @Snakes Alive haven't already said, I think, just arranged a little differently. Check my math.

Given a sample space [math]\small [X, 2X][/math] of possible values for the selected envelope [math]\small Y[/math] and the unselected and unopened envelope [math]\small U[/math], we can calculate an expected value for [math]\small U[/math]:

[math]\small \begin{align}E(U \mid Y=X) &=P(U=2X \mid Y = X)(2X) + P(U=X \mid Y=X)(X) \\ &= 2X \\ E(U \mid Y=2X) &=P(U=2X \mid Y = 2X)(2X) + P(U=X \mid Y=2X)(X) \\ &= X \\ E(U)&=E(U \mid Y=X)P(Y=X) + E(U \mid Y=2X)P(Y=2X) \\ &= \frac32 X\end{align}[/math]

The question is whether it is legitimate to do something like this instead:

[math]\small \begin{align}E(U \mid Y=X) &=P(U=2X \mid Y = X)(2Y) + P(U=X \mid Y=X)(Y) \\ &= 2Y \\ E(U \mid Y=2X) &=P(U=2X \mid Y = 2X)(Y) + P(U=X \mid Y=2X)(\frac{Y}{2}) \\ &= \frac{Y}{2}\\ E(U)&=E(U \mid Y=X)P(Y=X) + E(U \mid Y=2X)P(Y=2X) \\ &= \frac54 Y\end{align}[/math]

I think the answer is just no. You can't do it this way. [math]\small Y[/math], [math]\small 2Y[/math], and [math]\small \frac{Y}{2}[/math] are not in the sample space of possible values for [math]\small Y[/math] and [math]\small U[/math]. That space consists entirely of [math]\small X[/math] and [math]\small 2X[/math]. What the switching analysis proposes is "substituting" for [math]\small X[/math] when conditioning on [math]\small Y=X[/math] or [math]\small Y=2X[/math]. But that's just not how it works. In this expression

[math]\small P(U=2X \mid Y=X)(2X)[/math]

[math]\small (2X)[/math] is a dollar value, while [math]\small U=2X[/math] and [math]\small Y=X[/math] are events, with probabilities of occurring, not equations you might use to set the value of [math]\small X[/math]. There's no line in here anywhere that says [math]\small Y = X[/math] as a simple equation.

There's also no place in our expectation formula for something like [math]\small X \mid Y=X[/math]. The possible values from our sample space are not "conditional" in some way. And it's obvious when you get to the third equation, that you cannot possibly add these "conditional values" together: what is the [math]\small Y[/math] in [math]\small \frac54 Y[/math] supposed to be? Is that [math]\small Y \mid Y=X[/math] or [math]\small Y \mid Y=2X[/math]?
Dawnstorm July 08, 2018 at 03:04 ¶ #194883
Quoting Jeremiah
The sample space is [[10,20],[5,10]]. Notice how there are two 10s. Now show me the math which allows you to eliminate both of them.


I haven't read past this page and only skimmed the the next two, so if I'm repeating what someone else said, or if that's irrelevant by now, please ignore. But this is complicated and I don't have much time, and I'm sure I'll forget if I don't reply now.

The square brackets represent envelopes - I'm sure of that. In a sample space of [[10,20],[5,10]] you're not defining the envelope we picked; you're defining the envelopes according to "contains 2X [10,20]", "contains X [5,10]". If you defined the envelope as "the one we picked" you'd get "the envelope we picked [10 (=2x), 10 (=x)]", and "the envelope we didn't pick [5 (= X), 20 (= 2X)]". That's because the two envelopes are interdependent, and that's why the events are order-sensitive, i.e. [[10 (=2X), (10 =x)] and [5 (= 2 X), 20 (= X)]] wouldn't work.

Tha sample space in your post is: [[10 (=2 X), 20 (= 2 X)], [5 = X, 10 = X]]. That is the sample space is only correct, if we're not picking an envelope at all, but defining the envelopes according to whether or not they contain X or 2 X. But then the values are arbitrary.

In any case, there is only one "10", and that's the one in the envelope we opened, whether that's X or 2X. The interdependence between the two envelopes determines that the other envelope has either a 5 or 20, and which of those is in there in turn determines whether 10 = X or 2 X (such is the nature of interdependence).

***

Also, the bet is inherently not avaragable, since repetition either immediately makes each subsequent repetition a win (by revealing X, if we check the result), or (if we stack the results without checking the wins) reveals X as soon as we get a dollar bill other than the one we get first (50 % at the start of the first repetition, 75 % at the start of the second repetition, ... = the likelihood of figuring out X).
Jeremiah July 08, 2018 at 03:56 ¶ #194892
Quoting Dawnstorm
you're defining the envelopes according to "contains 2X [10,20]", "contains X [5,10]".


Sorry no, that was not my intent. In the event of R you have A=10 and B=20. In the event of S you have A=10 and B=5. These are mutually exclusive events, which means in the case of R the amount 5 does not exist at all, and in the event of S the amount 20 does not exist at all. So one of those sample spaces is feeding you false information. The only way to avoid this is to treat X as the unknown variable it is.

Here was the original argument, which I only did because Michael requested that I do it. However, an algerbic solution, which I have posted several times already, models this problem much more accurately.

Quoting Jeremiah


So we have two cases here and have no clue which one we are in. Earlier I defined these cases as amount X case R, and and amount 2X case S. We have a lot of variables flying around so let's try to be consistent here.

Now that we have listed all possible outcomes we can define our sample space as [R,S], well call this sample space 2.

Now remember by our definitions an event is a subset of our sample space.

In event R X=10 and since in event R B must be 2X then B = 20.

So the sample space of event R is [10,20].

In event S 10=2X and since in event S B must be X then B= 5.

So the sample space of event S is [5,10]. (order does not matter)

So our sample space, which we named as sample space 2, is [R,S] where R is the set [10,20] and S is the set [5,10] or we can express it as [[10,20],[5,10]]






Jeremiah July 08, 2018 at 04:02 ¶ #194893
The problem with the [5,20] argument is that one of those numbers is not possible, therefore calculations based on those numbers will be misleading. To do so is to incorporate false information into your math.
Srap Tasmaner July 08, 2018 at 04:25 ¶ #194894
I suppose I could also have thrown in this:

[math]\small \begin{align} E(U \mid Y=10) &= P(U=2X \mid Y=10)(2X) + P(U=X \mid Y=10)(X) \\ &=\frac12 2X + \frac12 X \\ &= \frac32 X \end{align}[/math]
Dawnstorm July 08, 2018 at 08:53 ¶ #194940
Quoting Jeremiah
Sorry no, that was not my intent. In the event of R you have A=10 and B=20. In the event of S you have A=10 and B=5. These are mutually exclusive events, which means in the case of R the amount 5 does not exist at all, and in the event of S the amount 20 does not exist at all. So one of those sample spaces is feeding you false information. The only way to avoid this is to treat X as the unknown variable it is.


Hm, thinking about it a bit more, I think we're making a basic mistake, here. X/X2 is the relationship of the variables, not the sample space. I'll go at it step by step so we can see if I've made a mistake somewhere:

1. We have two envelopes with two different amounts of money:

Envelope1 = X $
Envelope2 = Y $

At that point E1 and E2 do not refer to specific envelopes, nor do X or Y refer to specific amounts. It's simply two variables with two values, and we have no more information. If we have 10 $ in one envelope and 20 $ in another, it doesn't matter whether we set 10 X and 20 Y, or the other way round. It's completely arbitrary. Both constellations describe the same event.

Both X and Y have the same sample space: any number that makes sense of $. Both sample spaces might be, for example, the natural numbers (weight, space, etc. are complications we don't need).

2. If we learn that one envelope contains exactly double the amount of the other, that tells us more. We now can get rid of one variable. But the sample space isn't X and 2X. It's the natural numbers for one (let's call it X), and depending on one of two assumptions we make about X, the sample space of the second is a transformation of X.

Two assumptions?

2. a) We assume X is greater of the two numbers.

Envelope1 = X $ (natural numbers)
Envelope2 = Y $ (X/2)

2. b) We assume X is the lesser of the two numbers

Envelope1 = X $ (natural numbers)
Envelope2 = Y $ (2*X)

These two assumptions both validly describe situation. We still don't define a real envelope; we merely define wether X is the greater number and Y is the lesser number, or the other way round.

In both these assumptions we don't know the actual value of X. So if someone tells us that one of the envelopes contains 10 $, then we don't know whether X is the greater or lesser number. With regards to the above, we don't know where to put it. But we do know it has to be one of the two: 10 $ is either the greater or the lesser number. This gives us two possibilities:

2. a)

Envelope1 = 10 $
Envelope2 = (10/2) = 5 $

or 2. b)

Envelope1 = 10 $
Envelope2 = (10*2) = 20 $

But what we've done here is twofold: we've set X = 10, and we've set envelope1 as the envelope that contains X. We do not know whether X is the greater or the lesser number. The question we care for is what's in envelope2, and the answer to that is:

If X is greater number, envelope2 contains 5 $.
If X is the lesser number, envelope2 contains 20 $.

The sample space for envelope1 was all the natural numbers, and the event is now 10. Since the sample space of envelope 2 is dependent on the sample space of envelope 1, there are only two possibilities: X/2 or 2X. We simply don't know whether X is the greater number or the lesser number.

It doesn't matter which envelope we open first, we never know which is the greater or the lesser. Because of this, we can set any of the envelopes as 1 or 2, and we always have the same situation:

E1 = 10 and E2 = 5 (X > Y, Y = X/2)
E1 = 10 and E2 = 20 (X < Y, Y = 2 X)

If we only open one envelope, we might open the other envelope first. We wouldn't know about 10, in that case, but either about 5 or 20, depending which is true.

For 20 we'd get:

E1 = 20 and E2 = 10 (X > Y, Y = X/2)
E1 = 20 and E2 = 40 (X < Y, Y = 2X)

The ratio remains a constant, no matter which number you draw, and that's why you alway stand to win twice as much as you would lose. This is a function of what you know about the ratio. However the natural numbers that make up the individual sample spaces differ.

If the envelopes contain 10 and 20 dollars, and you set E1 as the envelope you pick first you get:

For E1 = 10:

the sample space for E2 is [5, 20].

For E1 = 20

the sample space for E2 is [10, 40]

That's because the sample space for E1 is not X. The sample space for E1 is the natural numbers. X is the event.. However, once we know the event for E1, we know that the sample space for E2 is [X/2, 2x], and that's because of the ratio. We can't reduce the sample space to 1 item because we cannot know whether X is the greater or the lesser number until we look at E2. But E1 is chosen at random.

So we get the following:

Envelope1 = [X | € N]
Envelope2 = [Y | € [X/2, 2X]]

I'm not an experienced mathematician, so I might have gotten the notation wrong. But does the reasoning make sense?

Michael July 08, 2018 at 09:12 ¶ #194944
Quoting Srap Tasmaner
I suppose I could also have thrown in this:

[math]\small \begin{align} E(U \mid Y=10) &= P(U=2X \mid Y=10)(2X) + P(U=X \mid Y=10)(X) \\ &=\frac12 2X + \frac12 X \\ &= \frac32 X \end{align}[/math]


You have two different values of X and so this is misleading.

Where you have P(U=2X?Y=10)(2X), the actual value of X is 10, given that you've defined the smaller envelope as having £10.

Where you have P(U=X?Y=10)(X), the actual value of X is 5, given that you've defined the larger envelope as having £10.

So it works out as:

[math]\small \begin{align} E(U \mid Y=10) &= P(U=2X \mid Y=10)(20) + P(U=X \mid Y=10)(5) \\ &=\frac12 20 + \frac12 5 \\ &= 12.5 \end{align}[/math]

To make this clearer, say I flip a coin to determine the value of X to put it an envelope Y. Using your formulation, we have:

[math]\small \begin{align} E(Y) &= P(H)(X) + P(T)(X) \\ &=\frac12 X + \frac12 X \\ &= X \end{align}[/math]

But let's say I'll put in £10 if it's heads and £100 if it's tails. The expected value, using my formulation, is:

[math]\small \begin{align} E(Y) &= P(H)(10) + P(T)(100) \\ &=\frac12 10 + \frac12 100 \\ &= 55 \end{align}[/math]
Jeremiah July 08, 2018 at 12:37 ¶ #194970
Quoting Dawnstorm
But does the reasoning make sense?


It makes sense, but it is wrong, and that is why it is misleading.

Forget the math and just think about this rationally.

Consider:

I have two envelopes and I secretly put 10$ in one and 20$ in the other, then hand you one at random.

You open it and see there is 10$. You have no idea what is in the other envelope so you imagine it could be 20$ or it could be 5$. However, it can't be 5$ ever, as it is 20$. A 5$ outcome would be impossible, so your imagination is feeding you false information. You imagined a number that is not even a possible outcome.

The distributed amounts into the envelopes is X and 2X and it will always be X and 2X no matter what you imagine it might be or how much you know about the envelopes.

Also, all this has been covered in extensive depth.
Srap Tasmaner July 08, 2018 at 13:47 ¶ #194980
Quoting Michael
You have two different values of X and so this is misleading.

Where you have P(U=2X?Y=10)(2X), the actual value of X is 10, given that you've defined the smaller envelope as having £10.

Where you have P(U=X?Y=10)(X), the actual value of X is 5, given that you've defined the larger envelope as having £10.

So it works out as:

[math]\small \begin{align} E(U \mid Y=10) &= P(U=2X \mid Y=10)(20) + P(U=X \mid Y=10)(5) \\ &=\frac12 20 + \frac12 5 \\ &= 12.5 \end{align}
[/math]


1. Y = 10
2. Y = X ? U = 20
3. Y = 2X ? U = 5

These statements are all true.

*4. Y = X
*5. ? U = 20 (1,2,4)
*6. Y = 2X
*7. ? U = 5 (1,3,6)

One of (4) and (6) is true and the other false, and thus one of (5) and (7) is true and the other false.

If (4) is true, then the sample space for Y and U is [10, 20]; 5 is not in the sample space and therefore you cannot use 5 in calculating the expected value of either Y or U.

If (6) is true, then the sample space for Y and U is [5, 10]; 20 is not in the sample space and therefore you cannot use 20 in calculating the expected value of either Y or U.

Quoting Michael
But let's say I'll put in £10 if it's heads and £100 if it's tails.


£10 and £100 are both in the sample space for [math]\small X[/math]: that's why your expected value calculation is correct.

Suppose this was our problem: we know one envelope has £10 and one has £20, and we're just to pick one and that's it.

[math]\small \begin{align} E(Y) &= P(Y=10)(10) + P(Y=20)(20) \\ &= 15 \end{align}[/math]

Easy peasy.

In our problem, we do not know whether the sample space is [5,10] or [10,20]. It is one or the other, but that doesn't mean our sample space is [5,10,20], not even subjectively. Our space is known to have exactly two values in it. You cannot plug three values into the expected value formula and get the right answer.
Michael July 08, 2018 at 14:36 ¶ #194987
Reply to Srap Tasmaner

Y is 10, therefore the sample space for X is [5, 10]. To work out the expected value of U we multiply the probability that X is 5 (0.5) to the value of U if X is 5 (5), we multiply the probability that X is 10 (0.5) to the value of U if X is 10 (20), and add them together.

It's exactly what we do with my example of the coin toss. The sample space for the toss is [H, T]. To work out the expected value of Y we multiply the probability that the toss is H (0.5) to the value of X if the toss is H (10), we multiply the probability that the toss is T (0.5) to the value of X if the toss is T (100), and add them together.
Michael July 08, 2018 at 14:51 ¶ #194988
Another way to phrase your formulation is:

[math]\small \begin{align} E(U \mid Y=10) &= P(X=10)(2X) + P(X=5)(X) \end{align}[/math]

The left and right side of the addition explicitly define different values of X. It's:

[math]\small \begin{align} E(U \mid Y=10) &= P(X=10)(2 * 10) + P(X=5)(5) \end{align}[/math]
Srap Tasmaner July 08, 2018 at 15:37 ¶ #194996
Quoting Michael
Y is 10, therefore the sample space for X is [5, 10]


I know it seems that way to you. That is your subjective view of the situation. But we are told no such thing. We are not told X is selected by some random process or even by a choice. There is no such thing, so far as we know, as a "sample space for X".

Here's an analogy. Suppose a friend tells me he's going to flip either his red/blue coin or his yellow/green coin. What's my expectation of red? Is it 1/4? How would I know that? He didn't tell me how he was going to choose which coin he was going to flip. We do have — unlike in the envelope problem — a space known to have four elements: [[red, blue], [yellow, green]]. Maybe what he meant was that he was
always going to flip the red/blue coin. That counts as flipping either. Maybe he meant he would randomly choose one, maybe some other method. I have no way of knowing. I should probably treat the two possible spaces indifferently, because what else can I do?

In our situation, I know it's tempting to say we should average the chance that our sample space is [10, 20] and the chance that it's [5, 10], but we can't. Even if we choose to treat the two spaces indifferently, we do not know there are two such spaces. This is the difference.

@andrewk I think argued that we have to treat X as a random variable, and that we have to treat any value we cannot exclude as a possible value for X. I can see the appeal of that, I really can. But it clearly leads to the wrong answer. If I present envelopes containing either £10 or £20 to a hundred switchers and let them open one, half of them will think there might be envelopes with £5 out there and half of them will think there might be envelopes with £40 out there. Half of them will trade their £10 for the £20, and half of them, sad to say, will trade their £20 for £10. Those with £10 did not risk losing only £5. Those with £20 had no chance of getting £40.
Michael July 08, 2018 at 15:44 ¶ #194997
Quoting Srap Tasmaner
I know it seems that way to you. That is your subjective view of the situation. But we are told no such thing. We are not told X is selected by some random process or even by a choice. There is no such thing, so far as we know, as a "sample space for X".


But your own argument made this same assumption.

[math]\small P(U=2X \mid Y=10)(2X)[/math] is the same as [math]\small P(X=10)(2X)[/math]

[math]\small P(U=X \mid Y=10)(X)[/math] is the same as [math]\small P(X=5)(X)[/math]

Edit: It's not even an assumption. It simply follows from a) Y = 10 and b) Y is X or 2X. If Y is 10 and Y is X then X is 10. If Y is 10 and Y is 2X then X is 5.
Srap Tasmaner July 08, 2018 at 15:57 ¶ #195002
Quoting Michael
But your own argument made this same assumption.


That's not an argument, it's just a calculation, and it didn't. It weights the possible values known to be in the sample space for [math]\small U[/math], namely [math]\small X[/math] and [math]\small 2X[/math], by the probability of the event of [math]\small U[/math] containing the larger of the two values, given that the value of one envelope is known to be 10, and the probability of the event of [math]\small U[/math] containing the smaller of the two values, given that one envelope is known to contain 10.

Knowing that one envelope contains 10 does not tell you whether [math]\small U[/math] is the larger or the smaller envelope, and does not tell you whether 5 or 20 are in the sample space. Not knowing whether 5 or 20 are in the sample space for [math]\small U[/math] we cannot use them. We could use 10, but 10 is the value of the envelope we've already got.
Michael July 08, 2018 at 16:00 ¶ #195003
Quoting Srap Tasmaner
That's not an argument, it's just a calculation, and it didn't. It weights the possible values known to be in the sample space for [math]U[/math], namely [math]X[/math] and [math]2X[/math], by the probability of the event of [math]U[/math] containing the larger of the two values, given that the value of one envelope is known to be 10, and the probability of the event of [math]U[/math] containing the smaller of the two values, given that one envelope is known to contain 10.


To ask if U is the larger of the two, given that Y is 10, is to ask if X is 10 and U is 20.

To ask if U is the smaller of the two, given that Y is 10, is to ask if X is 5 and U is 5.

So if there's a probability of 0.5 that U is larger than Y, where Y is 10, then there's a probability of 0.5 that U is 20, and if there's a probability of 0.5 that U is smaller than Y, where Y is 10, then there's a probability of 0.5 that U is 5. So 0.5 * 20 + 0.5 * 5.
Michael July 08, 2018 at 16:05 ¶ #195004
Quoting Srap Tasmaner
Knowing that one envelope contains 10 does not tell you whether UU is the larger or the smaller envelope, and does not tell you whether 5 or 20 are in the sample space. Not knowing whether 5 or 20 are in the sample space for UU we cannot use them. We could use 10, but 10 is the value of the envelope we've already got.


We derive the sample space from:

1. Y = 10
2. U = 2X or U = X.

If U = 2X then Y = X. As Y = 10, 2X = 20.
If U = X then Y = 2X. As Y = 10, X = 5.
Srap Tasmaner July 08, 2018 at 16:06 ¶ #195005
Reply to Michael
And yet my use of X and 2X leads to the correct conclusion, while your substituting Y and Y/2 leads to the wrong conclusion. Since that is the only difference, you ought to conclude that you cannot substitute this way.

((This is fun, but I have to go work on the Tractatus. I'll check back here later today.))
Michael July 08, 2018 at 19:37 ¶ #195054
Quoting Srap Tasmaner
In this expression

[math]\small P(U=2X \mid Y=X)(2X)[/math]

[math]\small (2X)[/math] is a dollar value


Yes. And that dollar value is twice the value of [math]\small Y[/math], so if [math]\small Y=10[/math] then [math]\small 2X=20[/math]. How can you possibly disagree with this? It's right there in your own equation: [math]\small Y = X[/math]. So [math]\small 2X = 2Y[/math].

You can't condition on [math]\small Y = X[/math] and then multiply by [math]\small 2X[/math] where [math]\small 2X \ne 2Y[/math]. That's just a contradiction.

And the same issue on the other side. You can't condition on [math]\small Y = 2X[/math] and then multiply by [math]\small X[/math] where [math]\small X \ne \frac12 Y[/math]. That's just a contradiction. If [math]\small Y = 10[/math] then [math]\small X = 5[/math].
Srap Tasmaner July 08, 2018 at 22:53 ¶ #195092
Quoting Michael
You can't condition on Y=X and then multiply by 2X where 2X?2Y. That's just a contradiction.


It's really not.

There are two different sorts of things here. One is the conditional probability of an event occurring, one is the value in our sample space for U that U will have if that event occurs; by abuse of notation we're actually calling that event "U = 2X". The way the game is set up, P(U = 2X | Y = X) = 1 and P(U = X | Y = 2X) = 1. No assertion is made here about the event "Y = X" actually occurring, or about its probability.

Maybe you're imagining we're talking about Y here the same way we're talking about R in this coin toss:

[math]\small \begin{align} E(R) &= P(R = \mathrm H)(10) + P(R = \mathrm T)(100) \\ &= \frac12(10) + \frac12(100) \\ &= 55\end{align}[/math]

But we're not. Here we're talking about the probability of the events "R = H" and "R = T" occurring, and weighting the values from our sample space, 10 and 100, by those probabilities.

In my expectation calculations, we're talking about U = ... occurring, not Y = ..., so you need to read them as

[math]\small \begin{align} E(U \dots) &= P(U = 2X \dots)(2X) + P(U = X \dots)(X) \end{align}[/math]

We're just matching up events of U taking a value from the sample space with that value.
Dawnstorm July 09, 2018 at 04:43 ¶ #195157
Quoting Jeremiah
no matter what you imagine it might be or how much you know about the envelopes.


Well, with full knowledge of the situation there's a 100 % chance that one envelope contains $ 10,-- and the other $ 20,-- and there's no need to invoke probablility. The reason we invoke probability at all is simply because we have incomplete knoweldge of the situation. And that's why a bet makes sense at all. I don't understand how can say that knowledge doesn't matter. It's the entire point of it.
Michael July 09, 2018 at 06:38 ¶ #195167
Reply to Srap Tasmaner

The expected value of U is the probability that event A is the case multiplied by the value of U if event A is the case plus the probability that event B is the case multiplied by the value of U if event B is the case.

Event A is "U is the larger envelope, given that Y is £10". If event A is the case then the value of U is £20. Your own calculation accepts that the probability that event A is the case is 0.5. So it's 0.5 * 20.

Event B is "U is the smaller envelope, given that Y is £10". If event B is the case then the value of U is £5. Your own calculation accepts that the probability that event B is the case is 0.5. So it's 0.5 * 5.

I honestly cannot understand which step here you disagree with.
Srap Tasmaner July 09, 2018 at 07:04 ¶ #195169
Reply to Michael
The sample space for U has two values in it. One of them is 10, and that's taken by Y. That leaves exactly one slot open in the sample space for either 5 or 20, and it certainly will be one of those, but we don't know which. If you know for a fact that one of those two values cannot be a value of U, because it cannot be in the sample space from which the values of U are drawn, then you cannot use both of those values when calculating the expected value of U. One of them has to go.

Since we don't know which one has to go, the only thing to do is continue, reluctantly perhaps and with some disappointment, using X and 2X. And what you find is that your expectation for U, in terms of X, does not change when you learn that Y = 10. Knowing only one of the two values is just not enough information.

That it is not enough information should be obvious. Look again at this example:

  • If I present envelopes containing either £10 or £20 to a hundred switchers and let them open one, half of them will think there might be envelopes with £5 out there and half of them will think there might be envelopes with £40 out there. Half of them will trade their £10 for the £20, and half of them, sad to say, will trade their £20 for £10. Those with £10 did not risk losing only £5. Those with £20 had no chance of getting £40.


There is a perfect symmetry here: half were lucky in the draft but unlucky in the trade; the other half were unlucky in the draft but lucky in the trade. Not one of them actually had any idea which they were, whether they saw £10 in their envelope or £20. And they all traded for no reason at all.
Michael July 09, 2018 at 08:18 ¶ #195176
Quoting Srap Tasmaner
Since we don't know which one has to go, the only thing to do is continue, reluctantly perhaps and with some disappointment, using X and 2X. And what you find is that your expectation for U, in terms of X, does not change when you learn that Y = 10. Knowing only one of the two values is just not enough information.


If you describe your expectation for U as 2X and if Y is known to be 10 then you're describing your expectation for U as £20. If you describe your expectation for U as X and if Y is known to be 10 then you're describing your expectation for U as £5.

Quoting Srap Tasmaner
That it is not enough information should be obvious. Look again at this example:


We're talking about the expected value of U if Y is 10. Situations where Y is 20 (or 5) aren't relevant to this consideration.

So you could say that the envelope sets are all £10 and £20 and everyone with £10 gains £10 by switching or you could say that the envelope sets are all £5 and £10 and everyone with £10 loses £5 by switching, or you could say that half the envelope sets are £10 and £20 and half are £5 and £10 and half the people with £10 gain £10 by switching and half lose £5 by switching.

There are a number of different real life scenarios (conditioned on Y = 10) that we can consider all with different values of U and gains/losses for switching. But what we're discussing right now is your calculation:

[math]\small \begin{align} E(U \mid Y=10) &= P(U=2X \mid Y=10)(2X) + P(U=X \mid Y=10)(X) \\ &=\frac12 2X + \frac12 X \\ &= \frac32 X \end{align}[/math]

You are accepting that the probability that U is larger than 10 is 0.5 and that the probability that U is smaller than 10 is 0.5.

But if U is larger than 10 then U is 20 and if U is smaller than 10 then U is 5.

So it's 0.5 * 20 + 0.5 * 5.

And if we were to condition on X being either 5 or 10 then we'd come to two different conclusions (neither of which are your (3/2)X):

[math]\small \begin{align} E(U \mid Y=10, X=5) &= P(U=2X \mid Y=10, X=5)(2X) + P(U=X \mid Y=10, X=5)(X) \\ &=0 \times 2X + 1 \times X \\ &=X \\ &=5 \end{align}[/math]

[math]\small \begin{align} E(U \mid Y=10, X=10) &= P(U=2X \mid Y=10, X=10)(2X) + P(U=X \mid Y=10, X=10)(X) \\ &=1 \times 2X + 0 \times X \\ &= 2X \\ &= 20 \end{align}[/math]

But none of what you've said here addresses the calculation as explained here, so please point out exactly which step it is you disagree with.
andrewk July 09, 2018 at 09:43 ¶ #195190
I've just been hit by the consequences of some of the issues raised in my Bayesian note. I didn't notice them before, but they're in there.

The first is that, unless the player adopts an assumed distribution for X, they have no probability distribution by which they can calculate expected gains, so it's simply meaningless to ask what their expected gain is. We can ask what the host expects the gain to be if we like. Since the host knows what X is, the answer to that is:

-X (a certain loss) if the host knows the player has the envelope with 2X
+X (a certain gain) if the host knows the player has the envelope with X
0 (an even chance of a gain or loss of X) if the host doesn't know which envelope the player has, but believes the choice of which envelope to put the doubled amount in was random with even odds.

But what the host expects doesn't bear on the question, which is 'what should the player do?' (assuming the player's utility function is the identity function).

Stripped of all the mathematics, my simplest answer to that (more sophisticated alternatives are possible) is: the player should estimate L, the maximum amount she thinks the game would be prepared to pay out. If Y<L/2 she should switch, otherwise she should not.

This is consistent with the player assuming that X can be any amount between 0 and L/2, with uniform probability. That is the assumption used in @Srap Tasmaner's PHP program, with num_trials = L/2, if I've interpreted the PHP correctly (I may not be remembering the variable name exactly, but you'll know the one I mean).

With that assumed distribution, the player will expect a zero gain if she switches regardless of the value of Y. But if she switches only if Y<L/2 the expected gain will be Y/2 for those cases.

I predict that, if that sim is run with a strategy that only switches when Y<num_trials / 2, it will converge on a gain that averages L/4 across those trials and 3L/16 across all trials.

Interestingly, the Bayesian note doesn't side completely with either prior 'side' of the argument. It shows that there exists a switching strategy that gives the player a strong expectation of gain over the Y they have seen, but it also shows that, if she has adopted an assumption of the distribution of X, and uses a strategy that switches regardless of the value of Y, her expectation of gain from switching is zero. The way we reconcile that with the fact that by switching she'll either gain Y or lose Y/2 is to observe that the probabilities of those two outcomes are not equal. The probabilities must be inferred from where the observed Y sits in the player's prior distribution for Y, which is inferred from her prior distribution for X. The higher Y is, the greater is the probability that it is the doubled amount, so the greater is the probability of losing Y/2 rather than gaining Y by switching.

For detail, see the note. The simplest example I can think of is where the player assumes that X is either 10,000 or 20,000. Then her assumed distribution for Y is 10,000 (prob = 1/4), Y=20,000 (prob=1/2), Y=40,000 (prob=1/4). If she sees Y=40,000 she knows she has the doubled amount (given her prior assumed distribution of X), so she shouldn't switch. Otherwise she should. That strategy gives an expected gain of (1/4) . 10,000 - (1/4) . 10,000 + (1/4) . 20,000= 5,000. That gain is equal to the expected loss that arises if she also switches when Y=40,000 (lose 40,000 / 2 with probability 1/4, ie lose 5,000). But using a Bayesian switching strategy, she sets up an expected gain of 5,000.

This also demonstrates why looking in the envelope makes a difference. If you don't look in the envelope, you can't use the above strategies, as they decide whether to switch based on the value of Y.
Michael July 09, 2018 at 09:54 ¶ #195195
Quoting andrewk
If Y<L/2 she should switch, otherwise she should not.


That's exactly what my program does (although I switch if Y is less than or equal to L/2). In my case, L is the highest 2X envelope seen so far and so doesn't require guessing some upper bound.

Quoting andrewk
I predict that, if that sim is run with a strategy that only switches when Y<num_trials / 2, it will converge on a gain that averages L/4 across those trials and 3L/16 across all trials.


It's a .25 gain in my program.
Michael July 09, 2018 at 10:05 ¶ #195199
Quoting andrewk
if I've interpreted the PHP correctly.


Do you know any programming languages? I could try writing my program in something else so you can better see what it's doing in case the PHP is too confusing.
andrewk July 09, 2018 at 10:11 ¶ #195203
Reply to MichaelMost of my languages are very old - Fortran, BASIC, Pascal, C, Simula, LISP, Prolog. These days I mostly use R, and am toying with Python in case that turns out to be useful if I want to get into 'data science'. I think I managed to understand srap's PHP program, so I'll try to work through yours as well as part of a self-education exercise.

It seems weird how variable names start with $. I suppose there's some carefully thought-out reason for that.
andrewk July 09, 2018 at 10:44 ¶ #195206
Quoting Michael
It's a .25 gain in my program.

That's a different metric than the ones I quoted. Mine is in dollars while yours, if I'm reading the PHP correctly, is the dollars divided by the total of all Ys observed, minus 1.

Measured on the same basis as yours, my model gives 0.5. That is more because mine uses L from the beginning, rather than progressively adapting it based on observations. My suggestion is that we set L to be the budget of the game show, because we know they can't pay more than that. If we don't know that we could use a suitably small proportion of the net assets of the company running the game show. Or if that's unknown, a suitably small proportion of the GDP of the country it comes from (or of the world, if we don't know the country).

Which approach is appropriate may depend on the exact setup of the repetitions. Yours appears to be a serial one, where the info from previous trials is available to the player in subsequent trials. Alternatively, we could have a parallel one, where a team of 10,000 players do one trial each simultaneously, and aim to maximise their team winnings.

There's also the question of whether we use the assumed prior distribution of X to model the possible values of X. To not do that requires having an additional distribution that models the uncertainty in our prior distribution, which is a bit too meta- for me at this time of night. I'll sleep on it. If we start with L estimated as above, in the serial case we could update it (improve it) in a Bayesian fashion based on each new observation of 2X.
Michael July 09, 2018 at 10:46 ¶ #195207
Reply to andrewk Here's my attempt at R:


# The amount earned if following the switching strategy
switch <- 0

# The amount earned if never switching
no_switch <- 0

# The highest value seen
max_2x <- 0

# Play 10,000 games
for (i in 1:10000)
{

# Select a value of X at random, multiples of 4 between 4 and 400.
# We do this because we don't want odd numbers or the chosen envelope
# to be double an odd number
x <- sample(1:100, 1) * 4

# Put X in one envelope and 2X in the other
envelopes <- c(x, x * 2)

# Select an envelope at random
n <- sample(1:2, 1)
choice = envelopes[n]

# Get the other envelope
if (1 == n)
{
other <- envelopes[2]
}

else
{
other <- envelopes[1]
}

# Increase the amount if never switching by the amount in the chosen envelope
no_switch <- no_switch + choice

# If the first game or the amount in the chosen envelope is less than or equal to
# half the highest value seen then switch and increase the switching strategy amount
# by the amount in the new envelope
if (

0 == max_2x
||
choice <= max_2x / 2

)
{
switch <- switch + other
}

# Otherwise increase the switching strategy amount by the amount in the chosen
# envelope
else
{
switch <- switch + choice
}

# Record the highest value seen
max_2x <- max(c(choice, other, max_2x))

}

# Output the gain that the switching strategy has over never switching
paste('Gain: ', (switch / no_switch) - 1)


The gain is .25.
Michael July 09, 2018 at 10:49 ¶ #195208
Quoting andrewk
That's a different metric than the ones I quoted. Mine is in dollars while yours, if I'm reading the PHP correctly, is the dollars divided by the total of all Ys observed, minus 1.


It's the amount you walk away with by following the switching strategy divided by the amount you walk away with by never switching, minus 1.

If I was just showing the amounts then it would be:

Switching strategy: £3,786,812
Never switch: £3,020,844

The switching strategy gives you 1.25 times the amount from never switching (which is just what the division and minus 1 is done to show).
Jeremiah July 09, 2018 at 11:33 ¶ #195212
Reply to Dawnstorm I did not say you have full knowledge. All of the concerns you are expressing have already been addressed by multiple people multiple times, and I don't feel like going in circles over this any more.

I summed this up towards the start of the thread:

Quoting Jeremiah
You have two envelopes, A and B.

There are two possible amounts for the contents of the two envelopes either X or 2X. You don't know which is which.

We'll call amount X case R, and and amount 2X case S.

You are handed envelope A.

Before you open it, you know that A could be case R or it could be case S. You have no clue which it is, so as an uninformative prior you give each case a 50% likelihood.

Now for the tricky part, you open envelope A and see it has 10 bucks in it.

Intuitively this seems like new information which would call for you to update your prior; however, it still does not tell you if are you in case R or case S. You don't know if that is 10=X or 10=2X. So in truth you can't really update your prior, as your prior was based on the uncertainty of being in case R or case S.

So your prior stands.

You consider swapping. You look at envelope B and realize it could be in case R or case S. You don't know which, so just as before you give it an uninformative prior and you give each case a 50% likelihood.

Now you could swap, but really probabilistically it changes nothing as your initial uncertainty would still stand. You would just trade the uncertainty of A for the uncertainty of B which is the same uncertainty. And the math? Well the math is indifferent to all options. So the decision to swap really comes down to if you feel lucky or not.


Jeremiah July 09, 2018 at 12:10 ¶ #195215
Quoting andrewk
I mostly use R, and am toying with Python in case that turns out to be useful if I want to get into 'data science'


There is no reason to put data science in quotations; it is a real branch of modern science.
The advancements of computers and the age of big data is what created a need for specialist in analyzing data.The two most common forms of data scientists are statisticians and computer scientists; however, there are other flavors as well.

R is mostly used by statisticians for data analysis, my impression is that Python is mainly used in machine learning, which would be the computer science side. From what I have read, it is not too hard for a statistician to cross over into machine learning, as many of the machine learning concepts come from statistical theory and practice. If your goal is simply to engage data analysis, and you already know R that is well enough, and more preferable if you wish to go the statistics path. However, being a statistician requires that you know both Classical and Bayesian methods, as many of the model assumptions in Classical statistics persist over into Bayesian statistics.



Srap Tasmaner July 09, 2018 at 12:21 ¶ #195219
Quoting Michael
so please point out exactly which step it is you disagree with


You are taking a weighted average of one value which is not only possible but actual, and one value that is not possible. You cannot calculate an expected value for a variable using values not in the sample space for that variable.
Michael July 09, 2018 at 12:25 ¶ #195221
Quoting Srap Tasmaner
You are taking a weighted average of one value which is not only possible but actual, and one value that is not possible.


You saying that there's a 50% chance that U is 2X given that Y is £10 is you saying that there's a 50% chance that U is £20.

You saying that there's a 50% chance that U is X given that Y is £10 is you saying that there's a 50% chance that U is £5.
Jeremiah July 09, 2018 at 12:27 ¶ #195223
The pro switchers never really gave a good reason how to reconcile the fact that their model has the potential to make impossible predictions. That is a valid reason for concern and if a model which makes no new assumptions upon seeing Y only provides possible outcomes then that is a definitive reason to favor that model.

Until they fix that problem, that will stand against their methods of approach.
Jeremiah July 09, 2018 at 12:34 ¶ #195225
The error here is making new assumptions upon seeing Y.
Srap Tasmaner July 09, 2018 at 20:03 ¶ #195296
Quoting Michael
You saying that there's a 50% chance that U is 2X given that Y is £10 is you saying that there's a 50% chance that U is £20.

You saying that there's a 50% chance that U is X given that Y is £10 is you saying that there's a 50% chance that U is £5.


I'm going to meet you half-way, Michael.

In essence what I'm saying is that P(U = 2X | Y = 10) = P(U = 2X), which entails that (U = 2X ? Y = 10) = ?. The trouble here, which we should have fixed long ago, is just abuse of notation. I can look at that and understand it as saying that the values loaded into the envelopes are independent of my choice of envelope. But it also suggests that the value of U and the value of Y are unrelated, which is plainly false. It's much more cumbersome to do it the long way, but I guess there's nothing for it.

We'll label the envelopes L and R. There are two independent events:
(1) [L = x, R = x], the loading of the envelopes; and
(2) [Y = L, Y = R]. the choosing of an envelope by the player.
(There are several equivalent ways of defining these.) We're also going to assign probabilities Y = L = 1/2 = Y = R, and L = x = 1/2 = R = x. (The defense for this is that since the player cannot deliberately choose L even if she wants to, she is indifferent, and since she is indifferent then there is no point in the loader of the envelopes not being indifferent. There is no gamesmanship attached to which indistinguishable envelope is which.)

The blind expectation looks like this:

[math]\small \begin{align} E(U) &= P(U=x)(x) + P(U=2x)(2x) \\ &= P(U=L)P(L=x)(x) + P(L=R)P(R=x)(x) + P(U=L)P(L=2x)(2x) + P(U=R)P(R=2x)(2x) \\ &= \frac12\cdot\frac12(x) + \frac12\cdot\frac12(x) + \frac12\cdot\frac12(2x) + \frac12\cdot\frac12(2x) \\ &= \frac32x\end{align}[/math]

What happens when we have selected and opened an envelope with value 10?

There are two possibilities: Y = L & L = 10 or Y = R & R = 10. It seems safe to treat these as equally likely. But now we have complications. Y = L and L = 10 are independent; the sort of events we'll be conditioning on this pair are U = R and R = x, which are also independent. But Y = L and U = R are not independent and L = 10 and R = x are not independent.

Case 1: Y = L & L = 10
[math]\small \begin{align} E(U\mid C_1) &= P(U=x\mid C_1)(x) + P(U=2x\mid C_1)(2x) \\ &= P(U=R\mid Y=L)P(R=x\mid L=10)(x) + P(U=R\mid Y=L)P(R=2x\mid L=10)(2x) \\ &= 1\cdot\frac12(x) + 1\cdot\frac12(2x) \\ &= \frac32x \end{align}[/math]

Obviously Case 2 will be the same and E(U) = 3X/2. This looks a whole lot like what I did in this post.

But is it right? I know what you're going to say: (x) should be 5 and (2x) should be 20. After all, if L = 10 and R = x, then R = 5.

But consider this: I dropped some terms from the expansion, namely all the terms in which U = L, because we're doing the case in which Y = L. All those terms just go to 0, so I dropped them. What if it turns out x = 10? Then P(R = x | L = 10) would also go to 0, and we'd end up with U = 20, which is fine.

Your way would have the term containing (5) disappear when x = 10. Does that make sense?

*** ADDED: Yeah, actually it does. That's what makes this so misleading. There's no avoiding the sample space issue. ***

We could even, if we wanted, go ahead and do more cases in which we set x = 10, now that we know that's a possibility. The only problem with that is that we cannot do a complementary case that's x =/= 10. What would you plug in for that?

So now we're back to the same issue: there is one unknown value in our sample space for L and R. It's either 5 or 20, but two values don't go in one slot. And you cannot calculate an expected value using values not known to be in your sample space. So we're stuck with x.

((Actually we don't need x. I'll be posting a version in which the loading sample space it's just [L = 2R, R = 2L], and our expected value is just (L + R)/2.))
andrewk July 09, 2018 at 23:09 ¶ #195334
Quoting Srap Tasmaner
We'll label the envelopes L and R.

Please Nooooooo! Let's not do that. I reserved the symbol L many pages ago for the maximum possible value ('Limit') in the player's prior distribution for 2X. If we start using it for something else, like one of the envelopes, we'll end up a terrible muddle. :joke:

I'd be interested in your thoughts on this post, and whether you've tried doing a simulation using the simple strategy outlined there. The discussion has been very fluid but I think I'm agreeing with you that the player's expected gain from blind switching is zero, but her expected gain from switching based on comparing the value of Y to L/2 is strongly positive (here L has the original meaning of Limit, not Left).

Reply to Michael Thank you for that. Now I can check my progress in PHP interpretation by comparing the two.
Srap Tasmaner July 09, 2018 at 23:10 ¶ #195335
Here's another slightly different version with a little twist.

As above, we'll have an envelope loading event, this time [L = 2R, R = 2L].

I'm just going to do the case for Y = L = 10. In addition to dropping all the terms that include U=L, I'm going to leave U=R (=1) out of the terms I keep.

E(U|Y=L=10) = P(L=2R | L=10)(R) + P(R=2L | L=10)(R)

Now the question is, can I do this:

= P(R=5 | L=10)(R) + P(R=20 | L=10)(R)
= R

That is, maybe there's no harm in doing a little algebra in how you describe the events whose probabilities you're looking at, but all that stays inside the parentheses-- you still don't get to touch (R) because there's no (R | L=10) or something.

I feel a little weird about it, but maybe there's room for a partially subjective description here, so long as you're careful not to average values that are not known to be in the sample space.

What do you think @Jeremiah? Is this okay?
Srap Tasmaner July 09, 2018 at 23:17 ¶ #195339
Quoting andrewk
Nooooooo


Sorry, man.

Quoting andrewk
the player's expected gain from blind switching is zero, but her expected gain from switching based on comparing the value of Y to L/2 is strongly positive.


I think a more complete, realistic answer is around here, yes. Still, for a single trial, your guess would have to be awfully lucky to be any help.
andrewk July 09, 2018 at 23:24 ¶ #195346
Quoting Srap Tasmaner
for a single trial, your guess would have to be awfully lucky to be any help.

Why? It's not about helping, it's about her expected gain, which is a pure calculation and nothing to do with luck. And my analysis is for a single trial.
Srap Tasmaner July 09, 2018 at 23:48 ¶ #195369
Reply to andrewk
For bogarting your L.
Jeremiah July 10, 2018 at 00:04 ¶ #195379
Reply to Srap Tasmaner

Let me try rewriting this.

Your sample space is [R =L/2, R = 2L].

Which means your distribution here:

= P(R=5 | L=10)(R) + P(R=20 | L=10)(R)
= R

Could be:

= P(R=5 | L=10)(R) + P(R=20 | L=10)(R)
= L/2

Or

= P(R=5 | L=10)(R) + P(R=20 | L=10)(R)
= 2L


Let me think about it some.

-----

Thoughts in progress. . .

= P(R=5 | L=10)(L/2) + P(R=20 | L=10)(2L)

Sorry, but I need more clarification on where you are going with this.
Dawnstorm July 10, 2018 at 00:09 ¶ #195380
Quoting Jeremiah
Let's call the two envelopes A and B. Now envelope A could have X or A could have 2X and likewise B could have X or B could have 2X. Those are all the possible outcomes so by the definition of a sample space our sample space is [A,B] where A is the set [X,2X] and B is the set [X,2X], which means our sample space could also be written as [[X,2X],[X,2X]].


I think I got it. We've got two variables, a numerical value X and a binary variable that tells us which letter we picked, the one containing X (smaller value) or the one containing 2X (the bigger value).

Let me explain step by step:

We have a value X. It's a numerical variable, and it describes the value of two letters in such a way that one letter has X, and another letter has 2X.

The second, the binary variable is E, for envelope, and it's values are yes/no. The question it answers is: Did we pick the envelope that contains the value X?

The sample space for X = N (natural numbers); the sample space for E is [yes, no].

Now we pick a letter and open it. We find it has the value 10. We now have new information about X. The sample space for X has shrunken from N to [5, 10], because 10 has to be either X or 2X.

We have no information on the "yes, no" question, but we do know that the letter we picked has the value 10. That leaves us with the following:

X [5, 10], E [yes, no]

We can use a if/then relation to connect the variables:

If E = yes then X = 10 (because if E is yes, then the letter we didn't pick is the larger one, 2X)
If E = no then X = 5 (because if E is no, then the letter we didn't pick is the smaller one, X)

Just for completeness sake:

If E = yes then 2X = 20
If E = no then 2X = 10

And in words:

If we picked the smaller letter X = 10, that means this letter has 10 (X), and the other is 20 (2X).
If we didn't pick the smaller letter X = 5. That means this letter has 10 (2X), and the other letter has 5 (X).

That means that if this letter is 10 (X | E = yes, or 2X | E = no) then the other letter has [5 (X | E = no), 20 (2X | E = yes)].

That's exactly the same situation as your [[10,20],[5,10]], viewed from a different perspective. Let me write it out: [[10 (X | E = yes), 20 (2X | E = yes)], [5 (X | E = no), 10 (2X | E = no)].

It's indisputable that if we pick up a letter and look inside and find a 10 we have:

X [5, 10], E [yes, no]

Everything else is just different groupings:

If we uncover a letter and it has the value Y, then the other letter has a value of [Y/2, 2Y].

Y ... [X | E = yes, 2X | E = no]
Y/2 ... [X | E = no]
2Y ... [2X | E = yes]

I believe this covers all our bases.

What this means for the switchers and the conundrum is currently beyond me. There's certainly something strange going on.

Srap Tasmaner July 10, 2018 at 00:13 ¶ #195381
Reply to Jeremiah
Right, good point. In which case, defining the sample space that way is the mistake -- turns our problem into the Ali Baba problem. Didn't mean to do that.

How would you feel about something like this?

E(U | Y=10) = P(U=5 | Y=10)(x) + P(U=20 | Y=10)(2X)
= 3X/2

Okay to describe the events that way?
Jeremiah July 10, 2018 at 00:30 ¶ #195389
Reply to Srap Tasmaner

My problem with this is that I feel like the numbers are just being bent until you get the answer you want.

There are two things we can use probability models for; making predictions and to better understand relations by creating an accurate model. You got the mid range you are looking for, but does your model explain the problem correctly?
andrewk July 10, 2018 at 00:49 ¶ #195395
Reply to Dawnstorm If the player adopts this as the sample space then they cannot use a uniform distribution as their Bayesian prior for X, because there cannot be a uniform distribution on the natural numbers. Hence a 'tailing-off' distribution would need to be selected, such as P(X=n)=2^-n for n=1, 2, ....

Given the adoption of a Bayesian prior distribution, the higher the observed value of Y (the value in the opened envelope), the greater the chance that it is 2X rather than X, and hence the less the expected gains from switching. Since a strategy of compulsory blind switching delivers expected gains of zero, a strategy of choosing an amount H and switching only when Y<H must have an expected positive gain.

Srap Tasmaner July 10, 2018 at 01:15 ¶ #195413
Reply to Jeremiah
I'm with you. I just hadn't thought of doing it this way before. It gives you a way to acknowledge what you've learned by learning the value of one of the envelopes, while acknowledging that you still don't know which of 5 and 20 is even a possible value of X. It feels close to the way we should think about the problem.
Srap Tasmaner July 10, 2018 at 01:32 ¶ #195421
Reply to Jeremiah
The more I look at it, the more I miss seeing U=X and U=2X. Maybe it's best to leave them alone. Seeing P(U=5...) when 5 might not even be a possible value for U just feels wrong.
Dawnstorm July 10, 2018 at 02:35 ¶ #195444
Quoting Srap Tasmaner
...which of 5 and 20 is even a possible value of X


I'm not quite done yet thinking, but 20 is definitely not possible value of X. It's like this:

For Y = 10:

5 is a possible expected value for X (alternative to 10=X).
10 is a definite value, either for X or for 2X
20 is a possible expected value for 2X (alternative to 10=2X).

This symmetry is systematic:

Y/2 = possible expected value for X
Y = definite value, either for X or for 2X
2Y = possible expected value for 2X

Y is definitely in the sample (because you're looking at it). If it's X the other card is 2X (and thus 2Y), and if it's 2X, the other card is X (and thus Y/2).

Or differently put: [5, 20] is [X, 2X] but not of each other - of the respective alternative of 10.
Srap Tasmaner July 10, 2018 at 02:38 ¶ #195446
Quoting Dawnstorm
20 is definitely not possible value of X


Just a typo
Dawnstorm July 10, 2018 at 02:42 ¶ #195447
Reply to Srap Tasmaner
Sorry about the correction. My head is swimming.
Jeremiah July 10, 2018 at 02:44 ¶ #195448
Reply to Srap Tasmaner Personally, I think there is a general misconception on these forums that Bayesian inference is an excuse to model the subjective rather than the objective; however, that approach is too open to observer bias. Priors assumptions need to be fully justified as does the posterior. Not only do we need to scrutinize the prior but also what information is acceptable for our posterior and perhaps for these reasons a Bayesian inference is just not appropriate for this problem.
Srap Tasmaner July 10, 2018 at 03:03 ¶ #195451
Reply to Jeremiah
The strangest thing about the puzzle to me is that you need only designate an envelope to get into trouble.

Wikipedia says Smullyan thought it was a logic puzzle and had nothing to do with probability.
Jeremiah July 10, 2018 at 03:59 ¶ #195457
Reply to Srap Tasmaner I think it has more to do with set theory than probability.


Srap Tasmaner July 10, 2018 at 04:38 ¶ #195458
Reply to Jeremiah
It is suggestive that the only probabilities ever in play are 50% and the only expected value calculation I have any faith in tells us absolutely nothing.

On the other hand, once you start iterating, there's plenty of cool stuff to do.
Jeremiah July 10, 2018 at 05:51 ¶ #195467
Reply to Srap Tasmaner Well the whole expected value approach has some interesting aspects to it.

If A1=Y=X then B1=2X or if A2=Y=2X then B2=X, where Y is the amount you see opening envelope A and X is the unknown amount originally selected by the facilitator.

Then in case one

B1 > Y

In case two

Y > B2

So B1 >Y> B2

Which means

P(A1)Y+P(B1)2X > P(A2)Y+P(B2)X or more importantly P(A1)Y+P(B1)2X is not equal to P(A2)Y+P(B2)X.

So since you don't know which case you are in after seeing Y and they are not equal you can't really calculate the expected value. Now if you never opened A and never saw Y, that is a different story. So the only rational thing to do is pretend Y does not exist, then subjectively you can treat case one and case two with the same algebra.

*Edit

Or rather I should say that the inclusion of Y makes calculating the expect returns impossible.
Jeremiah July 10, 2018 at 12:28 ¶ #195584
Reply to Dawnstorm

The distribution in the other letter cannot be [Y/2, 2Y] as one of those values simply does not exist. You have still created a sample space with impossible outcomes. The truth is that Y is not usable information. The error is making new assumptions based on Y.

Jeremiah July 10, 2018 at 12:34 ¶ #195585
If you don't change your assumptions upon seeing Y this problem becomes direct and accurate to solve.
Michael July 10, 2018 at 12:53 ¶ #195598
Reply to Jeremiah I think the issue is that you and I mean something different by an outcome being possible.

Let's say you toss a coin. If it's heads you put a red ball in one box and a blue ball in a second box. If it's tails you put a red ball in one box and a green ball in a second box. I pick a box at random, not knowing the outcome of your coin toss, and find a red ball.

I would say, given the information available to me, that it's possible that there's a blue ball in the second box and that it's possible that there's a green ball in the second box, with a 50% probability of each. The sample space for the other box is [blue, green].

Whereas you would say that the sample space for the other box is either [red, blue] or [red, green] and that we just don't know which it is, and that because we know that it doesn't contain a red ball that either blue is certain and green is impossible or green is certain and blue is impossible.

Maybe @Srap Tasmaner and @andrewk could comment on this too. What is the sample space of the other box? Does the answer depend on whether or not one is a Bayesian?
Michael July 10, 2018 at 14:10 ¶ #195614
Reply to Srap Tasmaner That's gone a bit over my head. With the above post in mind, this perhaps better explains where I'm coming from, and perhaps you could explain how it's addressed by your post:

I toss a coin. If it's heads then I put a red ball in one box and £5 in the other. If it's tails then I put a red ball in one box and £20 in the other. You pick a box at random, not knowing the outcome of the coin toss, and find a red ball. What is the sample space of the other box and its expected value?

I would say that the sample space of the other box (U) is [£5, £20] and that it's expected value is:

[math]\small \begin{align} E(U) &= P(U=5)(5) + P(U=20)(20) \\ &=\frac12 5 + \frac12 20 \\ &= 12.5 \end{align}[/math]

Now perform the same calculation but instead of a red ball and £5 if heads and a red ball and £20 if tails, it's £10 and £5 if heads and £10 and £20 if tails (which is the same as X = 5 if heads and X = 10 if tails). The fact that it's £10 rather than a red ball in my box doesn't change the sample space or expected value of the other box.
Jeremiah July 10, 2018 at 15:40 ¶ #195661
Paralleling an example can be useful, but it also can be misleading. I rather stay focused on the problem in the OP.
Srap Tasmaner July 10, 2018 at 15:57 ¶ #195669
Quoting Michael
If it's heads you put a red ball in one box and a blue ball in a second box. If it's tails you put a red ball in one box and a green ball in a second box.


See how red blue and green are all mentioned by name as possibilities.
Michael July 10, 2018 at 16:06 ¶ #195670
Quoting Srap Tasmaner
E(U)=P(U=x)(x)+P(U=2x)(2x)


What I think we need to do is explain what x means here. Is it "the amount that's actually in the smaller envelope"? So:

E(U)=P(U is the smaller envelope)(the amount that's actually in the smaller envelope)+P(U is the larger envelope)(the amount that's actually in the smaller envelope)

Or is it "the amount that would be in the smaller envelope were this event to be the case"? So:

E(U)=P(U is the smaller envelope)(the amount that would be in U if U is the smaller envelope)+P(U is the larger envelope)(the amount that would be in U if U is the larger envelope)

You seem to be working under the first definition, whereas I'm working under the second definition.
Michael July 10, 2018 at 16:07 ¶ #195671
Quoting Srap Tasmaner
See how red blue and green are all mentioned by name as possibilities.


I don't understand what you're implying by this response.
Srap Tasmaner July 10, 2018 at 16:38 ¶ #195677
Reply to Michael
Take a step back from all the math and the modeling. Try to see the forest here.

(1) There are two envelopes.
(2) You end up with one of them.

Maybe you just pick one, maybe there's some long drawn out complicated process. Whatever happens between (1) and (2), you end up with one of the two. Your expected gain is just the average of their values.

You don't know the total value of the envelopes, how that value is selected, what it's range might be if it even has one. Right here in this post, I haven't even told you the envelopes necessarily have different values, or that their values have a fixed ratio, or a fixed difference. If I let you look in one, how much more do you know? Almost nothing. You might as well not bother.

There are two objects of unknown value and you end up with one of them. So far as a "decision" goes here, you might as well treat them as equal, or treat the choice as a matter of indifference, just flip a coin. There is not nearly enough information available to base a decision on.
Michael July 10, 2018 at 16:45 ¶ #195679
Quoting Srap Tasmaner
There is not nearly enough information available to base a decision on.


Yes, because you’ve said that we don’t know anything. But in the case we’ve been discussing we know that one envelope contains twice as much as the other and that mine has £10. This is information that allows us to calculate an expected value as explained here.
Srap Tasmaner July 10, 2018 at 17:07 ¶ #195682
Reply to Michael
You cannot calculate an expectation for X if you do not know what the sample space for X is.

It really should be called the "Grass is Always Greener" problem, because the whole point of that saying is that the greater greenness of the grass on the other side of the fence is an illusion you generate yourself by applying your favorite cognitive fallacy.
Srap Tasmaner July 10, 2018 at 17:19 ¶ #195683
Reply to Michael
Even using terms like "expectation" or "expected value" is too fancy here. We're just talking about a mean of two values.

What's the mean of A and B? (A + B)/2.
What's the mean of X and 2X, for some X? 3X/2.
What's the mean of U and 10? (U + 10)/2 = U/2 + 5.
Michael July 10, 2018 at 18:30 ¶ #195724
Reply to Srap Tasmaner It's the mean of 5 and 20, given that either there's £5 or £20 in the other envelope.

Do you disagree with the calculation here with the red ball and £5 if heads or red ball and £20 if tails?
Dawnstorm July 10, 2018 at 18:34 ¶ #195726
Quoting Jeremiah
The distribution in the other letter cannot be [Y/2, 2Y] as one of those values simply does not exist. You have still created a sample space with impossible outcomes. The truth is that Y is not usable information. The error is making new assumptions based on Y.


No, I have created a sample space with one impossible and one necessary outcome. It's an either/or situation, and that's appropriate because expectations are based on information rather than on what's actually the case. The statement that for every Y the other envelpe has to contain either Y/2 or 2Y is correct, and remains correct even after you check the other envelope and discover one or the other value inisde.

The distribution will be one of the two scenarios:

Y/2 = 100 %, Y = 0 %
Y/2 = 0 %, Y = 100 %

Y is not a random variable and doesn't have a sample space. That's why I said the random variable is a binary. Y = X? Yes/No. The other envelope has to take one of those values, based on two values:

- The value of this envelope (a fixed value)
- Whether you picked the envelope with X, or the one with 2 X (a random variable)

You need to know the latter to calculate the value of the other envelope, but you won't have the information until you check the other envelope, at which point the calculation becomes pointless.





Michael July 10, 2018 at 18:57 ¶ #195733
Reply to Srap Tasmaner Your approach to my example of the red ball would be to say that a coin toss determines the value of some X to be put in the other envelope and so that the expected value is:

E(U) = P(H)(X) + P(T)(X) = 0.5X + 0.5X = X

Which I think is a completely misleading way to phrase it and conflates what actually are different values of X. The expected return is the probability of event 1 being the case multiplied by the amount if event 1 is the case plus the probability of event 2 being the case multiplied by the amount if event 2 is the case. The amount (X) is conditional on the event, not some independent constant.
Srap Tasmaner July 10, 2018 at 22:47 ¶ #195777
Reply to Michael
The coins and colored balls thing is different because there are four possible outcomes, you're just choosing in two steps, maybe because you don't have a four-sided coin. Probability of each is 1/4, just takes two steps to get there.

I am still thinking about the math.

This sequence converges:

[math]\frac{1}{2^n}y-\frac{1}{2^{n+1}}y[/math]

This one doesn't:

[math]2^{n+1}y-2^ny[/math]
andrewk July 10, 2018 at 22:53 ¶ #195778
Quoting Michael
I would say, given the information available to me, that it's possible that there's a blue ball in the second box and that it's possible that there's a green ball in the second box, with a 50% probability of each. The sample space for the other box is [blue, green].


Probability is used to model uncertainty, and nearly all uncertainty in our world is epistemological. If one is a Hard Determinist (a term that I think is not well-defined, but let's leave that aside for now) then ALL uncertainty is epistemological.

One constructs a probability space based on one's knowledge, so there is no absolute probability space that models a game but rather a probability space that models a particular stakeholder's perspective on the game.

In the above case the probability space you describe that is blue and green, each having 50% probability, is an appropriate probability space for the player of the game. For the game host however, who knows whether the second box has blue or green, the probabilities are either 0 and 1, or 1 and 0.

A minor technical point: the sample space is the set of all conceivable outcomes (called 'events'). I deliberately say 'conceivable' rather than 'possible' because it can contain events that the person knows to be impossible. A probability space is a sample space together with an assignment of probabilities to each event, as well as some other technical stuff (sigma algebras) that we needn't go into here. A probability space can assign zero probabilities to some events, as long as the sum of all assigned probabilities of events in the sample space is 1. Events that the space's 'owner' knows to be impossible will be assigned probability zero.

So the game host and the player can have the sample space. But they will assign different probabilities to events in it, so they have different probability spaces. If the second box holds green, the host will assign 0 probability to the event 'blue' while the player will assign 0.5 to it.

Quoting Michael
Does the answer depend on whether or not one is a Bayesian?
I'm not sure. I feel the answer may be 'perhaps', but the definition of the Bayesian vs Frequentist divide seems to be very fuzzy. I think a hard-line Frequentist may reject the epistemological interpretation, but that would seem to render them unable to use most methods of modern statistics. EIther I've misunderstood what frequentism is, or there are very few hard-line Frequentists in the world.
Michael July 10, 2018 at 23:19 ¶ #195781
Quoting Srap Tasmaner
The coins and colored balls thing is different because there are four possible outcomes, you're just choosing in two steps, maybe because you don't have a four-sided coin. Probability of each is 1/4, just takes two steps to get there.


Using a coin toss to determine if it's red ball + £5 or red ball + £20 is no different to using it to determine if it's £10 + £5 or £10 + £20 which is no different to using it to determine if it's X = 5 or X = 10. So you seem to be tacitly agreeing that if we know that X = 5 or X = 10, as determined by a coin toss, before we start then if we find £10 in our envelope then the expected value of the other envelope is £12.50.

But then what's the difference between using a coin toss to determine if it's X = 5 or X = 10 and using a dice to determine if it's X = 5 or X = 10 or X = 20 or X = 40 or X = 80 or X = 160? It'll still work out as above that if there's £10 in our envelope then the expected value of the other envelope is £12.50. And what's the difference between using a dice to determine if X is one of those six values and using a random number generator to pick any X between any range? Surely the math behind the expected value of the other envelope works out exactly the same as it does in the case of the red ball and either £5 or £20.
Srap Tasmaner July 10, 2018 at 23:54 ¶ #195788
Reply to Michael
There are two ways to look at this:

(1) Knowing the rules of the game, when you get the $10 envelope, you use your amazing Math Powers to deduce that the other envelope contains $5 or $20. (This is like kids educational TV.)

(2) Upon finding $10 in the first envelope, you start making up fairy tales that convince you to trade your bird in the hand for two in the bush.

I more and more see the soundness of doing the math as you do, as a matter of fact, which bothers me a bit because the answer it produces is patently wrong. It may not be a question of whether the math is being done right, but whether this particular tool is appropriate for the job at hand.
Srap Tasmaner July 11, 2018 at 00:57 ¶ #195796
The other big picture issue that has gotten short shrift in this thread, by focusing on the open envelope, is the paradox of trading an unopened envelope (or even picking one).

If you are offered the trade after picking, but without opening, you can conclude readily that the value of the other envelope is 5/4 the value of yours, whatever that is. But if you trade, and still don't open, you can conclude that the value of the first envelope is 5/4 the value of the one you traded for.

And you can reason this way even before picking, so that the other envelope is always better. How can you even pick one?
Srap Tasmaner July 11, 2018 at 01:21 ¶ #195805
Quoting Jeremiah
P(A1)Y+P(B1)2X > P(A2)Y+P(B2)X or more importantly P(A1)Y+P(B1)2X is not equal to P(A2)Y+P(B2)X


Which is to say that mean[Y, 2Y] > mean[Y/2, Y].

I've been thinking some about how this works. If you tried, as the player, to broaden your view of the situation, it might go something like this:

  1. Here's 10.
  2. The other envelope is 5 or 20.
  3. If it's 5, I'm just as likely to have picked 5.
  4. Then I'd think the other envelope has 5/2 or 10.
  5. If it's 20, I'm just as likely to have picked 20.
  6. Then I'd think the other envelope has 10 or 40.


You could go on, which is why I got to thinking about how going smaller converges, but going bigger doesn't. (The space does have a lower but not an upper bound, so far as you know.) Point being there's no mean value for the space as a whole. Jumping in at any point Y shows you ever increasing gains to your right and ever diminishing losses to your left. You get just a little taste of that when you try to calculate your expectation for the other envelope.
Srap Tasmaner July 11, 2018 at 01:42 ¶ #195810
The rest of the point being that envelopes worth less than yours, yours being worth Y, have an average value of [s]Y/2[/s] 0, as a matter of fact. The envelopes worth more than Y have no average value.

Edit: dumbness.
Benkei July 11, 2018 at 07:44 ¶ #195862
I thought this was solved eons ago? The total amount of the envelopes is fixed; switching or keeping results in the same. The total amount is always 3x. The expected amount (E) in an envelope is therefore 50% x or 50% 2x, e.g. 3x/2. That's the expected amount any way you cut that cookie.

Jeremiah July 11, 2018 at 12:03 ¶ #195907
Reply to Benkei

I posted the solution on the 6th post. However, without the stubborn refusal of reality, then I doubt many of the threads on these philosophy forums would go much of anywhere.
Srap Tasmaner July 11, 2018 at 12:41 ¶ #195921
Reply to Benkei
There are two natural and apparently sound approaches, one of which, the one you mention, produces the correct result. The puzzle is figuring out what's wrong with the other one. (Our efforts have been hampered somewhat by some people thinking the other answer is actually right.)
Benkei July 11, 2018 at 13:08 ¶ #195925
Reply to Srap Tasmaner ah... I'd opt for the reductio ad absurdum. If there's no limit to switching, you'd have to switch indefinitely based on the other faulty interpretation which is of course ridiculous.
Srap Tasmaner July 11, 2018 at 13:21 ¶ #195929
Reply to Benkei
Agreed. But it would be nice, knowing that the argument leads to absurdity and is therefore false, to pinpoint the step we should disallow. Like figuring out where you divided by 0 in the *proof we learned as kids that 2 = 1.
Benkei July 11, 2018 at 14:13 ¶ #195933
Reply to Srap Tasmaner Ok. I'll have a stab at that (I have to admit I only read the first few pages here so might be repeating things).

Ok, so we have a wrong approach:

If the envelope I'm holding is X then switching either gives you 2X or X/2. Either you win X or you lose 1/2X, so switching is a winning proposition.

One venue I'm thinking about is that this falsely suggests there are three possible values for the envelopes: X, 2X and X/2. But we know there are only two; X and 2X.

If the envelope I'm holding is X then switching gives me 2X but if it's 2X then switching gives me X. Profit and loss are equal.

The mistake could also be found in the assumption that the envelope I hold has a determinate amount X of which the values of the other envelope is derived.
Srap Tasmaner July 11, 2018 at 14:36 ¶ #195936
Quoting Benkei
The mistake could also be found in the assumption that the envelope I hold has a determinate amount X of which the values of the other envelope is derived.


If only the amount in the first envelope, the envelope you chose and perhaps are even allowed to open, is fixed, and the second envelope is then loaded with either half or twice the amount in yours, then switching is the correct strategy. This is the variant Barry Nalebuff calls the Ali Baba problem.
Michael July 11, 2018 at 14:53 ¶ #195943
Quoting Benkei
One venue I'm thinking about is that this falsely suggests there are three possible values for the envelopes: X, 2X and X/2. But we know there are only two; X and 2X.

If the envelope I'm holding is X then switching gives me 2X but if it's 2X then switching gives me X. Profit and loss are equal.

The mistake could also be found in the assumption that the envelope I hold has a determinate amount X of which the values of the other envelope is derived.


We're dealing with a situation where we know that there's £10 in our envelope. What's the value of the other envelope? It's possible that it's £5, as the envelope set could be £5 and £10, and it's possible that it's £20, as the envelope set could be £10 and £20. It's not possible that it's £1 as the envelope set can't be £1 and £10.

So this strikes me as a conceptual disagreement over what it means for an outcome to be possible, and I think the disagreement is one between the Bayesian and the frequentist. I recall an earlier discussion where another poster (who I also clashed with here on a similar issue) said that once a coin had been tossed it would be wrong to say that it's equally likely to be heads as tails (even if we haven't looked); instead if it's actually heads then it's not possible that it's tails and if it's actually tails then it's not possible that it's heads. I believe Jeremiah and Srap (and perhaps you?) would take this same reasoning and say that if it's actually £5 in the other envelope then it's not possible that it's £20 and if it's actually £20 in the other envelope then it's not possible that it's £5.

I don't share this view on probability. We can still talk about the probable outcome of an event that's already happened. If you've flipped a coin and hidden the result from me then I will say that it's equally likely to be heads as tails (and it must be one of these). If you've chosen X = 5 or X = 10 and placed the amounts in the envelopes then I will say that it's equally likely to be X = 5 as X = 10 and so that if there's £10 in my envelope then it's equally likely that the other envelope contains £5 as £20 (and it must be one of these).
Benkei July 11, 2018 at 15:09 ¶ #195946
Quoting Srap Tasmaner
If only the amount in the first envelope, the envelope you chose and perhaps are even allowed to open, is fixed, and the second envelope is then loaded with either half or twice the amount in yours, then switching is the correct strategy. This is the variant Barry Nalebuff calls the Ali Baba problem.


Well, uhmm... no...? The first envelope has an amount that is either X or 2X, the other is either X or 2X. The other is not half or twice the amount of X. The other envelope is only half iff the opened envelope contains 2X and it's only twice as much iff the opened envelope contains X.
Benkei July 11, 2018 at 15:20 ¶ #195949
Quoting Michael
I recall an earlier discussion where another poster (a frequentist) said that once a coin had been tossed it would be wrong to say that it's equally likely to be heads as tails (even if we haven't looked); instead if it's actually heads then it's not possible that it's tails and if it's actually tails then it's not possible that it's heads. I believe Jeremiah and Srap (and perhaps you?) would take this same reasoning and say that if it's actually £5 in the other envelope then it's not possible that it's £20 and if it's actually £20 in the other envelope then it's not possible that it's £5.


No, I don't think I would agree with that either.

Quoting Michael
We're dealing with a situation where we know that there's £10 in our envelope. What's the value of the other envelope? It's possible that it's £5, as the envelope set could be £5 and £10, and it's possible that it's £20, as the envelope set could be £10 and £20. It's not possible that it's £1 as the envelope set can't be £1 and £10.


The total sum possible for both envelopes in the above assuming one envelope contains 10 GBP is either 3x = 30 or 3x = 15 but we know it's either one of the two, it cannot be both. Your expression however allows for both and therefore has to be wrong by necessity.

I also refer to my earlier comment that the above expression, if we allow for unlimited switching of envelopes, would entail having to switch indefinitely which is absurd.
Michael July 11, 2018 at 15:25 ¶ #195951
Quoting Benkei
Your expression however allows for both and therefore has to be wrong by necessity.


It doesn't.

The total sum possible for both envelopes in the above assuming one envelope contains 10 GBP is either 3x = 30 or 3x = 15 but we know it's either one of the two, it cannot be both.


I know it cannot be both. It's one or the other. If 3X = 30 then there's £20 in the other envelope. If 3X = 15 then there's £5 in the other envelope. So the value of the other envelope is either £20 or £5. These are the (only) two possible values. And either because we know that the value of X was chosen at random or because we have no reason to believe that one is more likely than the other, we assign a probability of 0.5 to each being the case.
Michael July 11, 2018 at 15:30 ¶ #195953
Quoting Benkei
I also refer to my earlier comment that the above expression, if we allow for unlimited switching of envelopes, would entail having to switch indefinitely wich is absurd.


We wouldn't, because we've opened an envelope in this example. I know that there's £10 in my envelope. If from this we can deduce an expected value of £12.50 in the other envelope then once we switch we have no reason to switch back. Instead we have a reason to stick.
Jeremiah July 11, 2018 at 15:40 ¶ #195954
Reply to Srap Tasmaner The error is in making new assumptions based on Y. Before you see Y you know that envelope A, the one you were given, has the possibility to be X or 2X. Which reminds true even after seeing Y, as you don't know if it is Y equals X or 2X. So as to the uncertainty as to if you have X or 2X, which determines what envelope B is, Y provides no useful information, therefore it is not appropriate to change your existing uncertainty based on Y. If you change your assumptions based on Y then you include false information into solution and that is why you get misleading results.
Benkei July 11, 2018 at 15:41 ¶ #195955
Reply to Michael Would you agree that your expression allows the envelopes to carry values of either X, 2X or X/2?

Quoting Michael
We wouldn't, because we've opened an envelope in this example. I know that there's £10 in my envelope. If from this we can deduce an expected value of £12.50 in the other envelope then once we switch we have no reason to switch back.


Fair enough. That earlier comment was a reply to the original OP so I suppose with this amendment it doesn't hold water any more (although I haven't worked through it so I'm just assuming you're right).

Michael July 11, 2018 at 15:55 ¶ #195956
Quoting Benkei
Would you agree that your expression allows the envelopes to carry values of either X, 2X or X/2?


No. One envelope has £10 and the other envelope has either £5 or £20. All this talk of X and 2X just confuses matters. It is just the case that there's a 50% chance that the other envelope contains £20 and a 50% chance that the other envelope contains £5.
Srap Tasmaner July 11, 2018 at 15:59 ¶ #195957
Quoting Michael
We wouldn't, because we've opened an envelope in this example. I know that there's £10 in my envelope. If from this we can deduce an expected value of £12.50 in the other envelope then once we switch we have no reason to switch back. Instead we have a reason to stick


Here's a proof (which you won't accept) that opening the envelope is irrelevant, and that your reasoning should be symmetrical.

Suppose you choose an envelope and then the facilitator tells you the other envelope has $10 in it. Then you would choose not to switch because yours has an expected value of $12.50.

Eventually you recognize that you would reason the same way whichever envelope you had chosen.
Michael July 11, 2018 at 16:01 ¶ #195958
Quoting Srap Tasmaner
Suppose you choose an envelope and then the facilitator tells you the other envelope has $10 in it. Then you would choose not to switch because yours has an expected value of $12.50.


I agree. I would choose not to switch.
Srap Tasmaner July 11, 2018 at 16:10 ¶ #195959
Reply to Michael
And it doesn't bother you that if you know the value of A you want B, but if you know the value of B you want A?
Srap Tasmaner July 11, 2018 at 16:21 ¶ #195960
Reply to Michael
How did you choose an envelope in the first place?

Suppose you have chosen, perhaps by flipping a coin, if the facilitator then offers to tell you the value of either, how will you choose which value to learn? By flipping a coin?
Michael July 11, 2018 at 16:23 ¶ #195961
Reply to Srap Tasmaner If one guarantees me £10 and the other could be £5 or £20 then I'm going to want the one that could be £20. It doesn't make a difference to me if it's my starting envelope or the other envelope.
Michael July 11, 2018 at 16:28 ¶ #195962
I wonder if this is anything like Deal or No Deal. We're down to the last two boxes. Yours either has £20,000 or it has £5,000. The Banker offers you £10,000 to walk away. Do you accept the offer or do you take a risk and hope that your box has £20,000?

The sample space that describes your box and the Banker’s offer could be written as [X, 2X], correct? So it seems comparable. But wouldn’t you agree that the expected value of your box is greater than the offer, and so that assuming you can stomach a loss of £5,000, you should decline?
Srap Tasmaner July 11, 2018 at 16:59 ¶ #195964
Reply to Michael
For DOND you accept any offer in the neighborhood of the expected payout, because the banker usually low-balls you. (There was extensive discussion among math types about whether it's a Monty Hall variant.)

Note, yet again, that all the values that could be in the cases are known from the start. There is no speculation about possible outcomes.
Michael July 11, 2018 at 17:20 ¶ #195967
Quoting Srap Tasmaner
Note, yet again, that all the values that could be in the cases are known from the start. There is no speculation about possible outcomes


What difference does that make? Replace the contestant with someone who doesn’t know anything about the opened boxes. What’s the expected value of his box? Should he decline the offer? Remove the unopened box that isn’t his and just tell him that either the Banker’s offer of £10,000 is X and his box is 2X or the Banker’s offer of £10,000 is 2X and his box is X. What’s the expected value of his box? Should he decline the offer?
Srap Tasmaner July 11, 2018 at 17:58 ¶ #195971
Quoting Michael
What’s the expected value of his box?


Unknown.

In DOND, after each case is opened I can tell you the total value and the average value of all the remaining cases. To the penny. With no guessing and no variables.
Srap Tasmaner July 11, 2018 at 18:16 ¶ #195981
Reply to Michael
When I calculate the total value of our envelopes to be U + 10, and the average to be U/2 + 5, I'm right. Whatever U turns out to be, these calculations will turn out to be correct.

How do you calculate the total and average value of all the envelopes, including your 10? What are the numbers?
Dawnstorm July 11, 2018 at 18:29 ¶ #195986
Okay, we have envelopes that contain a certain value. This thread has used X for the values in the envelope and [X, 2X] for the sample space of an envelope. This thread has also used Y for the value of an envelope. Here's the thing:

We can define the value in the envelope in relation to each other, and we get A [X, 2X], B [X, 2X], where X is the smaller of the two values. (Should we decide to make X the bigger of the two values we get A[X/2, X], B[X/2,X].)

But we can also define the envelopes in relation to each other. We get:

A [Y], B[Y/2, 2Y]

Note that this defines the relationship of the envelopes, in a way the other notation doesn't:

A[X, 2X], B[X, 2X] allows:

A = X, B = X
A = 2X, B = 2X.

We need additional restriction (such as A=/= B) to rule these out. We need no additional restrictions if we're looking at the contents of the envelope directly, rather than looking at the values first and then wondering what is in which envelope.

A [Y], B[Y/2, 2Y]

is a shorter and more complete way to look at "One envelope contains twice as much money as the other", than A[X, 2X], B[X,2X].

We're not making additional assumptions, we're just using different variables as our basis.

A[X, 2X], B[X, 2X] -- The values in the envelope defined in relation to each other.

A[Y], B[Y/2, 2Y] -- The envelopes defined in relation to each other, according to their relative value.

If we know that one of the values is 10, but not in which envelope it is, we get:

A[X[5,10],2X[10,20]], B[X[5, 10],2X[10,20]]

or

A[10], B[5, 20]

It's exactly the same thing, looked at from two different perspectives. There are no new assumptions. In both cases, we don't know whether 10=X or 10=2X. In the former notation we have to enter 10 in both envelopes and wonder which one picked. In the latter we just enter 10 in the letter we picked (obviously, since it's the one we've seen), and wonder what's in the other. And both notations have three values: 5, 10, 20. They're just organised into different either/or structures, because the notations define the letters differently (interchangable; defining in one in term of the other).

Srap Tasmaner July 11, 2018 at 18:37 ¶ #195988
Reply to Michael
You have an average total value of 22.5 and an average envelope value of 11.25. Both of those values always turn out to be wrong.
Srap Tasmaner July 11, 2018 at 19:51 ¶ #196003
Quoting Srap Tasmaner
average total value


That we're driven to use such a phrase is apparently the whole problem.

Can this sort of thing be done rigorously? What would we have if we did?
Dawnstorm July 11, 2018 at 22:29 ¶ #196053
So how's this:

A, B = two envelopes; X = the smaller of two values, 2X = the greater of two values; Y = the known value of one envelope

P (A=X and B= 2X) + P (A=2X and B=X) = 1

Corollary: P (A=X and B=X) + P (A=2X and B=2X) = 0

This merely describes the set-up.

P (Y=X) + P (Y=2X) = 1

This describes the fact that if we know one value, we cannot know whether it's the samller or the bigger value (but it has to be one).

From this we get:

P (A=Y and B=2Y) + P (A=2Y and B=Y) + P (A=Y/2 and B=Y) + P (A=Y and B=Y/2) = 1

Corollary: P (A=Y and B=Y) + P (A=2Y and B=2Y) + P (A=Y/2 and B=2Y) + P(A=2Y and B=Y/2) = 0 [At least one value is by definition Y, and because of the set-up, both can't be Y.]

Now we look into envelope A and discover Y. This renders all the probabilities 0 where A=/=Y, so we get:

P (A=Y and B=2Y) + P (A=Y and B=Y/2) = 1

Corollary: P (A=Y and B=Y) + P (A=Y/2 and B=2Y) + P(A=2Y and B=Y/2) + P (A=2Y and B=Y) + P (A=Y/2 and B=Y) = 0

Did I make a mistake anywhere here? To me, this proves that saying both envelopes have to include either X or 2X and that if one envelope contains Y the other has to contain either Y/2 or 2Y are the same thing from a different perspective.
andrewk July 11, 2018 at 22:38 ¶ #196057
Quoting Michael
there's a 50% chance that the other envelope contains £20 and a 50% chance that the other envelope contains £5.

The resolution of the apparent paradox is that the probabilities are not 50:50 for most values of Y.

Either the player has not adopted a Bayesian prior distribution for X, in which case she has no basis for assigning any probabilities to the options of U=X and U=2X, or she uses the prior distribution to calculate the probabilities. (U is the value in the unopened envelope)

It is fairly straightforward to show (and I did so in my note) that when she does that, regardless of the prior distribution adopted, the probability of U=2X depends on the observed value Y and will be more than 50% up to a certain calculable critical point after which it will be less than 50%.

The case where the prior distribution is X=5 or 10 with equal probability demonstrates this. If Y=5 then it is certain that U=2X=10. If Y=20 it is certain that U=X=10. If Y=10 then the odds are 50:50 that U=2X, ie 5 or 20.

There are many different ways the calculations for this can be approached, and we've seen several of them in this thread. But whatever approach one is using, one should subject it to a hard critical eye when a 50:50 assumption is made because in many cases, and possibly in all cases when it's about what's in the unopened envelope, that assumption will not be justified.
Jeremiah July 11, 2018 at 23:27 ¶ #196069
The more I read the responses to this thread, the more appreciation I grow for a good quality book.
Jeremiah July 12, 2018 at 01:45 ¶ #196080
What is the point if you are just modeling yourself? Math and science should help us diverge from the self and step closer to the truth.
Efram July 12, 2018 at 07:44 ¶ #196131
25 pages of reading later...

I'm going to try to come at this from a different angle to try to break the stalemate. I'm in a curious position because I can somewhat see where both sides are coming from.

I think it would help to clarify one thing first: The rule that you could potentially win more than you risk losing holds true regardless of the amount in the envelope - so opening the chosen envelope is irrelevant because a) it doesn't physically change anything and b) you don't learn anything objectively significant that you don't already know.

So we can temporarily take opening the envelope and learning any amounts out of the equation. I include this provision because I think it helps dispel the illusions / the mental trickery / the human intuition, etc. that comes from thinking about fixed amounts of money (I'll elaborate on this later).

So having chosen envelope A, you could say that if envelope B contains twice the amount, you potentially gain more than you'd potentially lose by switching - but importantly, you can also say that if A contains twice the amount as B, you potentially gain more than you'd lose by staying. So logically/mathematically/statistically, there's no advantage to either strategy.

So I think the mistake here was only applying this logic to switching, without realising it applies to staying. Also, I think the promise of 2X a known amount creates the illusion and the desire to chase money that potentially doesn't even exist.

(You may also say that any statistical method that searches for an objectively superior strategy and depends on opening the envelope, must be inherently flawed - because as explained above, it's an insignificant step revealing objectively useless information - so if you're somehow making it significant, you're doing something wrong.)

Now to revisit the idea of knowing the amount in the envelope: I think using amounts like £5/10/20 is misleading because £5 intuitively feels like a throwaway amount that anyone would be happy to lose. Instead, what if your chosen envelope contained a cheque for £10 million? Would you throw away £5m chasing an additional £10m that may not even exist?

And here it gets interesting for me because... given a £10 envelope, I really would switch because a £5 loss is nothing. Given a £10m envelope, I'd stay. So I think there is an argument to be made that, on an individual basis, depending entirely on the circumstances surrounding the person (their financial situation, their priorities and such) and the amount of money on offer, in some cases they may choose to gamble away their known amount chasing a higher amount, accepting that this is a purely subjective decision and that it doesn't increase their chances of maximising their profit, it's not an inherently superior strategy, etc. It's purely, "In this instance, I'd be happy to lose £x in the pursuit of potentially winning £y."

... So I think another flaw here was this assumption/assertion that a gamble with a 2:1 payout and 50% chance of winning is always worth taking. Again, I would not bet £5m on the 50% chance of getting £10m back. You could in fact draw up many scenarios in which the gamble would be stupid (e.g. where the amount you're gambling away would be life-changing or where losing that money would be life-threatening, whereas the higher amount you could potentially win would have diminishing returns (again, I could have some fun with £5m, a lot of fun with £10m, but wouldn't even know what to do with £20m))

In summary:

I disagree that you can make the absolute claim that switching is always the better strategy, in the sense that it's either always in the person's best interests (which is subjective and may be wrong, such as in the personal example I gave) or on the basis that it is somehow statistically/logically/strategically superior (which isn't true at all). But I do agree that an individual in a real world situation may choose to gamble and it may be the "right" choice for them specifically.

(I may yet change my mind on all of this after I've wrapped my head around it a bit more)
Benkei July 12, 2018 at 08:57 ¶ #196139
Reply to Michael Funny, I was just thinking how inserting an amount just confuses things. 10 GBP is as much a meaningless placeholder as Y or A to denote the value of the envelope in that respect. Let's stick to what we know, we don't know the value of either envelope but we do know one is twice as much as the other. So one is X and the other is 2X for a total of 3X for both envelopes.

Let's name the envelopes Y and Z (note, they do not denote amounts). The expression "if Y = X then Z is 2X or X/2" only adds up to 3X in one instance, the rest results in false conclusions as it contradicts the premise that the total should always be 3X. Knowing that Y is either X or 2X, we get four possibilities:

If Y = X then Z = 2X for a total of 3X is true.
If Y = X then Z = X/2 for a total of 1.5X is false.
If Y = 2X then Z = 2X for a total of 4X is false.
If Y = 2X then Z = X/2 for a total of 2.5X is false.

This suggests that replacing the variable of one envelope with a fixed amount or a fixed placeholder messes up things. I'm not sure why. Maybe @andrewk can tell me.
Michael July 12, 2018 at 09:21 ¶ #196141
Quoting Benkei
"if Y = X then Z is 2X or X/2" only adds up to 3X in one instance, the rest results in false conclusions as it contradicts the premise that the total should always be 3X.


You're conflating. When you say "if Y = X then Z is 2X or X/2" you're defining X as the value of Y, but when you say that the total should be 3X you're defining X as the smaller amount, which might not be Y.

What you should say is:

If Y = X, where X is the smaller amount, then Z = 2X, and if Y = 2X, where X is the smaller amount, then Z = X.

Now when we introduce Y = 10 we have two conditionals:

1. If Y = 10 and Y = X, where X is the smaller amount, then Z = 2X and Z = 20
2. If Y = 10 and Y = 2X, where X is the smaller amount, then Z = X and Z = 5

One of these antecedents is true and one of these is false. I assign a probability of 50% to each, either because I know that the value of X was chosen at random from a distribution that includes 5 and 10 or because I have no reason to prefer one over the other (the principle of indifference). So there's a 50% chance that Z = 20 (if X = 10 was selected) and a 50% chance that Z = 5 (if X = 5 was selected).
Benkei July 12, 2018 at 09:41 ¶ #196143
Reply to Michael That's how you proposed it originally.

In the above you have an inherent contradiction in your conditionals as X and 2X are both 10. As a result and as you correctly state one of them is false by necessity. For probability both outcomes should be at least possible. Otherwise, one outcome carries the probability of 0% and the other 100%. That you don't know which one is true or false does not result in an equal probability.

Michael July 12, 2018 at 09:46 ¶ #196144
Quoting Benkei
In the above you have an inherent contradiction in your conditionals as X and 2X are both 10.


Obviously. That's how different conditionals work. Let's say I toss a coin and record the result R:

1. If R = heads then ...
2. If R = tails then ...

1 and 2 have contradictory antecedents. But I'm not saying that both the antecedent of 1 and the antecedent of 2 are true. One is true and one is false, with a 50% chance of each being true. And the same with my example with the envelopes:

1. If X = 10 then ...
2. If 2X = 10 then ...

Or:

1. If X = 10 then ...
2. If X = 5 then ...

Or:

1. If the £10 envelope is the smaller envelope then ...
2. If the £10 envelope is the larger envelope then ...
Benkei July 12, 2018 at 10:04 ¶ #196149
Quoting Michael
1. If R = heads then ...
2. If R = tails then ...

1 and 2 have contradictory antecedents. But I'm not saying that both the antecedent of 1 and the antecedent of 2 are true. One is true and one is false, with a 50% chance of each being true. And the same with my example with the envelopes:

1. If X = 10 then ...
2. If 2X = 10 then ...


Well, you're turning it around here. To illustrate with coins it would be something weird like:

If R = heads then
If 2R = heads then

The correct one is:

Quoting Michael
1. If X = 10 then ...
2. If X = 5 then ...


If X = 10 then the other is 20
If X = 5 then the other is 10

In both cases you have now assumed you're opening the smaller envelope and the other HAS to be the bigger envelope. Both outcomes are in principle possible as the total is indeed 3X.
Michael July 12, 2018 at 10:21 ¶ #196153
Quoting Benkei
If X = 10 then the other is 20
If X = 5 then the other is 10

In both cases you have now assumed you're opening the smaller envelope and the other HAS to be the bigger envelope.


You're missing the "and Y = 10" part:

1. If Y = 10 and X = 10 then ...
2. If Y = 10 and X = 5 then ...

Or to put it in simple terms:

1. If my £10 envelope is the smaller envelope then ...
2. If my £10 envelope is the larger envelope then ...

These are the perfectly reasonable conditionals I'm considering, and I'm assigning a probability of 50% to each antecedent.
Jeremiah July 12, 2018 at 11:55 ¶ #196166
Reply to Michael

In relation to the problem in the OP:

Why do you need to include Y, Michael? There is no justified reason to do that.

It does not provide updated information for the original uncertainty of X or 2X, which is reason enough to leave it out and it will absolutely give untrue information. One of the values in your domain is not true, one of your subjective possible outcomes is not an objective possible outcome. So why are you modeling the subjective, when you can model the objective? Why is your subjective model superior to an objective model?


Jeremiah July 12, 2018 at 12:10 ¶ #196167
There has been no justified reason at all as to why we should engage in fantasy over reality.
Michael July 12, 2018 at 13:08 ¶ #196170
Quoting Jeremiah
Why do you need to include Y, Michael?


It's in your OP:

"Initially you are allowed to pick one of the envelopes, to open it, and see that it contains $Y."

It does not provide updated information for the original uncertainty of X or 2X


I know. But as you say, our £10 could be X or our £10 could be 2X. If our £10 is X then X = 10 and the other envelope contains 2X = £20. If our £10 is 2X then X = 5 and the other envelope contains X = £5.

So although it doesn't help us determine if we have the smaller envelope (X) or the larger envelope (2X), it does help us determine how much could possibly be (or not be) in the other envelope. It could be £5. It could be £20. It can't be £40.

With that new information we can make a decision, and I think @Efram is right when he says this:

Now to revisit the idea of knowing the amount in the envelope: I think using amounts like £5/10/20 is misleading because £5 intuitively feels like a throwaway amount that anyone would be happy to lose. Instead, what if your chosen envelope contained a cheque for £10 million? Would you throw away £5m chasing an additional £10m that may not even exist?

And here it gets interesting for me because... given a £10 envelope, I really would switch because a £5 loss is nothing. Given a £10m envelope, I'd stay.


If there's £10 in my envelope then I would take the risk and switch, hoping for £20. If there's £10,000,000 in my envelope then I would say that sticking is better than switching because the potential loss of £5,000,000 is too significant.

I think this notion that the answer to the question is determined by whether or not we'd win or lose in the long run over repeated games (with various starting envelopes and possible values of X), and that if we'd break even then it doesn't matter what we do, is short-sighted.
RainyDay July 12, 2018 at 14:13 ¶ #196183
Congratulations (almost) everyone for keeping a cool head through 25 pages. I wonder if acceptance/rejection of the principal of indifference (https://en.wikipedia.org/wiki/Principle_of_indifference) is what divides many people.

I'd also like to see the original problem rephrased to eliminate personal valuations of the outcome. There's little value in the question if we can all argue along lines of "oh well, I always switch 'cause I'm curious" or "after I see the first amount, I already feel like a winner and that's enough for me".
Jeremiah July 12, 2018 at 15:40 ¶ #196192
Reply to Michael The simple fact that it is there is not a reason to include it. Determining what information to include is part of the process, you need actual justification, especially considering that your apporach leads to an impossible outcome. And I am only concerned with formal justifications.
andrewk July 12, 2018 at 22:30 ¶ #196267
Quoting Benkei
Let's name the envelopes Y and Z (note, they do not denote amounts). The expression "if Y = X then Z is 2X or X/2" only adds up to 3X in one instance, the rest results in false conclusions as it contradicts the premise that the total should always be 3X. Knowing that Y is either X or 2X, we get four possibilities:

If Y = X then Z = 2X for a total of 3X is true.
If Y = X then Z = X/2 for a total of 1.5X is false.
If Y = 2X then Z = 2X for a total of 4X is false.
If Y = 2X then Z = X/2 for a total of 2.5X is false.

This suggests that replacing the variable of one envelope with a fixed amount or a fixed placeholder messes up things. I'm not sure why. Maybe andrewk can tell me.

Hi Benkei. Nice to see you join this discussion.

Since X denotes the smaller of the two amounts, the first statement is true and the other three are false. But the player cannot use the statements because she only knows Y. She doesn't know what X is, and unless she adopts a Bayesian prior distribution for X she doesn't know the probability that Y=X either, so she can't use conditionals.

I understand that people feel discomfort with the use of Bayesian priors and feel that your expectation of gain is then based on your own guessed distribution, which you know to be wrong, but that's how Bayesian methods work. For all their limitations, they are all we have (except for a complicated exception that I'll mention further down, and which I doubt anti-Bayesians will feel any more comfortable with).

If we refuse to use a Bayesian prior then what can we say? The value X is a definite value, known to the game host, not a random variable. We have know the value Y, having seen it in the opened envelope.

If we insist on modelling the situation from a full-knowledge perspective rather than our limited-knowledge perspective, then the gain from switching is X with certainty if Y=X and -X with certainty if Y=2X. But we can't know which is the case so the calculation is useless. We can't introduce probabilities of one or the other cases being actual because we are modelling from a position of full knowledge and only one of them is true.

Some of the calculations adopt a half-way position where they make X a fixed, non-random amount, and the coin flip result a Bernoulli(0.5) random variable, such that Y=X if B=0, otherwise Y=2X. Such a calculation reflects the state of knowledge of the game host, if we assume the host knows X but doesn't know which envelope has the larger amount in it.

Under such an approach the expected gain from switching is zero.

But we ask, why is it reasonable to model the knowledge limitation of the host by randomness, but not to do the same for the player? If that approach is reasonable for the host, it is reasonable for the player, and it is more appropriate to use a Bayesian approach, since it is the player's expectation that we have been asked about.

On the other hand, if modelling knowledge limitation by randomness is not considered reasonable then we are forced back to where everything is modelled as known and the expected gain is either X or -X with certainty, but we don't know which applies.

Now for that exception. If one doesn't like that Bayesian approaches model gains by assuming the prior distribution is correct, then we could introduce a distribution for errors in the distribution.

Say our prior is a lognormal distribution. That has two parameters mu and sigma, for which we assume values to do our calcs. We could reflect our lack of certainty about the parameters by making those two parameters themselves random variables, to reflect our uncertainty about those. Then the calculation will reflect our uncertainty about the prior.

But guess what happens! It turns out that this approach is identical to assuming a Prior that is the convolution of the original prior with the distributions of the two parameters. So all we've done by modelling the fact that our prior is a guess is change to a different prior. We can repeat that process as often as we like - modelling the uncertainty in the uncertainty in the uncertainty in .... - and we'll still end up with a Bayesian prior. It'll just be more dispersed than the one we started with.

We might reject the parametric approach as too constrained and instead model uncertainty directly on the CDF of the prior. That gets messy but it will still end up with the same general outcome - a single but different Bayesian prior.

Summary

We have three options:

1. Treat X and Y as both known. Then there is no randomness and the switch gain is either X with certainty or -X with certainty, so the expected gain is equal to that certain gain but the player doesn't know the amount, so this approach is useless to her.

2. Treat Y as known and model X using a Bayesian prior. This leads to a rule under which the player can calculate a value c such that her expected switch gain is positive if Y<c and negative if Y>c.

3. Treat X as known and Y as unknown. Then the switch gain has a distribution of X or -X with even odds, so the expected switch gain is zero. This is the approach defended by srap. The approach is coherent but it begs the question of why it is valid to model lack of knowledge about Y/X by randomness, but not lack of knowledge about X.

Note that approaches 2 and 3 both predict zero as expected gain from blind switching. The difference between them is that 2 gives a strategy for switching based on the observed value of that, when followed, gives a positive expected gain from switching.
JeffJo July 13, 2018 at 00:40 ¶ #196299
Reply to Jeremiah
You are playing a game for money. There are two envelopes on a table.
You know that one contains $X and the other $2X, [but you do not
know which envelope is which or what the number X is]. Initially you
are allowed to pick one of the envelopes, to open it, and see that it
contains $Y . You then have a choice: walk away with the $Y or return
the envelope to the table and walk away with whatever is in the other
envelope. What should you do?

Imagine three variations of this game:
  • Two pairs of envelopes are prepared. One pair contains ($5,$10), and the other pair contains ($10,$20). You pick a pair at random, and then pick an envelope from that pair. You open it, and find $10. Should you switch? Definitely. The expected value of the other envelope is ($5+$20)/2=$12.50.
  • Ten pairs of envelopes are prepared. Nine pairs contain ($5,$10), and the tenth pair contains ($10,$20). You pick a pair at random, and then pick an envelope from that pair. You open it, and find $10. Should you switch? Definitely not. The expected value of the other envelope is (9*$5+$20)/10=$6.50.
  • You are presented with ten pairs of envelopes. You are told that some pairs contain ($5,$10), and the others contain ($10,$20). You pick a pair at random, and then pick an envelope from that pair. You open it, and find $10. Should you switch? You can't tell.


(And note that in any of them, you know you will get $10 if you switch from either $5 or $20.)

The error in most analyses of the Two Envelope Problem, is that they try to use only one random variable (you had a 50% chance to pick an envelope with $X or $2X) when the problem requires two (what are the possible values of X, and what are the probabilities of each?).

The Principle of Indifference places a restriction on the possibilities that it applies to: they have to be indistinguishable except for their names. You can't just enumerate a set of cases, and claim each is equally likely. If you could, there would be a 50% chance of winning, or losing, the lottery. In the Two Envelope Problem, you need to know the distribution of the possible values of $X to answer the question
Jeremiah July 13, 2018 at 02:05 ¶ #196318
Quoting JeffJo
ou can't just enumerate a set of cases, and claim each is equally likely. If you could, there would be a 50% chance of winning, or losing, the lottery.


That is a very bad understanding of what a sample space and an event is. You are not applying your Principle of Indifference there, which states from your link: "The principle of indifference states that if the n possibilities are indistinguishable except for their names, then each possibility should be assigned a probability equal to 1/n." n in this case would be the total possible combinations of the lottery numbers.




Jeremiah July 13, 2018 at 02:11 ¶ #196319
Furthermore, it makes no sense to use a probability density curve on this problem, considering X would only be selected ONCE, which means X<2X ALWAYS (given that X is positive and not 0). That means no matter what X is the expected value will always be 1/2X+X, in every single case.

If you try to fit X to a statistical distribution you are just piling assumptions on top of assumptions. You are making assumptions about the sampling distribution and the variance. Assumptions in which you do not have the data to justify. You are also making assumptions about how X was even selected. Assumption on top of assumption on top of assumption. . . .

Ya, great math there.
Jeremiah July 13, 2018 at 02:20 ¶ #196320
There is a reason we need to consider X as an unknown and approach it as such, with algebra. To do otherwise means making a bunch of baseless assumptions.

I know algebra is not the most glamorous math, it, however, is very robust, which makes it the more appropriate tool when dealing with these unknowns.
Andrew M July 14, 2018 at 04:31 ¶ #196688
Quoting andrewk
2. Treat Y as known and model X using a Bayesian prior. This leads to a rule under which the player can calculate a value c such that her expected switch gain is positive if Y<c and negative if Y>c.


I think the issue is that even if you know Y from opening the initial envelope, the expected gain from switching is still zero if you don't also know c.

You could potentially calculate c if you observed many runs of the experiment and c remained constant. In which case you could condition on amounts less than or equal to c and in those cases calculate a positive expected gain from switching.

However for a single run, c just is the lower amount in the two envelopes and is, per the problem definition, unknown.
andrewk July 14, 2018 at 04:38 ¶ #196690
Quoting Andrew M
I think the issue is that even if you know Y from opening the initial envelope, the expected gain from switching is still zero if you don't also know c.

c is not an observer-independent item that can be known or not. It is a feature of the Bayesian prior distribution the player adopts to model her uncertainty.

From the God's-eye (ie omniscient) point of view, which is perspective 1 from the quoted post, there is no c, because there is no non-trivial probability distribution of X. X is a fixed quantity, known only to God and to the game show host.

So we cannot talk meaningfully about 'the real value of c'.
Andrew M July 14, 2018 at 04:40 ¶ #196691
Quoting andrewk
So we cannot talk meaningfully about 'the real value of c'


Can you give a concrete example where such a value would be used?
andrewk July 14, 2018 at 04:52 ¶ #196692
Reply to Andrew M I gave it above. The player would use it. They would estimate L, the maximum possible payout (eg the budget of the game show). The simplest approach is to then set c=L/2 and switch iff Y<c. That strategy delivers a positive expected gain under perspective 2.
Andrew M July 14, 2018 at 06:09 ¶ #196703
Reply to andrewk Yes, assuming that the player does accurately estimate the maximum possible payout (and the procedure for generating the envelope amounts). If she doesn't, then the positive expected gain calculation is invalid.
andrewk July 14, 2018 at 07:13 ¶ #196707
Reply to Andrew M She doesn't have to estimate it accurately. There are only three possibilities.

A. X<2X<c. In this case the expected gain from switching is zero.
B. c<X<2X. In this case the expected gain from switching is zero.
C. X<c<2X. In this case the expected gain from switching is X.

So for the competitor to decide not to use the strategy, she would have to be absolutely certain that case C is impossible.
Jeremiah July 14, 2018 at 11:06 ¶ #196733
Quoting andrewk
From the God's-eye (ie omniscient) point of view, which is perspective 1 from the quoted post, there is no c, because there is no non-trivial probability distribution of X. X is a fixed quantity, known only to God and to the game show host.
And algebra.
Jeremiah July 14, 2018 at 11:08 ¶ #196736
The difference between the two envelopes will always be X and you don't need to be God to understand that very simple concept.
Srap Tasmaner July 14, 2018 at 20:09 ¶ #196839
((urk. still don't have it.))
Jeremiah July 15, 2018 at 01:44 ¶ #196911
I have been messing with this in R, and wrote a function which simulates the game. Note that is not a simple repeated sample from a predefined sample space. It simulates the game, by selecting X randomly then randomly places X or 2X into A. Then X or 2X into B based on what is in A. It then returns the value of both A and B.

The function, which is called two.envelopes, is one go at the game, and then the function replicate can be used to run it several times in a row. Which I did then output those to a matrix.

I ran the game simulation under 4 different conditions: Where X is chosen from a normal distribution, where X is chosen from a uniform distribution, where is X is chosen from a Cauchy distribution and where X is sampled from an interval scale. The function could be used as well to do actual statistical analyses either Classical or Bayesian, by generating enough simulated data to support such an approach.

I know these efforts will be lost on some people, but it does provide a visual summary which demonstrates the distribution in which X was selected from is not significant when assessing the possible outcome of envelope A and B concerning X or 2X.

Also, this gives results that can be reviewed which are not dependent on defining a sample space or on calculating an expected value.

Normal Distribution:

two.envelopes <- function(){
x <- (rnorm(1))
x <- (abs(as.numeric(format(round(x, 3)))))*10
#randomly selects a number
#limits the number of decimal places x can have and muiltples x by 10 to simluate realistic dollar values.
p <- c(x,2*x)
A <- sample(p, 1, replace=F)
#creates a vector with x and 2x then randomly selects one for A.
if (A == x) {
B <- 2*x
} else {
(B <- x)
}
return(c(A,B))
}
#sets the value for B based on: if A = x then B = 2x or if A = 2x then B = x
g <- t(replicate(100, two.envelopes()))
head(g)

#results

[,1] [,2]
[1,] 5.23 10.46
[2,] 5.48 10.96
[3,] 25.60 12.80
[4,] 6.17 12.34
[5,] 3.88 7.76
[6,] 7.59 15.18




Uniform distribution:


two.envelopes <- function(){
x <- (runif(1))
x <- (abs(as.numeric(format(round(x, 3)))))*10
#randomly selects a number
#limits the number of decimal places x can have and muiltples x by 10 to simluate realistic dollar values.
p <- c(x,2*x)
A <- sample(p, 1, replace=F)
#creates a vector with x and 2x then randomly selects one for A.
if (A == x) {
B <- 2*x
} else {
(B <- x)
}
return(c(A,B))
}
#sets the value for B based on: if A = x then B = 2x or if A = 2x then B = x
g <- t(replicate(100, two.envelopes()))
head(g)

#results

[,1] [,2]
[1,] 27.20 13.60
[2,] 28.72 14.36
[3,] 12.49 24.98
[4,] 12.95 25.90
[5,] 61.18 30.59
[6,] 2.66 1.33



Cauchy distribution:


two.envelopes<- function(){
x <- (rcauchy(1, location = 0, scale = 1))
x <- (abs(as.numeric(format(round(x, 3)))))*10
#randomly selects a number
#limits the number of decimal places x can have and muiltples x by 10 to simluate realistic dollar values.
p <- c(x,2*x)
A <- sample(p, 1, replace=F)
#creates a vector with x and 2x then randomly selects one for A.
if (A == x) {
B <- 2*x
} else {
(B <- x)
}
return(c(A,B))
}
#sets the value for B based on: if A = x then B = 2x or if A = 2x then B = x
g <- t(replicate(100, two.envelopes()))
head(g)

[,1] [,2]
[1,] 10.22 20.44
[2,] 24.54 12.27
[3,] 2.05 4.10
[4,] 8.96 4.48
[5,] 15.44 7.72
[6,] 13.74 27.48



Interval Scale:

two.envelopes <- function(){
x <- (sample(1:100, 1))
#randomly selects a number
p <- c(x,2*x)
A <- sample(p, 1, replace=F)
#creates a vector with x and 2x then randomly selects one for A.
if (A == x) {
B <- 2*x
} else {
(B <- x)
}
return(c(A,B))
}
#sets the value for B based on: if A = x then B = 2x or if A = 2x then B = x
g <- t(replicate(100, two.envelopes()))
head(g)

#results

[,1] [,2]
[1,] 27 54
[2,] 136 68
[3,] 33 66
[4,] 14 28
[5,] 30 60
[6,] 57 114


The thing to notice here is that in all cases the absolute value of the difference between column one and column two is always equal to the lesser of the two (save rounding errors). The lesser of the two is X.


Jeremiah July 15, 2018 at 13:17 ¶ #197078
I changed the code a bit to come up with another visual demonstration. I changed the two.envelopes function to just output A and then copied it to another function called two.envelopes.s which outputs B.

What this simulates is if you never switch then you walking away with A and if you always switch then you walk away with B. I used a normal distribution for this example but honestly you can do the same thing for any distribution since the content of A and B are determined by the same chance event.

The point of this demonstration is to show that the possible distribution of A is the same as the possible distribution of B so I have included some graphs that can be visually compared, and I use a Kolmogorov-Smirnov Tests, also known as the K-S test. This is a non-parametric test, and if you want the details on how it works just Google it, the concept is actually really simple.

The K-S test compares two distributions to see if they match.

The hypotheses works like this: Let F(x) and S(x) designate some unknown distribution functions of the X's and Y's respectively.

Then our following two-sided null hypothesis is: F(x) = S(x) for all of x
Then our alternative hypothesis is: F(x) does not equal S(x) for at least one value of x

If you have never seen a classical statistical hypotheses test, the short and sweet of it, is if we get a low p-value we consider this evidence against the null hypothesis. The lower the p-value the greater the evidence. P-values range from 0 to 1. They are the probability of a ratio as extreme or more extreme than the observed given the null is true. Note they are not evidence for the null, failing to reject does not prove a null. The null is just that annoying guy that always demands you prove everything you say, but it is the alternative hypothesis that we are really testing for.


Here is the code:

two.envelopes <- function(){
x <- (rnorm(1))
x <- (abs(as.numeric(format(round(x, 3)))))*10
#randomly selects a number
#limits the number of decimal places x can have and muiltples x by 10 to simluate realistic dollar values.
p <- c(x,2*x)
A <- sample(p, 1, replace=F)
#creates a vector with x and 2x then randomly selects one for A.
if (A == x) {
B <- 2*x
} else {
(B <- x)
}
return(c(A))
}
#sets the value for B based on: if A = x then B = 2x or if A = 2x then B = x
g <- replicate(10000, two.envelopes())


two.envelopes.s <- function(){
x <- (rnorm(1))
x <- (abs(as.numeric(format(round(x, 3)))))*10
#randomly selects a number
#limits the number of decimal places x can have and muiltples x by 10 to simluate realistic dollar values.
p <- c(x,2*x)
A <- sample(p, 1, replace=F)
#creates a vector with x and 2x then randomly selects one for A.
if (A == x) {
B <- 2*x
} else {
(B <- x)
}
return(c(B))
}
#sets the value for B based on: if A = x then B = 2x or if A = 2x then B = x
g.s <- replicate(10000, two.envelopes())

library(ggplot2)
plot(g)
plot(g.s)
ggplot() + aes(g)+ geom_histogram(binwidth=10, colour="black", fill="white")

ggplot() + aes(g.s)+ geom_histogram(binwidth=10, colour="black", fill="white")

ks.test(g, g.s)

#K-S test results

p-value will be approximate in the presence of ties
Two-sample Kolmogorov-Smirnov test

data: g and g.s
D = 0.0077, p-value = 0.9283
alternative hypothesis: two-sided



So we see with a D test statistics of 0.0077 and a 0.92 p-value we don't have strong enough evidence to support the alternative hypothesis that the two distributions are reasonably different.

Of course this was an expected outcome and would remain true no matter how X was selected, as once X is selected its distribution in the envelopes is now something separate which depends on how the envelopes themselves are selected.

If you don't like the K-S test here are some plots that allow you to view the similarities:

There are scatter plots of each distribution and histograms of each. They will look very similar.

Scatter Plots:

https://ibb.co/ksr0P8

https://ibb.co/bW6gxT

Histograms:

https://ibb.co/c9w3Bo

https://ibb.co/h30248



Srap Tasmaner July 15, 2018 at 19:31 ¶ #197129
Quoting andrewk
3. Treat X as known and Y as unknown. Then the switch gain has a distribution of X or -X with even odds, so the expected switch gain is zero. This is the approach defended by srap. The approach is coherent but it begs the question of why it is valid to model lack of knowledge about Y/X by randomness, but not lack of knowledge about X.


This is more or less fair. As far as this part of the problem goes, I haven't gotten past my first comment on this thread, that there is a de dicto/de re problem.

(A) There is a 1/2 chance that I will pick the larger of the two envelopes.
(B) The envelope I pick has a 1/2 chance of being the larger of the two envelopes.

These may usually be functionally or instrumentally equivalent, and we might usually use the same tools to model our uncertainty, but they are still different, and this is the occasion when the difference matters. I have a 1/2 chance of picking the envelope valued at 2X, but that envelope does not have a 1/2 chance of having a larger value than the X envelope. 2X has no chance of being less than X when X > 0.

If you can show me how to respect this difference within a subjective framework, I'd be all for it.
Dawnstorm July 15, 2018 at 21:11 ¶ #197146
Quoting Srap Tasmaner
If you can show me how to respect this difference within a subjective framework, I'd be all for it.


This is how I see the problem:

Objectively, you're in one game, where one envelope contains X and the other contains 2X.

As soon as you pick an envelope, though, you have a potential value Y, which is, again, either X or 2X, but that's a bifurcation point: you have now two games. That should be obvious, because saying that Y could either be X or it could be 2X would mean X=2X, and that would be nonsense in an objective framework. What this means is that you now have two subjectively possible games, only one of which you're actually in. This holds for both values, so you have three possible game in the meta-system, one of which - the objective one you're in - is selected twice: once for each envelope.

So, if you were to dimensionalise your variable for the three games, you get: X(1), X(2), and X(3) - where X(2) is the game you're actually in, and it's the only of the three games that's selected no matter what envelope you pick.

So when you're saying that Y could be either X or 2X, you're not talking about the same X. You're either talking about [X(2), 2X(1)] if you pick X(2), or [X(3), 2X(2)]. if you pick 2X(2).

You know that if you pick X(2) you win by switching, and if you pick 2X(2), you lose by switching. Objectively, the amount you're losing or winning can only be X(2). But all you know is the proportion: if you picked the lower amount you win Y, and if you picked the higher amount you lose Y/2. Even subjectively, the amount you win or lose is always X(2). But your frame of reference differs: If you picked the lower of the two values, the amount you could have lost appears to be X(1) [=X(2)/2], and if you lose, the amount you could have won appears to be X(3) [=2X(2)].

Both those values don't exist in the objective game, but you're problem is that - while playing - you don't know whether X(2) is Y or Y/2. You could be in any of two games, one of which game 2, the real one, and the other is either game 1 (the smaller-sum game), and the other is game 2 (the bigger-sum game), but from value Y alone you can't tell.

Because you can't tell, you have two options: take Y into account anyway, or ignore it. These are two perspectives on decision making, and neither really causes unpleasant surprises, because all that changes is the reference system. You either work with an indefinite certain value (in which case it doesn't matter whether you look into an envelope or not), or with two definite but uncertain values (if you look into one envelope and make that the basis of your decision), [or, for completeness sake, with three indefinite and uncertain values (if you don't look into any envelope and set the value Y as the envelope you currently have - this is the switch-back-and-forth constellation)]. In all three cases, the only value you can win is X(2), but depending on your reference system the value may look proportionally smaller or bigger.

I think the core difference between people here lies in the different ideas of what we should with context, or maybe even what should count as context, when it comes to real-life decisions. And that's something buried fairly deeply in our worldviews, so it's not that easy to untangle.
Srap Tasmaner July 16, 2018 at 01:22 ¶ #197198
Quoting Dawnstorm
Because you can't tell, you have two options: take Y into account anyway, or ignore it. These are two perspectives on decision making, and neither really causes unpleasant surprises, because all that changes is the reference system.


But doesn't it cause trouble?

Suppose the problem is presented to you this way: one of these envelopes is worth twice the other; you get to pick one, maybe look, are offered the trade. You might begin — as I tried once — by describing the sample space as [L=2R, R=2L]. This leads to trouble. Depending on which one is true you get a different value for |L - R|: if L=2R, then |L - R| = R = L/2, and if R=2L, |L - R| = L = R/2. It gets worse if you not only use two variables but make the variables dependent on your choice. That's our Y and U. What we are quite specifically unable to know is which is bigger, and we've chosen a way of describing the sample space that is only coherent if you know which is bigger.

If you came at the problem from here, you'd realize at some point that the clever thing to do is introduce a single variable X that is orthogonal to your choice and orthogonal to which envelope has which value. |X - 2X| = X, no matter the rest. It gives you an invariant description of the sample space so that you can properly measure the consequences of your decisions.

What's disorienting is that the best way to describe the problem was given to us first, and then we are left to discover the wrong ways all on our own.
JeffJo July 16, 2018 at 01:47 ¶ #197203
Reply to Jeremiah
That is a very bad understanding of what a sample space and an event is. You are not applying your Principle of Indifference there, which states from your link: "The principle of indifference states that if the n possibilities are indistinguishable except for their names, then each possibility should be assigned a probability equal to 1/n." n in this case would be the total possible combinations of the lottery numbers.

Yes, my point was that the lottery example is a very bad description of a sample space. In fact, It is the archtype for just that. But so is ignoring that you are assuming a distribution of amounts as well as whether you picked high or low. Maybe if you looked at my examples, you'd understand this. That was also a point I made.

When you look in an envelope and see $10, it means that one of two possible events has occurred. The envelopes were filled with ($5,$10) AND you picked the higher, or the envelopes were filled with ($10,$20) AND you picked the lower. The PoI applies to whether you picked high or low, since those outcomes are equivalent except in name. It does not apply to whether the envelopes were filled with ($5,$10) or ($10,$20), yet you treat them as equally likely.

The Two Envelope Problem cannot be solved without a distribution for the amounts, which is why you get a paradox when you ignore it.
Jeremiah July 16, 2018 at 02:40 ¶ #197211
Reply to JeffJo

I am not doing this, not until you actually read all of my posts in this thread.
Jeremiah July 16, 2018 at 02:45 ¶ #197212
I know this is a long thread, but tacking remarks on the end while only skimming though it, or skipping pages just leads to repeated content.
Dawnstorm July 16, 2018 at 02:47 ¶ #197213
Quoting Srap Tasmaner
If you came at the problem from here, you'd realize at some point that the clever thing to do is introduce a single variable X that is orthogonal to your choice and orthogonal to which envelope has which value. |X - 2X| = X, no matter the rest. It gives you an invariant description of the sample space so that you can properly measure the consequences of your decisions.


But you have to remember if you go one envelope has X and the other 2X, then you're defining as the envelope that contains X as the one with the smaller value. So if you look into an envelope, you can't know which envelope you've opened, so the other must contain either twice that of the one you've opened, or half that of the one you've opened: it's the neutral value, split over an either/or situation.

X and Y are commensurable. It's the same thing. I don't see a difference.
Srap Tasmaner July 16, 2018 at 02:51 ¶ #197215
Reply to Dawnstorm
I would say that defining the space as [X, 2X] just makes it painfully obvious that knowing the value of one envelope is completely useless, and that you should not bother with some X/2 or 2X conundrum. You can calculate the value of swapping before even choosing, and you will be right.
Jeremiah July 16, 2018 at 03:01 ¶ #197221
Reply to Dawnstorm

I pointed out a few times that the sample space of event R and the sample space of event S are equal subsets of each other, which means mathematically we can treat them the same. I also pointed out that as soon as you introduce Y they are no longer equal subsets and therefore mathematically cannot be treated the same.

Here is an example. If Z=M and N=M then Z=N.
Dawnstorm July 16, 2018 at 09:38 ¶ #197264
Quoting Jeremiah
I pointed out a few times that the sample space of event R and the sample space of event S are equal subsets of each other, which means mathematically we can treat them the same. I also pointed out that as soon as you introduce Y they are no longer equal subsets and therefore mathematically cannot be treated the same.

Here is an example. If Z=M and N=M then Z=N.


I'm hopelessly confused.

I read your [[10,20],[5,10]] as: "Given that one envelope has the value 10, either [X = 10 and 2X=20] or [X=5 and 2X=10]". And that describes the sample space of both envelopes A and B.

A sample space of A[X, 2X], B[X,2X] gives you the following possibilities:

A=X, B=X
A=X, B=2X
A=2X, B=X
A=2X, B=2X

A=X, B= X (never selected, due to setup)

A=10, B=10
A=5, B=5

A=X, B=2X

A=10, B=20
A=5, B=10

A=2X, B=X

A=10, B=5
A=20, B=10

A=2X, B=2X (never selected due to setup)

A=10, B=10
A=20, B=20

So if look into A and discover 10 inside, all I have to do is to look through all possible constellations, which are both in the sample space you defined, and selected by the set-up:

A=10, B=20
A=10, B=5

This is the result of [[10,20],[5,10]] under the stipulation that A=/=B.

If this is not the case, I have read you wrong, and I can't for the life of me figure out where or how. Have I missed possible constellations? Have misread your sample space? What?


Jeremiah July 16, 2018 at 11:11 ¶ #197284
Reply to Dawnstorm R and S is the event you have X or 2X when you get A. By definition of A and B, if A=X then B =2X, or if A =2X then B=X. So by definition if A equals X then B cannot also equal X.

Quoting Jeremiah
We define A and B as: If A=Y=X then B=2X or if A=Y=2X then B=X, where Y is the amount you see opening envelope A and X is the unknown amount originally selected by the facilitator.

My claim is then that the only possible outcomes for B is X or 2X.

Proof:

For all of Y, Y is a positive real number, such that Y=X or Y=2X, where X is some positive real number.

You are handed A and you see Y inside.

There are two cases here:

Case One

A=Y=X

By definition of A and B if A=Y=X then B=2X therefore B=2X

Case Two

A=Y=2X

By definition of A and B if A=Y=2X then B=X therefore B=X.

Those are the only two possible cases for B therefore by the definition of a sample space the sample space for B is [X,2X]


It gets messy I'll agree, as [R,S] is the same as [X,2X], but you have to remember they represent case one or case two. In case one B cannot equal X, by the definition of B and so on.

We also suffer from sloppy notation, we probably should be using subscript.

Jeremiah July 16, 2018 at 12:13 ¶ #197288
It should probably all be reviewed and written up in proper notation, but it has been such a long thread I am not sure I want to spend the time to do that. I feel that my post number 6 sums it up concisely even if informally. Then with the simulations I did on page 26 I feel I have provided empirical proof of that statement. The next step is to formalize everything but since this is informal discourse that seems like unneeded effort to me.

It might be time to consider making a new thread. I kind of feel that everything that needs to be said about this conundrum has been said.
JeffJo July 16, 2018 at 13:27 ¶ #197291
Quoting Jeremiah
I am not doing this, not until you actually read all of my posts in this thread.
What? You don't want to address a correct analysis, until I weed through pages of debate that appears to be inconclusive? Because I can guarantee you, that applying my correct analysis can resolve them.

How about I read until I can point out three errors? But some of them will be repeats of what I already have said. In fact, I'll start by stating it another way. Here are two proposed solutions:

  1. Your envelope has $X.The other has $X/2 or $2X, 50% chance each. So the expected value is ($X/2)/2+($2X)/2=$5X/4 and the expected gain by switching is $X/4.
  2. (You seem to have suggested this one once) The magnitude of the difference between the two envelopes is $D; so there is a 50% chance it is +$D, and a 50% chance it is -$D. The expected gain is 0.

This is paradox, so one must be wrong. Yet, there is only one difference in the theoretical approach taken: #1 uses two possibilities for the contents of the two envelopes, while #2 uses only one. The error must be there.

+++++

You said: "You have to understand that X is a variable." This is incomplete. It's a random variable, representing (above) the (known or unknown) value of the envelope you picked. But some of those pages you want me to read confuse it with D. And even if you don't accept that you need to use it to describe your sample space, you still can represent it as a random variable.

That means it has a range, and a prior distribution. The range has to include $X, $X/2, and $2X. But if the probability of $X/2 (or $2X) is non-zero, the range must include $X/4 (or $4X). And then it must include $X/8 (or $8X). If you don't want this to continue indefinitely - which implies arbitrarily small and large amounts are possible - then there has to be a zero probability in X's distribution for some powers of 2. The first solution above implicitly assumes that all powers of 2 have the same probability.

+++++

Michael said: "By switching there's a 50% chance of gaining an extra £10 and a 50% chance of losing £5." This is wrong. The chance of picking the larger envelope is indeed 50% when you don't consider an amount, but you have to include the probability of having the amount you consider.

His program says that there was a 50% chance that the envelopes contained ($5,$10), but ignored the 25% possibility of picking the $5 envelope from that pair. There was another 50% chance that the envelopes contained ($10,$20), and he ignored the possibility of picking the $20 envelope. He considered only the possibility of picking the $10 envelope.

His error is assuming a distribution for the values. The OP does not provide that information, even if you look and see $10. He calculated the expectation if you are given the 50:50 split between the two sets, and that you picked $10. That conditional expectation is indeed the switching gains. It just isn't the OP.

+++++
NoAxioms said: "My solution is to switch only if the amount in the envelope is an odd number." This recognizes that the probability of ($X/2,$X) must be zero if X is odd, but doesn't recognize that the probabilities of ($X/2,$X) and ($X,$2X) do not have to be the same if X is even.

+++++
You said: "What we have establish[ed] is that -X and X are equally likely to occur." You are misinterpreting how Michael is using X. Yours is the value in the lower envelope,which makes it the difference. His is the value in your envelope, which makes the difference -X/2 or +X. He gets an invalid answer, because he needs to consider the relative probabilities of the two sets of envelopes. You consider only one set, so you don't.

I read more, and it was all thrashing. If you have a specific post you want me to read, point it out.
Jeremiah July 16, 2018 at 15:35 ¶ #197313
Reply to JeffJo If you are not willing to read the thread, then I am not willing to read your post.
JeffJo July 16, 2018 at 20:29 ¶ #197398
Reply to Jeremiah
But I have read it now - the majority is either name calling, or the debating of INCORRECT interpretations (on almost all sides) of various concepts in probability. Regardless, what I have said so far, and will continue to say, applies to all of it, whether of not I cite how in every instance. Some of these concepts are:

1. This problem is not about statistics. What you meant when you called it a "data science," is that it tries to apply the concepts of theoretical probability to real-world situations.

2. In theoretical probability, "probability" is an undefined term. Given a sample space S, any corresponding set of numbers that satisfy the Kolmogorov axioms (all are >=0, if A and B are disjoint events then Pr(A)+Pr(B)=Pr(A&B), and Pr(S)=1), is a set of probabilities for that space. This does not interpret the meaning of the values.

3. A random variable is a measurable quantity in the result of a random process that, within your knowledge, can have any value in some set of values. As a random variable, it has a probability distribution. This means that the lower value in the pair of envelopes is a random variable, that has a probability distribution. A "probability density curve" does not have to be "used to select X.," whatever it is you think that means. Before you look in an envelope, does your knowledge allow L it to have one value in some set, whether or not that set is known to you? Then it is a random variable that has a probability distribution (distributions apply to discrete random variables, as with amounts of money. Densities need a continuous random variable).

A corrected version of your solution, if you don't look in an envelope: Let L be the random variable representing the low value in the envelopes. Say the "given event" is that the (unknown) low-value is L1; that is, one value in the set of possibilities is realized. (Note that L1 is an unknown, and not a random variable. Ask about the difference if it is unclear to you why I point this out.) There is a probability Pr(L=L1) that we can't possibly know, but it will turn out that we don't need to know it.

Similarly, let R be a random variable representing the relative value of the envelope you pick. It can be 1/2, or 2. That is, if R=1/2, you picked the smaller envelope. Note that we can say Pr(R=1/2) = Pr(R=2) = 0.5 by the Principle of Indifference.

The prior probability that L=L1 AND R=1/2 is Pr(L=L1)*Pr(R=1/2) = Pr(L=L1)/2.
The prior probability that L=L1 AND R=2 is Pr(L=L1)*Pr(R=2) = Pr(L=L1)/2.

The definition of the conditional probability for event A, given event B, is Pr(A|B)=Pr(A&B)/Pr(B):

Pr(R=1/2|L=L1) = (Pr(L=L1)/2)/Pr(L=L1) = 1/2.
Pr(R=2|L=L1) = (Pr(L=L1)/2)/Pr(L=L1) = 1/2.

These are the probabilities you should use in your expectation calculation. Since Pr(L=L1) divides out, we don't need to know it. You are confusing the fact you can take a shortcut to get this result, with that shortcut being logically correct.

Note how the value of your envelope different in these two cases: L1 in the first, and 2*L1 in the second. Michael's error is treating the "given" event as a fixed value for your envelope, but using the same shortcut. It no longer gets the right result.

Let V be the value of your envelope. If we treat the "given event" as V=V1, then

Pr(R=1/2|V=V1) = Pr(R=1/2&V=V1)/Pr(V=V1) = Pr(R=1/2&L=V1)/Pr(V=V1) = Pr(L=V1)/Pr(V=V1)/2
Pr(R=2|V=V1) = Pr(R=2&V=V1)/Pr(V=V1) = Pr(R=2&L=V1/2)/Pr(V=V1) = Pr(L=V1/2)/Pr(V=V1)/2
Finally,
Pr(V=V1) = Pr(L=V1&R=1/2)+Pr(L=V1/2&R=2) = [Pr(L=V1)+Pr(L=V1/2)]/2

So the numbers to use in the probability calculation are

Pr(R=1/2|V=V1) = Pr(L=V1)/[Pr(L=V1)+Pr(L=V1/2)]
Pr(R=2|V=V1) = Pr(L=V1/2)/[Pr(L=V1)+Pr(L=V1/2)]

Now the distribution of the values matters. Micheal implicitly assumed Pr(L=V1)=Pr(L=V1/2).
Srap Tasmaner July 16, 2018 at 21:20 ¶ #197423
Quoting JeffJo
Since Pr(L=L1) divides out, we don't need to know it. You are confusing the fact you can take a shortcut to get this result, with that shortcut being logically correct.


Doesn't this amount to saying that the loading of the envelopes and the selection of an envelope are independent events, in which case conditioning is pointless?

And then given that the player has no choice but to treat which envelope they "choose" as a matter of indifference-- they might as well flip a coin-- what possible reason could the facilitator have for not also treating which value is assigned to which envelope as a matter of indifference? They too could just as well flip a coin. Which leaves me puzzled about the point of your V=V1 stuff, if I'm following what you did there.
Jeremiah July 16, 2018 at 22:08 ¶ #197440
Quoting JeffJo
What you meant when you called it a "data science," is that it tries to apply the concepts of theoretical probability to real-world situations.


Data science, strangely enough, involves data. As a data scientist your job is to analyze the data, then it is the job of the subject matter experts to interpret how that applies to the real world. Statistics is a data science and in statistic we measure uncertainty, which is why some people call it the science of uncertainty.

Jeremiah July 16, 2018 at 22:11 ¶ #197443
I have said all I am going to say about this problem, as at this point the arguments are just recycling themselves. I am fully satisfied with my approach and my solution. It is time to move on.
Srap Tasmaner July 16, 2018 at 23:04 ¶ #197460
Reply to Jeremiah
As we say goodbye to the two envelopes, I'd like to call attention to a couple oddities of the alternative analyses:

(A1) No-switchers imagine the first step as a choice or random selection between two items, and then the second step is trading that item for the one item left-- no choice.

(A2) Switchers imagine the first step as getting some determinate value-- there need not be a "choosing" here at all-- and then the second step is a random selection from two alternatives.

(B1) No-switchers see the options as getting either the smaller or the bigger of two items.

(B2) Switchers redefine smaller as "bigger of a smaller pair" and bigger as "smaller of a bigger pair".

How these symmetries arise seemingly just from the way you assign variables still puzzles me a bit.
JeffJo July 18, 2018 at 16:05 ¶ #198053
Mixing random variables and unknowns can be very un-intuitive, especially to those who are out of practice.

Reply to Srap Tasmaner
Doesn't this amount to saying that the loading of the envelopes and the selection of an envelope are independent events,
That isn't as useful as you might think. You can assert how that independence is obvious, since the random variable R (where R is 1/2 or 2 if you picked low or high) is chosen without knowledge of the random variable L (the low value of the pair). But all this independence means is, for any values of the unknowns L1 and R1, that:

  • Pr(L=L1&R=R1) = Pr(L=L1)*Pr(R=R1).


What independence doesn't tell you, is how Pr(L=L1/2&R=2) = Pr(L=L1/2)/2 compares to Pr(L=L1/2&R=1/2) = Pr(L=L1)/2. If you need to compare them, independence does nothing for you.

If you consider a value - like you do whenever you calculate an expectation - you have to condition on that value. Here, V is the random variable for your envelope's value:

  • E = Exp(Other Envelope|V=V1) = (V1/2)*Pr(R=2|V=V1) + (2V1)*Pr(R=1/2|V=V1)E = (V1/2)*Pr(R=2&V=V1)/Pr(V=V1) + (2V1)*Pr(R=1/2&V=V1)/Pr(V=V1)E = V1*[Pr(R=2&V=V1)/2 + 2*Pr(R=1/2&V=V1)]/Pr(V=V1)


Note that it is L that is independent of R, not V. So you can't separate Pr(R=1/2&V=V1) into Pr(R=1/2)*Pr(V=V1) = Pr(V=V1)/2. As a trivial example, if V=$1, then R can't be 2 and Pr(R=1/2&V=$1)=Pr(V=$1).

Changing the random variable in this formulation (that is, once you started this way) from V to L, so you can use independence, doesn't help:

  • E = V1*[Pr(R=2&V=V1)/2 + 2*Pr(R=1/2&V=V1)]/Pr(V=V1)E = V1*[Pr(R=2&L=V1/2)/2 + 2*Pr(R=1/2&L=V1)]/[Pr(R=2&L=V1/2) + Pr(R=1/2&L=V1)]E = 2*V1*[Pr(L=V1/2)/4 + Pr(L=V1)]/[Pr(L=V1/2) + Pr(L=V1)]


This approach to an expectation inherently compares the probabilities of two possible combinations fo envelopes. This result applies whether you do know V1, or don't know V1. If you do, you need to know the relative probabilities of those two possible sets of envelopes, which you don't have. If you don't know V1, then you get the expectation by integrating over all possible values of V, which requires even more knowledge you don't have. With a lot of work (too much), you could prove that this will always be equal to the expectation of your envelope.

There is an easier way, but it applies only if you don't know what is in your envelope. Use L instead of V from the beginning and condition on L=L1. Then you can use independence, you only need to use Pr(L=L1), and it divides out. The disadvantage is, that you can't answer if you look and see $10 in your envelope. WHICH IS CORRECT.

?Jeremiah

We don't have data in the OP; we have a theoretical problem only.
Jeremiah July 18, 2018 at 18:01 ¶ #198074
Quoting JeffJo
We don't have data in the OP; we have a theoretical problem only.


You keep demonstrating how few of my posts you have actually read.
Srap Tasmaner July 18, 2018 at 18:33 ¶ #198077
Quoting JeffJo
There is an easier way, but it applies only if you don't know what is in your envelope.


If, even before selecting an envelope, you see that there is no reason to prefer one envelope over the other, what compels you to discard that analysis upon selecting and opening an envelope? Is it no longer true that if you drew X you'd trade for 2X and if you drew 2X you'd trade for X? How could selecting or even looking in an envelope make that false?
JeffJo July 18, 2018 at 18:43 ¶ #198080
Reply to Jeremiah
I've looked at them all,and seen no actual data. By which I mean examples where actual envelopes have been filled with actual money, and presented to an actual person. That's the only way statistics ("data science) matter.
JeffJo July 18, 2018 at 18:53 ¶ #198082
Reply to Srap Tasmaner
If, at that point, you postulate a value in an envelope, you need to postulate a probability distribution that covers all possible ways that value could be in an envelope. Even if it is unknown. Did you miss the part where I said that, if you don't know the value, you technically have to integrate over all possible sets? But that you can prove both envelopes have the same expectation with any legitimate distribution?

And if, at that point, you postulate a value for any of these functionally equivalent quantities:

  • The lower of the two envelopes.
  • The higher of the two envelopes.
  • The absolute value of the difference.
  • The sum.

... then your solution only uses a probability for one, and it divides out. But if you look in it, you need two.

Honestly, my conclusions are much the same as yours. I just explain them correctly. Why are you arguing? Do you even know what you are arguing about?
Srap Tasmaner July 18, 2018 at 19:10 ¶ #198084
Quoting JeffJo
If, at that point, you postulate a value in an envelope, you need to postulate a probability distribution that covers all possible ways that value could be in an envelope. Even if it is unknown.


I'm just trying to understand the "need to" in that sentence.

Quoting JeffJo
Did you miss the part where I said


Don't be that guy. I'm reading your posts and asking about what I don't understand.

(Btw, MathJax is available here, so it's possible to make your equations more readable.)
Srap Tasmaner July 18, 2018 at 19:27 ¶ #198087
Reply to JeffJo
Let me put it a different way.

If you can show that we can, using the perhaps unknown value of our selected envelope, get the same answer we get by ignoring that value and doing some simple algebra, then that would count as a solution to the two envelopes problem. So you're offering a solution and I'm really not.

We haven't actually been talking about solutions much in this thread because some participants did not accept that the simple algebraic solution is actually right.
Jeremiah July 18, 2018 at 21:05 ¶ #198111
Reply to JeffJo You didn't look at them all. If you had you would had noticed I raised the same objections. Then you would have noticed I simulated a data set based on the conditions of the problem. Also statistics definitely does empirical investigations via simulation.
JeffJo July 19, 2018 at 13:23 ¶ #198310
Sorry, I don't know MathJax. With having broken my foot on Friday (did you notice a gap in my responses?), it is taking all the effort I can spare to reply here. If you can point out an on-line tutorial, I'll look at it in my copious "free time."

Reply to Srap Tasmaner
I'm just trying to understand the "need to" in that sentence.

In short, the "need to" include the probability distribution is because the formulation of the "simple algebraic solution" is incorrect if you exclude it.

I'm assuming that you understand the difference between conditional and unconditional probabilities. The expected value of the other envelope, given a certain value in your envelope, requires that you use probabilities conditioned on your envelope having that value. So even if X is unknown:

  1. The unconditional probability that the other envelope contains $X/2 is not 1/2, it is Pr(L=$X/2)/2.
  2. The unconditional probability that the other envelope contains $2X is not 1/2, it is Pr(L=$X)/2.
  3. If you have $X, those are the only possible cases.
  4. To get conditional probabilities, you need to divide the probability of each possible case by the sum of them all.


So the expected value of the other envelope, given that you have $X, is:

  • [($X/2) * Pr(L=$X/2) + (2*$X) * Pr(L=$X)] / [Pr(L=$X/2) + Pr(L=$X)]


Note how this can be different, for different values of X, if Pr(*) varies. I'm not trying to "be that guy," but apparently nobody read my first post either. I pointed out examples of how that can happen: https://thephilosophyforum.com/discussion/comment/196299

The "simple algebraic solution" assumes that the probability of any two possible values of L is the same, which makes this reduce to:

  • [($X/2) + (2*$X)] / 2]


Note that this assumption means that the probability of getting $10 is the same as getting $5, which is the same as getting $2.50, or $1.25, or $0.625, or $0.3125, etc. And it also implies that any two possible high values are the same, which means that getting $10 is just as likely as $10,240, or
$10,485,760, or $10,737,418,240,etc. THERE IS NO UPPER BOUND TO THE VALUES IMPLIED BY THE "SIMPLE ALGEBRAIC SOLUTION."

This is another reason (besides failing the requirement that the cases be equivalent except in name) that the Principle of Indifference can't be applied.
JeffJo July 19, 2018 at 13:30 ¶ #198313
Reply to Jeremiah
I did look. Maybe you didn't read mine: "I mean examples where actual envelopes have been filled with actual money, and presented to an actual person. That's the only way statistics matter."

If you simulate the problem, then all you are testing is your interpretation of the problem, warts and all. And applying statistics to the results may show how statistics work, but nothing about whether your interpretation is right or about the original problem. Micheal also simulated the problem.

Whether or not you want to address it, the distribution of the possible values in the envelopes is required for the problem. Ignoring it is making a tacit assumption that includes an impossible distribution.
Jeremiah July 19, 2018 at 15:38 ¶ #198327
Reply to JeffJo Feel free to look at my simulations on page 26 and point out specifics.

JeffJo July 19, 2018 at 20:48 ¶ #198365
Reply to Jeremiah
Right. That was after my first post. I read it before the rest of the thread, so I didn't think that was what you were referring to. I didn't want to go into this amount detail about it (hoping that my explanations would suffice), but you insist.

Let X be a set of positive dollar values, and x0 be the lowest value in X.

Let F(x) be a probability distribution function defined for every x in X, and for x0/2 as well. But F(x0/2)=0 since x0/2 isn't in X.

Let Y be chosen uniformly from {1,2}.

Define your random variable A = X*Y. So X=A/Y, where the denominator can be 1 or 2. This makes the probability distribution for A equal to F(A/1)/2+F(A/2)/2 = [F(A)+F(A/2)]/2. Call this F1(A).

Define your random variable B = X*(3-Y). So X=B/(3-Y), where the denominator can be (3-1) or (3-2). This makes the probability distribution for B equal to F(B/(3-1))/2+F(B/(3-2)/2. But simple rearrangement shows that this F1(B).

The point is that we can prove that the distributions for A and B are the same. And all your simulation shows, is that if you can correctly derive the result of a process, then a correct simulation of that process statistically approximates the result you derived. It says nothing about the OP; certainly not that the distribution is unimportant.

And btw, the distribution you used in the version you posted is a discretization of the Half-normal distribution. And it is possible that it could put $0 in both envelopes.

+++++

And your simulation does nothing to explain why the expectation formula E = (X/2)/2 + (2X)/2 = 5X/4 is wrong. It is because the correct formulation, if someone picks your envelope A and it contains X, is:

  • E = [(X/2) * F(X/2) + (2*X) * F(X)] / [F(X/2) + F(X)]


Your simulation does nothing to show this. But you can in various ways. Choose any of your distributions, but fixing that "zero" problem.

One way to test it, is to chose a range of values like between $10 and $11. If you have an amount in that range (ignore values outside it), your average gain should be about $2.50 if you switch. And this will be true whether you start with envelope A, or B. I can't say the exact amounts, because it depends on how F(10) differs from F(20). The exact amounts are the kind of thing you can find with a statistical simulation like yours.

Or, just calculate the average percentage gain if you switch. You will find that it is about 25%, whether you switch from A to B, or from B to A.
Jeremiah July 19, 2018 at 21:36 ¶ #198369
Reply to JeffJo I am well aware 0 was a possible outcome, the code just runs better without the loops, and it was not significant enough to care.

Quoting JeffJo
Your simulation does nothing to show this.


Sorry my simulation proves you wrong.
JeffJo July 20, 2018 at 14:01 ¶ #198564
Reply to Jeremiah
I am well aware 0 was a possible outcome, the code just runs better without the loops, and it was not significant enough to care.


Use a "ceiling" function instead of a "round" function. Or just add 0.0005 before you round.

Sorry my simulation proves you wrong.


Any statistical analysis addresses a question. Yours addresses "Is the distribution of A the same as the distribution as B?" And it can only show what the answer most likely is, not prove it.

But, the answer to that question is pretty easy to prove. As I did. So there wasn't much point in the statistical analysis, was there?

What you didn't address, but could, is whether the two random variables are independent. Which they are not. Since having two identical distributions is meaningless if they are not independent, your simulation did not address anything of significance to the OP.

Or what the expectation of the other envelope is relative to yours, and why the naive apparent gain can't be realized.Answer: With any bounded distribution, there is a smallest possible value where you will always gain a small amount by switching, and a largest value where you will always lose a large amount by switching. In between, you typically gain about 25% by switching once, and lose that 20% (remember, the baseline is now the switched-to value, so the dependency is reversed) by switching back. But over the entire distribution, the large potential loss if you had the largest value makes the overall expectation 0.

Those are the issues that are important to the OP, and your simulation doesn't provide any useful information.
Jeremiah July 20, 2018 at 15:35 ¶ #198599
Reply to JeffJo

Or I could just not worry about an outcome of zero since it has zero impact.


Jeremiah July 20, 2018 at 15:42 ¶ #198600
@JeffJo I have already stated I am done debating this problem. So I am sorry if you have an issue with my correct solution.
JeffJo July 20, 2018 at 20:53 ¶ #198668
Reply to Jeremiah
If you want to address the original problem, it matters that by your methods, ignoring their other faults, the two envelopes can contain the same amount. I understand that you are more interested in appearing to be right, than in actually addressing that problem. But I prefer to address it.

Reply to Jeremiah
Exactly what do you think "[your] correct solution" solves? I told you what it addresses, but you decided you were done before hearing it.

I've tried to explain to you why the issue you addressed is not the OP, but you have chosen not to accept that. If you don't want to "debate in circles," then I suggest you accept the possibility that the contributions of others may have more applicability than yours.
Jeremiah July 20, 2018 at 21:35 ¶ #198674
Reply to JeffJo


I am happy with my correct results.
Srap Tasmaner July 21, 2018 at 02:11 ¶ #198714
(Never mind.)
Jeremiah July 21, 2018 at 02:46 ¶ #198718
Going a little chop happy on my posts there.
Jeremiah July 21, 2018 at 03:40 ¶ #198738
Why would you even edit out the fact that I think my solution is correct? Am I not allowed to have that view?
Pierre-Normand July 21, 2018 at 04:17 ¶ #198753
I just came upon this thread and didn't read though all of it. I did read the first few and the last few pages. It seems to me that @andrewk and @JeffJo have a correct understanding of the problem, broadly consistent with mine.

The paradox seems to me to stem a vacillation between assuming that the player possesses (and can thereafter make use of) some knowledge of the bounded probability distribution of the possible contents of the two envelopes, which can be represented by a joint prior probability distribution, and the alternative assumption (inconsistent with the first) that after opening up one envelope the posterior probability distribution of the content of the unopened envelope necessarily remains equal to 0.5 for the two remaining possible values of its content. This can only occur if the player disregards his prior knowledge (or happens by cheer luck upon a value such that the posterior probabilities for the two remaining possible values or the content of the unopened envelope are 0.5).
Srap Tasmaner July 21, 2018 at 04:48 ¶ #198756
Quoting Pierre-Normand
some knowledge of the bounded probability distribution of the possible contents of the two envelopes


I'm having trouble imagining what the source of this knowledge might be.
Pierre-Normand July 21, 2018 at 05:10 ¶ #198760
Quoting Srap Tasmaner
I'm having trouble imagining what the source of this knowledge might be.


Since it's incomplete knowledge, or probabilistic knowledge, that is at issue, all that is needed is the lack of total ignorance. Total ignorance might (per impossibile) be represented by a constant probability density for all finite values, and hence a zero probability for all finite value intervals. The prior probability that the content of the first envelope (which represents your knowledge before opening it) is smaller than ten billion times the whole UK GDP would be zero, for instance. Any other (reasonable) expectation that you might have in a real world instantiation of this game would yield some probabilistic knowledge and then, therefore, lend itself to a Bayesian analysis whereby the paradox doesn't arise.
JeffJo July 21, 2018 at 12:04 ¶ #198828
The point is that there must be a prior distribution for how the envelopes were filled, but the participant in the game has no knowledge of it. I express it as the probability of a pair, like Pr($5,$10) which means there is $15 split between the two. There is also a trivial prior distribution for whether you picked high, or low; it is 50% each.

The common error is only recognizing the latter.

If you try to calculate the expected value of the other envelope, based on an unknown value X in yours, then you need to know two probabilities from the unknown distribution. The probability that the other envelope contains X/2 is not 1/2, it is Pr(X/2,X)/[Pr(X/2,X)+Pr(X,2X)]. The 50% values from the second distribution are used to get this formula, but they divide out.

The problem with the OP, is that we do not know these values, and can't make any sort of reasonable guess for them. But it turns out that the "you should switch" argument can be true:
  • In Jeremiah's half-mormal simulation:
  • The probability that X=$5 is 0.704%, and that X=$10 is 0.484%.
  • The probability that A=$10 is (0.704%+0.484%)/2=0.594%.
  • Given that A has $10, the probability that B has $5 is (.704%/2)/0.594% = 59.3%
  • Given that A has $10, the probability that B has $20 is (.484%/2)/0.594% = 40.7%
  • Given that A has $10, the expected value of B is (59.3%)*$5 + (40.7%)*$20 = $11.11.
  • So it seems that if you look in your envelope, and see $10, you should switch.
  • In fact, you should switch if you know that you have less than $13.60. And there is a 66.7% chance of that. (Suggestion to Jeremiah: run your simulation three times: Always switch from A to B, always keep A, and switch only if A<$13.60. The first two will average - this is a guess - about $12, and the third will average about $13.60.)
  • It is the expected gain over all values of X that is $0, not an instance where X is given.The naive part of Jeremiah's analysis, is that knowing how A and B have the same distribution is not enough to use those distributions in the OP. He implicitly assumes they are independent, which is not true.


So the OP is not solvable by this method. You can, however, solve it by another. You can calculate the expected gain by switching, based on an unknown difference D. Then you only need to use one probability from the unknown distribution, and it divides out.

Conclusions:
  1. If you don't look in your envelope, there can be no benefit from switching.
    • This is not because the distributions for the two envelopes are the same ,...
    • ... even though it is trivial to prove that they are the same, without simulation.
    • The two distributions are not independent, so their equivalence is irrelevant.
    • It is because the expected gain by switching from the low value to the high, is the same as the expected loss from switching from high to low.
  • If you do look in your envelope, you need to know the prior distribution of the values to determine the benefit from switching.[list]
  • With such knowledge, it is quite possible (even likely) that switching will gain something. If Jeremiah could be bothered to use his simulation, he could prove this to himself.
  • But it is also possible that you could lose, and in the cases where you do, the amounts are greater. The average over all cases will always be no change.

  • [/list]
    Jeremiah July 21, 2018 at 12:18 ¶ #198831
    Reply to JeffJo I specifically said that my simulation is not about finding expected results as that entire argument is flawed. Which I pointed out in a different post, that you likely didn't read. Also, I have said a number of times why the knowledge of Y is not relevant, but I am assuming you have not read that either.
    Jeremiah July 21, 2018 at 12:22 ¶ #198833
    I don't think @JeffJo even understands the other argument.
    Jeremiah July 21, 2018 at 12:31 ¶ #198834
    Notice how I have yet to post another thread. I have another problem lined up, but with the mods hacking out relevant content and the general performance of some people in this thread, I just am not sure anymore that these forums are the right place. The solution to this problem is so simple and straight forward and the fact that so many have missed it is discouraging.
    JeffJo July 21, 2018 at 12:32 ¶ #198835
    Reply to Jeremiah
    I am happy with my correct results.

    And again, you won't say what results you mean.

    Your solution from page 1, that ...
    If you have X and you switch then you get 2X but lose X so you gain X; so you get a +1 X. However, if you have 2X and switch then you gain X and lose 2X; so you get a -1 X.

    ... is a correct solution to the original problem when you don't look in the envelope. The problem with it, is that it doesn't explain to Reply to Michael why his program doesn't model the OP. That is something you never did correctly, and you refuse to accept that I did.

    Your conclusion from page 26, that...
    the possible distribution of A is the same as the possible distribution of B

    ... is also correct, although it is easier to prove it directly, But it is still irrelevant unless you determine that the two distributions are independent. AND THEY ARE NOT.

    It is this conclusion from page 26:
    the distribution in which X was selected from is not significant when assessing the possible outcome of envelope A and B concerning X or 2X.

    ... that is incorrect, as I just showed in my last post. The probability that A has the smaller value depends on the relative values of two probabilities in that distribution, so it is significant to the question you address here.

    Averaged over the entire distribution, there is no expected gain. Which you can deduce from your page-1 conclusion. For specific values, there can be expected gains or losses, and that depends on the distribution.
    Jeremiah July 21, 2018 at 12:35 ¶ #198836
    Reply to JeffJo

    I have already comment on all of this, read the thread. Don't just lie about reading it, actually read it.
    Jeremiah July 21, 2018 at 12:37 ¶ #198838
    There was an entire section of the thread in which we debated the role of Y. Clearly @JeffJo you didn't read it.
    Jeremiah July 21, 2018 at 12:44 ¶ #198841
    It is painfully obvious @JeffJo that you have not read the thread and as a result don't understand where these arguments are coming from.
    JeffJo July 21, 2018 at 14:47 ¶ #198852
    Reply to Jeremiah
    The point of this demonstration is to show that the possible distribution of A is the same as the possible distribution of B. ... So we see with a D test statistics of 0.0077 and a 0.92 p-value we don't have strong enough evidence to support the alternative hypothesis that the two distributions are reasonably different.

    It is provable without simulation that the the two distributions are the same, so this is pointless. We can accept that the distributions are the same. And it is is obvious you didn't read my posts describing why the simulation is pointless. In short, the "data" you apply "data science" to pertains only to how well your simulation addresses the provable fact.

    It is also provable that the distributions are not independent. Since you technically need to use a joint probability distribution for any analyses using two random variables, and you can only separate a joint distribution into individual distributions when they independent, this conclusion can have no bearing on the original problem. It is also obvious that you did not read my posts that explain this.

    You conclude that I did not read your posts, because I didn't comment on them. By not reading mine, you missed the fact that I don't need to comment. Conclusions drawn from evidence that has already been discredited do not need to be addressed.
    Jeremiah July 21, 2018 at 14:57 ¶ #198854
    Quoting JeffJo
    , so this is pointless.


    Funny how I already said something very much like this.
    Jeremiah July 21, 2018 at 15:09 ¶ #198856
    Reply to Srap Tasmaner

    You might find this interesting:

    https://www.researchgate.net/publication/266706577_The_fallacy_of_the_two_envelopes_problem
    Michael July 21, 2018 at 15:29 ¶ #198858
    Reply to Jeremiah That article shows that if you get to open your envelope you can use the knowledge of its value to apply a switching strategy to better your earnings.

    So it’s similar to the strategies that andrewk and I have described.

    Edit: it’s actually the same as andrewk’s.
    Pierre-Normand July 21, 2018 at 15:59 ¶ #198866
    Quoting Michael
    If my £10 envelope is Envelope X then switching to Envelope 2X gains me £10 and if my £10 envelope is Envelope 2X then switching to Envelope X loses me £5.


    (This was Michael's response to a post by Baden on p.3 of this thread)

    I just wanted to note that, as Michael may have realized by now, the higher expected value of the choice of switching, as compared with the choice of not switching, only is larger than zero if the act of opening the first envelope is assumed not to yield any additional (probabilistic) knowledge regarding the content of the second envelope. But if we assume any knowledge of the prior joint probability distribution of the contents of the two envelopes whatsoever, then, in that case, applying Bayes' Theorem in order to calculate the posterior probability distribution of the content of the second envelope yields an expected value of zero for the act of switching (as compared with not-switching).

    On edit: The assumption that no additional knowledge regarding the content of the second envelope would be gained by opening the first only would valid in the case where the two distributions (prior probabilities) were independent, which they aren't.
    fdrake July 21, 2018 at 16:50 ¶ #198883
    It seems to me that most of the disagreements aren't actually about how to calculate probabilities given a scenario, but rather on which scenario we're in. In the hope of disambiguating it, I'll consider a generalised envelope problem. Instead of the amounts being X and 2X, we'll generalise to U and V which are assumed to be positive real valued.

    This makes the problem, per Jeramiah's OP:

    You are playing a game for money. There are two envelopes on a table.
    You know that one contains $U and the other $V, [but you do not
    know which envelope is which or what the numbers U or V are]. Initially you
    are allowed to pick one of the envelopes, to open it, and see that it
    contains $Y . You then have a choice: walk away with the $Y or return
    the envelope to the table and walk away with whatever is in the other
    envelope. What should you do?



    The first interpretation consists in:
    (1) Being given an envelope.
    (2) Opening it doesn't do anything to the sample space, conditioning is irrelevant.

    [hide="First interpretation".]If you switch from U, you get V. If you switch from V, you get U.
    These are the only two possible scenarios for switching.
    What's the gain, then? In the first case, the gain is 0.5(V-U), in the second case the gain is 0.5(U-V). The sum is 0. There's no expected profit from switching.

    So what if you substitute in V=2U?

    0.5(U-2U)+0.5(2U-U)=0

    Still 0.

    Now what about not switching.

    If you don't switch from U, you get U. If you don't switch from V, you get V.
    In the first case, the from not switching is U-V, in the second case, the gain from not switching is V-U.
    Each has equal probability of 0.5.

    So the expected gain from not switching is 0.5(U-V)+0.5(V-U), which is 0.

    It doesn't matter if you switch or don't switch so long as the amounts are independently generated and fixed. The space of outcomes is gaining U-V or gaining V-U with equal probability, they cancel.[/hide]

    Now for when the card is revealed and the sample space is... to be determined, as it's more complex. This is dealing with the original problem as stated by Jeramiah:

    You are playing a game for money. There are two envelopes on a table.
    You know that one contains $X and the other $2X, [but you do not
    know which envelope is which or what the number X is]. Initially you
    are allowed to pick one of the envelopes, to open it, and see that it
    contains $Y . You then have a choice: walk away with the $Y or return
    the envelope to the table and walk away with whatever is in the other
    envelope. What should you do?


    The confusions go away when you actually realise there are two possible sample spaces given that you receive X, and there is no information on which you're in.

    The second interpretation consists in:
    (1) Opening the envelope to receive X.
    (2) There is no information over whether you're in the case (X,X/2) or (X,2X).

    [hide="Second interpretation"]

    You actually have 2 more complicated cases. The first case is when you have X and the amount in the other envelope is X/2, the second case is when you have X and the amount in the other envelope is 2X.

    Consider the first case. The envelopes now contain X and X/2. If you have X and switch you gain -X/2, if you have X/2 and switch you gain X/2, which are equally probable, so they cancel in the expectation giving 0.

    The second case. The envelopes now contain X and 2X. If you have X and switch you gain X, if you have 2X and switch you lose X, these are equally probable, so they cancel out in the expectation giving 0.

    Now we have to decide what the probability is of being in the (X,X/2) case given that you observed X in the first one, VS the probability of being in the (X,2X) case given that you observed X in the first one. Assuming they're both equally likely, the resultant expectation is the average of the previous two... which is still 0. This is why Reply to Pierre-Normand 's and @andrewk's comments about no information on which case you're in are important.

    What if you now know which of the two cases (X,X/2) or (X,2X) you're in? Well, that's pretty simple, if you know the case and you opened the envelope everything is deterministic from then on. If you have X, this tells you nothing about which of those composite states you're in, and if it did the problem collapses entirely given that you know X.
    [/hide]

    You end up with expectation 0 from switching and not switching so long as you're attending to the sample space consistently, independent of the interpretation.

    Why is this different from the Monty Hall problem? When you're asked 'whether you would like to switch', the probability distribution changes to a distribution yielding 0.5 probability to each door, giving 2/3 probability of winning by Bayes' theorem. In the second interpretation, being told you receive X gives you no information about the resultant gain. Monty Hall does.

    Reply to Michael 's enduring confusion throughout the thread consists in sneaking in some assumption that, in the second interpretation, the subject knows which case they're in. If instead the subject does not, the sample space is not (X/2,2X), it's (X/2,X,2X) if you receive a random envelope (which you need three of for this to make sense). This doesn't resemble anything like the original problem in which there are 2 envelopes.

    TLDR: you're never actually getting to the sample space (X/2,2X) from what you're given. If you actually do end up in that case, then the result's an obvious (even deterministic) choice given that you know X. If you interpret everything carefully, there's no preference for switching because there's never any information on which case you're in.

    Edit2: Also, this is pretty much the analysis in Jeramiah's linked paper, though it's analysed in terms of conditional expectations rather than probabilities.
    Michael July 21, 2018 at 17:04 ¶ #198888
    Quoting fdrake
    You actually have 2 more complicated cases. The first case is when you have X and the amount in the other envelope is X/2, the second case is when you have X and the amount in the other envelope is 2X.

    Consider the first case. The envelopes now contain X and X/2. If you have X and switch you gain -X/2, if you have X/2 and switch you gain X/2, which are equally probable, so they cancel in the expectation giving 0.

    The second case. The envelopes now contain X and 2X. If you have X and switch you gain X, if you have 2X and switch you lose X, these are equally probable, so they cancel out in the expectation giving 0.


    What do you mean by X here? Are you using it to refer to the value of the smallest envelope or to refer to the value of the opened envelope? It looks like you're doing both, and so the above doesn't make much sense (especially with "if you have X/2" which is impossible under either definition).
    Michael July 21, 2018 at 17:37 ¶ #198898
    Reply to Pierre-Normand By this do you just mean that if we know that the value of X is to be chosen from a distribution of 1 - 100 then if we open our envelope to find 150 then we know not to switch?
    Jeremiah July 21, 2018 at 17:42 ¶ #198901
    Reply to Michael

    I am already convinced my approach is correct, Michael. I have no doubt about it, and I no longer care about arguing or proving that point. You can interpret this article however you wish. If you learn something from it great; if you decide to think of it as personal validation that is your choice. I have been reading a number of papers on this problem with a number of different approaches and outcomes and I found this guy's approach interesting. And I think it is wise if I keep my thoughts about Andrewk’s approach to myself.
    fdrake July 21, 2018 at 17:51 ¶ #198905
    Reply to Michael

    There are 2 envelopes.
    You open an envelope and see X.
    The envelopes could have been filled with either X and 2X, or X and X/2. These are jointly exhaustive possibilities.
    This gives two cases to analyse. Which are labelled (X,2X) and (X,X/2). These correspond to the case when one envelope has X in it and the other envelope has 2X in it. And the case where one envelope has X in it and the other envelope has 2X in it. The probability distribution here is on the sample space:

    A=(one envelope contains X and the other contains 2X)
    B=(one envelope contains X and the other contains X/2)

    Having an envelope means being in case A or being in case B. Opening the envelope does nothing to inform you of whether you are in case A or case B. Let's assume case A and case B are equally likely. That is, it's equally like that A (your envelope contains X and the other contains 2X) or B (your envelope contains X and the other contains X/2).

    If you are in case A, having an envelope means that the envelope you hold is either X or 2X.
    If you are in case B, having an envelope means that the envelope you hold is either X or X/2.

    Assume you're in case A. If you have the lower valued envelope X and switch, you gain X. If you have the higher valued envelope 2X and switch you lose X. It is equally likely that you have X or 2X, so the expected gain conditional on being in case A is:

    0.5(X-X)=0

    Assume you're in case B. If you have the lower valued envelope X/2 and switch, you gain X/2. If you have the higher valued envelope X and switch, you lose X/2. So the expected gain conditional on being in case A is:

    0.5( 0.5X - 0.5X) = 0

    Now, it is random whether you are in case A or case B. They are equally likely. This means that the overall expectation of switching is the average of the expectations of switching in each case.

    So the average of 0 from case A and 0 from case B is 0.5(0+0)=0.

    With your approach, you have the sample space (2X,X/2) from switching. Please answer the following question:

    What is the probability of obtaining the envelope containing X? Not the conditional probability of the envelope you have containing X given that you just opened it. This is a trick, your approach does not answer this question - since it cannot be answered using only 2 envelopes unless the probability of obtaining an envelope containing X is 0...
    Michael July 21, 2018 at 17:59 ¶ #198908
    Quoting Jeremiah
    You can interpret this article however you wish.


    I interpreted it as it is literally written:

    Suppose we know only that the two amounts in the envelope are different (and no longer that the larger amount is double the smaller one). No information is provided of how the different amounts were chosen. We are allowed to open one randomly selected envelope. Does there exist a strategy that will lead us to accept the larger amount with a probability greater than [math]\frac{1}{2}[/math]?

    The answer is yes. This may come as a surprise to an unprepared reader, but the strategy is very simple.

    Let [math]S[/math] and [math]T[/math] denote the different amounts in the first and second envelopes, respectively, and let [math]x[/math] be a fixed positive number. We consider the following strategy:

    Choose [math]S[/math], if and only if [math]S > x[/math]; choose [math]T[/math] otherwise.

    ...

    If the smaller amount equals [math]M[/math], say, and the larger [math]2M[/math], then a randomized choice yields an expected value of [math]\frac{M + 2M}{2} = 1.5M[/math]. Strategy (6), however, yields an expected amount of [math]1.5M(p_1 + p_3) + 2Mp_2 = 1.5M + 0.5Mp_2[/math].
    Michael July 21, 2018 at 18:03 ¶ #198910
    Quoting fdrake
    Having an envelope means being in case A or being in case B. Opening the envelope does nothing to inform you of whether you are in case A or case B. Let's assume case A and case B are equally likely. That is, it's equally like that A (your envelope contains X and the other contains 2X) or B (your envelope contains X and the other contains X/2).

    If you are in case A, having an envelope means that the envelope you hold is either X or 2X.
    If you are in case B, having an envelope means that the envelope you hold is either X or X/2.

    Assume you're in case A. If you have the lower valued envelope X and switch, you gain X. If you have the higher valued envelope 2X and switch you lose X. It is equally likely that you have X or 2X, so the expected gain conditional on being in case A is:

    0.5(X-X)=0

    Assume you're in case B. If you have the lower valued envelope X/2 and switch, you gain X/2. If you have the higher valued envelope X and switch, you lose X/2. So the expected gain conditional on being in case A is:

    0.5( 0.5X - 0.5X) = 0


    You're doing it again. Is X the value of my envelope or the value of the smallest envelope? You're switching between both and it doesn't make any sense, especially where you say "if you have the lower value envelope X/2".
    fdrake July 21, 2018 at 18:04 ¶ #198911
    Reply to Michael

    Where did I switch between stuff?
    Michael July 21, 2018 at 18:07 ¶ #198913
    Quoting fdrake
    Where did I switch between stuff?


    First you say "You open an envelope and see X" and then you say "If you have the higher valued envelope 2X and switch you lose X".

    How can I see X in my envelope but have 2X?

    And you also say "If you have the lower valued envelope X/2". But what does X mean here? It can't be the value of my envelope, because you're supposing that my envelope is X/2, and it can't be the value of the smallest envelope, because you're supposing that my envelope is X/2, which is smaller than X.
    Jeremiah July 21, 2018 at 18:12 ¶ #198916
    Reply to Michael I read that part. In fact I read it several times.
    fdrake July 21, 2018 at 18:13 ¶ #198917
    Reply to Michael

    Ok. I'll say it without the abuse of notation.

    There are 2 envelopes.
    You open an envelope and see the value U.
    So your random variable is U.
    The envelopes could have been filled with either X and 2X, or X and X/2. These are jointly exhaustive possibilities. These described the possible states, of either having an envelope twice the value of the other or half the value of another.
    This gives two cases to analyse. Which are labelled (X,2X) and (X,X/2). These correspond to the case when one envelope has X in it and the other envelope has 2X in it. And the case where one envelope has X in it and the other envelope has X/2 in it. The probability distribution here is on the sample space:

    A=(one envelope contains X and the other contains 2X)
    B=(one envelope contains X and the other contains X/2)

    Which means that we will analyse the cases of the expectation of switching given A, the expectation of switching given B, then use those to form the overall expectation of switching.

    Having an envelope means being in case A or being in case B. Opening the envelope does nothing to inform you of whether you are in case A or case B. Let's assume case A and case B are equally likely. That is, it's equally like that A (your envelope contains X and the other contains 2X) or B (your envelope contains X and the other contains X/2).

    If you are in case A, having an envelope means that the envelope you hold is either X or 2X. That is, U=X or U = 2X.
    If you are in case B, having an envelope means that the envelope you hold is either X or X/2. That is, U = X or U = X/2.

    Case A and Case B are jointly exhaustive. Note that if one envelope is filled with X/2, the other cannot be filled with 2X, it must be filled with X. Similarly, if one envelope is filled with 2X, the other must be filled with X. This is because one envelope must be twice the value of another (or equivalently, one is half the value of the other).

    Assume you're in case A. If you have the lower valued envelope (U=X) and switch, you gain X (you now have U=2X). If you have the higher valued envelope U=2X and switch you lose X (since you had 2X and switched to X). It is equally likely that you have X or 2X, so the expected gain conditional on being in case A is:

    0.5(X-X)=0

    Assume you're in case B. If you have the lower valued envelope X/2 and switch, you gain X/2. If you have the higher valued envelope X and switch, you lose X/2. So the expected gain conditional on being in case A is:

    0.5( 0.5X - 0.5X) = 0


    Now, it is random whether you are in case A or case B. They are equally likely. This means that the overall expectation of switching is the average of the expectations of switching in each case.

    So the average of 0 from case A and 0 from case B is 0.5(0+0)=0.

    With your approach, you have the sample space (2X,X/2) from switching. Please answer the following question:

    What is the probability of obtaining the envelope containing X? Not the conditional probability of the envelope you have containing X given that you just opened it. This is a trick, your approach does not answer this question - since it cannot be answered using only 2 envelopes unless the probability of obtaining an envelope containing X is 0...

    Better?
    Michael July 21, 2018 at 18:17 ¶ #198919
    Quoting fdrake
    You open an envelope and see the value U.
    So your random variable is U.
    The envelopes could have been filled with either X and 2X, or X and X/2.


    What does X mean here?
    fdrake July 21, 2018 at 18:18 ¶ #198920
    Reply to Michael

    X is a fixed dollar amount. Set it equal to 1 if you want, the reasoning proceeds the same way.
    Michael July 21, 2018 at 18:20 ¶ #198922
    Quoting fdrake
    X is a fixed dollar amount. Set it equal to 1 if you want, the reasoning proceeds the same way.


    OK, so how much is the U that I see in my envelope?
    fdrake July 21, 2018 at 18:21 ¶ #198923
    Reply to Michael

    You always observe X in your envelope. What was the probability of obtaining U=X? Not the conditional probability of getting X given that you opened the envelope containing it.
    Michael July 21, 2018 at 18:22 ¶ #198924
    Quoting fdrake
    You always observe X in your envelope. What was the probability of obtaining U=X? Not the conditional probability of getting X given that you opened the envelope containing it.


    So now you're back to defining X as the amount in my envelope and then supposing that I could have 2X and lose X. You're not making any sense.
    fdrake July 21, 2018 at 18:24 ¶ #198925
    Reply to Michael

    Ok. This is from how expectations work.

    Imagine that we have two envelopes, one filled with X and one with 2X.

    If I have an envelope containing X, and switch to an envelope containing 2X, I gain X from the switch.
    If I have an envelope containing 2X, and switch to an envelope containing X, I lose X from the switch.

    Does that make sense to you?
    Michael July 21, 2018 at 18:25 ¶ #198926
    Quoting fdrake
    Imagine that we have two envelopes, one filled with X and one with 2X.

    If I have an envelope containing X, and switch to an envelope containing 2X, I gain X from the switch.
    If I have an envelope containing 2X, and switch to an envelope containing X, I lose X from the switch.

    Does that make sense to you?


    Yes. So let's say that there's £10 in my envelope:

    If I have an envelope containing X (10), and switch to an envelope containing 2X (20), I gain X (10) from the switch.
    If I have an envelope containing 2X (10), and switch to an envelope containing X (5), I lose X (5) from the switch.
    fdrake July 21, 2018 at 18:26 ¶ #198927
    Reply to Michael

    Would you agree that {5,10,20} are the possible values for things in the envelopes?
    Michael July 21, 2018 at 18:27 ¶ #198928
    Quoting fdrake
    Would you agree that {5,10,20} are the possible values for things in the envelopes?


    I agree that {10} is the certain value for the thing in my envelope and that {5, 20} are the possible values for the thing in the other envelope.

    I don't know if it's correct to merge them as you have done. Rather it's either {10, 5} or it's {10, 20}.
    fdrake July 21, 2018 at 18:28 ¶ #198929
    Reply to Michael

    If 5 and 20 are permissible values for the envelopes, does it stand to reason that I could receive an envelope which is 4 times another envelope?
    Michael July 21, 2018 at 18:29 ¶ #198930
    Quoting fdrake
    If 5 and 20 are permissible values for the envelopes, does it stand to reason that I could receive an envelope which is 4 times another envelope?


    They're permissible values for the other envelope. My envelope must be £10. So either it's {10, 5} for both or it's {10, 20} for both.
    fdrake July 21, 2018 at 18:30 ¶ #198931
    Reply to Michael

    Then what's the probability of receiving an envelope containing 10? Not the probability of having 10 given that you just looked,
    Michael July 21, 2018 at 18:32 ¶ #198932
    Quoting fdrake
    Then what's the probability of receiving an envelope containing 10?


    Your question is ambiguous. Are you asking for the probability that I selected the £10 envelope (given that there's £10 in one and either £5 or £20 in the other) or the probability that the host selects £10 as a value to put in one of the envelopes? The first is 50%, the second is unknown.
    fdrake July 21, 2018 at 18:35 ¶ #198933
    Reply to Michael

    In your set up. There are three possible values for envelopes, {5,10,20}. Imagine that all envelopes are still closed. And you are given an envelope. What's the probability of having 10?
    Michael July 21, 2018 at 18:36 ¶ #198934
    Quoting fdrake
    In your set up. There are three possible values for envelopes, {5,10,20}. Imagine that all envelopes are still closed. And you are given an envelope. What's the probability of having 10?


    That's not my set up. My set up is that there's £10 in my envelope and that one envelope contains twice as much as the other. I then deduce from this that the other envelope contains either £5 or £20.
    fdrake July 21, 2018 at 18:37 ¶ #198935
    Reply to Michael

    Right. Let's try another thing.

    What's the probability that the two envelopes are filled with {5,10} and the probability that the two envelopes are filled with {10,20}? You know that you're in one of these states given that you just saw 10.
    Michael July 21, 2018 at 18:46 ¶ #198937
    Quoting fdrake
    What's the probability that the two envelopes are filled with {5,10} and the probability that the two envelopes are filled with {10,20}? You know that you're in one of these states given that you just saw 10.


    That depends on how the host selects the values. If he selects a value of X at random from some distribution that includes 5 and 10 then the unconditional probability of {5,10} or {10, 20} being selected is 1/n each (where n is the number of values in the distribution), and so the conditional probability given the £10 in my envelope is 0.5 each.

    But if the host selects the value any other way then the objective probabilities will differ. However, assuming the participant doesn't know how the values are selected, he'll just apply the principle of indifference and assume a probability of 0.5 each.
    JeffJo July 21, 2018 at 18:53 ¶ #198938
    Reply to Jeremiah
    I specifically said that my simulation is not about finding expected results as that entire argument is flawed.

    If you did, that statement was completely obfuscated by your sloppy techniques. And it isn't the argument that is flawed, it is the assumption that you know the distribution. As shown by the points you have ignored in my posts.

    But if that is what you meant, why do you keep pointing out your simulations, which coudl prove something but, as you used them, do not.

    Reply to Jeremiah
    The thing to notice here is that in all cases the absolute value of the difference between column one and column two is always equal to the lesser of the two (save rounding errors). The lesser of the two is X.

    The thing to notice here is that you can't use your "X"- the lower value - as a condition unless you see both envelopes, which renders analysis pointless.

    Reply to Jeremiah
    I pointed out a few times that the sample space of event R and the sample space of event S are equal subsets of each other, which means mathematically we can treat them the same.


    • A sample space is a set of all possible outcomes. An event is a subset of the sample space. Events don't have sample spaces.
    • It not possible for two sets to be unequal subsets of each other.
    • We are less concerned with the sample spaces, than with the corresponding probability distributions.

    So the message of this posts seems to be "I really don't know what I am talking about, but will put words together that I hope will make it sound like I do."

    Please, correct me if I am wrong. I have tried to make sense of what you said, but much of it defines all attempts.

    Reply to Jeremiah
    R and S is the event you have X or 2X when you get A. By definition of A and B, if A=X then B =2X, or if A =2X then B=X. So by definition if A equals X then B cannot also equal X.

    This is unintelligble.

    Maybe you meant "R and S are events that are conditioned on you having chosen envelope A and it haing the low value or the high value, respectively. If you associate either with a value X from the sample space of possible values, which has nothing to do with R or S, then R means that B must have 2X, and S means that B must have X/2." But you were trying to dissuade Dawnstorm from what appears to have been a valid interpretation of another of your fractured statements; that X was simultaneously possible for both A and B. Even though he realized you could not have meant that, and said as much.

    But this still pointless. If you aren't given a value in X, all you need to do is point out that the potential loss is the same as the potential gain. If you are given a value, you do need the distributions. Which you would know, if you read my posts as well I as have (tried to) read yours.

    I also pointed out that as soon as you introduce Y they are no longer equal subsets and therefore mathematically cannot be treated the same.

    This may be what you were referring to when about "Y." It still refers to ill-defined sets, not distributions.
    fdrake July 21, 2018 at 18:55 ¶ #198939
    Quoting Michael
    But if the host selects the value any other way then the objective probabilities will differ. However, assuming the participant doesn't know how the values are selected, he'll just apply the principle of indifference and assume a probability of 0.5 each.


    Right. So there are two cases.

    A: One envelope is filled with X and the other 2X.
    B: One envelope is filled with X and the other X/2.

    Knowing that your envelope has X=10 doesn't let you distinguish between the two cases, right? Same for any value of X.

    The values in the envelopes are entirely determined by the case. The cases can't be mixed to obtain a sample space of {X/2,2X} since that's not a possible assignment by the question.

    It's also entirely random whether you're observing the thing or its multiple. This means switching has to be averaged within the case (with equal probability assignments for each outcome) and then over the cases (with equal probability assignments for each case).
    Michael July 21, 2018 at 18:57 ¶ #198940
    Quoting fdrake
    Right. So there are two cases.

    A: One envelope is filled with X and the other 2X.
    B: One envelope is filled with X and the other X/2.

    Knowing that your envelope has X=10 doesn't let you distinguish between the two cases, right? Same for any value of X.


    Yes, so in case A I gain £10 by switching, in case B I lose £5 by switching, and each case is equally likely.
    Jeremiah July 21, 2018 at 19:00 ¶ #198941
    Reply to JeffJo
    I will not further debate such specifics.
    fdrake July 21, 2018 at 19:05 ¶ #198945
    Reply to Michael

    If you're in case A, you don't know whether you're in case A. This means you don't know if you gain or lose by switching. Same with case B.

    In case A you're assigned either X or 2X.
    In case B you're assigned either X or X/2.

    I think you're getting hung up on the idea that because you've observed a specific value for X, the other is known. Informally: you have X, yes, but you don't know whether it really is X or 2X. Or in my previous set up. You see U, you don't know whether it is [X or 2X] or [X/2 or X], so you don't know if you gain by switching.
    Michael July 21, 2018 at 19:16 ¶ #198947
    Quoting fdrake
    In case A you're assigned either X or 2X.
    In case B you're assigned either X or X/2.


    You're doing it again. It's not possible that we have 2X or X/2 because we've defined X as the value of our envelope. Your cases should be written as:

    A: My envelope is X and the other envelope is 2X
    B: My envelope is X and the other envelope is X/2

    If A is the case then we gain X (10) by switching and if B is the case then we lose X/2 (5) by switching.

    Informally: you have X, yes, but you don't know whether it really is X or 2X.


    Right, so you're conflating. On the one hand you're defining X as the value of my envelope and on the other hand you're defining X as the value of the smallest envelope. This can be fixed by defining Y as the value of my envelope, and so the value of the other envelope is either 2Y or Y/2.

    You see U, you don't know whether it is [X or 2X] or [X/2 or X], so you don't know if you gain by switching.


    I know I don't know if I gain by switching. That's not the point. The point is that if I gain then I gain £10, that if I lose then I lose £5, and that each is equally likely.
    fdrake July 21, 2018 at 19:18 ¶ #198948
    Reply to Michael

    Would you agree that my analysis would work if you didn't look in the envelope? Or that looking in the envelope was irrelevant?


    JeffJo July 21, 2018 at 20:10 ¶ #198956
    Reply to Michael
    You're going it again. Is X the value of my envelope or the value of the smallest envelope? You're switching between both and it doesn't make any sense, especially where you say "if you have the lower value envelope X/2".

    I hope I'm not talking down, that isn't my point. But probability really needs great care with terminology, and it has been noticeably lacking in this thread. This question is a result of that lack.

    Let's say that the possible values for envelopes are $5, $10, $20, and $40. This is sometimes called the range of a random variable that I will call V, for the value of your envelope.

    A conventional notation for a random variable is that we use the upper case V only to mean the entire set {$5,$10,$20,$40}. If we want to represent just one value, we use the lower case v or an expression like V=$10, or V=v if we want to treat it as unknown.

    Each random variable has a probability distribution that goes with it. The problem is, we don't know it for V.

    The conditions in the OP mean that there are three possibilities for the pair of envelopes: ($5,$10), ($10,$20), and ($20,$40). Various people have used the random variable X to mean the lower value of the pair; I think you are the only one who has used it to mean what I just called V. So X means the set {$5, $10, $20}. Notice how "$40" is not there - it can't be the low value.

    The most obvious random variable is what I have called R (this may be backwards from what I did before). So R=2 means that the other envelope has twice what yours does. Its range is {1/2,2}. It is the most obvious, since the probability for each value is clearly 50%.

    From this, we can derive the random variable W, which I use to mean the other envelope. (Others may have confusingly called it Y, or used that for the higher value; they were unclear). Its specific value is w=v*r, so its derived range is {$2.50,$5,$10,$20,$40,$80}. But we know that two of those are impossible. So what we do, is use a probability distribution where Pr(V=$5 & R=1/2)=0, and Pr(V=$20 & R=2)=0. Essentially, we include the impossible values that may come up in calculations in the range, and make them impossible in the probability distribution.

    Now, if we don't see a value in an envelope, we know that v-w must be either +x, or -x, with a 50% chance for either. So switching can't help. The point to note is that we don't know what value we might end up with; it could be anything in the full range of V.

    Your expectation calculation uses every value of W that is in its range, including the impossible ones. It has to, and that is why they are included in the range. Because of that, you can't use the probabilities for R alone - you need to do something to make $2.50 and $80 impossible.

    So you use conditional probabilities for R, not the unconditional ones:

    Exp(W|V=v) = (v/2)*Pr(R=1/2|V=v) + (2v)*Pr(R=2|V=v)
    = [(v/2)*Pr(R=1/2 & V=v) + (2v)*Pr(R=2 & V=v)] / [Pr(R=1/2 & V=v) + (2v)*Pr(R=2 & V=v)]

    We can't separate R and V in those probability expressions, because they are not indepepmndent. But we can if we transform V into X:

    = [(v/2)*Pr(R=1/2 & X=v/2) + (2v)*Pr(R=2 & X=v)] / [Pr(R=1/2 & X=v/2) + (2v)*Pr(R=2 & X=v)]
    = [(v/2)*Pr(R=1/2)*Pr(X=v/2) + (2v)*Pr(R=2)*(X=v)] / [Pr(R=1/2)*Pr(X=v/2) + (2v)*Pr(R=2)*Pr(X=v)]

    And since Pr(R=1/2)=Pr(R=2)=1/2, they divide out:

    = [(v/2)*Pr(X=v/2) + (2v)*Pr(X=v)] / [Pr(X=v/2) + (2v)*Pr(X=v)]

    Unfortunately, we don't (and can't) know the probabilities that remain. For some values of v, it may be that you gain by switching; but then for some others, you must lose. The average over all possible values of v is no gain or loss.

    What you did, was assume Pr(X=v/2) = Pr(X=v) for every value of v. That can never be true.
    fdrake July 21, 2018 at 20:26 ¶ #198959
    Reply to JeffJo

    As an aside, I think we're saying the same thing from different angles. The fundamental error Michael's making is losing track of what the sample space is and how conditioning works in the problem set up. I've been trying (as have some other people in the thread) to communicate the idea behind:

    Now, if we don't see a value in an envelope, we know that v-w must be either +x, or -x, with a 50% chance for either. So switching can't help. The point to note is that we don't know what value we might end up with; it could be anything in the full range of V.


    but I'm stumped on how to explain it better. It's pretty clear that Michael thinks conditioning on X makes a difference, which yields an impossible sample space for the problem set up (hence my question on what the raw probability of P(X=the starting value) was, and Michael's answer that it was 'unknown' - which destroys the probability measure he's using). But yeah, don't know how to get it across.

    Michael July 21, 2018 at 21:00 ¶ #198968
    Reply to JeffJo Reply to fdrake

    I think the disagreement is that you see the situation as this:

    Assume there's £10 in one envelope and £20 in the other. If you chose the £10 envelope then switching gains you £10 and if you chose the £20 envelope then switching loses you £10. Each is equally likely and so the average gain from switching over a number of games is £0. Assume there's £10 in one envelope and £5 in the other. If you chose the £10 envelope then switching loses you £5 and if you chose the £5 envelope then switching gains you £5. Each is equally likely and so the average gain from switching over a number of games is £0. This is shown by this simulation.

    Whereas I see the situation as this:

    Assume there's £10 in my envelope and that one envelope contains twice as much as the other. The other envelope must contain either £5 or £20. Each is equally likely and so the expected value of the other envelope is £12.50. I can then take advantage of this fact by employing this switching strategy to achieve this .25 gain.
    andrewk July 21, 2018 at 22:34 ¶ #198997
    Reply to fdrake Even in that more general case, the Bayesian approach can give a switching strategy with a positive expected net gain. Based on our knowledge of the world - eg how much money is likely to be available for putting in envelopes - we adopt Bayesian priors for U and V that are iid. We can use the priors to calculate the expected gain from switching as a function of the observed amount Y. That gain function will be a function that starts at 0, increases, reaches a maximum then decreases, going negative at some critical point and staying negative thereafter. The strategy is to switch if the observed amount Y is less than that critical point.

    A simple way to think of this is that it's using the observed value Y to calculate an updated estimate of the Bayesian-updated probability that we have the larger of the two amounts. But because of nonlinearities, the strategy must be based on expected gains rather than just on whether that probability is greater than 0.5.

    I like that your post encompasses multiple interpretations. This highlights an important point - that probability is simply a tool, not a fundamental truth about the universe. There is no such thing as 'the absolute probability (or expected value) of Z'. Probabilities are calculated in the context of a probability space, and we are free to set up whatever probability space we like to solve a problem. It is meaningless to say that one probability space is 'correct' and another is 'incorrect'. In finance one uses multiple different probability spaces, with different probabilities assigned to a single event, to analyse risk (eg we often speak of 'risk-neutral' vs 'historical' probabilities). Each probability space serves a different purpose. We can ask whether a probability space appears to help towards achieving its aim, but it makes no sense to ask whether a probability space is correct.
    fdrake July 21, 2018 at 22:55 ¶ #199006
    Reply to andrewk

    There's an infinity of well justified approaches if you relax both the equal probability assumptions I used. But yes, probability's just a modelling tool most of the time.

    Quoting andrewk
    We can ask whether a probability space appears to help towards achieving its aim, but it makes no sense to ask whether a probability space is correct.


    But so are sample spaces. They're a usually neglected part of model formation since it's usually obvious what all possible values of the measurement are; extreme values of measurements are also pretty easy to eyeball (EG, the probability that an adult human is taller than 3 meters is close to 0) even if more general tail behaviour isn't.

    Getting the sample space right in interpretation 2 is an important part of the solution, even when you're using priors to incorporate different information than what's available here from the relationship of the observed value in the envelope to whatever contextual information you deem relevant.

    You could also use different loss functions rather than raw expected loss to leverage other contextual information, but I don't see any useful way of doing that here.
    Michael July 21, 2018 at 23:30 ¶ #199020
    Quoting andrewk
    Even in that more general case, the Bayesian approach can give a switching strategy with a positive expected net gain. Based on our knowledge of the world - eg how much money is likely to be available for putting in envelopes - we adopt Bayesian priors for U and V that are iid. We can use the priors to calculate the expected gain from switching as a function of the observed amount Y. That gain function will be a function that starts at 0, increases, reaches a maximum then decreases, going negative at some critical point and staying negative thereafter. The strategy is to switch if the observed amount Y is less than that critical point.


    That critical point is going to be the highest [math]X[/math] that can (will?) be selected by the host, correct? If he selects a value from 1 to 100 for the smaller envelope then you never want to switch if your envelope contains more than 100.

    If we do switch only (and always) when our envelope contains £100 or less then we have a gain of 0.25.

    I've worked out that the expected gain if we switch only when our envelope is less than or equal to some fixed amount is [math]0.25*\frac{n}{M}^2[/math] where [math]M[/math] is the highest [math]X[/math] that can (will?) be selected by the host and [math]n[/math] is our chosen limit for switching. So for [math]M = 100[/math], our expected gain for some different values of [math]n[/math] are:

    0 = 0
    25 = 0.015625
    50 = 0.0625
    75 = 0.140625
    100 = 0.25

    This formula only works if our chosen limit is less than or equal to [math]M[/math]. I can't figure out the formula for if it's greater. I've only simulated that the rough gains are:

    125 = 0.204124
    150 = 0.145
    175 = 0.080
    200+ = 0

    Maybe you can work it out?
    andrewk July 21, 2018 at 23:38 ¶ #199021
    Quoting fdrake
    You could also use different loss functions rather than raw expected loss to leverage other contextual information, but I don't see any useful way of doing that here.

    Indeed, and that's where utility curves come in. If a parent has a child who will die unless she can get medicine costing M, and the parent can only access amount F, the parent should switch if the observed amount is less than M-F and not switch otherwise.
    Srap Tasmaner July 21, 2018 at 23:44 ¶ #199022
    If the game is iterated, so that you can accumulate data about the sample space and its probability distribution, then it's an interesting but completely different problem. We can still talk about strategies in the non-iterative case.

    The three choices are:

    1. Never Switch,
    2. Always Switch, and
    3. Sometimes Switch.


    There is some evidence that Sometimes Switch increases your expected gain. (I've played around a tiny bit with this, and the results were all over the place but almost always positive. I don't really know how to simulate this.) That's interesting but not quite the "puzzle" here.

    If you were trying to find a strategy that is nearly indistinguishable from Never Switch over a large number of trials (not iterated, just repeated), then it would be Always Switch. If, for instance, you fix the value of X, so that there is a single pair of envelopes used over and over again, then we're just talking about coin flips. A Never Switch strategy might result in HTHHTHTT... while Always Switch would be THTTHTHH... and it couldn't be more obvious they'll end up equivalent.

    So then the puzzle is what to do about the Always Switch argument, which appears to show that given any value for an envelope you can expect the other envelope to be worth 1/4 more, so over a large number of trials you should realize a gain by always switching. This is patently false, so the puzzle is to figure out what's wrong with the argument.

    The closest thing I have to answer is this:
    If you define the values of the envelopes as X and 2X for some unknown X, you're fine.
    If you want instead to use variables for the value of the envelope you selected, Y, and the value of the one you didn't, U, you can do that. But if you want to eliminate one of them, so you can calculate an expectation only in terms of Y or U, you have to know which one is larger. (Note that there is no ambiguity with X and 2X.) Which one is larger you do not and cannot know.

    User image
    andrewk July 21, 2018 at 23:45 ¶ #199023
    Quoting Michael
    That critical point is going to be the highest XX that can (will?) be selected by the host, correct?

    Yes, if we assume a uniform distribution for X on the interval [1,M]. If we assume a more shaped distribution that decays gradually to the right then it will be something different. A gradually changing distribution would be more realistic because it would be strange to say that the probability density of choosing X=x is constant until we reach M and then suddenly plunges to zero. The calculations get messier and hard to discuss without long equations if we use fancy distributions (such as beta distributions or truncated lognormals) rather than a simple uniform distribution. But they can be done.
    Jeremiah July 22, 2018 at 00:01 ¶ #199024
    Quoting andrewk
    Each probability space serves a different purpose. We can ask whether a probability space appears to help towards achieving its aim, but it makes no sense to ask whether a probability space is correct.


    It absolutely makes sense to ask if it is correct, and that should be the first question you ask yourself whenever you model something.
    Jeremiah July 22, 2018 at 00:04 ¶ #199025
    In any science you should repeatedly stop and ask yourself, "Is this correct?"
    Jeremiah July 22, 2018 at 00:08 ¶ #199026
    This is why I became disillusioned with philosophy. I wanted real answers, not made up ones
    Pierre-Normand July 22, 2018 at 01:58 ¶ #199049
    Quoting andrewk
    Indeed, and that's where utility curves come in. If a parent has a child who will die unless she can get medicine costing M, and the parent can only access amount F, the parent should switch if the observed amount is less than M-F and not switch otherwise.


    Agreed. Alternatively, some player's goal might merely be to maximise the expected value of her monetary reward. In that case, her choice to stick with the initial choice, or to switch, will depend on the updated probabilities of the two possible contents of the second envelope conditional on both the observed content of the first envelope and on some reasonable guess regarding the prior probability distribution of the possible contents of the first envelope (as assessed prior to opening it). My main argument rests on the conjecture (possibly easily proven, if correct) that the only way to characterize the problem such that the (posterior) equiprobability of the two possibilities (e.g. ($10, $20) and ($10, $5)) is guaranteed regardless of the value being observed in the first envelope ($10 only in this case) is to assume something like a (prior) uniform probability distribution for an infinite set of possible envelope contents such as (... , $0.5, $1, $2, ...).
    Pierre-Normand July 22, 2018 at 02:04 ¶ #199053
    Quoting Jeremiah
    It absolutely makes sense to ask if it is correct, and that should be the first question you ask yourself whenever you model something.


    You may call one interpretation the correct one in the sense that it provides a rational guide to behavior given a sufficient set of initial assumptions. But it this case, as is the case with most mathematical or logical paradoxes, the initial set of assumptions is incomplete, inconsistent, or some assumptions (and/or goals) are ambiguously stated.
    Pierre-Normand July 22, 2018 at 02:10 ¶ #199054
    Quoting Michael
    By this do you just mean that if we know that the value of X is to be chosen from a distribution of 1 - 100 then if we open our envelope to find 150 then we know not to switch?


    That's one particular case of a prior probability distribution (bounded, in this case) such that the posterior probability distribution (after one envelope was opened) doesn't satisfy the (posterior) equiprobability condition on the basis of which you had derived the positive expected value of the switching strategy. But I would conjecture that any non-uniform or bounded (prior) probability distribution whatsoever would likewise yield the violation of this equiprobability condition.
    Jeremiah July 22, 2018 at 02:36 ¶ #199060
    Reply to Pierre-Normand

    Like making a bunch of assumptions based on Y.
    Srap Tasmaner July 22, 2018 at 04:02 ¶ #199070
    Quoting JeffJo
    Unfortunately, we don't (and can't) know the probabilities that remain. For some values of v, it may be that you gain by switching; but then for some others, you must lose. The average over all possible values of v is no gain or loss.

    What you did, was assume Pr(X=v/2) = Pr(X=v) for every value of v. That can never be true.


    My first post in this thread three weeks ago:

    Quoting Srap Tasmaner
    You're right that seeing $2 tells you the possibilities are {1,2} and {2,4}. But on what basis would you conclude that about half the time a participant sees $2 they are in {1,2}, and half the time they are in {2,4}? That is the step that needs to be justified.


    But I still need help with this.

    Yesterday I posted this and then took it down:

    [math]\small \begin{align} O(X=a:X=\frac{a}{2}\mid Y=a)&=O(X=a:X=\frac{a}{2})\frac{P(Y=a\mid X=a)}{P(Y=a\mid X=\frac{a}{2})} \\&=O(X=a:X=\frac{a}{2}) \end{align}[/math]

    Bayes's rule in odds form, which shows that knowing the value of the envelope selected (Y), provides no information at all that could tell you whether you're in a [a/2, a] situation or [a, 2a].

    I took it down because the Always Switcher is fine with this, but then proceeds to treat all the possible values as part of one big sample space, and then to apply the principle of indifference. This is the step that you claim is illegitimate, yes? Not the enlarging of the sample space.

    Quoting JeffJo
    Essentially, we include the impossible values that may come up in calculations in the range, and make them impossible in the probability distribution.


    Is this the approach that makes it all work?

    I kept thinking that Michael's mistake was assuming the sample space includes values it doesn't. (That is, upon seeing Y=a, you know that a or a/2 is in the sample space for X, but you don't know that they both are.) But I could never quite figure out how to justify this -- and that's because it's a mistaken approach?

    Quoting JeffJo
    Unfortunately, we don't (and can't) know the probabilities that remain. For some values of v, it may be that you gain by switching; but then for some others, you must lose. The average over all possible values of v is no gain or loss.


    Right and that's what I saw above -- the odds X=a:X=a/2 are still whatever they are, and still unknown.

    Your last step, averaging across all values of V, I'm just trusting you on. Stuff I don't know yet. Can you sketch in how you handle the probability distribution for V?
    Michael July 22, 2018 at 09:31 ¶ #199098
    Quoting Srap Tasmaner
    So then the puzzle is what to do about the Always Switch argument, which appears to show that given any value for an envelope you can expect the other envelope to be worth 1/4 more, so over a large number of trials you should realize a gain by always switching. This is patently false, so the puzzle is to figure out what's wrong with the argument.


    In half the games where you have £10 you switch to the envelope with an expected value of £12.50 and walk away with £20. In half the games where you have £20 you switch to the envelope with an expected value of £25 and walk away with £10. The gain from the first game is lost in the second game.

    It's because of this that you don't gain in the long run (given that some X is the highest X and every game where you have more than this is a guaranteed loss), and it's with this in mind that I formulated my strategy of only switching if the amount in my envelope is less than or equal to half the maximum amount seen, which I've shown does provide the expected .25 gain (which is no coincidence; the math I've been using shows why the gain is .25). And if we're not allowed to remember previous games then the formula here shows the expected gain from some arbitrarily chosen limit on when to switch, peaking at .25.

    So as a simple example, you switch when it's £10 into an envelope with an expected value of £12.50 and walk away with £20 and stick when it's £20 because you don't want to risk losing your winnings from the first game. In total you have £40. The person who sticks both times has £30. You have .25 more than him.

    Also, that article you provided refers to this paper which shows with some simulations that the expected gain from following their second switching strategy averages at .25 (thick black lines at top):

    User image
    Jeremiah July 22, 2018 at 10:01 ¶ #199103
    No amount of "math" will ever change the actual contents of the envelopes. Some of you are just pushing numbers around on the page, but math is not magic, it can't change the actual dollar values.

    And I know I am just speaking in the wind at this point, but we could physically set this game up, using various dollar amounts and you'd never get the expected gain some here are predicting. You can't just think about the numbers, you have to think about the actual outcome.
    Michael July 22, 2018 at 10:06 ¶ #199105
    Quoting Jeremiah
    And I know I am just speaking in the wind at this point


    Well, you did say here that "[you are] already convinced [your] approach is correct... [you] have no doubt about it, and [you] no longer care about arguing or proving that point".

    So I don't know why you keep posting or why you'd expect anyone to address you further.
    Jeremiah July 22, 2018 at 10:16 ¶ #199108
    You should be willing to empirically justify your theory.
    Jeremiah July 22, 2018 at 10:47 ¶ #199110
    Reply to Michael

    They are making a lot of assumptions. Conditions and information not included in the OP.
    Jeremiah July 22, 2018 at 11:19 ¶ #199115
    I already commented on the assumptions that follow the use of distributions earlier in this thread. So basically we are back to once more modeling a pile of assumptions.
    Jeremiah July 22, 2018 at 11:22 ¶ #199117
    As I pointed out the thread is just going in circles.
    Michael July 22, 2018 at 11:27 ¶ #199118
    Quoting Jeremiah
    If you are not willing to justify your model empirically, well then that says it all. You should be willing to empirically justify your theory.


    I am. I already ran the simulation.

    I've also built the game for us to play here.

    First select your chosen envelope. Then select either "switch" or "stick". Then press "next" to play the next game.

    Using my strategy for 50 games gave this result:

    User image
    Jeremiah July 22, 2018 at 11:30 ¶ #199119
    Reply to Michael I only read R.
    Michael July 22, 2018 at 11:32 ¶ #199120
    Reply to Jeremiah Here it is in R.

    Edit: Now has comments
    Jeremiah July 22, 2018 at 11:53 ¶ #199123
    Reply to Michael

    You still need to notate your code. Especially on forums like these. I don't know why you don't do that. It almost makes it seem like you are trying to hide your assumptions in the code.


    You are still using your incorrect sample space.

    I am not going to look at any more code that is not notated. I mean that should just be common sense if you are going to post it here.

    Michael July 22, 2018 at 12:00 ¶ #199124
    Reply to Jeremiah I've added comments.
    Jeremiah July 22, 2018 at 12:02 ¶ #199125
    Reply to Michael

    Thank you, sorry for getting riled, I just hate going over someone else's code without notes.
    Jeremiah July 22, 2018 at 12:08 ¶ #199128
    Reply to Michael

    I like using simulations for empirical investigation; however, you and I, deeply disagree on the underlying assumptions and the code will reflect that if we are not careful.
    Jeremiah July 22, 2018 at 12:14 ¶ #199129
    If you use a distribution you are making assumptions not included in the OP. I pointed this out before.

    One thing we can be sure of from the OP is that one has X and one has 2X.
    Michael July 22, 2018 at 12:21 ¶ #199130
    Reply to Jeremiah Here you ran your own simulation with X selected at random (multiples of 10).

    You then ran the simulation with other methods of selecting X and said "the distribution in which X was selected from is not significant when assessing the possible outcome of envelope A and B concerning X or 2X".

    I'll try running my simulation using the three other methods you described and see if I get the same .25 gain (or a gain of any amount).
    Jeremiah July 22, 2018 at 12:23 ¶ #199131
    Reply to Michael

    If you are doing it based on the your X, X/2 sample space, you'll get your expected gain. I have no doubt about that. The math already proves that.

    To simulate this we need agreed upon assumptions.
    Michael July 22, 2018 at 12:27 ¶ #199132
    Quoting Jeremiah
    If you are doing it based on the your X, X/2 sample space, you'll get your expected gain.


    There's nothing like that. I just open my envelope, which contains either X or 2X, and I switch if it's less than or equal to the highest X I've seen.

    Perhaps you could point out which line(s) of my code you disagree with. Is it just how I select X?

    x <- sample(1:100, 1) * 4
    Jeremiah July 22, 2018 at 12:36 ¶ #199134
    Reply to Michael

    No, I used the same scale in my code.

    It is this:

      if (

    0 == max_2x
    ||
    choice <= max_2x / 2

    )
    {
    switch <- switch + other
    }

    # Otherwise increase the switching strategy amount by the amount in the chosen
    # envelope
    else
    {
    switch <- switch + choice
    }

    # Record the highest value seen
    max_2x <- max(c(choice, other, max_2x))


    You code is based off your assumptions.
    Michael July 22, 2018 at 12:37 ¶ #199135
    Quoting Jeremiah
    You code is based off your assumptions.


    Huh? That's not an assumption. That's my strategy. I switch envelopes if the value in my envelope is less than or equal to the highest X I've seen in previous games.

    So if in the first game we have £10 and £20 then in the second game I switch if I have £10 but not if I have £20.
    Jeremiah July 22, 2018 at 12:38 ¶ #199136
    Reply to Michael

    Basing it on "previous games" is an assumption. That information was never in the OP.
    Jeremiah July 22, 2018 at 12:41 ¶ #199137
    Reply to Michael

    Don't get me wrong, Michael, I found your linked article here an interesting read, but it moves beyond the scope of the problem in the OP, and all these assumptions are subjectively based.
    Jeremiah July 22, 2018 at 12:48 ¶ #199139
    Even if this was a game show, they are not going to give you 20,000 goes to figure out their range. That makes no sense. This is what I mean by being subjective. I rather remain objective and get a model that approaches reality.
    Michael July 22, 2018 at 12:49 ¶ #199140
    Reply to Jeremiah

    So first you say "If you are not willing to justify your model empirically, well then that says it all. You should be willing to empirically justify your theory." and then you don't like when I test my theory by playing 100 games? That makes no sense.

    Even if you don't like that I get to remember previous games, there can still be a gain if we choose some arbitrary amount to be the limit for when I decide to switch. So, if I were to always switch if my envelope contains £400 or less and stick otherwise then using my simulation I would gain .25. If my limit was £200 then I would gain 0.0625. If my limit was £600 then I would gain ~0.145.

    The formula for the expected gain, as explained here, is [math]0.25*\frac{n}{M}^2[/math] where [math]M[/math] is the highest [math]X[/math] that can be selected by the host and [math]n[/math] is our chosen limit for switching (although as I also say there, this formula only works when our limit is less than or equal to [math]M[/math]; I haven't worked out the formula for when it's greater).

    So re-run my simulation but replace the lines you don't like with:


    # If the amount in the chosen envelope is less than or equal to
    # 300 then switch and increase the switching strategy amount
    # by the amount in the new envelope
    if (choice <= 300)
    {
    switch <- switch + other
    }

    # Otherwise increase the switching strategy amount by the amount in the chosen
    # envelope
    else
    {
    switch <- switch + choice
    }


    The gain is ~0.14.
    Jeremiah July 22, 2018 at 12:52 ¶ #199142
    Reply to Michael

    I already ran my own simulations, Michael, and the idea that if this was a game you'd get many turns to learn the range is very unrealistic. This is what I am not interested in. I didn't get into statistics to map people subjective assumptions. I can do that without math.
    Michael July 22, 2018 at 12:56 ¶ #199143
    Reply to Jeremiah As I said above, you don't need to learn the range. You can choose any arbitrary amount before you start and switch only if the amount in your envelope is less than or equal to that amount. You will have an expected gain if your chosen amount is less than the highest 2X envelope, with a best case scenario of .25 if your chosen amount happens to be the highest X envelope.
    Jeremiah July 22, 2018 at 12:59 ¶ #199145
    Reply to Michael

    I choose 10 billion.
    Srap Tasmaner July 22, 2018 at 13:03 ¶ #199147
    Reply to Michael
    There are Sometimes Switch strategies that work, so far as I can tell.

    Do you believe that shows that your original argument, which concludes that the value of whatever envelope you don't have is 1/4 more than the one you do have, is valid?
    Michael July 22, 2018 at 13:05 ¶ #199148
    Quoting Srap Tasmaner
    Do you believe that shows that your original argument, which concludes that the value of whatever envelope you don't have is 1/4 more than the one you do have, is valid?


    The expected value (given the information available to us), yes.
    Srap Tasmaner July 22, 2018 at 13:10 ¶ #199150
    Reply to Michael
    But that argument, that "calculation", is not based on using any particular strategy. It's just this:

    E(U)=.5(2Y) + .5(Y/2)

    Do you believe that the success of the various switching strategies available shows that this expectation is correct?
    Michael July 22, 2018 at 13:12 ¶ #199151
    Reply to Srap Tasmaner Yes, which is why my switching strategy (and the second switching strategy in the paper you referred to) provides a gain of .25. It's not a coincidence that the values coincide.
    Srap Tasmaner July 22, 2018 at 13:16 ¶ #199153
    Reply to Michael
    If that expected value calculation is correct, then Always Switch should produce the expected gain, shouldn't it?

    What, in that formula, suggests that a Sometimes Switch strategy is correct?
    Jeremiah July 22, 2018 at 13:20 ¶ #199154
    A "switch strategy" is just a way to approximate the distribution through iterations. Or the transformed distribution.
    Michael July 22, 2018 at 13:22 ¶ #199155
    Quoting Srap Tasmaner
    If that expected value calculation is correct, then Always Switch should produce the expected gain, shouldn't it?


    No, because if the amount in your envelope (say £160) is more than the highest X that the host can choose (say £100) then you're always going to lose, even though the expected value of the other envelope, given the information available to you, is £200.

    This is the fact that my strategy accounts for.

    Quoting Srap Tasmaner
    What, in that formula, suggests that a Sometimes Switch strategy is correct?


    I don't know what you mean by this. The simulation of the strategy shows that the strategy is correct. The formula just explains why the gain from the strategy is 0.25; the expected value of the other envelope is [math]\frac{5}{4}Y[/math].
    Jeremiah July 22, 2018 at 13:25 ¶ #199156
    It needs a simulation with a distribution but gives no new information of the distribution. Perhaps by scrambling the possible outcome than assigning random arbitrary labels. If the distribution is not known then you can't approximate it and get accurate results. You'd still have the problem of bounds though. Maybe scramble those as well.
    Srap Tasmaner July 22, 2018 at 13:33 ¶ #199157
    Quoting Michael
    The formula just explains why the gain from the strategy is 0.25; the expected value of the other envelope is 5Y/4.


    Not all Sometimes Switch strategies produce an expected gain of Y/4.

    None of them calculate their expected gain using your formula.
    Jeremiah July 22, 2018 at 13:43 ¶ #199159
    The best way to sovle this is still the simple algreba, it introduces no new assumptions. However, if you are going to simulate this it should be done in a way were the distribution and bounds remain as unknowns, instead of being set beforehand, if that could be done than it could become a useful tool for mapping unknowns distributions.
    Jeremiah July 22, 2018 at 14:03 ¶ #199163
    A "switching strategy" is essentially machine learning. It is also out of scope of the OP, there is no guarantee such methods are applicable.
    Jeremiah July 22, 2018 at 14:14 ¶ #199164
    It is an interesting idea in terms of exploring unknown distributions; however, no one has actually justified this approach with respects to the OP. People are making far too many assumptions that they have no way of confirmimg.
    Jeremiah July 22, 2018 at 14:18 ¶ #199166
    We went from being totally uninformed at the start of the thread to the knowledge gained after thousands of iterations with predefined conditions never included in the OP. Did you really map the OP, or did you map your assumptions?

    This is one of the reasons we need to constantly question, "Is this correct?"
    fdrake July 22, 2018 at 14:22 ¶ #199167
    Reply to Jeremiah

    ITT Jeremiah forgets that frequentist expectation calculations are asymptotic.
    Jeremiah July 22, 2018 at 14:27 ¶ #199168
    Reply to fdrake I really do not care about this Classical vs Baysian nonsense you all have going on in these forums. That mind set didn't even exist to me before you all started in about it. Which makes me constantly question what other bad habits I could pick up here.
    Jeremiah July 22, 2018 at 14:29 ¶ #199169
    As I said many, many times algreba is the correct tool to use here. Not Baysian or Classical statistics, but simple algreba. Simply because I talk about the stats doesn't mean I have changed my mind on that.
    fdrake July 22, 2018 at 14:40 ¶ #199171
    Reply to Jeremiah

    You could pick up a bad habit like charitable reading or obtain some appreciation towards the other half of statistics, or worse even, philosophy in general - which you regularly express contempt for.

    As soon as you apply an expectation operator to the random variable in the envelope, you're already required to apply the context of long term behaviour and the independent repeatability of the trial. Regardless of the interpretation of the sample space and sampling mechanism, the concordance of the expected gain calculation with the long run sample gain echos the assumption. It's literally set up that way. It's in the algebra. If you terminated the simulation when you still have a small sample, you can analytically calculate the finite sample properties - which don't have to coincide with the expectation as you well know, and rarely exactly do.

    Michael's calculations are actually correct if his assumptions are, his algebra is right, it's the modelling of the situation that differs. It's just algebra.
    Jeremiah July 22, 2018 at 14:55 ¶ #199173
    Quoting fdrake
    philosophy in general - which you regularly express contempt for.


    I picked up my contempt for philosophy from these forums many years ago. I was a member of the old forums.

    Quoting fdrake
    As soon as you apply an expectation operator to the random variable in the envelope, you're already required to apply the context of long term behaviour and the independent repeatability of the trial.


    Which is why you need to stop and ask yourself, "Is this correct?" You need to make sure what you are doing is applicable. It is math, not magic, you need to make sure your approach fits.

    Quoting fdrake
    if his assumptions are


    Talk about "charitable reading" . . . I think I have fully expressed that my main problem is with the assumptions.


    Srap Tasmaner July 22, 2018 at 14:59 ¶ #199174
    One interesting point about the Arbitrary Cutoff strategy is that Never Switch and Always Switch can be seen as the degenerate cases: Never sets the cutoff to 0; Always to, well, "infinity".

    (Btw, good find on the article, @Jeremiah. Addressed my bafflement over how assigning variables leads to trouble.)
    fdrake July 22, 2018 at 15:01 ¶ #199176
    Quoting Jeremiah
    Which is why you need to stop and ask yourself, "Is this correct?" You need to make sure what you are doing is applicable. It is math, not magic, you need to make sure your approach fits. God forbid I question the legitimacy of this approach.


    This is exactly why andrewk and Pierre's comments are on point. They found ambiguities in the problem (the equiprobability assumption, which as stated is not part of the problem!), then showed another way of filling in the blanks in andrewk's case, and gestured towards the general difference in approach in Pierre's case.
    Jeremiah July 22, 2018 at 15:08 ¶ #199178
    Reply to fdrake

    The whole distribution thing is faulty. I agree in the strictness sense of the definition there is an unknown distribution, but as far was we know it was whatever was in his pocket when he filled the envelopes. We can't select a distribution to use, as we have no way to check it. We don't know what the limits are and have no way to check that. So it is not that I disagree with making assumptions, it is making unnecessary assumptions; aka Occam's razor.

    Jeremiah July 22, 2018 at 15:13 ¶ #199180
    If you introduce a known distribution then you are making assumptions about the distribution. Classical or Bayesian, it does not matter, that is true for both. If you insist on defining it on these terms then why are we not adhering to the Law of Parsimony?
    Jeremiah July 22, 2018 at 15:18 ¶ #199182
    The simplest explanation is that our gain/loss is either x or-x.
    fdrake July 22, 2018 at 15:24 ¶ #199183
    Reply to Jeremiah

    Why is equiprobability simple but other priors aren't?

    There's no simple reason to assume equiprobability. Doing so requires appealing to more sophisticated mathematical arguments with assumptions that probably don't hold anyway. Things like limiting distributions of independent draws or entropy maximisation.

    How I would actually approach the problem:

    If I deem the amount of money in my envelope tiny (say <100) I'd switch to be able to afford some nice things.

    If I deem the amount of money in my envelope around some threshold that would give me some more financial security, I'd walk away with the money in my envelope. I think 10,000 is about right. That's a down payment on a house, over a year's rent etc.

    If it's a ridiculously large amount of money, I'd switch again out of greed and that the loss wouldn't be felt so much because I'd use it for financial security/savings. I'd still be able to do what I wanted with the middle amount or the smaller amount.




    Jeremiah July 22, 2018 at 15:30 ¶ #199186
    Quoting fdrake
    Why is equiprobability simple but other priors aren't?


    Equiprobability is unbiased.
    fdrake July 22, 2018 at 15:31 ¶ #199187
    Reply to Jeremiah

    That's a principle of indifference then. Equally possible things are equally probable. A rule for assigning subjective probabilities.
    Jeremiah July 22, 2018 at 15:41 ¶ #199189
    Reply to fdrake

    If you don't use a random sampling method your event could become skewed by observational bias. I am sure there are cases to use weighted selection methods, but you need to justify their use, not just throw them out there just because. The goal is to mitigate observational bias; however, it can never be fully scrubbed. Still we need to try and let the distribution reveal itself instead of injecting it full of our opinions. We live in a house of subjectivity, and I just want to get as close to the objective as I can, even if that is an impossible task. Maybe you didn't pick up on it, but I use to have a significant interest in philosophy.


    Jeremiah July 22, 2018 at 15:45 ¶ #199192
    I should note a credit to the philosophers, I have found, after crossing over to science, that the science types do seem to have problems with the whys of their doings.
    fdrake July 22, 2018 at 15:48 ¶ #199195
    Reply to Jeremiah

    If you assume equiprobability as a prior then you're only not influencing the results if your prior is a pointmass on 0.5 and the actual value is 0.5. This is a terrible prior, as it fixes the posterior to have p=0.5 despite anything and everything. In a situation of uncertainty and ambiguity, assuming infinite certainty (no prior variance) is completely nuts.
    Jeremiah July 22, 2018 at 15:56 ¶ #199200
    Reply to fdrake

    Over the long run an equiprobability as a prior has the least amount of drag. Unless you can justify using a weighted selection method it is the best approach.
    Jeremiah July 22, 2018 at 16:01 ¶ #199203
    Reply to fdrake

    I'll tell you what next time I do a class project I won't use a random sampling method and we'll see if I get an F or an A. Good thing I am learning how to do statistics on these forums and not in the classroom.
    fdrake July 22, 2018 at 16:18 ¶ #199213
    Reply to Jeremiah

    Random sampling's good. p's also random since it's uncertain. This is the point.
    Jeremiah July 22, 2018 at 17:39 ¶ #199257
    [Consider] the philosophy in Bayesian statistics of using an uninformative prior.
    fdrake July 22, 2018 at 19:08 ¶ #199274
    Reply to Jeremiah

    'Uninformative' priors usually aren't uninformative, and sometimes they aren't even probability functions. For example, the equiprobability 'prior' you use on the probabilities is actually infinitely informative for the probability! What you gain in 'uninformativeness' on the level of outcomes you spend in infinite informativeness on the level of the (in the problem unspecified) probability parameter. There's uncertainty you're not modelling with equiprobability.

    I suppose I'll stop antagonising you now.
    Jeremiah July 22, 2018 at 19:35 ¶ #199280
    Reply to fdrake

    Ask yourself why they generally are using equiprobability as a prior when they are uninformed. There is a reason why, [and] why random samples use equiprobability.
    Jeremiah July 23, 2018 at 00:03 ¶ #199300
    [ I suggest that readers and contributors] check the definition of a random sample. It has a very interesting definition in this context, which I actually already posted in this thread.
    Andrew M July 23, 2018 at 02:22 ¶ #199314
    It seems to me that there are some claims about the Two Envelopes problem that everyone might agree on.

    1. If the player does not know the amount in the chosen envelope then the expected gain from switching is zero.

    2. If the player knows the amount in the chosen envelope and also knows everything about the distribution then the expected gain can be calculated and used to strategically switch on (i.e., switch if the expected gain is positive else stick).

    For example, if the player knows that there are only two equally likely envelope pairs of { $5, $10) and { $10, $20 } respectively and sees $10 then they would know that there is a $2.50 expected gain from switching. Whereas if they see $20, they would know that there is a $10 expected (and actual) loss from switching.

    3. If the player knows the amount in the chosen envelope but knows nothing else about the distribution then there is no general strategy that would increase their expected gain above zero.

    4. If the player knows the amount in the chosen envelope and knows or can estimate information about the distribution then there are strategic switching strategies (e.g., Cover's strategy) that can increase their expected gain above zero.
    Srap Tasmaner July 23, 2018 at 02:35 ¶ #199320
    Reply to Andrew M
    I agree with all of those.

    *** You might have (3) and (4) a little wrong but I can't judge. The McDonnell & Abbott paper makes noises about the player using Cover's strategy having no knowledge of the PDF of X.

    Pierre-Normand July 23, 2018 at 02:52 ¶ #199322
    Quoting Andrew M
    1. If the player does not know the amount in the chosen envelope then the expected gain from switching is zero.


    You might not find that everyone agrees on this first claim since, under conditions of equiprobability, the paradox arises whereby (1) acquiring knowledge of the content X of the first envelope yields and expected value of 1.25*X for switching and (2) merely acquiring knowledge of the content of the first envelope ought not to change anything to the already determined expectation of switching. This is what makes the assumption of equiprobability so problematical (since (2) can be inferred from it).

    On edit: I looked at earlier posts of yours in this thread, such as this one, and I see that we are on the same page.
    Jeremiah July 23, 2018 at 05:51 ¶ #199331
    Random selection, which means equal probability, mitigates observational bias by treating each n in a population the same. This helps maximize the influence of an unknown population distribution on your sample.

    This is also the reason it is used as an uninformed prior in Bayesian statistics, by setting the unknowns equal the prior will have less pull on the posterior, allowing your sample to have more influence on the outcome.

    If you don't know the distribution you try to give the population distribution as much room as you can to revel itself. You do this by trying to limit the influence of your personal bias both conscious and unconscious.

    Not really something I should have to explain, but it seems it needed clarification.


    Pierre-Normand July 23, 2018 at 06:13 ¶ #199333
    Quoting Jeremiah
    Random selection, which means equal probability, mitigates observational bias by treating each n in a population the same.


    The equiprobability that I am talking about is the posterior equiprobability between the two possible contents of the second envelope: either X/2 or 2*X. This posterior equiprobability only is guaranteed by an unbounded prior distribution. If one rather assumes a prior distribution that assigns the same probability to a finite population of possible envelope contents, then such a prior isn't uniform since it assigns a zero probability (or zero probability density) to all the conceivable envelope contents that fall outside of this finite discrete (or continuous albeit bounded) range. (One might also consider the case of unbounded albeit convergent, and hence normalisable, probability density functions. And those aren't uniform either).
    Srap Tasmaner July 23, 2018 at 06:59 ¶ #199337
    Quoting Pierre-Normand
    The equiprobability that I am talking about is the posterior equiprobability between the two possible contents of the second envelope: either X/2 or 2*X.


    Okay, tell me if I'm doing this wrong.

    Let S be the smaller of the two values, M be your envelope, and N the other. This is certainly true:

    [math]\small \begin{align} E(N) &= (2S)P(M=S)+(S)P(M=2S)\end{align}[/math]

    And so is this:

    [math]\small \begin{align} E(N\mid M=a) &= (2S)P(M=S\mid M=a)+(S)P(M=2S\mid M=a)\end{align}[/math]

    Let [math]\small p=P(S=a\mid M=a)[/math]; then [math]\small 1-p=P(S=\cfrac{a}{2}\mid M=a)[/math]. Now we can say this:

    [math]\small \begin{align} E(N\mid M=a) &=2ap+{a\over 2}(1-p) \\&= a\cfrac{3p+1}{2}\end{align}[/math]
    Possible values of p:

    [math]\small \begin{align} p&=1\to E(N\mid M=a)=2a\\p&=0\to E(N\mid M=a)=\frac{a}{2} \end{align}[/math]

    So far so good. But we cannot do this:

    [math]\small p=\cfrac12\to E(N\mid M=a)=\cfrac{5a}{4}[/math]

    anymore than we can do this:

    [math]\small p=\cfrac13\to E(N\mid M=a)=a[/math]

    There are only two possible values for N, given an observed value for M, and the only two values for p that produce possible values for N are 0 and 1.

    How am I to interpret that result?
    Pierre-Normand July 23, 2018 at 07:24 ¶ #199339
    Quoting Srap Tasmaner
    So far so good. But we cannot do this:

    [math]\small p=\cfrac12\to E(N\mid M=a)=\cfrac{5a}{4}[/math]


    (How should I proceed in order to quote your formulas correctly?)

    Why couldn't you do that? If the initial set up calls for randomly assigning values for the two envelopes in the finite range ((1,2),(2,4),(4,8)) for instance, then, in that case, assuming the player knows this to be the initial set up (and hence uses it as his prior) then the posterior probability conditionally on observing any value of M that isn't either 1 or 8 (that is, conditionally on values 2 or 4 being observed) p will indeed be 1/2.

    I was arguing that it can't be 1/2 regardless of the value being observed in the first envelope unless the prior being assumed is an infinite and uniform (and hence non-normalisable) distribution.
    andrewk July 23, 2018 at 07:44 ¶ #199340
    Reply to Pierre-Normand
    If you right-click on a TeX formula and select 'Show Math As...' then 'TeX commands', then you can copy and paste the code for that in between [ math ] and [ /math ] delimiters (without the white space inside the brackets) and, all going well, it will appear as nicely displayed TeX in your post.

    Unfortunately I don't think there is a single-click facility to quote a post including its TeX properly. It has to be done equation by equation, which is a bother.
    Pierre-Normand July 23, 2018 at 07:47 ¶ #199341
    Quoting andrewk
    If you right-click on a TeX formula and select 'Show Math As...' then 'TeX commands', then you can copy and paste the code for that in between ...


    Thanks so much. I'll do this from now on.
    Michael July 23, 2018 at 08:19 ¶ #199347
    Quoting Srap Tasmaner
    [math]\small \begin{align} E(N\mid M=a) &= (2S)P(M=S\mid M=a)+(S)P(M=2S\mid M=a)\end{align}[/math]


    Isn't this the same as:

    [math]\small \begin{align} E(N\mid M=a) &= (2a)P(S=a\mid M=a)+(\frac{a}{2})P(2S=a\mid M=a)\end{align}[/math]

    @andrewk @Pierre-Normand
    Pierre-Normand July 23, 2018 at 08:54 ¶ #199351
    Quoting Michael
    ... Isn't this the same as: ...


    Why are they not the same? In the case where the unseen envelope M is the smaller one, its content is indeed S = a/2.
    Michael July 23, 2018 at 08:57 ¶ #199352
    Reply to Pierre-Normand Sorry, I'm a bit confused by your response. Did you read me as saying "this isn't the same as" rather than "isn't this the same as"?
    Pierre-Normand July 23, 2018 at 09:19 ¶ #199356
    Quoting Michael
    Sorry, I'm a bit confused by your response. Did you read me as saying "this isn't the same as"?


    Indeed! I misread you precisely in this way. We agree then.
    JeffJo July 23, 2018 at 10:36 ¶ #199360
    Quoting Jeremiah
    I will not further debate such specifics.

    Of course you won't. You don't like facts that disagree with your beliefs.

    You have made various claims in this thread, I've told you which you are right, and which you wrong. All you can say is "I believe my solution is correct," without saying which it is that you think is correct. And I'm done trying to educate you.

    Jeremiah July 23, 2018 at 11:23 ¶ #199363
    Quoting JeffJo
    without saying which it is that you think is correct


    I have been very clear on my position, and this is why I stonewalled you. It was clear to me that you were not reading my posts. You kept "disagreeing" with me on points I agreed with you on.
    JeffJo July 23, 2018 at 11:36 ¶ #199365
    Quoting fdrake
    As an aside, I think we're saying the same thing from different angles.


    I agree. I think it is most convincing to present multiple angles. But it isn't (just) the sample space that is the issue. It is the probability space which includes:

    • A sample space S which lists every indivisible outcome.
    • An event space F which lists all of the combinations of outcomes from S that are of interest (with some restrictions we needn't go into).
    • A probability distribution function Pr(*) that associates a probability with every member of F.


    It is Pr(*) and its relationship to F that is the source of confusion.

    +++++

    Quoting Michael
    I see the situation as this:

    Assume there's £10 in my envelope and that one envelope contains twice as much as the other. The other envelope must contain either £5 or £20. Each is equally likely and so the expected value of the other envelope is £12.50. I can then take advantage of this fact by employing this switching strategy to achieve this .25 gain.


    The error is "Each is equally likely," and it is wrong because we need to work with F, not S. My very first post gave an example. Suppose I fill 9 pairs of envelopes with ($5,$10) and one pair with ($10,$20). I choose a pair at random, and present it to you saying "one contains $X and the other $2X, [but you do not know which envelope is which or what the number X is]."

    • Aside: Since I am way too familiar with various formulations of the problem, I haven't been looking at the original here. It does use "X" where I used "V", and almost everybody except Michael has been using X to mean something different. This is likely one cause of confusion. So please note that in the future, I will only use V for the value in your envelope. To avoid confusion, I will not use X at all anymore, but use D for the absolute difference between the two envelopes; it is happy coincidence that this is also the lower value of the pair.


    Do you really believe, if you see $10, that there is a 50% that this is the smaller of the two envelope presented to you?

    No. There is a 10% chance that this is the smaller value, and a 90% chance it is the larger value. Because there was a 90% chance I chose the pair ($5,$10), and a 10% chance I chose the pair ($10,$20). The 50% chances you want to use don't even seem to play a role in this determination.

    The point is that, in the correct version for your calculation E=($V/2)*P1 + ($2V)*P2, the probability P1 is not the probability of picking the larger value. It is the probability of picking the larger value, given that the larger value is $10. In my example, that 90%. In the OP, you do not have information that will allow you to say what it is.

    Note that this doesn't mean that the expectation is that there is no change. In my example, it is ($5)*(90%)+($20)*(10%) = $6.50, and you shouldn't switch. In the OP, you still do not have information that will allow you to say what it is. But averaged over all possible values of V, there will be no expected gain.
    Jeremiah July 23, 2018 at 11:37 ¶ #199366
    The simple truth of this is, if I walked up to you on the street and handed you one envelope and said one of these has twice as much as the other, you'd have no clue as to range, distributions or anything of that sort, even after seeing Y. You could make speculations, but that is all they would be and they would carry a high degree of uncertainty you could never account for in your calculations, as they would just be wild guesses.

    You could spin all types of models, but you're still just shooting in the dark. The truth of it is, in that moment, switching or don't, you stand to gain x and you stand to lose x. That is the one thing we know is constant.
    JeffJo July 23, 2018 at 11:40 ¶ #199367
    Quoting andrewk
    Even in that more general case, the Bayesian approach can give a switching strategy with a positive expected net gain.


    No, it gives you a strategy that works on your assumed prior, not necessarily on reality. The point of a Bayesian analysis is to guess at a prior, and refine it from evidence in the real world.
    Michael July 23, 2018 at 11:51 ¶ #199369
    Quoting JeffJo
    The error is "Each is equally likely," and it is wrong because we need to work with F, not S. My very first post gave an example. Suppose I fill 9 pairs of envelopes with ($5,$10) and one pair with ($10,$20). I choose a pair at random, and present it to you saying "one contains $X and the other $2X, [but you do not know which envelope is which or what the number X is]."


    But suppose you don't do this. Suppose you just select some X at random from {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, put it in one envelope, and then put 2X in the other envelope. I select one at random and open it to see £10. Am I right in saying that {£5, £10} and {£10, £20} are equally likely?

    Quoting JeffJo
    The point is that, in the correct version for your calculation E=($V/2)*P1 + ($2V)*P2, the probability P1 is not the probability of picking the larger value. It is the probability of picking the larger value, given that the larger value is $10. In my example, that 90%. In the OP, you do not have information that will allow you to say what it is.


    If we don't have this information then we should apply the principle of indifference, which will have us say that {£5, £10} and {£10, £20} are equally likely.
    Jeremiah July 23, 2018 at 11:52 ¶ #199370
    Reply to JeffJo

    You don't "guess" a prior. Priors have to be justified. If you don't know you use an uninformative prior.
    JeffJo July 23, 2018 at 12:00 ¶ #199372
    Quoting Jeremiah
    If you use a distribution you are making assumptions not included in the OP. I pointed this out before.

    Jeremiah oversimplifies.

    If you use a specific distribution, then your results apply only to that distribution and not the OP. And AFAIK nobody but Jeremiah has implied otherwise. So my recent example does not say that the expected value of the other envelope in the OP is $6.50 if you see $10 in yours.

    What is true, even in the OP, is that if you see V=v, the expected value of the other envelope is

    • [(v/2)*Pr(v/2,v) + (2V)*Pr(v,2v)] / (v/2)*Pr(v/2,v) + (2V)*Pr(v,2v)]


    But this is a symbolic solution only, not a numeric one. It applies to the OP with an unknown probability space {S, F, Pr(*)}. It implies that you need to know the this space to give an answer for a specific value of V.

    But if you apply the requirements placed on Pr(*) for this to be a valid probability space, this symbolic expression can be shown to evaluate to the expected value of your envelope.
    Jeremiah July 23, 2018 at 12:01 ¶ #199373
    Reply to JeffJo

    Still not interested. I don't even read your post, I just kind of skim over them. You know, like you were doing to me.
    JeffJo July 23, 2018 at 12:09 ¶ #199375
    Quoting Jeremiah
    I agree in the strictness sense of the definition there is an unknown distribution, but as far was we know it was whatever was in his pocket when he filled the envelopes. We can't select a distribution to use, as we have no way to check it.

    And that unknown value in his pocket has a distribution. We don't need to "check it," as long as the symbolic probability space we use satisfies the requirements of being a probability space.

    The OP also doesn't include a provision for repeatability, so devising learning strategies is also outside its scope. The answer is that, if you don;t look, there is no expected gain by switching. If you do, there can be a gain or loss, but you can't calculate it.
    Michael July 23, 2018 at 12:11 ¶ #199376
    Quoting Jeremiah
    The simple truth of this is, if I walked up to you on the street and handed you one envelope and said one of these has twice as much as the other, you'd have no clue as to range, distributions or anything of that sort, even after seeing Y. You could make speculations, but that is all they would be and they would carry a high degree of uncertainty you could never account for in your calculations, as they would just be wild guesses.

    You could spin all types of models, but you're still just shooting in the dark. The truth of it is, in that moment, switching or don't, you stand to gain x and you stand to lose x. That is the one thing we know is constant.


    And if I see £10 then I stand to gain £10 and I stand to lose £5.
    JeffJo July 23, 2018 at 12:12 ¶ #199377
    Quoting Jeremiah
    You don't "guess" a prior. Priors have to be justified. If you don't know you use an uninformative prior.


    So an "uninformative prior" is not a "prior" ? And an informative prior that is based on only partial information is not still a "guess" about the rest?

    My point is that there is no place to claiming a Bayesian solution to the OP.
    JeffJo July 23, 2018 at 12:15 ¶ #199379
    Quoting Michael
    And if I see £10 then I stand to gain £10 and I stand to lose £5.


    But the probabilities are not the same as the probabilities of having picked the larger, or smaller, value. They are the probabilities of picking the smaller value given that that value is $10, and the probability of picking the larger value given that that value is $10, respectively.
    Jeremiah July 23, 2018 at 12:15 ¶ #199380
    Reply to Michael

    I already know where you stand, Michael.
    JeffJo July 23, 2018 at 12:16 ¶ #199382
    Quoting fdrake
    ?Jeremiah


    Why is equiprobability simple but other priors aren't?


    Not only is it not "simple," you can prove that it makes an invalid probability space.
    Jeremiah July 23, 2018 at 12:18 ¶ #199383
    Reply to JeffJo

    You don't "guess" a prior. Even if you use an uninformative prior you have to justify that approach.
    Jeremiah July 23, 2018 at 12:19 ¶ #199384
    Reply to JeffJo

    I already made several comments on the justification behind random samples. Read much?
    Jeremiah July 23, 2018 at 12:25 ¶ #199385
    People who might be reading this thread, who have no exposure to random sampling or Bayesian inference, should not walk away with the idea that using random sampling is a random decision or that Bayesian inference is about guessing.
    JeffJo July 23, 2018 at 14:16 ¶ #199401
    Reply to Jeremiah
    From Wikipedia:
    Bayesian inference is a method of statistical inference in which Bayes' theorem is used to update the probability for a hypothesis as more evidence or information becomes available.
    ...

    H stands for any hypothesis whose probability may be affected by data (called evidence below). Often there are competing hypotheses, and the task is to determine which is the most probable.

    Pr(H), the prior probability, is the estimate of the probability of the hypothesis H.


    Since there is no provision for "data/information/evidence" in the OP, only a one-time thought problem, Bayesian inference does not, and cannot, apply.

    But if you try, you need an hypothesis, and an estimate - which I called a "guess" - of what the probability of that hypothesis is. And an informed prior is just an educated guess.

    Yes, I have read this thread; and no, it contains no hypothesis from the OP that can be tested this way.
    fdrake July 23, 2018 at 14:31 ¶ #199406
    Quoting JeffJo
    I agree. I think it is most convincing to present multiple angles. But it isn't (just) the sample space that is the issue. It is the probability space which includes:


    Yeah. In my analysis this shows up when you ask what the raw probability of receiving X is, not the conditional probability of receiving X given that you just looked in the envelope. Michael correctly intuited that this is unknown. Some unknowns are benign, this one makes the probability space wrong.
    Jeremiah July 23, 2018 at 15:32 ¶ #199420
    Reply to JeffJo You are misinterpreting what I said, what your link says and your source is Wikipedia.
    Srap Tasmaner July 23, 2018 at 16:32 ¶ #199434
    Quoting Pierre-Normand
    If the initial set up calls for randomly assigning values for the two envelopes in the finite range ((1,2),(2,4),(4,8)) for instance, then, in that case, assuming the player knows this to be the initial set up (and hence uses it as his prior) then the posterior probability conditionally on observing any value of M that isn't either 1 or 8 (that is, conditionally on values 2 or 4 being observed) p will indeed be 1/2.


    In one sense, yes, because we can say E(N | M=a) = (3*E(p) +1)/2, where p = P(S=a | M=a).

    But how do we calculate E(p)? I think the player in your example can, but can a player with a lot less information than yours?
    JeffJo July 23, 2018 at 16:47 ¶ #199435
    Quoting Jeremiah
    You are misinterpreting what I said, what your link says and your source is Wikipedia.


    You have not interpreted a single thing I have said correctly; in fact, you've replied to very few of them. Most significantly this time, how Bayesian Inference is inapplicable to the OP. And you can find similar information in any source about Bayesian Inference - it isn't wrong just because it is in Wikipedia.
    Srap Tasmaner July 23, 2018 at 17:17 ¶ #199438
    Quoting JeffJo
    The point is that, in the correct version for your calculation E=($V/2)*P1 + ($2V)*P2, the probability P1 is not the probability of picking the larger value. It is the probability of picking the larger value, given that the larger value is $10. In my example, that 90%. In the OP, you do not have information that will allow you to say what it is.


    This is absolutely right. I think the confusion comes when you switch from

    E(other) = (larger)P(picked smaller) + (smaller)P(picked larger)

    where the probabilities of picking smaller and larger are equal, to

    E(other | picked = a) = (2a)P(picked smaller | picked = a) + (a/2)P(picked larger | picked = a)

    because it's tempting to think these conditional probabilities are equal, just like the unconditional probabilities above, but this we do not know.

    (Philosophical aside: I think this is close to my concern that there is a difference between "There's a 1/2 chance of my picking the smaller envelope" and "There's a 1/2 chance that the value of the envelope I picked is the smaller.")

    What is true is that

    P(picked smaller | smaller = c) = P(picked larger | smaller = c) = 1/2

    but that's completely different.

    Quoting JeffJo
    But averaged over all possible values of V, there will be no expected gain.


    I would still like to know more about how this works, though it may be over my head.
    Srap Tasmaner July 23, 2018 at 18:00 ¶ #199445
    It still feels to me like we're circling around the difference between

    P(picking larger)

    and

    P(I picked larger | I picked)

    All of us agree the first is just 1/2.** But the second is troublesome. Once you've picked, you definitely have the larger or the smaller, but you don't know which. It might be safe to continue to treat this the same as just the chance of picking larger, so long as you don't use the observed value of what you picked. But if you want to use the observed value, you have to be very careful to avoid saying things that amount to there being a 1/2 chance that 10 > 20.


    ** Although maybe it needn't be. Suppose you actually had data on individuals picking, and one individual is consistently "lucky". We don't need to know why or how, but we could still say this individual's chance of picking the larger is better than average.
    Jeremiah July 23, 2018 at 18:19 ¶ #199446
    Reply to JeffJo What you think I have issue with is not what I have issue with. I literally mean you are misinterpreting me. Furthermore what you are harping on is something I already commented on towards the start of the thread.
    JeffJo July 23, 2018 at 19:00 ¶ #199453
    Reply to Jeremiah
    I have agreed that what you said near the beginning of this thread was right. Did you read that?

    You have been very reticent to point out what it is you think I have not read, or have misinterpreted. Or you point one out, then say later that it wasn't important. Yet every time you did (and it was ambiguous), I have pointed out why you are wrong, or it is irrelevant. Did you read that?

    There are really only two conclusions that can be drawn about the the OP:

    • If you don't look in the envelope, it is proven that there is no expected gain by switching.
    • If you do look, THERE IS PROBABLY AN EXPECTED GAIN OR LOSS, but you have no information that would let you calculate it. This is different from knowing it is 0.


    I keep "harping on" this because you keep implying there are other conclusions that may be possible, and there are not. But you refuse to reply to these facts. I have said this many times. Did you read them?
    JeffJo July 23, 2018 at 19:18 ¶ #199459
    Quoting Srap Tasmaner
    I think the confusion comes when you switch from

    E(other) = (larger)P(picked smaller) + (smaller)P(picked larger)

    where the probabilities of picking smaller and larger are equal, to

    E(other | picked = a) = (2a)P(picked smaller | picked = a) + (a/2)P(picked larger | picked = a)

    because it's tempting to think these conditional probabilities are equal, just like the unconditional probabilities above, but this we do not know.


    But we do know that it can't be true. That's the point.

    Either can't be true for all values of this "a", or there are impossible values in the set of possible a's and selection is impossible:
    • If there is a minimum value for a, thenP(picked smaller | picked = amin) = 1 and P(picked larger | picked = amin) = 0
    • If there is not, then a can be arbitrarily small, which is impossible (well, impractical).
    • If there is a maximum value for a, thenP(picked smaller | picked = amax) = 0 and P(picked larger | picked = amax) = 1
    • If there is not, then a can be arbitrarily large. Which is impossible.
    Jeremiah July 23, 2018 at 20:43 ¶ #199467
    Quoting JeffJo
    Did you read that?


    I stopped there.
    Jeremiah July 23, 2018 at 21:56 ¶ #199473
    Quoting JeffJo
    If you do look, THERE IS PROBABLY AN EXPECTED GAIN OR LOSS, but you have no information that would let you calculate it. This is different from knowing it is 0.


    Quoting Jeremiah
    So since you don't know which case you are in after seeing Y and they are not equal you can't really calculate the expected value. Now if you never opened A and never saw Y, that is a different story.


    You did not read the thread.

    Jeremiah July 23, 2018 at 22:01 ¶ #199474
    @JeffJo this is why I am stonewalling you, as you keep trying to argue points with me that I agree with and have already commented on. It is a clear indication to me that either you did not read the thread or you skimmed through it. Whatever the case, you have no clue what my actual position is, even though I have posted extensively on it.
    andrewk July 23, 2018 at 22:06 ¶ #199475
    Quoting JeffJo
    No, it gives you a strategy that works on your assumed prior, not necessarily on reality.

    Where I differ from that perspective is that I reject the notion that there is such a thing as a 'real' probability (aka 'true', 'raw', 'correct', 'absolute' or 'observer independent' probability).
    Jeremiah July 23, 2018 at 22:11 ¶ #199477
    Reply to andrewk

    Some probabilistic models are more reliable and accurate than others.
    Jeremiah July 23, 2018 at 22:20 ¶ #199479
    The more unnecessary assumptions you add to your model the more it will inflate your uncertainty; however, this uncertainty will not show up in your calculations. This is the price you pay for those assumptions.
    andrewk July 23, 2018 at 22:24 ¶ #199480
    [math]\small \begin{align} E(N\mid M=a) &= (2S)P(M=S\mid M=a)+(S)P(M=2S\mid M=a)\end{align}[/math]
    Quoting Michael
    Isn't this the same as:

    [math]\small \begin{align} E(N\mid M=a) &= (2a)P(S=a\mid M=a)+(\frac{a}{2})P(2S=a\mid M=a)\end{align}[/math]

    Provided that all outcomes in the probability space have either M=S or M<=2S*, Yes it is.

    In that case both are applications of the law of total probability, which says that:

    [math]E[N|A] = E[N|A\wedge B]P(B|A) + E[N|A\wedge \sim B]P(\sim B|A) [/math]

    In this instance event A is the set of all outcomes where M=a and, for srap's version, event B is the set of outcomes where M=S. So event ##\sim B## is the set of outcomes where ##. For your version B is the set of outcomes where 2S=a.

    * I haven't been following closely enough to know whether that is the case with this notation. I haven't seen letters N, S or M used before. Last time I was reading closely it was X, Y and U
    JeffJo July 24, 2018 at 14:55 ¶ #199743
    Quoting Jeremiah
    If you do look, THERE IS PROBABLY AN EXPECTED GAIN OR LOSS, but you have no information that would let you calculate it. This is different from knowing it is 0. — JeffJo

    So since you don't know which case you are in after seeing Y and they are not equal you can't really calculate the expected value. Now if you never opened A and never saw Y, that is a different story. — Jeremiah

    You did not read the thread.

    I did read the thread. You did not read my replies. Like this one, where I said "you have no information that would let you calculate [the expected gain or loss]" and you replied with "you can't really calculate the expected value" as if I hadn't just said the same thing.

    In one of those replies you ignored, I explained to you how your own half-normal simulation will show that there is an expected gain if the value you find is less than $13.60, and an expected loss if it is greater. I'm not claiming that you should know such things in general - in fact, I explicitly said you don't - but THERE MUST BE SOME VALUES WHERE THE EXPECTED GAIN IS NOT ZERO.

    Now, you can repeat your unfounded assertions as often as you want. I have proven them to be incorrect.
    JeffJo July 24, 2018 at 15:20 ¶ #199747
    Quoting andrewk
    I differ from that perspective is that I reject the notion that there is such a thing as a 'real' probability (aka 'true', 'raw', 'correct', 'absolute' or 'observer independent' probability).


    Why? I think you confuse the fact that probabilities are intangible with being unreal.

    Probability is, essentially, a measure of our uncertainty about a result. If I know enough about a coin's weight distribution, the forces applied to it, the aerodynamics in the room, and the landing surface, then We can calculate whether it will land on Heads or Tails. As you repeat the flips, some of these details change which will end up in a 50:50 frequency distribution. If we don't know these details, it is a 50:50 probability distribution each time. These are just different, and very real, properties of the same process.

    Similarly, it is because we don't know anything except ($D, $2D) about the circumstances behind the amounts in the envelopes that we must treat it as a probability distribution. Could your envelope contain $10? There is no reason to believe that it can't, and it seems to be a reasonable value. Is it certain that it contains $10? Absolutely not. These two facts make it describable by a probability. Don't confuse not being able to determine the probability, with inapplicability of probability.

    And what you seem to be avoiding with that attitude, is that the expectation formula (v/2)/2 + (2v)/2 is already assuming:

    • That there are at least three values of v that are possible, namely v/2, v, and 2v.
    • That neither of the possible pairs is certain. So there is probability distribution.
    • That distribution says Pr(v/2,v) = Pr(v,2v), and
    • By transitivity, every value of the form v*2^N, where N is any integer in -inf<N<inf, is possible.
    • And all the possible pairs have the same probability. Which must be 0.
    Jeremiah July 24, 2018 at 15:45 ¶ #199751
    Quoting JeffJo
    You did not read my replies. Like this one, where I said "you have no information that would let you calculate [the expected gain or loss]" and you replied with "you can't really calculate the expected value" as if I hadn't just said the same thing.


    That was me quoting myself from earlier in the thread. I posted that before you even joined the conversation.
    Srap Tasmaner July 24, 2018 at 19:09 ¶ #199771
    Quoting Michael
    And if I see £10 then I stand to gain £10 and I stand to lose £5.


    If you see £10 then either you stand to gain £10 or you stand to lose £5, but not both.

    I have two pairs of envelopes A = {5, 10} and B = {10, 20}. I'm going to offer you a choice from one pair or the other. What is your chance of getting 10?

    P(10 | A) = P(10 | B) = 1/2

    if we assume you're an average chooser without "10 seeking" talent. Clear enough.

    But what is P(10)?

    P(10) = P(10 | A)P(A) + P(10 | B)P(B) = P(10 | A)P(A) + P(10 | B)(1 - P(A)) = P(A)/2 + 1/2 - P(A)/2 = 1/2.

    So your chance of picking 10 is 1/2, no matter what P(A) is. P(A) drops out.

    What's your chance of picking 5?

    P(5) = P(5 | A)P(A) = P(A)/2

    What's your chance of picking 20?

    P(20) = P(20 | B)(1 - P(A)) = (1 - P(A))/2

    No idea in either case, because P(A) does not drop out.

    If you got a 10, what's your expected value for the other envelope U? You can go two ways here. You could say

    E(U | 10) = 5 * P(A)/2 + 20 * (1 - P(A))/2

    and that would be true, but it somewhat misses the point. I choose before you choose. "The other envelope" is not well-defined until I have chosen A or B, at which point you can say P(A) = 1 or P(A) = 0. You never get to pick from all four envelopes; you only get to pick from the pair I have chosen. We ignored this when calculating P(10) because my choice didn't matter. Now it does.

    E(U | A, 10) = 5 and E(U | B, 10) = 20.

    You'll still want to do this

    E(U | 10) = E(U | A, 10)P(A) + E(U | B, 10)(1 - P(A))

    and then say that since you know nothing about P(A), you can only apply the principle of indifference and assume P(A) = 1/2. You might be wrong; I may be unaccountably inclined toward A to the tune of 1000:1 but you have no way of knowing that and the rational thing to do is go with indifference.

    But this only makes sense because I've told you that I was choosing from two sets of envelopes in the first place. What if I didn't tell you that? What if there only ever was one pair? What if there were thousands? Maybe some of those have duplicate amounts, maybe not. Maybe there's only a single pair with 10 in it. (This is @JeffJo's thing, and it's worth thinking about. You can't really even count on using 1 - P(A), much less assume P(A) = 1/2.)


    Here's a real life version. Suppose I have some cash and two envelopes, and I'm going to split my cash in such a way that one envelope has twice as much as the other. Suppose I have one $10, one $5 and 6 $1's. What are my options?

    [math]\small \begin{array}{ccc}&Envelope\ 1&Envelope\ 2\\A&1&2\\B&2&4\\C&3&6=5+1\\D&5&10\\E&6=5+1&12=10+2\\F&7=5+2&14=10+4\end{array}[/math]

    There are some combinations I can't make because I don't have enough of the right denominations.

    We could talk about this table as we talked about the collection {{5, 10}, {10,20}}. If you knew how much money I had and in what denominations, there are several cases in which, upon opening an envelope, you'd already know whether you have the larger or the smaller.

    But let's suppose you don't know any of that. You could also figure that if you got an odd number it must be the smaller (because I'm only using bills, no coins) so I'll cleverly not choose one of those; I'll choose only from

    [math]\small \begin{array}{ccc}&Envelope\ 1&Envelope\ 2\\B&2&4\\E&6=5+1&12=10+2\end{array}[/math]

    If I choose B, and you draw the 2, you can reason that I would have excluded {1, 2}, so the other must be 4. Similarly, if I choose E, and you draw the 6, then you can reason that I would have excluded {3, 6} and so the other must be 12. Ah well. I'd have to have more money to make the game perfect.

    But what if I choose B and you draw the 4? 8 is mathematically possible, but there's no {4, 8} here. Similarly, if I choose E and you draw the 12; 24 is mathematically possible, but there's no {12, 24} here.

    So what is your expectation before getting an envelope? Unknown. Something less than half the total cash I have on me, which you don't know, but there are other constraints based on the denominations and some gamesmanship.

    Again, there's no game until I choose. Say I choose B. You don't know it, but the average value of B is 3. If you draw the 2, trading gains you 2; if you choose the 4, trading costs you 2. Say I choose E. You don't know it, but the average value of E is 9. If you choose 6, trading gains you 6; if you choose 12, trading costs you 6.

    Once I have chosen, what you stand to gain or lose by switching is always a fixed amount, without regard to how you choose. Even taking the god's-eye-view of all the possibilities, as we did above with {{5, 10}, {10, 20}}, there is no case in which you stand both to gain and to lose.

    You may still think it's rational to assume there is. That is, on drawing 4, to assume the envelopes might very well be {4, 8} rather than {2, 4}, and even to assume the chances of {2, 4} and {4, 8} are equal.

    That's a lot of assuming. (And it will convince you trade your 4, which is a mistake.) You could instead recognize that all of your choices are conditional on my choice: my choice determines how much is to be gained or lost; your choice determines whether you gain or lose. There are some cases where you can guess whether you have the lower value or the higher, but that's just a guess. (If you draw a 6, do you know for a fact that the envelopes aren't {3, 6}? Of course not. I may have chosen {3, 6} just on the chance that you wouldn't expect me to include any odd numbers.)

    So what is the rational expectation for the other envelope, given that I have chosen and given that you have chosen? There is no chance left once we've both chosen, though there is knowledge on my side and ignorance on yours. Does the other envelope contain either half or twice the amount in yours? Yes, of course. Are there non-zero chances of both? No. Should you assume there are anyway? No. You should recognize that I have fixed the amount you will gain or lose by switching; you cannot know whether you chose the larger or the smaller, so you cannot know whether you will gain or lose that fixed amount by switching, so there is no reason either to switch or to stick.

    (Note also that we get here without assigning P(A) or P(B) or P(any letter) a value. I choose, then you choose. That's it.)

    EDIT: Table typos.
    Michael July 24, 2018 at 19:21 ¶ #199775
    Quoting Srap Tasmaner
    You should recognize that I have fixed the amount you will gain or lose by switching; you cannot know whether you chose the larger or the smaller, so you cannot know whether you will gain or lose that fixed amount by switching, so there is no reason either to switch or to stick.


    Sure there is. If there's £10 in my envelope and I know that the other envelope contains either £5 or £20 because I know that one envelope contains twice as much as the other then I have a reason to switch; I want an extra £10 and am willing to risk losing £5 to get it.
    Srap Tasmaner July 24, 2018 at 19:24 ¶ #199776
    Reply to Michael
    You may entertain yourself by switching and call that a reason, but there is no expected gain from switching.
    Srap Tasmaner July 24, 2018 at 19:49 ¶ #199778
    Quoting Michael
    If there's £10 in my envelope and I know that the other envelope contains either £5 or £20 because I know that one envelope contains twice as much as the other then I have a reason to switch; I want an extra £10 and am willing to risk losing £5 to get it.


    I think you're making two assumptions you shouldn't:

    1. there is non-zero chance C that the other envelope contains twice the value of your envelope;
    2. the odds Not-C:C are no greater than 2:1, so that you can expect at least to break even.


    There is no basis whatsoever for either of these assumptions.

    In my example, if I choose B, you stand to gain 2 or to lose 2, depending on which envelope you chose, and whether you switch. The amount you gain or lose was determined by me in choosing B. If I choose E, you stand to gain 6 or to lose 6, depending on which envelope you chose, and whether you switch. The amount you gain or lose was determined by me in choosing E.
    Michael July 24, 2018 at 19:54 ¶ #199780
    Quoting Srap Tasmaner
    You may entertain yourself by switching and call that a reason, but there is no expected gain from switching.


    We've already established that the expected gain is

    [math]\small \begin{align} E(B\mid A=a) &= P(X=a\mid A=a)2a+P(2X=a\mid A=a)\frac{a}{2} \end{align}[/math]

    The objective probabilities of [math]\small X=a\mid A=a[/math] and [math]\small 2X=a\mid A=a[/math] depend on how the host selects the value of [math]\small X[/math].

    If he selects it at random from a distribution that includes [math]\small \frac{a}{2}[/math] and [math]\small a[/math] then the objective probability of [math]\small X=a\mid A=a[/math] is [math]\small 0.5[/math] and the objective probability of [math]\small 2X=a\mid A=a[/math] is [math]\small 0.5[/math]. So there would be an objective expected gain.

    If he selects it at random from a distribution that includes [math]\small a[/math] but not [math]\small \frac{a}{2}[/math] then the objective probability of [math]\small X=a\mid A=a[/math] is [math]\small 1[/math] and the objective probability of [math]\small 2X=a\mid A=a[/math] is [math]\small 0[/math]. So there would be an objective expected gain.

    If he selects it at random from a distribution that includes [math]\small \frac{a}{2}[/math] but not [math]\small a[/math] then the objective probability of [math]\small X=a\mid A=a[/math] is [math]\small 0[/math] and the objective probability of [math]\small 2X=a\mid A=a[/math] is [math]\small 1[/math]. So there would be an objective expected loss (and it's because of these cases that if we always switch then we earn as much as the never-switcher, and it's these cases that my conditional switching strategy (and those of others) accounts for).

    The epistemic probabilities of [math]\small X=a\mid A=a[/math] and [math]\small 2X=a\mid A=a[/math], however, only depend on our knowledge, and given the principle of indifference, we will calculate the epistemic probability of [math]\small X=a\mid A=a[/math] as being [math]\small 0.5[/math] and the epistemic probability of [math]\small 2X=a\mid A=a[/math] as being [math]\small 0.5[/math], and so an epistemic expected gain. This is my motivation for switching (at least for single-play games, and only if I'm willing to lose).

    Edit: "objective" might not have been the best term to use, as by "epistemic probability" I am referring to objective Bayesian probability.
    Michael July 24, 2018 at 19:57 ¶ #199781
    Quoting Srap Tasmaner
    There is no basis whatsoever for either of these assumptions.


    It's the principle of indifference.
    Srap Tasmaner July 24, 2018 at 22:01 ¶ #199794
    Reply to Michael
    What I don't understand is what your argument is against the alternative analysis. Which of these do you not accept?

    1. The envelopes are valued at X and 2X, for some unknown X.
    2. You have a 1/2 chance of picking the 2X envelope.
    3. If you trade the 2X envelope, you lose X.
    4. You have a 1/2 chance of picking the X envelope.
    5. If you trade the X envelope, you gain X.
    andrewk July 24, 2018 at 22:03 ¶ #199795
    Quoting JeffJo
    Probability is, essentially, a measure of our uncertainty about a result.

    In broad terms I do not disagree with that characterisation. But there is often more than one way to represent uncertainty, and these lead to different probability spaces. I have referred previously to the observation that in finance many different, mutually incompatible probability spaces can be used to assign a value to a portfolio of derivatives. To try to mount an argument that a particular probability space is the sole correct probability space for analysing a problem, one would have to make a bunch of assumptions to start and, as we see from the length of this interesting thread, those assumptions are rarely uncontroversial.
    Quoting JeffJo
    And what you seem to be avoiding with that attitude, is that the expectation formula (v/2)/2 + (2v)/2 is already assuming:

    I am not an advocate for that expectation formula, so I don't see why you'd think I am avoiding those objections to it.
    Michael July 24, 2018 at 22:05 ¶ #199796
    Quoting Srap Tasmaner
    What I don't understand is what your argument is against the alternative analysis. Which of these do you not accept?

    1. The envelopes are valued at X and 2X, for some unknown X.
    2. You have a 1/2 chance of picking the 2X envelope.
    3. If you trade the 2X envelope, you lose X.
    4. You have a 1/2 chance of picking the X envelope.
    5. If you trade the X envelope, you gain X.


    I accept all of them. I reject the implicit conclusion that the gain and loss are symmetric. If my envelope contains £10 then 3. and 5. are:

    3. If I trade the 2X = 10 envelope, I lose X = 5.
    5. If I trade the X = 10 envelope, I gain X = 10.
    Srap Tasmaner July 24, 2018 at 22:08 ¶ #199797
    Quoting Michael
    I accept all of them. I reject the implicit conclusion that the gain and loss are symmetric. If my envelope contains £10 then 3. and 5. are:

    3. If I trade the 2X = 10 envelope, I lose X = 5.
    5. If I trade the X = 10 envelope, I gain X = 10.


    Then you reject 1, because those are two different values of X.
    Jeremiah July 24, 2018 at 22:12 ¶ #199798
    It should be noted the a so called "switching strategy" can only work if it has the time to learn the distribution. It only works because in the long run it can gather enough information to approximate the distribution, but at the start its predictions will be very unreliable.


    Consider @Michael's simulation he posted: Here

    Now he ran it for 10,000 times, that means it was able to gather a lot of information on the distribution but what if we try it with 5 times, what is our expected gain then? I will use his code but change the number of times to run it.

    Let's give go at 5 iterations :

    [1] "Gain: -0.112966601178782"

    At 10 iterations:

    [1] "Gain: 0.190537084398977"

    At 20 iterations:

    [1] "Gain: 0.468846391116595"

    At 30 iterations:

    [1] "Gain: 0.331561140647656"

    At 50 iterations:

    [1] "Gain: 0.146130465279402"

    At 100 iterations:

    [1] "Gain: 0.246130667031913"

    Finally at 100 iterations do we get Micheal's predicted expected returns. A "switching strategy" depends on repeat occurrences to work, as it has to gather that information. So just how many envelopes do you think you'll get to open?
    Jeremiah July 24, 2018 at 22:22 ¶ #199801
    A Bayesian inference is subject to the same fault, it will need several occurrences to correct the errors of baseless assumptions, before becoming accurate.
    Jeremiah July 24, 2018 at 22:28 ¶ #199802
    The truth is, the OP never mentioned you'll get to open 100 envelopes. In fact in the OP there are only two envelopes and you only get to pick one of them. These "switching strategies" are not applicable, as you don't have a chance to learn the distribution though repeatedly opening envelopes.
    Michael July 24, 2018 at 22:30 ¶ #199803
    Quoting Srap Tasmaner
    Then you reject 1, because those are two different values of X.


    I don't reject 1. Either a) the envelopes are valued at £10 and £20 (so X = 10) or, b) the envelopes are valued at £5 and £10 (so X = 5). As it's an unknown value of X, I don't know which it is.

    What you (and others) are saying is that if a) is the case then I gain X and if b) is the case then I lose X, which is true, but not symmetric, because if a) is the case then I gain £10 and if b) is the case then I lose £5.
    Srap Tasmaner July 24, 2018 at 22:49 ¶ #199805
    Reply to Michael
    If X = 10 and your envelope is worth 10, you have the X envelope. By trading, you gain X. This is the X that matters. For any pair of envelopes, there is a single value of X. (If your envelope was worth 20, you would have the 2X envelope and would lose X by trading.)

    If X = 5 and your envelope is worth 10, you have the 2X envelope. By trading, you lose X. (If your envelope was worth 5, you would gain X by trading.)

    Every pair of envelopes has one larger and one smaller. You have an even chance of picking the larger or the smaller. If you picked the larger, you can only lose by trading. If you picked the smaller, you can only gain by trading. There is never any case, no matter what envelope you picked from whatever pair, in which you have a non-zero chance of gaining and a non-zero chance of losing. It's always one or the other and never both.
    Michael July 24, 2018 at 23:01 ¶ #199807
    Quoting Srap Tasmaner
    If X = 10 and your envelope is worth 10, you have the X envelope. By trading, you gain X. This is the X that matters. For any pair of envelopes, there is a single value of X. (If your envelope was worth 20, you would have the 2X envelope and would lose X by trading.)

    If X = 5 and your envelope is worth 10, you have the 2X envelope. By trading, you lose X. (If your envelope was worth 5, you would gain X by trading.)

    Every pair of envelopes has one larger and one smaller. You have an even chance of picking the larger or the smaller. If you picked the larger, you can only lose by trading. If you picked the smaller, you can only gain by trading. There is never any case, no matter what envelope you picked from whatever pair, in which you have a non-zero chance of gaining and a non-zero chance of losing. It's always one or the other and never both.


    I know this. If X = 10 then I gain £10 by switching. If X = 5 then I lose £5 by switching. I'm betting on the value of X being 10. It's a £5 bet with a 2:1 payout. If the value of X was selected at random from a distribution which includes both 5 and 10 then there's a 50% chance of winning. And even if it wasn't, given the principle of indifference I will assign an objective Bayesian probability of 50% to each event, which is all I have to work with. If I don't have any reason to believe that X = 5 is more likely than X = 10 then why wouldn't I switch? Not switching is an implicit bet that X = 5, which doesn't pay out (or cost) anything.
    Srap Tasmaner July 24, 2018 at 23:13 ¶ #199810
    Reply to Michael
    Switching is not objectively worse than sticking. It's also not objectively better. Half the time switching is a mistake. Half the time sticking is a mistake. But that's because of your choice, not because of the values in the envelopes.

    But it is still false that you have an expected gain of 1/4 the value of your envelope. You really don't. All these justifications for assigning 50% to more possibilities than two envelopes can hold are mistaken. You picked from one pair of envelopes. This is the only pair that matters. You either have the bigger or the smaller. Trading the bigger is a loss, trading the smaller is a gain, and it's the same amount each way.

    (Maybe one day I'll figure out how to make this into a proper wager -- something with paying each other the value of the envelopes each ends up with. As it is, you make money either way.)
    Pierre-Normand July 24, 2018 at 23:55 ¶ #199814
    Quoting Srap Tasmaner
    But it is still false that you have an expected gain of 1/4 the value of your envelope. You really don't. All these justifications for assigning 50% to more possibilities than two envelopes can hold are mistaken. You picked from one pair of envelopes. This is the only pair that matters. You either have the bigger or the smaller. Trading the bigger is a loss, trading the smaller is a gain, and it's the same amount each way.


    I agree that in the context of any real world instantiation of this problem, what you say is true (because there is no real world instantiation of this problem, with finite stocks of money, that satisfies the condition of equiprobability tacitly assumed in the original formulation). The challenge that @Michael would have to answer is this: Why is it, on his view, that it isn't rationally mandatory for him to switch his choice even before he has looked into his envelope? And if it is rationally mandatory for him to switch without even looking -- because whatever the content X of his envelope might be, the expected gain from switching is 0.25X -- then why isn't it also rationally mandatory for him to switch yet again, if given the opportunity, without even looking?
    Andrew M July 25, 2018 at 00:14 ¶ #199815
    Quoting Srap Tasmaner
    *** You might have (3) and (4) a little wrong but I can't judge. The McDonnell & Abbott paper makes noises about the player using Cover's strategy having no knowledge of the PDF of X.


    There is an expected gain of X from strategic switching if the algorithm generates a random number between the X and 2X envelope amounts. In this case, the player will switch only when the chosen amount is less than the random number (thus ending up with the other envelope with 2X) and stick otherwise (thus keeping her chosen envelope with 2X).

    However there needs to be a distribution to generate the random number from. If that distribution is too wide or too dissimilar to the envelope distribution, the probability of the above situation occurring could be vanishingly small such that it is never realizable in practice. So for the strategy to be useful, at least a ballpark estimate of the maximum possible amount would be needed.
    Srap Tasmaner July 25, 2018 at 02:42 ¶ #199841
    Quoting Andrew M
    between the X and 2X envelope amounts


    Right. The paper Jeremiah linked talks about this too. I was thinking about this on a 6-hour drive a few days ago, and I agree that in general we're talking vanishing smallness. However -- one neat thing about how the game works is that the numbers, and thus the intervals get bigger and bigger faster and faster. Or, rather: all of these strategies are mainly designed to avoid big losses, so we don't really care if small intervals are hard to hit; we only care about the really big intervals and those are if not easy, at least easier to hit. Any big loss avoided will end up pushing you over breaking even.

    This practical reasoning stuff I find endlessly cool -- but it's only barely related to the "puzzle" aspect here.
    Srap Tasmaner July 25, 2018 at 02:47 ¶ #199846
    Reply to Pierre-Normand
    I agree completely and have so argued. All you really have to do to get the ball rolling is designate the value in the envelope. It's the innocent "Let Y = ..." This is what I love about that paper Jeremiah linked. I have repeatedly voiced my bafflement that just assigning variables a certain way can lead to so much trouble, and the paper addresses that directly.
    andrewk July 25, 2018 at 03:39 ¶ #199882
    Reply to Srap Tasmaner
    Right. The paper Jeremiah linked talks about this too.

    That paper appears to put forward the same position as mine: that always-switching delivers no expected gain, even if the envelope has been opened, but that a strategy based on switching only if the observed amount is less than some pre-selected value delivers a positive expected gain.
    Srap Tasmaner July 25, 2018 at 03:50 ¶ #199883
    Reply to andrewk
    Yes, and the cutoff can be entirely arbitrary, but the effect will often be tiny. (I spent a few minutes trying to get a feel for how this works and was seeing lots of 1.000417.... sorts of numbers. The argument is sound, so I probably won't spend any more time trying to figure out how to simulate knowing nothing about the sample space and its PDF.)
    Andrew M July 25, 2018 at 03:57 ¶ #199884
    Quoting Michael
    But suppose you don't do this. Suppose you just select some X at random from {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, put it in one envelope, and then put 2X in the other envelope. I select one at random and open it to see £10. Am I right in saying that {£5, £10} and {£10, £20} are equally likely?


    Yes. That is because you know what the distribution is.

    Quoting Michael
    If we don't have this information then we should apply the principle of indifference, which will have us say that {£5, £10} and {£10, £20} are equally likely.


    Without knowing the distribution you don't know whether both the envelope pairs were possible and, if they were, whether they were equally weighted.

    Given that knowledge you can apply the principle of indifference (based on the envelope pair weightings being identical). And you can also calculate the expected gain. Otherwise all bets are off, so to speak.
    Pierre-Normand July 25, 2018 at 04:11 ¶ #199886
    Quoting Srap Tasmaner
    The argument is sound, so I probably won't spend any more time trying to figure out how to simulate knowing nothing about the sample space and its PDF.


    One way to represent "knowing nothing" might be to take the limit of an initial distribution that is uniform between 0 and M, where M tends towards infinity. In that case, the cutoff value that you can rely on to maximise your gain also tends towards infinity. In practice, that means always switching; and the expected added value from switching tends towards 0.25X, where X is the value of the envelope that you were initially dealt. This still appears to give rise to the same paradox whereby switching increases your expectation by 1.25 even though switching doesn't change anything to the probabilistic distribution of the value of the envelope that you end up holding. But the paradox only is apparent since your expectation from the non-switching strategy tends towards infinity and 1.25 times infinity (or aleph-zero) still is infinity. It is thus both true that your expectation from switching remains the same and is increased by a 1.25 factor. In this limiting case, though, it is infinitely unlikely that you will be dealt an envelope containing an amount smaller than M, however large M might be. This also explains why, in this limiting case, you should always switch.
    Srap Tasmaner July 25, 2018 at 04:29 ¶ #199889
    Reply to Pierre-Normand
    Thanks. (There is lots I have yet to learn, so some of this is going right by me -- for now.)

    I did wonder -- maybe a week ago? it's somewhere in the thread -- if there isn't an inherent bias in the problem toward switching because of the space being bounded to the left, where the potential losses are also getting smaller and smaller, but unbounded to the right, where the potential gains keep getting bigger and bigger.

    It's just that in the single instance, this is all an illusion. There is this decreasing-left-increasing-right image projected onto the single pair of envelopes in front of you, but you can't trust it. It even occurred to me that since there are not one but two bits of folk wisdom warning of this error -- "the grass is always greener .. " and "a bird in the hand ..." -- that this might be a widely recognized (but of course easily forgotten) cognitive bias.
    Pierre-Normand July 25, 2018 at 04:46 ¶ #199890
    Quoting Srap Tasmaner
    I did wonder -- maybe a week ago? it's somewhere in the thread -- if there isn't an inherent bias in the problem toward switching because of the space being bounded to the left, where the potential losses are also getting smaller and smaller, but unbounded to the right, where the potential gains keep getting bigger and bigger.


    Yes, you can have a uniform discrete distribution that is bounded between 0 and M such that the possible values are M, M/2, M/4, ... In that limit case also, if the player takes M as the cutoff for not-switching (that is, she only switches when she sees a value lower than M) her expectation is 1.25X whenever she switches and her expectation is X=M when she is dealt M (and therefore doesn't switch). Her overall expectation if she were rather to always switch would only be X. The limit case where M tends towards infinity also yields an always switching strategy (with M=infinity being the cutoff) with an expectation that is both X (=infinity) and 1.25X (=infinity).
    Jeremiah July 25, 2018 at 11:30 ¶ #199911
    Reply to andrewk

    You modeled a different scenario than the OP, then argued that it was impossible for you to be wrong, as you claimed there is no such thing as being correct. However, this is not art class, and it is possible to be incorrect.
    JeffJo July 25, 2018 at 12:44 ¶ #199915
    Quoting Michael
    If there's £10 in my envelope and I know that the other envelope contains either £5 or £20 because I know that one envelope contains twice as much as the other then I have a reason to switch; I want an extra £10 and am willing to risk losing £5 to get it.

    So, you are willing to risk losing $5 for the chance to gain $10? Regardless of the odds behind that risk?

    Say I offer you the chance to play a game. It costs you $5 to play, but if you win I will return your $5, and give you $10. The game is to flip a fair coin, and if you get Heads N times in a row, you win.
    1. Say I tell you that N=1. Are you willing to play? I hope so, as the chances of winning are 1 in 2 and your expectation is ($-5)/2+($10)/2=$2.50.
    2. Say I tell you that N=10. Are you willing to play? (The chances of winning are now 1 in 1024.)
    3. Say we determine N by rolling a fair die. Are you willing to play? You could get odds of 1 in 2 again, but you could also get odds of 1 in 64. (The overall chances are just under 1 in 6.)
    4. Say I tell you that there is an integer written on every card in a deck of cards, and you determine N by drawing a card at random. Are you willing to play if I don't tell you what the numbers could be?


    You seem to resist accepting that the OP is most similar to game #4, and not at all similar to game #1. You may be able to calculate the chances of drawing a particular card, but if you don't know what is written on any particular card then this does not translate into a 1/52 chance of drawing a "1".

    In the OP, you have no way of knowing whether your benefactor was willing to part with more than $10. If all he had was a $5 bill and a $10 bill, then he can't. Your chances of picking Low=$5 or High=$10 were indeed 50% each, but your chances of picking Low=$10 were nil.

    But if you don't care about chances, only the possibility of gain? And so answered "yes" to all four game? Then go ahead and switch envelopes in the OP. Just don't expect a gain. That can't be determined from the information.
    JeffJo July 25, 2018 at 12:53 ¶ #199916
    Quoting Michael
    If he selects it at random from a distribution that includes a2 and a then the objective probability of X=a?A=a is 0.5 and the objective probability of 2X=a?A=a is 0.5. So there would be an objective expected gain.

    The highlighted assertion is incorrect. First off, "objective probability" means the "likelihood of a specific occurrence, based on repeated random experiments and measurements (subject to verification by independent experts), instead of on subjective evaluations." Se have no such repeated measurements, so any assessment of Pr(X=a?A=a) is subjective.

    The Principle of Indifference itself is a subjective assessment. But to apply it, you first must determine some kind of an equivalence between the origin of the cases to which you apply it. You can't do that to the values here, only the chance of picking High or Low.
    Michael July 25, 2018 at 13:09 ¶ #199917
    Quoting JeffJo
    The highlighted assertion is incorrect. First off, "objective probability" means the "likelihood of a specific occurrence, based on repeated random experiments and measurements (subject to verification by independent experts), instead of on subjective evaluations." Se have no such repeated measurements, so any assessment of Pr(X=a?A=a) is subjective.


    So if I pick a number at random from {1, 2, 3, 4, 5, 6, 7, 8, 9, 10} you disagree that the objective probability that I will pick 5 is 0.1?

    Quoting JeffJo
    So, you are willing to risk losing $5 for the chance to gain $10? Regardless of the odds behind that risk?


    If I know that the odds are even then I will play. If I know that the odds aren't even then I might be willing to play, depending on the odds. If I don't know the odds then I will play.

    Quoting JeffJo
    In the OP, you have no way of knowing whether your benefactor was willing to part with more than $10. If all he had was a $5 bill and a $10 bill, then he can't. Your chances of picking Low=$5 or High=$10 were indeed 50% each, but your chances of picking Low=$10 were nil.


    And if all he had was a $10 bill and a $20 bill then my chances of picking High = $10 is nil.

    So what am I supposed to do if I don't know how the values are selected? As I said here, if I don't have any reason to believe that X = 5 is more likely than X = 10 then why wouldn't I switch? I think the principle of indifference is entirely appropriate in this circumstance. There's more to gain than there is to lose, and a loss of £5 is an acceptable risk.
    JeffJo July 25, 2018 at 13:47 ¶ #199933
    Quoting andrewk
    In broad terms I do not disagree with that characterisation.

    Well, I can't address your disagreement unless you explain why you feel that way. That characterization is correct. There may be different ways people express their uncertainty, but it still boils down to the same concept.

    But there is often more than one way to represent uncertainty, and these lead to different probability spaces. I have referred previously to the observation that in finance many different, mutually incompatible probability spaces can be used to assign a value to a portfolio of derivatives.

    What kind of differences are you talking about? There is no single way to express a sample space, and in fact what constitutes an "outcome" is undefined. We've experienced that here: some will use a random variable V that means the value in your envelope, while others represent the same property of the process by the difference D (which is the low value as well).

    But the significant difference in those portfolio analyses is the distribution function Pr(). Even though ones subjectivity may be based on past experience, there is no guarantee that the underlying process will be the same in the future, or in the cases being compared. The factors determining the actual values are not as consistent as is required for analysis.

    So any assessment is, by necessity, subjective to some degree. Different sample spaces (or probability spaces) simply allow the analysts to apply their subjectivity in different ways.

    But we really are getting off the point. Which is that they do use a probability space, not whether it is "real," "absolute," or even "correct." That is irrelevant. The point here is that, over the set of all possible probability spaces for the OP, there will either be some values of v where the expected change is non-zero, or the expected value over V is infinite. And in fact, the only way that the expected change is 5v/4, is if the probability distribution says the two possible pairs are equally likely. Which also implies you are assuming a probability space. The only way the expected change is identically zero, is if you don't know v or you know that Pr(v/2,v)=2*Pr(v,2v).

    And what you seem to be avoiding with that attitude, is that the expectation formula (v/2)/2 + (2v)/2 is already assuming: — JeffJo

    I am not an advocate for that expectation formula, so I don't see why you'd think I am avoiding those objections to it.

    Maybe I was mixing Andrews up. I apologize.

    JeffJo July 25, 2018 at 14:18 ¶ #199941
    Quoting Srap Tasmaner
    There is never any case, no matter what envelope you picked from whatever pair, in which you have a non-zero chance of gaining and a non-zero chance of losing


    This emphasizes how a probability space changes based on your knowledge. Or rather, what knowledge is missing.

    I just flipped a coin on my desk. I can see whether it is Heads or Tails. So "there is never a case where there is a non-zero chance of Heads, and a non-zero chance of Tails."

    But If I ask you to assess the two cases, you should say that each has a 50%. The fact that the outcome is determined does not change how probability works for those who do not know the determination.

    Srap Tasmaner is saying that, to someone who knows what is in *both* envelopes, the possibility of gaining or losing is determined. Michael is saying that, to someone who doesn't see both, the two cases should be treated with probabilities that are >=0, and that add up to 1.

    The error is thinking that both must be 50%. Your chance of High or Low is 50% if you don't know the value in the one you chose, but it can't be determined if you do.
    Srap Tasmaner July 25, 2018 at 14:22 ¶ #199943
    Quoting Michael
    If I know that the odds are even then I will play. If I know that the odds aren't even then I might be willing to play, depending on the odds. If I don't know the odds then I will play.


    This particular quandary isn't supposed to arise in real life. A bookmaker first estimates the odds, and then the payouts are simply those odds minus the vigorish (his profit). If you know that a wager is paying off at 2:1, then you know the odds of it paying off are around 2:1 against.

    If this were not true then (a) bookmaking would not be a thing; more to the point (b) you should not be gambling. Placing a wager based only on the payout without considering the odds of winning is crazy. If the principle of indifference tells you to assume there's even odds whenever you don't know the odds, then the principle of indifference shouldn't be gambling either.

    As you've pointed out, in essence what happens here is that on finding $10, you pocket $5, and then place a $5 wager at 2:1 that the other envelope has $20. So the bookmaker in this case is paying you to play, which is no way to run a book. Suppose instead you had to pay that $5 for the opportunity to switch. That is, you give back the $10 plus pay $5 out of pocket. Would you still play? If the other envelope has $5, you've lost nothing, but if it has $20, you've made $15. That seems alright. A free chance to get $15 with no risk. But then you could have walked away with $10 for no risk.

    Still not sure how to make this into a proper wager. We need to zero-in on the expectation of $12.50 somehow.
    JeffJo July 25, 2018 at 14:49 ¶ #199949
    Quoting Michael
    So if I pick a number at random from {1, 2, 3, 4, 5, 6, 7, 8, 9, 10} you disagree that the objective probability that I will pick 5 is 0.1?

    Certainly. It isn't "objective." I thought I made that pretty clear.

    Before I say whether I agree with the value, you should understand that "pick at random" does not mean "pick with uniform randomness." These two are often confused. Had you said "uniform", of course I would agree with that probability. But it would be neither objective nor subjective, it would be explicit.

    The best guess for a subjective probability is that you would pick uniformly. But if you want an objective probability, you need to find a test subject and get them to repeat the experiment many times. That's what objective probability means. And it has been shown over and over that people can't do that with uniformity.

    If I know that the odds are even then I will play.

    And that's the point. You cannot know this in the two envelope problem, when you know what value you are switching from. Unless, of course, you know how the amounts were determined. Do you?

    If I know that the odds aren't even then I might be willing to play, depending on the odds. If I don't know the odds then I will play.

    I'm assuming, based on the first sentence here, that you left a "not" out of the second?

    You can't know the odds when you look in an envelope and see a value. You can choose to play, not knowing the odds, but your calculation of the expectation is wrong.

    And if all he had was a $10 bill and a $20 bill then my chances of picking High = $10 is nil.

    Yep. Now, do you know how the odds of having only a $5 and a $10 compare to only having a $10 and a $20? No? Then you can't say that the chances of gaining are the same as the chances of losing.

    So what am I supposed to do if I don't know how the values are selected?

    Say "I don't know how to compare the chances of gaining to the chance of losing."

    As I said here, if I don't have any reason to believe that X = 5 is more likely than X = 10 then why wouldn't I switch? I think the principle of indifference is entirely appropriate in this circumstance.

    Nope. The PoI applies only if you can establish that there is a causal equivalence between every member of the set to which you apply it. It is specifically inapplicable here, because there cannot be a strategy for filling the envelopes where it is true for an arbitrary value you see.

    There's more to gain than there is to lose, and a loss of £5 is an acceptable risk.

    That is a different question. The point is that the risk is unknowable, and probably not 50%. Whether you think that a $5 loss is acceptable regardless of the risk is a subjective decision only you can make.

    Srap Tasmaner July 25, 2018 at 14:55 ¶ #199951
    Quoting JeffJo
    Srap Tasmaner is saying that, to someone who knows what is in *both* envelopes, the possibility of gaining or losing is determined. Michael is saying that, to someone who doesn't see both, the two cases should be treated with probabilities that are >=0, and that add up to 1.

    The error is thinking that both must be 50%. Your chance of High or Low is 50% if you don't know the value in the one you chose, but it can't be determined if you do.


    I do see that. From the player's point of view her uncertainty might as well be modeled as the outcome not yet having been determined and still subject to chance.

    On the other hand, I think the right way to look at it is what I've been saying lately:

    1. there are two choices;
    2. the host's choice determines how much can be gained or lost by switching;
    3. the player's choices determines whether they gain or lose.


    The player's choice actually happens in two steps, picking and then switching or not, but the effect is the same. You could pick A and switch to B, or you could pick B and stick. The player gets to determine whether they end up with A or B by whatever method they enjoy, but that's all they get to do. More reason to think switching is pointless.

    What's frustrating about the whole expected value calculation is that the point of doing it at all is not to tinker with the chances of getting the bigger of the two envelopes the host has offered -- it has to include tinkering with the amounts in those envelopes. There's nothing to be done with the choice because whether you choose in one step or two, it's just a coin flip. (Thus different from Monty Hall, where the key is understanding how your choice works, and the odds of having chosen correctly.)

    So I've been a bit strident about this because to bother with the expected value calculation here means including in your calculation events known to be counterfactual. Is this actually unusual, or am I being stupid? Events that haven't happened yet may become counterfactual by not happening and of course we set odds for those. But I keep thinking that that the player cannot choose until the host chooses -- that's the nature of the game -- and thus before there is an opportunity for the player to choose, some events have definitely become counterfactual already. I've thought that one way to describe this is to say that "the other envelope" is not well-defined until both choices have been made, and they are always made in order, (1) host, (2) player.

    So I agree with your point about the player modeling their uncertainty, the same point @andrewk and @Michael have made. But there are nuances here that puzzle me. If it turns out my concerns are misplaced, that's cool. The whole point of these sorts of puzzles is to sharpen your understanding of probability, which I am eager to do.

    ** ADDENDUM **

    I think the "counterfactual" stuff is wrong.

    It's perfectly intelligible to talk about the chances of something having happened or not happened in the past, and that's putting odds on a counterfactual. It's intelligible both in cases where you know what happened ("He just made a one in a hundred shot!") and in cases where you don't ("What's more likely? That I forgot my own name or that you typed it wrong?").

    So that's not it.

    That leaves two acceptable options:

    1. Ignore the values and only consider the odds that you picked the larger of the two offered; those odds are even.
    2. Consider the values but recognize that you do not know the probability of any particular value being in the other envelope -- in which case your calculation cannot be completed.
    Srap Tasmaner July 25, 2018 at 15:17 ¶ #199955
    Quoting JeffJo
    You can't know the odds when you look in an envelope and see a value. You can choose to play, not knowing the odds, but your calculation of the expectation is wrong.


    This is the point of the odds calculation I posted before, right? The observed value of the envelope provides no information that could help you decide whether you're in [a/2, a] or [a, 2a], because your choice is always a coin flip:

    [math]\small \begin{align} O(X=a:X=\frac{a}{2}\mid Y=a)&=O(X=a:X=\frac{a}{2})\frac{P(Y=a\mid X=a)}{P(Y=a\mid X=\frac{a}{2})} \\&=O(X=a:X=\frac{a}{2}) \end{align}[/math]

    (Which raises puzzles about how switching strategies work, and I'd have have to study more to be clear on that. If there is an upper bound, then you'd like to be able to look at a and determine that X=a/2 is more likely than X=a -- that is, that you're getting close to the upper bound and ought not switch. But that's all to one side.)
    JeffJo July 25, 2018 at 18:34 ¶ #199982
    Quoting Srap Tasmaner
    On the other hand, I think the right way to look at it is what I've been saying lately:

    there are two choices;
    the host's choice determines how much can be gained or lost by switching;
    the player's choices determines whether they gain or lose.


    This is only true if we do not look in an envelope. That *is* the OP, but the other has also been discussed.

    It is true because we only need to consider one value for the host's choice, and so it divides out. If we look, we need to consider two. And there is no information about the relative probabilities of those two host-choices.

    These are the same two conclusions I have been "harping on" all along, and it is still true that they are the only possible conclusions. If you don't look, the two envelopes have the same expected value. If you do, there is not enough information to say how the probabilities split between having the higher, or lower, value.
    Srap Tasmaner July 25, 2018 at 18:57 ¶ #199984
    Quoting JeffJo
    If you don't look, the two envelopes have the same expected value. If you do, there is not enough information to say how the probabilities split between having the higher, or lower, value.


    Okay -- this is what I keep forgetting.

    Before you look, you could say both envelopes have an expected value of m=3X/2 for some X. Once you've looked in your envelope, its expected value is no longer m and therefore the expected value of the other is no longer m.

    So we are, contrary to my wishes, forced to consider the expected value of the other envelope, and that leads directly to considering more than one possible value for the other envelope, but with no knowledge of the probabilities that attach to those values.

    Thanks for repeating yourself until I get it. I will ask that less of you as time marches on.
    Srap Tasmaner July 25, 2018 at 19:02 ¶ #199985
    Reply to JeffJo
    One more question:

    What if we just say that, having observed the value of our envelope to be a, then the expected value of the other is 3X - a for some unknown X? That formula, unlike the expected value formula, doesn't require any probabilities to be filled in. It's uninformative, but so what?
    JeffJo July 25, 2018 at 20:13 ¶ #199996
    Quoting Srap Tasmaner
    What if we just say that, having observed the value of our envelope to be a, then the expected value of the other is 3X - a for some unknown X? That formula, unlike the expected value formula, doesn't require any probabilities to be filled in. It's uninformative, but so what?


    To what purpose? It doesn't help you to answer any of the questions.

    Besides, the correct expectation formula is [(a/2)*P1 + (2a)*P2]/(P1 + P2), where P1 and P2 are the probabilities that the pair had (a/2,a) or (a,2a), respectively. We can set this equal to yours, and solve for X in terms of a, P1, and P2. So whether or not you "fill in" P1 and P2, your X still depends on them.
    Srap Tasmaner July 25, 2018 at 22:40 ¶ #200021
    Quoting JeffJo
    To what purpose? It doesn't help you to answer any of the questions.


    I thought putting our ignorance front and center could be a feature rather than a bug.

    Also if we do attempt to estimate the shape of the problem as a whole, it will be in terms of X.

    For instance we could ask a simplish question like, what is P(3X - a > a)?

    We'll end up doing exactly things and not doing exactly the same things.
    Andrew M July 26, 2018 at 00:21 ¶ #200041
    Quoting JeffJo
    And what you seem to be avoiding with that attitude, is that the expectation formula (v/2)/2 + (2v)/2 is already assuming: — JeffJo

    I am not an advocate for that expectation formula, so I don't see why you'd think I am avoiding those objections to it. - andrewk
    Maybe I was mixing Andrews up. I apologize.


    I don't advocate it either. I advocate E = ((v/2) * Pr(v/2,v) + (v*2) * Pr(v,2v)) / (Pr(v/2,v) + Pr(v,2v)).
    Andrew M July 26, 2018 at 07:14 ¶ #200157
    Quoting Michael
    So what am I supposed to do if I don't know how the values are selected? As I said here, if I don't have any reason to believe that X = 5 is more likely than X = 10 then why wouldn't I switch? I think the principle of indifference is entirely appropriate in this circumstance. There's more to gain than there is to lose, and a loss of £5 is an acceptable risk.


    You can make a similar argument for keeping. Suppose you choose an envelope but, in this game, instead of opening your envelope the host opens the other envelope and shows you the amount which is £10. Now your choice is to switch to the £10 envelope or keep your chosen envelope. It seems that there is more to gain by keeping, so you keep.

    The arguments are symmetrical. That could be an argument to always select the unknown quantity. Or it could be an argument to be indifferent to keeping or switching. The latter would be an application of the indifference principle based on a symmetry.

    That conclusion is also supported by running the game many times which shows that the actual gain from always switching (or always keeping) is more or less zero.
    Michael July 26, 2018 at 07:26 ¶ #200159
    Reply to Andrew M I agree (that we should stick when shown the other envelope).
    Michael July 26, 2018 at 08:00 ¶ #200168
    Quoting Andrew M
    That conclusion is also supported by running the game many times which shows that the actual gain from always switching (or always keeping) is more or less zero.


    And that's because of what I explained here.
    Srap Tasmaner July 26, 2018 at 08:40 ¶ #200172
    Reply to Michael
    Before looking in your envelope, do you have an expectation of gain from swapping?
    Andrew M July 26, 2018 at 10:32 ¶ #200202
    Quoting Michael
    And that's because of what I explained here.


    Yes your account of objective probabilities explains it. But that is just probability simpliciter where the player's expected gain calculations are based on her knowledge of the distribution.

    The problem is when knowledge of the distribution is absent. There isn't a symmetry between {a/2,a} and {a,2a} (as there is with, say, the two sides of a fair coin) because one of those envelope pairs may not be part of the distribution. And even if they were both present, there might be other relevant differences that make one envelope pair more likely to be selected than the other.

    It's like treating a potentially biased coin as fair. Actual results won't reflect calculated expectations if assumptions about the coin weighting are wrong.
    Jeremiah July 26, 2018 at 12:38 ¶ #200260
    I ran across this line while reading one of my books and thought it pertained well to this thread:

    The final criterion for deciding whether a model is "good" is whether it yields good and useful information. The motivation for using mathematical models lies primarily in their utility.


    Mathematical Statistics with Applications, Wackerly, Mendenhall, Scheaffer.

    I will let people interpret that in the context of the thread how they like.

    Personally, I think in terms of modeling the actual OP the inclusion of distributions or switching strategies is misguided. If our goal is to assess the situation before us then they move outside that scope. However, these models do provide a useful platform to investigate properties that may be applied to other probabilistic aspects. I know undoubtedly some will take that to mean something I don't mean, but there is not much I can do about that.

    JeffJo July 26, 2018 at 13:27 ¶ #200275
    Quoting Michael
    And that's because of what I explained here.

    Quoting Michael
    We've already established that the expected gain is

    E(B?A=a)=P(X=a?A=a)2a+P(2X=a?A=a)a/2


    Close. But we can’t all seem to agree on what that means.

    [i]I’m going to assume that A means your envelope, B means the “other” envelope, and X means the lower value. But A, B, and X mean the abstract concept of the random variable; it is a, b, and x that mean values. So “2X” is meaningless. What I think you mean here is:

    E(B?A=a) = Pr(X=a?A=a)*(2a) + Pr(X=a/2?A=a)*(a/2)[/i]

    The objective probabilities of X=a?A=a and 2X=a?A=a depend on how the host selects the value of X.


    And that definition is worthless to the OP. If we have a “host” and know how he “chooses”, then we have an explicit probability distribution. We wouldn’t need any of the other names (objective, subjective, frequentist, Bayesian, epistemic, etc.) mentioned here, whether singly or in combination.

    The point is, we don’t. We have no distribution, by any name or definition. That doesn’t change the fact that there has to be one for you to calculate an expectation. It just means that any conclusions you draw have to apply regardless of the name or definition.

    If he selects it at random from a distribution that includes a2 and a then the objective probability of X=a?A=a is 0.5 …


    Again, “at random” does not mean “with uniform probability.” You are assuming a uniform probability distribution, and that can’t work. That assumption means that the probability that X is $10 is the same as the probability that X is $20, or $40, or $80, or … to infinity. And it is also the same as the probability that X is $5, or $2.50, or $1.25, or … to 1/infinity. The expectation with this distribution is an infinite amount of money, and each has a probability of 0% (which is not a contradiction, since this is a variation of a continuous distribution).

    Does your host have an infinite amount of money? Does he have a way to pick one integer at random from all integers in -inf<N<inf?

    So there would be an objective expected gain.


    You confuse the fact that there can be an expected gain for specific values in most possible distributions, with the fallacy that it there is a gain any value in any distribution. Again, use my example where there is a 50:50 chance that the envelopes are ($5,$10) or ($10,$20).

    • If a=$5, a 25% chance, there is a certain gain of $5.
    • If a=$20, a 25% chance, there is a certain loss of $10.
    • If a=$10, a 50% chance, there is an expected gain of $10/2-$5/2 = $2.50
    • But what this means when you don’t know what a is, is that the expectation is:($5)*(25%) – ($10)*(25%) + ($2.50)*(50%) = $1.25 - $2.50 + $1.25 = $0.


    For any valid, finite probability distribution, there will be some values of that produce a gain. But there will also be others that produce a loss. And the expectation over all of them will be $0.
    JeffJo July 26, 2018 at 13:52 ¶ #200279
    Quoting Jeremiah
    I think in terms of modeling the actual OP the inclusion of distributions or switching strategies is misguided.

    Choosing any explicit distribution for the OP is indeed misguided, which is why your simulations were misguided. That, and the fact that your conclusions could be proven without such modeling.

    But that doesn't mean we can ignore the fact that we need a distribution, if we want to calculate an expectation when three possible values are considered. As in the (v/2)/2+(2v)/2 = 5v/4 expectation formula. We may not know what it is, but there is one. Ignoring the fact that there must be a distribution is a mathematical error, and is why that formula is mathematically incorrect.

    And there are properties of all valid probability distributions that we can make use of. That expectation considers three values, v/2, v, and 2v and thus requires probabilities for two sets of envelopes. But we can see that if Pr(v/2,v)=Pr(v,2v), then the formula is correct. And for other possible relationships, there can (and will) be both gains and losses.

    If you consider only two values, there is a mathematically correct formula: if D is the difference, the expected gain is (+d)/2 + (-d)/2 = 0. We don't need to to know the distribution to D to see that this is correct.

    However, these models do provide a useful platform to investigate properties that may be applied to other probabilistic aspects.


    Indeed. Your half-normal distribution shows that there is an expected gain if your envelope contains less than $13.60, and an expected loss if it contains more. The others will show similar properties. But again, you don't really need to simulate them to show this. The only utility would be to convince those who don't want to accept that math works. You will undoubtedly ignore this, but there is not much I can do about that.
    Jeremiah July 26, 2018 at 15:40 ¶ #200324
    My simulations were there to display the inherit ambiguity in defining a prior distribution. X is an unknown, treat it like an unknown. I have never once in the entire thread expressed that there is no limit or distribution, in fact I expressed the opposite. That doesn't change the fact that X is an unknown.

    Jeremiah July 26, 2018 at 15:50 ¶ #200330
    I have also already shown that trying to calculate expected returns is a misguided effort.
    JeffJo July 26, 2018 at 19:29 ¶ #200392
    Quoting Jeremiah
    My simulations were there to display the inherit ambiguity in defining a prior distribution. X is an unknown, treat it like an unknown.

    Quoting Jeremiah
    I have also already shown that trying to calculate expected returns is a misguided effort.

    And my response to these sentiments has always been that you can't define/calculate the prior distribution, and that it was a misguided effort to even try (as you did).

    That doesn't mean there isn't a prior distribution, that you can ignore the fact that there a prior distribution, that it is proper to treat a random variable with a prior distribution as an unknown, or that there isn't useful information that can be obtained from the properties that a prior distribution must have.

    Some of that information is that you can prove for a reasonable (i.e., non-infinite) prior distribution, that there must be some values of the amount in your envelope where there is an expected gain given that v, others where there is an expected loss, but that the expectation over V must be zero. This is provable without defining what the prior distribution is, without any of the ambiguity you claim exists.
    Srap Tasmaner July 26, 2018 at 19:50 ¶ #200396
    Nothing new here, just checking my understanding. (Or, rather, whether I have shed all my misunderstandings, even recent ones.) Check my math.

    If I understand it correctly, our situation is something like this:
    User image

    The host will choose a value for X before the player chooses an envelope. For any value [math] x_i[/math] the host chooses, the player's chance of choosing the smaller envelope is

    [math]\small P(Y=X\mid X=x_i)=\cfrac12[/math]

    and you can also sum across all those to get the unconditional probability

    [math]\small P(Y = X) = \sum_{x_i}P(Y=X\mid X=x_i)P(X=x_i)=\cfrac12[/math]

    And similarly the chance of picking the 2X envelope is 1/2 for any value of X or for all of them together.

    Also, for any given value a we can say that the probability of picking a is

    [math]\small\begin{align} P(Y=a)&=P(Y=X\mid X=a)P(X=a)+P(Y=2X\mid X=\cfrac{a}{2})P(X=\cfrac{a}{2})\\&=\cfrac{P(X=a)+P(X=\cfrac{a}{2})}{2}\end{align}[/math]

    And naturally P(X = a | Y = a) is just

    [math]\small \begin{align} P(X=a\mid Y=a)&=P(Y=a\mid X=a)\cfrac{P(X=a)}{P(Y=a)}\\&=\cfrac{\cfrac12 P(X=a)}{\cfrac12\left( P(X=a)+P(X=\cfrac{a}{2})\right)}\\&=\cfrac{P(X=a)}{P(X=a)+P(X=\cfrac{a}{2})} \end{align}[/math]

    In considering the chance of choosing the smaller envelope, the choice of X drops out, but here we have the opposite: the equiprobability of choices made the the chance of picking some value a a simple mean of the probabilities of X being a and X being a/2; now those chances of choosing cancel out, and we're only comparing probabilities of X values.

    Our expectation for the unpicked envelope:

    [math]\small \begin{align} E(U\mid Y=a)&=\cfrac{a}{2}\cdot P(Y=2X\mid X=\cfrac{a}{2}, Y=a)+2a\cdot P(Y=X\mid X=a, Y=a)\\&=\cfrac{\cfrac{a}{2}\cdot P(X=\cfrac{a}{2})+2a\cdot P(X=a)}{P(X=\cfrac{a}{2})+P(X=a)} \end{align}[/math]

    And again, choice has dropped out completely.

    What do we know about P(X = a) and P(X = a/2)? We know that

    [math]\small P(X=a\mid Y=a)+P(X=\cfrac{a}{2}\mid Y=a) = 1[/math]

    nearly by definition, although really there are choices canceling out here.

    Do we know that both P(X = a) and P(X = a/2) are non-zero? We know that at least one of P(X = a | Y = a) and P(X = a/2 | Y = a) is non-zero, but we do not know that both are. Without Y = a, we wouldn't even know that at least one of P(X = a) and P(X = a/2) are non-zero. Without knowing that both are non-zero, we can't even safely talk about the odds P(X = a):P(X = a/2).
    Jeremiah July 26, 2018 at 19:51 ¶ #200397
    Reply to JeffJo
    I was never the one advocating for the use of a prior. I am not sure where you got that notion.
    Srap Tasmaner July 26, 2018 at 19:56 ¶ #200398
    Quoting JeffJo
    you can't define/calculate the prior distribution, and that it was a misguided effort to even try (as you did)


    FWIW, my memory is that @Jeremiah only got into the sims & distributions business because everyone was talking about these things and it was his intention to put an end to all the speculation and get the discussion back on track. It seemed to me he did this reluctantly with the intention of showing that even if you made some assumptions you shouldn't -- this has always been his view -- it might not help in the way you think it does.

    Your post suggests you read those old posts as showing Jeremiah is invested in some of these statistical models of the problem and he never has been.
    Andrew M July 27, 2018 at 00:26 ¶ #200452
    Quoting Jeremiah
    Personally, I think in terms of modeling the actual OP the inclusion of distributions or switching strategies is misguided. If our goal is to assess the situation before us then they move outside that scope. However, these models do provide a useful platform to investigate properties that may be applied to other probabilistic aspects.


    I agree. Regarding the OP, the math provides no reason to be anything other than indifferent to sticking or switching.

    (Of course, people may wish to stick or switch for individual reasons related to the specific context, such as utility, but that is a separate issue.)
    Andrew M July 27, 2018 at 00:37 ¶ #200454
    Quoting JeffJo
    I’m going to assume that A means your envelope, B means the “other” envelope, and X means the lower value. But A, B, and X mean the abstract concept of the random variable; it is a, b, and x that mean values. So “2X” is meaningless. What I think you mean here is:

    E(B?A=a) = Pr(X=a?A=a)*(2a) + Pr(X=a/2?A=a)*(a/2)


    Isn't 2X just a transformation of X that doubles the possible values in X? So Pr(2X=a) would be equivalent to Pr(X=a/2). Here's an academic example using P(X^2 <= y).
    Andrew M July 27, 2018 at 01:35 ¶ #200461
    Quoting Srap Tasmaner
    Do we know that both P(X = a) and P(X = a/2) are non-zero? We know that at least one of P(X = a | Y = a) and P(X = a/2 | Y = a) is non-zero, but we do not know that both are. Without Y = a, we wouldn't even know that at least one of P(X = a) and P(X = a/2) are non-zero. Without knowing that both are non-zero, we can't even safely talk about the odds P(X = a):P(X = a/2).


    Yes. You learn something about the distribution when you open an envelope (namely, that it had an envelope with that seen amount). But not enough to calculate anything useful. It's like getting a bicycle with one wheel. You might wonder whether you could get somewhere with it, but you probably can't.
    Srap Tasmaner July 27, 2018 at 01:56 ¶ #200467
    Reply to Andrew M
    I'm still working on it.

    We can also say that

    P(X = a) + P(X = a/2) <= 1

    but other than that, their values can range freely.*** (It is in some sense a coincidence that their sum can also be described as the event Y = a.)

    Do we need to assume that X is not continuous? If it is, all these probabilities are just 0, aren't they?

    *** Urk. Forgetting that at least one of them has to be non-zero.
    Pierre-Normand July 27, 2018 at 02:26 ¶ #200474
    Quoting Andrew M
    Yes. You learn something about the distribution when you open an envelope (namely, that it had an envelope with that seen amount). But not enough to calculate anything useful. It's like getting a bicycle with one wheel. You might wonder whether you could get somewhere with it, but you probably can't.


    I disagree. Suppose you were to engage in one million iterations of that game and find that the seen envelope contents converge on a specific and roughly uniform distribution of amounts all belonging in the discrete range ($1,$2,$4,$8,$16), with deviations from 1/5 frequencies that aren't very statistically significant. (I am assuming that the game only allows for amounts in whole dollars, for simplicity). Wouldn't that information be useful? I would argue that the useful knowledge that you thus gain is being accrued progressively, one little bit at a time, and could be represented by the successive updating from an allegedly very tentative long tailed initial prior distribution that represents your initial expectation that the dealer likely doesn't have access to an amount of money in excess of one million dollars, say, with the peak of the distribution somewhere around $50, say. This initial prior could be very wrong, but through (Bayesian) updating it after each iteration of the game, will lead to a prior that converges towards the 'real' distribution. Hence, each envelope that you look at provides some useful information since it is more likely than not to lead you, at each step, to updating your initial prior in the direction of a more reliable one.
    andrewk July 27, 2018 at 02:49 ¶ #200477
    Quoting Pierre-Normand
    (I am assuming that the game only allows for amounts in whole dollars, for simplicity

    Interestingly, if the game only allows whole dollars - or even whole cents, and the player knows that, they can use it as the basis for another strategy: if the number is odd, switch, otherwise don't. That's because if the number is odd it cannot be the doubled value, so the other one must be.

    To remove that option, I recast the problem with the envelopes containing IOUs rather than cash, for an amount that is a real number of cents, with an arbitrary but large number of decimal places shown. The amount is only rounded to the nearest cent (or dollar) when the IOU is cashed in.
    Pierre-Normand July 27, 2018 at 02:52 ¶ #200479
    Quoting andrewk
    (...) To remove that option, I recast the problem with the envelopes containing IOUs rather than cash, for an amount that is a real number of cents, with an arbitrary but large number of decimal places shown. The amount is only rounded to the nearest cent (or dollar) when the IOU is cashed in.


    That's clever.
    Andrew M July 27, 2018 at 03:47 ¶ #200508
    Quoting Srap Tasmaner
    Do we need to assume that X is not continuous? If it is, all these probabilities are just 0, aren't they?

    *** Urk. Forgetting that at least one of them has to be non-zero.


    Yes, I think it's reasonable to assume discreteness (with a finite but unspecified precision and range).

    Quoting Pierre-Normand
    Wouldn't that information be useful?


    Yes. But I think the OP is asking for a general solution for one run with no special assumptions about the context (such as whole dollar amounts or million dollar limits).

    Considering multiple runs as blind runs with no knowledge acquired from previous runs should be OK. Perhaps using amnesia per the Sleeping Beauty problem...

    Quoting andrewk
    To remove that option, I recast the problem with the envelopes containing IOUs rather than cash, for an amount that is a real number of cents, with an arbitrary but large number of decimal places shown. The amount is only rounded to the nearest cent (or dollar) when the IOU is cashed in.


    :up:
    Pierre-Normand July 27, 2018 at 04:13 ¶ #200518
    Quoting Andrew M
    Yes. But I think the OP is asking for a general solution for one run with no special assumptions about the context (such as whole dollar amounts or million dollar limits).


    For sure, I agree, since any non-uniform prior would violate the equiprobability condition that alone grounds the derivation of the unconditional 1.25X expectation from switching.
    Srap Tasmaner July 27, 2018 at 05:05 ¶ #200537
    Quoting Pierre-Normand
    the equiprobability condition that alone grounds the derivation of the unconditional 1.25X expectation from switching.


    I'm still confused. This makes it sound like the switching argument isn't fallacious -- it just makes an unwarranted assumption. So if every value of X were equally probable, then it would be true that you can expect a .25 gain from switching? I see how the math works, but if that's true, isn't it true whether you know the value of your envelope or not? And if that's true, isn't it also true for the other envelope as well?

    If that's how the calculation goes, then something's wrong because in any pair of envelopes, trading is a gain for one side and a loss for the other.
    Pierre-Normand July 27, 2018 at 05:18 ¶ #200544
    Quoting Srap Tasmaner
    I'm still confused. This makes it sound like the switching argument isn't fallacious -- it just makes an unwarranted assumption. So if every value of X were equally probable, then it would be true that you can expect a .25 gain from switching? I see how the math works, but if that's true, isn't it true whether you know the value of your envelope or not? And if that's true, isn't it also true for the other envelope as well?


    Yes, yes and yes, but the assumption isn't merely unwarranted, it is impossible that it be true in any real world instantiation of the problem where the available amounts that can figure in the distribution all are smaller than some finite upper bound. It follows from the equiprobability assumption not only that every possible amount in the distribution are equiprobable but also that the distribution is unbounded(*). In that case, your prior expectation, before you open the envelope, is infinite. The probability that you would be dealt an amount X that is lower than some finite upper bound M is vanishingly small however big M might be. But if you do wind up with some finite amount X in your envelope, then your conditional expectation upon switching is 1.25X. That doesn't make the unconditional expectation from the always-switching strategy any larger than the unconditional expectation of the 'always-sticking' strategy since 1.25 times aleph-zero is aleph-zero. The situation is rather akin to Cantor's Hotel where all the (countably infinitely many) rooms are filled up and there nevertheless still is 'room' for accommodating twice as many guests.

    (*) Some distributions, such as the Gauss or Poisson distributions, are unbounded and well behaved (i.e. yielding finite expectations) but they are not uniform and so don't satisfy the equiprobability assumption.
    Srap Tasmaner July 27, 2018 at 05:39 ¶ #200552
    Reply to Pierre-Normand
    Thanks. You've told me this before -- and I appreciate your patience. I'll mull it over some more.

    I think I'm just reluctant to see the simple situation of choosing between two envelopes of different values in terms of the strange behavior of infinity.

    I keep thinking of switching as just being a positive or negative change, but the switching argument accepts that!

    Every time I think I've got a handle on this, it slips away.
    Pierre-Normand July 27, 2018 at 06:10 ¶ #200558
    Quoting Srap Tasmaner
    I think I'm just reluctant to see the simple situation of choosing between two envelopes of different values in terms of the strange behavior of infinity.


    Yes, it is indeed the strange behavior of infinity that generates the paradox.

    (Edit: Opps, there are some mistakes below that I'll correct later today)
    ((Edit again: I'll correct them in a separate reply to this post))

    Maybe I can get some more mileage from my analogy with Cantor's Hotel(*). Suppose you are hosted in this Hotel in some random even numbered room X. (The rooms are labeled 1,2,3,...). You are then offered to toss a coin and move to room X/2 if you flip tails, and move to room 2X if you flip heads. You can also choose not to toss the coin and stay in your room. Whatever you do, when you leave the hotel you are being awarded your room's number worth of dollars. Suppose everyone who occupies an even numbered room gets offered the same deal and everyone chooses to flip the coin. After the move, some rooms will be empty and some rooms will have one or (at most) two occupants. But that's immaterial. The point is that guests can expect to increase their rewards by 1.25 on average. It is also true that if they had chosen to flip the coin without looking at their room number, and only know the number Y of the room where they relocated as dictated by the result of the coin toss, they would still expect to increase their reward expectation to 1.25Y if offered to move back to whatever initial room they came from (assuming they had forgotten what it is that they flipped and hence couldn't deduce where it is that they came from before choosing whether to move back).

    In this case, it's the fact that the Hotel has countably infinitely many rooms that enables the assumption of equiprobability to hold. Before the coin flip, each occupant is equally likely to double her reward than she is to halve it and hence is warranted to flip. But conversely, after she moved, she is equally likely to have moved there from a rooms that was twice as valuable than from a room that was half as valuable and hence is warranted to move back if given the opportunity, assuming only that she has forgotten where she came from!

    (*) On edit: What I referred to as Cantor's Hotel is better known as Hilbert's Grand Hotel, or Hilbert's Infinite Hotel.
    Srap Tasmaner July 27, 2018 at 06:47 ¶ #200567
    Quoting andrewk
    To remove that option, I recast the problem with the envelopes containing IOUs rather than cash


    I don't think we really need to agonize over the amounts supposedly being money. We could use real numbers and play competitively. The winner is just whoever ends up with the highest number.
    JeffJo July 27, 2018 at 14:17 ¶ #200659
    Quoting Andrew M
    Isn't 2X just a transformation of X that doubles the possible values in X?

    I was being terse. A longer version of what I said is "So '2X' is meaningless if you try to use it as a value." This thread has gone on too long, and I didn't want to have to explain the mathematics of probability theory any more than I already have.

    The following comments may seem incredibly pedantic, but understanding them is necessary to avoid the confusions found throughout this thread. The convention I use is that an upper-case letter is a random variable, and the corresponding lower case letter is an unknown value in that range of that random variable. So...

    • X is a random variable. It does not, and can not, mean a single value.
    • You'd do that with an expression like X=$10 or X=x, which define events not values. What these expressions literally mean is "The event where the instantiated value of the random variable is $10" or "... is the unknown x taken from the range of X."
    • A more proper version is "X?{$10}", which makes it clearer that we are talking about an event.
    • Or even "X?{$5,$10}", but that is not useful in a problem where you only consider one value at a time.
    • You can consider a new random variable Y=2X. You find its distribution, not a value, by the transformation methods in your link.
    • So "2X" can't be used as a value in an expectation calculation.
    • But you could use y, as an instantiated value of the Y I just defined. And x as an instantiated value for X, in which case y=2x.
    • That expectation calculate will still have to use either Pr(X?{x}) or Pr(Y?{y}). Which we've been simplifying to Pr(x) or Pr(y).


    It is very important to understand that you only use the random variable itself to define an event. That is, as the argument of a probability function. And any value, known or unknown, has to be carefully associated with its probability.

    In fact, this explains Michael's error from the start:
    Quoting Michael
    The amount you have is $x. The other envelope contains either $2x or $x/2. If it's $2x then you gain $x by switching. If it's $x/2 then you lose $x/2 by switching.


    In this expression, Michael is using two new random variables, but doesn't recognize them as such. R represents the palyer's choice, and can be {2,1/2} with probability 50% each. Y is the other envelope, defined by Y=R*X (remember, these are random variables). His error is only recognizing one and not treating it as carefully as he should. So he missed that the distribution for Y is found by the transformation methods in your link, and that he needs to know the probabilities of the pair being ($x/2,$x) and ($x,$2x) to do this.

    It also explains what Jeremiah doesn't want to accept as his error. You can't simply treat a random variable as an unknown. You can consider a set of unknown values from its range, but only if you couple that with their probabilities.

    JeffJo July 27, 2018 at 14:29 ¶ #200660
    Quoting Srap Tasmaner
    Jeremiah only got into the sims & distributions business because everyone was talking about these things and it was his intention to put an end to all the speculation and get the discussion back on track. It seemed to me he did this reluctantly with the intention of showing that even if you made some assumptions you shouldn't -- this has always been his view -- it might not help in the way you think it does.


    My points have been that the results of these simulations can be proven by considering the properties of probability distributions in general, and that the same approach can explain everything that needs to be said about the OP. Including some things that he said which are wrong.

    I replied about specifics in the simulations because he asked me to do so. I assumed there was data he considered to be significant in them because he said I didn't see that it was in them.
    Srap Tasmaner July 27, 2018 at 14:33 ¶ #200661
    Reply to JeffJo
    Fair enough.
    JeffJo July 27, 2018 at 14:45 ¶ #200663
    Quoting Srap Tasmaner
    Do we need to assume that X is not continuous? If it is, all these probabilities are just 0, aren't they?


    When you deal with continuous random variables, you use the probability density function F(x). You then use events that describe ranges of values, like $5<=X<$10, and integrate F(x) over that range to get a probability. The result that Pr(X=$10) must be zero is not an issue then, because F(X=$10) might not be.

    But if you try to use a continuous random variable to make the expectation formula always mean a 25% gain, then you will find that Pr(2^n<=X<2^(n+1)) must be the same for all integers n. That's why that expectation formula implies an infinite supply of money.
    JeffJo July 27, 2018 at 15:08 ¶ #200665
    Quoting Srap Tasmaner
    I'm still confused. This makes it sound like the switching argument isn't fallacious -- it just makes an unwarranted assumption.


    Described this way, the "1.25 expectation" is not fallacious, it just makes an unwarranted assumption. It is the consequences of that assumption that are fallacious.

    Again: for any finite distribution - that is, one with a maximum possible value (and a minimum is helpful to assume) - there will be some values where there is an expected gain, and some where there is an expected loss. Jeremiah's simulations can demonstrate this, and that is the only useful purpose they have. It is the expectation over all such values that must be zero for finite distributions.

    The reason this is important to note, is that the expectation formula (v/2)*Q(v) + (2v)*(1-Q(v)) = 2v-3Q(v)/2, where Q(v) is a probability function, is correct. Assuming Q(v) is identically 1/2 is not.

    That doesn't mean you can't construct a probability space where it is identically 1/2, or others where the expectation is always a gain. You can. They require infinite money to be available, and that is the fallacious part.
    Srap Tasmaner July 27, 2018 at 15:11 ¶ #200666
    Quoting JeffJo
    The result that Pr(X=$10) must be zero is not an issue then, because F(X=$10) might not be.


    Right, right. (I am actually studying in my spare time, I swear.)

    Quoting JeffJo
    You can't simply treat a random variable as an unknown. You can consider a set of unknown values from its range, but only if you couple that with their probabilities.


    If I may take advantage of your patience a bit more ...

    Suppose I naively approach the problem this way: I think I'm solving for an unknown; I observe the value of y, and I write down my equations:

    (1) y + u = 3x
    (2) y = 10

    I can then get as far as

    u = 3x - 10

    but lacking, say,

    *(3) 3x = 30

    I'm stuck with with an equation that still has two unknowns, so I am forced to treat u and x as variables rather than simply unknown values. As you note, instead of using x I could also write

    (4) y = ru

    where r ? {½, 2} but that leaves me with two sets of equations:

    {y = 10, u = 2y}, {y = 10, u = y/2}

    Either of those can be solved, but not knowing the value of r, it still amounts to an equation

    u = 10r

    with two unknowns. Since I can't solve that, I'm back to variables instead of unknowns.
    Michael July 27, 2018 at 15:32 ¶ #200667
    Quoting JeffJo
    In this expression, Michael is using two new random variables, but doesn't recognize them as such. R represents the palyer's choice, and can be {2,1/2} with probability 50% each. Y is the other envelope, defined by Y=R*X (remember, these are random variables). His error is only recognizing one and not treating it as carefully as he should. So he missed that the distribution for Y is found by the transformation methods in your link, and that he needs to know the probabilities of the pair being ($x/2,$x) and ($x,$2x) to do this.


    If I'm told that one envelope contains twice as much as the other, and if I pick one at random, am I right in saying before I open it that there's a 50% chance that my envelope contains the smaller amount?[sup]1[/sup] If so, I must also be right in saying after I open it and see the amount that there's a 50% chance that my envelope contains the smaller amount (assuming I don't know how the values are selected).

    If I'm right in saying that there's a 50% chance that my envelope contains the smaller amount then I am right in saying that there's a 50% chance that the other envelope contains twice as much as my envelope (and a 50% chance that the other envelope contains half as much as my envelope).

    [sup]1[/sup] Consider what you said here:

    I just flipped a coin on my desk. I can see whether it is Heads or Tails. So "there is never a case where there is a non-zero chance of Heads, and a non-zero chance of Tails."

    But If I ask you to assess the two cases, you should say that each has a 50%. The fact that the outcome is determined does not change how probability works for those who do not know the determination.
    Jeremiah July 27, 2018 at 15:38 ¶ #200669
    Reply to JeffJo ... [Y]ou have been misinterpreting me since you joined the conversation. ...
    Srap Tasmaner July 27, 2018 at 16:14 ¶ #200677
    Quoting Michael
    If I'm told that one envelope contains twice as much as the other, and if I pick one at random, am I right in saying before I open it that there's a 50% chance that my envelope contains the smaller amount? If so, I must also be right in saying after I open it and see the amount that there's a 50% chance that my envelope contains the smaller amount.


    I share your frustration, Michael.

    If I offer you a choice between envelopes containing $5 and $10, you have a 50% chance of picking the envelope that has $5 in it. Having chosen an envelope, you no longer have a chance of picking the $5 envelope -- you either did or didn't.

    You still have to express your uncertainty about whether the envelope you did pick was the smaller or the larger, since you don't know the contents of both envelopes, and seeing $10 doesn't tell you whether you got the smaller or the larger. But you cannot say that the amount you observe has a 50% chance of being the smaller. Given more complete knowledge, you would find you had been saying that $10 has a 50% chance of being smaller than $5, which is absurd.

    The only safe way to express your uncertainty -- that is, the only way to formulate it so that increasing your knowledge wouldn't render your beliefs absurd -- is conditionally. And this makes sense. If the larger amount is $10, then picking $10 is necessarily picking the larger amount; if the larger amount is $20, then picking $10 is necessarily picking the smaller amount.

    When you work through expressing the probabilities conditionally, you find that the 50% associated with your choosing an envelope cancels out. And in a sense, it should -- we're now working out the consequences of your choice. The uncertainty that remains does not derive from your choosing at all -- we're past that. The uncertainty that remains is all down to the host's choice of envelope values.

    After that, I'm still a bit murky, I'm sorry to say. Part of it I can see as the sometimes counter-intuitive nature of conditional probabilities, but part of it still eludes me.
    Michael July 27, 2018 at 16:22 ¶ #200678
    Reply to Srap Tasmaner This is why I think the issue is related to the debate between frequentists and Bayesians. For objective Bayesians, "probability quantifies the reasonable expectation everyone (even a "robot") sharing the same knowledge should share in accordance with the rules of Bayesian statistics, which can be justified by Cox's theorem"[sup]1[/sup]. The objective Bayesian will say that an already-flipped coin has a 50% probability of being heads, even if it's actually tails, and that my £10 envelope has a 50% probability of being the smaller amount, even if it's actually the larger amount, whereas the frequentist would deny both of these (as far as I'm aware).
    Srap Tasmaner July 27, 2018 at 16:59 ¶ #200680
    Reply to Michael
    It's only the difference between describing your expectation conditionally and unconditionally. By describing your expectation conditionally, you leave room for the future evidence you would rely on to update.
    JeffJo July 27, 2018 at 18:31 ¶ #200689
    Quoting Jeremiah
    The simple truth is that you have been misinterpreting me since you joined the conversation. I saw it from your first response to me. I looked at your post and realized you were making false assumptions based on viewing post out of context of the thread. I knew if I enegaged you on that level the conversation would consistent of me untangling all of your misconceptions.


    The *actual* truth is that you have been misinterpreting me from my very first post (Reply to JeffJo), and you continue to demonstrate that here.

    In that post, I cited your statement of the OP to address it, and only it. I quite intentionally made no reply to anything that anybody - especially you - had written in the thread. If you would like to tell me how you think the posts I didn't refer to, were referred to out of context, I'm all ears.

    I even tried to be polite when you rudely misinterpreted my example of faulty logic as something I was claiming to be true:

    Quoting JeffJo
    You can't just enumerate a set of cases, and claim each is equally likely. If you could, there would be a 50% chance of winning, or losing, the lottery.

    Quoting Jeremiah
    That is a very bad understanding of what a sample space and an event is. You are not applying your Principle of Indifference there

    Quoting Jeremiah
    Ya, great math there.

    Quoting JeffJo
    Yes, my point was that the lottery example is a very bad description of a sample space.


    You went on to demonstrate just how insufficient your knowledge of probability is, and the fact that you didn't understand anything I had said. Probably because you didn't read it:

    Quoting Jeremiah
    It makes no sense to use a probability density curve[1] on this problem, considering X would only be selected ONCE[2], which means X<2X ALWAYS[3] (given that X is positive and not 0). That means no matter what X is the expected value will always be 1/2X+X[4], in every single case.

    If you try to fit X to a statistical[5] distribution you are just piling assumptions on top of assumptions[6]. You are making assumptions about the sampling[7] distribution and the variance[8]. Assumptions in which you do not have the data to justify. You are also making assumptions about how X was even selected.[9]


    1. It's a probability distribution, and it's a set. A density curve is for continuous random variables.
    2. The expectation formula considers two. X was the the random variable for the lower of the two envelopes. If v is the value in your envelope (and yes, we only need one v) the expectation considers X=v/2 and X=v
    3. Which is what "X was the lower of the two" means.
    4. Where did you get this? At first rad, I was willing to accept as a typo. But not anymore.
    5. Statistics is used on an experimental data set from repeated trials. We don't have that.
    6. I made no assumptions. I described the two random variables that exist in the OP, and used an example.
    7. What sampling? Besides, that applies to statistics, and this is a probability problem.
    8. What variance? That is a statistical measure, and this is a probability problem. No variance is involved.
    9. Which was the point. How X was chosen affects a random variable in the OP, and so it affects the correct expectation formula.


    But after my polite reply, where I did not point out any of these misrepresentations of yours, you became belligerent started saying you would not read anything I wrote until I had read all of the irrelevant posts.
    Quoting Jeremiah
    I am not doing this, not until you actually read all of my posts in this thread.

    Then, despite the fact that I tried to address only those posts that had a smidgen of relevancy, or ones you pointed out as significant (and later claimed were not), you continued to insist you wouldn't read what I wrote. And it's quite clear you didn't; or at least that you didn't understand any of it.
    Jeremiah July 27, 2018 at 22:05 ¶ #200715
    How could anyone who has read this thread possibly concluded I was ever advocating for a statistical solution. I have been very clear that a statistical approach is incorrect.

    Jeremiah July 27, 2018 at 22:09 ¶ #200717
    Quoting JeffJo
    Statistics is used on an experimental data set from repeated trials.


    Yes, and it is also used on observational data sets to make generalized inferences about a population.
    Jeremiah July 28, 2018 at 00:44 ¶ #200753
    Reply to Michael

    You people really need to drop this Classical v. Bayesian mind set many of you have. The idea that they are somehow different tool boxes is misleading, they come from the same tool box.
    Srap Tasmaner July 28, 2018 at 01:16 ¶ #200754
    Reply to Michael
    1. For a single trial, the player cannot calculate an expected value for the other envelope, and therefore either (a) they cannot make a rational decision to switch or stick, or (b) they must use some criterion other than expected value.

    2. For multiple trials, the Always Switch and Always Stick strategies are, in the long run, indistinguishable.

    If I am the player, and I know that (2) is the case, that does not entail, in the case before me, either that I should switch or that I should stick. For any particular trial, either switching or sticking is the right thing to do. But once I know that (1) is the case, I can return to (2) and conclude either that there is no way for me to steer the outcome toward gain, or that I should try some other strategy. (Even if I only get the one chance, I should, if I can, use a method that improves my chances of gain, even if it's a small improvement, unless the disutility of using such a method outweighs the expected gain.) Or I could return to (1) and see if there is anything besides expected value out there.

    I believe both (1) and (2), but I am not clear on the relation between them.
    Jeremiah July 28, 2018 at 01:21 ¶ #200756
    Quoting JeffJo
    Then go ahead and switch envelopes in the OP.


    There is not enough information to calculate expected gain.
    Jeremiah July 28, 2018 at 01:24 ¶ #200757
    Quoting JeffJo
    it gives you a strategy that works on your assumed prior


    Assuming your prior is correct, that is.
    Jeremiah July 28, 2018 at 01:25 ¶ #200758
    Quoting JeffJo
    The point is that there must be a prior distribution for how the envelopes were filled


    True, but you will have no knowledge of what that may be.
    Jeremiah July 28, 2018 at 01:35 ¶ #200760
    Quoting JeffJo
    you became belligerent started saying you would not read anything I wrote until I had read all of the irrelevant posts.


    And yet you didn't read the posts, did you? Not then, maybe you read a few more after I pushed you. I may be an ass, but at least I read a thread before criticizing people.
    Jeremiah July 28, 2018 at 11:17 ¶ #200846
    The limit does not need to be specified, as the envelopes will never step outside the limit. Mathematically you cannot determine if you have the the smaller amounts or larger amounts as you can never rule out which case you are in. You can speculate on such things, but you can't quantify them. It is pointless to consider the conditional probability since both cases are subjectively equal in probability, it would still boil down to a coin flip. You can do it for completeness, but it really makes no difference.
    Jeremiah July 28, 2018 at 11:25 ¶ #200847
    The solution has always been what I posted on the first page of this thread in post number 6, which has also been my stance this entire thread. A statistical solution has never been a viable option, which has also been my stance this entire thread. The truth is this problem has always been really simple to solve, it is untangling all the speculations and assumptions that confounded it.
    JeffJo July 28, 2018 at 14:27 ¶ #200890
    Quoting Jeremiah
    How could anyone who has read this thread possibly concluded I was ever advocating for a statistical solution. I have been very clear that a statistical approach is incorrect.

    How could anyone who has read this thread have possibly concluded that I ever made this conclusion? When all I said was that any use of statistics - which you did advocate repeatedly - was inappropriate for a probability problem or a thought problem?

    The only valid use of - or mention of - statistics in this thread would be to verify that a simulation can represent the reality I have proven with mathematics. The only valid use of such a simulation would be to convince doubters (of that proof) that it works. If you would read the tread, and not snippets out of context, you will see that this is what I have said about statistics and simulations.

    +++++
    Quoting Jeremiah
    "Statistics is used on an experimental data set from repeated trials." — JeffJo
    Yes, and it is also used on observational data sets to make generalized inferences about a population.

    So that "observational data set" is the "experimental data set," isn't it? With each sample being an instance of the experiment "how does a single member of population X behave in circumstances Y?"

    See how easy this is when you are not trying to find fault that isn't there? But even if you don't want to acknowledge this, do we have either in the OP? No? So why keep bringing it up?

    +++++
    Quoting Jeremiah
    Then go ahead and switch envelopes in the OP. — JeffJo

    There is not enough information to calculate expected gain.

    So read the statement in its context, where I said exactly that. You are removing it from its context to make it look bad:
    But if you don't care about chances, only the possibility of gain? ... Then go ahead and switch envelopes in the OP. Just don't expect a gain. That can't be determined from the information.


    +++++
    Quoting Jeremiah
    it gives you a strategy that works on your assumed prior — JeffJo

    Assuming your prior is correct, that is.

    So read the statement in its context, where I said exactly that. You are removing it from its context to make it look bad:
    Even in that more general case, the Bayesian approach can give a switching strategy with a positive expected net gain. — andrewk

    No, it gives you a strategy that works on your assumed prior, not necessarily on reality.


    +++++
    Quoting Jeremiah
    The point is that there must be a prior distribution for how the envelopes were filled — JeffJo

    True, but you will have no knowledge of what that may be.

    Yes, as I have said repeatedly. And if you read the entire thread, you will see that this has been my point all along. Even though you don't know what the distribution is, you still have to treat whatever value you are using as a random variable with a probability distribution, and not simply "as an unknown." Which is what you have advocated.

    I'm not even sure you understand what that means. An unknown "x" can be used in a calculation by itself. The purpose may be to treat it as an independent variable, and draw a plot. But if you want to use a random variable X and assume an unknown value x for it, that calculation must couple the use of x with a probability Pr(X=x).

    So the expectation calculation, when you have value v in your envelope, is not (v/2)/2+(2v)/2 = 5v/4. It is (v/2)*Q+(2v)/(1-Q) = 2v-3Q/2 for some unknown probability Q that depends on the unknown distribution which exists even though it is unknown. And it varies with v, so we can use an arbitrary function Q(v).

    But there are restrictions we can place on Q(v). From the OP, unless your benefactor has an infinite supply of money, there is a v where Q(v)=1 and the expectation is v/2. And unless he can halve any amount, there is another where Q(v)=0 and the expectation is 2v.

    +++++
    Quoting Jeremiah
    And yet you didn't read the posts, did you? Not then, maybe you read a few more after I pushed you. I may be an ass, but at least I read a thread before criticizing people.

    And what people did I criticize this way? I simply pointed out that this problem is controversial because of an error that is routinely made everywhere the controversy exists.

    But do you even understand what "to criticize" means? It means "to consider the merits and demerits of and judge accordingly". You were the one who chose to take my valid criticism of the methodology personally, and immediately became an ass. I tried very hard to avoid replying to that behavior, but you wouldn't let me.
    JeffJo July 28, 2018 at 14:42 ¶ #200896
    Quoting Jeremiah
    The limit does not need to be specified, as the envelopes will never step outside the limit. Mathematically you cannot determine if you have the the smaller amounts or larger amounts as you can never rule out which case you are in. You can speculate on such things, but you can't quantify them. It is pointless to consider the conditional probability since both cases are subjectively equal in probability, it would still boil down to a coin flip. You can do it for completeness, but it really makes no difference.

    The purpose is to show why the formula (v/2)/2 + (2v)/2 = 5v/4 is wrong. The approach behind the formulation is indeed correct; it just makes a mistake that doesn't show up in the formula. And can't, if you accept the assertion "it is pointless to consider the conditional probability."

    Call the conditional probability you dismiss so easily Q(v). It is the conditional probability that the other envelope contains v/2, given that yours has v. So the conditional probability that the other envelope contains 2v, given that yours has v, is 1-Q(v). The correct expectation is now:
    • (v/2)*Q + (2v)*(1-Q(v)) = 2v-3v*Q(v)/2


    This reduces to the fallacious 5v/4 iff Q(v)=1/2. If (you do understand what it means when one starts a sentence with "if", don't you?) you could dismiss conditional probability, as you do, 5v/4 actually does become mathematically correct. The only way to prove that is fallacious is to show that Q(v) can't be identically 1/2.

    So it seems there is a point to considering Q(v), even if you don't know what it is.
    JeffJo July 28, 2018 at 14:48 ¶ #200898
    Quoting Jeremiah
    The solution has always been what I posted on the first page of this thread in post number 6, which has also been my stance this entire thread. A statistical solution has never been a viable option, which has also been my stance this entire thread. The truth is this problem has always been really simple to solve, it is untangling all the speculations and assumptions that confounded it.


    Quoting Jeremiah
    You could have X or 2X. If you have X and you switch then you get 2X but lose X so you gain X; so you get a +1 X. However, if you have 2X and switch then you gain X and lose 2X; so you get a -1 X.


    And few have doubted it. Certainly not I - I said the equivalent many times.

    But that solution doesn't explain why 5v/4 is wrong, it just provides a contradictory answer. And unless you can show why one is wrong, then all you have established is a paradox. Not a solution.

    Gee, do you think maybe that was my point in my first post? And to try to make that point without criticizing the people who think 54/4 is right? And certainly not anybody who had posted your solution?

    Jeremiah July 28, 2018 at 15:22 ¶ #200903
    Quoting JeffJo
    When all I said was that any use of statistics - which you did advocate repeatedly -


    Quoting Jeremiah
    Statistics is simply not designed for a problem like this; it is better to just use basic mathematics. Statistics is for analyzing data.


    This is me on page six. You are grossly mistaken on this point, never once did I advocate the use of statistics for addressing the OP. I talked about statistics in response to others but I was very vocal and clear that it should not be used for the OP. Had you read the thread you would have known this and been able to place my posts concerning statistics in proper context.
    Jeremiah July 28, 2018 at 15:25 ¶ #200904
    Reply to JeffJo

    Already did that. It was not that hard.
    Jeremiah July 28, 2018 at 15:30 ¶ #200905
    Quoting JeffJo
    You are removing it from its context to make it look bad


    Just following your lead.
    Jeremiah July 28, 2018 at 15:34 ¶ #200906
    Quoting JeffJo
    So that "observational data set" is the "experimental data set," isn't it?


    I find it interesting that you didn't pick up on what happened there.
    Jeremiah July 28, 2018 at 15:45 ¶ #200909
    Quoting JeffJo
    I tried very hard to avoid replying to that behavior, but you wouldn't let me.


    The only control I have over you is what you allow me to have.
    JeffJo July 28, 2018 at 15:59 ¶ #200910
    Quoting Michael
    The objective Bayesian will say that an already-flipped coin has a 50% probability of being heads, even if it's actually tails, and that my £10 envelope has a 50% probability of being the smaller amount, even if it's actually the larger amount, whereas the frequentist would deny both of these (as far as I'm aware).

    Why would you think that?

    In my opinion, the debate between Bayesian and Frequentist, or "objective" and "subjective," has nothing whatsoever to to with the definition of "probability." Because there isn't one. The following may be oversimplified, but I believe it addresses your concerns:

    Nobody really defines probability as the ratio of successes to trials, for a simple reason. To use such a definition, one would need to perform an infinite number of trials. Since that is impossible, that definition is useless. What all of them do, however, is assume that the frequency of X should approach Pr(X) as the number of trials increases. They just disagree on what X is.

    A Frequentist will assume that X is fixed property of his system. So the probability distribution is a fixed property, whether he determines it objectively or subjectively. His goal may be to use experimental data to approximate what it is, by comparing experimental results to what he expects from that fixed system.

    A Bayesian's X is an idealized mental system, with a knowable probability distribution. She uses the same experimental data to change her mental system to a less idealized one. So it becomes more objective than before.

    The point is that none of these distinction have anything to do with the experiments "I will now flip a coin," "I just flipped a coin," or the Two Envelope Problem. You may believe that your past experience with coin flips (objectively) confirms your (both Frequentist and Bayesian) impression that unflipped coin will land Heads with a 50% probability. But you are really just using the subjective application of the Principle of Indifference, and then accepting that it coens't contradict your experience. There are two cases, neither is preferred over the other either subjectively or objectively (the weak PoI), and there is a subjective similarity between the two (the strong PoI).

    When the coin has been flipped, but is not yet revealed, all of these terms apply the same way. It is still a potential result and the same probability factors - whatever you want to claim they are - apply. The coin is not in a state of being 50% heads and 50% tails. It is in an unknown state that has a 50% chance to be either, just like before the flip it had a 50% chance to end up in either. (Many forget that the point of Schroedinger's Cat was that this mixed state is paradoxical by a classical definition of "existence").

    The same applies to the Two Envelope Problem. Regardless of which adjectives you want to apply to the definition of probability, the chance that the other one has v/2, given that yours has v, is conditional. It depends on how the (insert the same adjectives here) probability that the pair contained (v/2,v) AND you picked high compared to the (insert the same adjectives here) probability that the pair contained (v,2v) AND you picked low.

    You can't assume that both are 50%, because you'd need to assume that it applies to all possible values of v. A true Bayesian would see that such a distribution is impossible.
    Jeremiah July 28, 2018 at 16:09 ¶ #200913
    Quoting andrewk
    This is not well-defined. It needs re-stating to make it unambiguous.


    The last thing that really needs to be addressed is this. @andrewk was correct that X needs to be defined, he was just wrong in how that needs to be done. It needs to be defined with notation with an index to represent the unknown limit and unknown distribution.

    If you want your equations to be complete @Srap Tasmaner you need to address Andrewk's standards here. I don't want to sort the notation myself, but you seem to enjoy that aspect.

    This may help:

    https://www.encyclopediaofmath.org/index.php/Random_variable
    Michael July 28, 2018 at 16:19 ¶ #200914
    Reply to JeffJo I'm not really sure that this addresses my main question. You say "the coin is not in a state of being 50% heads and 50% tails. It is in an unknown state that has a 50% chance to be either, just like before the flip it had a 50% chance to end up in either." Would you say the same about the envelope? There's a 50% chance of picking the lower-value envelope, and so after having picked an envelope it's in an "unknown state" that has a 50% chance of being either the lower- or the higher-value envelope?
    Srap Tasmaner July 28, 2018 at 18:16 ¶ #200933
    Quoting Michael
    There's a 50% chance of picking the lower-value envelope, and so after having picked an envelope it's in an "unknown state" that has a 50% chance of being either the lower- or the higher-value envelope?


    Let's leave the envelopes aside for a moment.

    Imagine an interval [0, L] for some positive real number L. Now let u and v be unequal real numbers in that interval. What is the chance that u < v? Intuitively, that's just v/L. Given a choice between u and v, what is the chance of picking u or v? 1/2. Given that you picked one of u and v, what is the chance that the one you picked is less than the other? We'll call your choice S and the other T (and abuse that notation):

    P(S < T | S = u) = v/L, P(S < T | S = v) = u/L

    Not only do we not know that those are equal, we know that they aren't, because u and v are unequal. But we can say

    P(S < T | S ? {u, v}) = (u + v)/2L

    because the chances of picking u and picking v are equal. Clearly,

    * P(S < T | S ? {u, v}) = 1/2

    if only if

    * (u + v)/2L = 1/2
    * u + v = L

    But there's no reason at all to think that u + v = L. All we know is that u + v ? 2L. (We could go on to ask what P(u + v = L), but I'm not sure what the point of that would be.)

    So the answer to this question, "What is the chance that the one you picked is smaller?" may or may not be 1/2, even though your chance of picking the smaller is 1/2. (And if it turns out u + v = L, that's sheerest coincidence and has nothing to do with your choice.)

    "My chance of picking the smaller" is just not the same as "the chance of what I picked being smaller", as I've been saying ineffectually for like 3 weeks.
    Michael July 28, 2018 at 18:41 ¶ #200937
    Quoting Srap Tasmaner
    "My chance of picking the smaller" is just not the same as "the chance of what I picked being smaller", as I've been saying ineffectually for like 3 weeks.


    That's because I disagree with your interpretation of probability. Your reasoning would seem to suggest that there's a 50% chance of a coin flip landing heads, but that after a flip, but before looking, we can't say that there's a 50% chance that it is heads. I think that we can say that.

    Before picking an envelope I will say that there's a 50% chance that I will pick the smaller envelope. After picking an envelope but before looking I will say that there's a 50% chance that I have picked the smaller envelope. After picking an envelope and after looking I will say that there's a 50% chance that I have picked the smaller envelope. Picking an envelope and looking inside doesn't provide me with information that allows me to reassess the initial probability that there's a 50% chance of picking the smaller envelope.

    As an example with the coin, say you flip it and if it's heads put it in a red envelope and if it's tails put it in a blue envelope. I don't know that the colour of the envelope you give me is determined by the result; I only know that you will give me an envelope containing the result of a coin toss. If you give me a red envelope then I will assess the probability that it's heads as 0.5, and I am right to do so, even though a red envelope always means a toss of heads.
    Srap Tasmaner July 28, 2018 at 18:46 ¶ #200940
    Quoting Michael
    That's because I disagree with your interpretation of probability. Your reasoning would seem to suggest that there's a 50% chance of a coin flip landing heads, but that after a flip, but before looking, we can't say that there's a 50% chance that it is heads. I think that we can say that.


    Admittedly, in strident moments I have said things like this.

    But look at my last post. It's not about interpretations of probability. It's about how conditional probability works, and it can be a little counter-intuitive.
    Michael July 28, 2018 at 18:56 ¶ #200942
    Quoting Srap Tasmaner
    Admittedly, in strident moments I have said things like this.

    But look at my last post. It's not about interpretations of probability. It's about how conditional probability works, and it can be a little counter-intuitive.


    Take my example of the coin toss and the red or blue envelope. The person with full knowledge of the rules will say that P(H | red envelope) = 1, but the person who doesn't know how the colour of the envelope relates to the result of the coin toss will say that P(H | red envelope) = 0.5. The condition of it being a red envelope isn't one that he can use to reassess the initial probability that P(H) = 0.5. It's right for him to say after receiving a red envelope that the probability that the coin landed heads is 0.5.

    And the same with the case of the money. The person with full knowledge will say that P(B = X | A = 20) = 1 if he knows that £20 is never selected as the lower value, but the person who doesn't know of the distribution will say that P(B = X | A = 20) = 0.5 because the condition of his envelope containing £20 isn't one that he can use to reassess the initial probability that P(B = X) = 0.5. It's right for him to say after opening his envelope that the probability that the other envelope contains twice as much is 0.5.
    Jeremiah July 28, 2018 at 20:57 ¶ #200962
    Quoting Michael
    Your reasoning would seem to suggest that there's a 50% chance of a coin flip landing heads, but that after a flip, but before looking, we can't say that there's a 50% chance that it is heads. I think that we can say that.


    Your 50% applies to your uncertainty about the state of the coin. You flip a coin it has a 50% chance of T or H, after that lands that part is done. Without seeing the coin you guess there is 50% chance it is heads. That 50% is about your guess. One is subjective the other is objective, but I agree with your general direction.
    Srap Tasmaner July 28, 2018 at 21:02 ¶ #200966
    Reply to Michael
    Coin flips and coin flips with colored envelopes are just the wrong kind of example to look at, because (a) you have categorical instead of numeric data, which means you're going to be tempted to substitute the probability of an event for the event, and (b) coin flips have magic numbers built in, magic numbers that happen to match up to the magic numbers you're trying to distinguish (the chances associated with choosing). This is just bad methodology. When you're trying to figure out some bit of math, you should go out of your way to avoid these magic numbers, and only bring them back in as easy-to-solve special cases of the general problem.

    I gave you an example about as general as I could think of. Look at how that example works.
    Jeremiah July 28, 2018 at 21:06 ¶ #200967
    Reply to Srap Tasmaner

    There is no reason you can't look at the OP and consider it in a categorical case.
    Srap Tasmaner July 28, 2018 at 21:07 ¶ #200969
    Srap Tasmaner July 28, 2018 at 21:19 ¶ #200972
    It's also slightly more complicated than I wanted because of the "reference" problem. If you don't designate either u or v as the reference variable, it all goes to hell.
    Jeremiah July 28, 2018 at 21:22 ¶ #200973
    The amount in the envelopes is already set, just like the coin was already flipped, the uncertainty we have been considering is subjective in nature.
    Jeremiah July 28, 2018 at 21:40 ¶ #200978
    Consider this: Say I have an unfair coin, on average it flips H 9 out of 10 times. You don't know this; however, all you see is a coin and without knowing it is unfair you give H a 50% chance. That is the difference between subjective and objective probability.

    The only way for you to know that the coin flips H 9 out of 10 times is to flip the coin several times. Maybe I flip it for you a few times, say I get four heads in a row, and you are starting to doubt your 50/50 assumption. Then I flip it more and get two more heads, now you no longer believe it is 50/50.

    That's Bayesian inference in a nutshell.
    Srap Tasmaner July 28, 2018 at 21:52 ¶ #200983
    Imagine u around .75L and v around .9L. They're just randomly selected values in [0, L]. We can't say at the same time that P(u < v) = .9 and P(v < u) = .75. Oops.

    Instead you have to say something like P(u < V | V = v, u in [0, L]) = v/L. And then P(u > V | V = v, u in [0, L]) = 1 - v/L. Anyway that's closer.

    (The other way, you might get, as with the values above, P(u > v) + P(v > u) > 1 or you demand that u + v = L, which is silly.)

    I feel bad about how messy I'm still being with variables.
    Srap Tasmaner July 28, 2018 at 22:02 ¶ #200987
    Reinventing math step-by-step is interesting, and I'm gaining insight by making every possible mistake, and doing so in public, but it would be far more efficient just to study more.
    Andrew M July 28, 2018 at 22:22 ¶ #200989
    Quoting Michael
    If I'm told that one envelope contains twice as much as the other, and if I pick one at random, am I right in saying before I open it that there's a 50% chance that my envelope contains the smaller amount?1 If so, I must also be right in saying after I open it and see the amount that there's a 50% chance that my envelope contains the smaller amount (assuming I don't know how the values are selected).


    You are referring to two different probabilities. The first is P(lower) which is 50%, the second is P(lower|amount) which depends on the specifics of the distribution.

    To see this, suppose the distribution is {{5,10},{5,10},{5,10},{5,10},{10,20}} with an equal probability of the host selecting any one of those envelope pairs.

    There is a 50% chance of the player choosing the lower envelope from the envelope pair that the host selected. When the amount is unknown, there is also a 50% chance that the selected envelope is the lower envelope.

    However if the player observes the amount to be 10, P(higher|10) = 4/5 and P(lower|10) = 1/5. The expected value from switching is 10/2 * P({5,10}) + 10*2 + P({10,20}) = 5 * 4/5 + 20 * 1/5 = 8. So there is a negative expected gain from switching.

    If the player does not know the initial distribution and simply assumes P(lower|10) = P(higher|10) = 1/2 then the calculated expected value from switching will be 12.50 which is wrong. However it will still be the case that P(lower) = 1/2 since that does not depend on their mistaken assumption.

    So the difference depends on whether one is conditioning on the specific amount or not. Without knowing the distribution, P(lower|amount) cannot be calculated, only P(lower) can. Opening the envelope and learning the amount constitutes a kind of context switch where the player switches from considering P(lower) to considering P(lower|amount).

    Edit: fixed math
    Srap Tasmaner July 28, 2018 at 22:38 ¶ #200993
    Quoting Andrew M
    P(lower) = P(lower|5) + P(lower|10) + P(lower|20) = 4/10 + 1/10 + 0/10 = 1/2.


    This isn't what you mean, is it?

    P(lower | 5) = 4/4 = 1, P(lower | 10) = 1/5, P(lower | 20) = 0/1.

    Srap Tasmaner July 28, 2018 at 23:06 ¶ #200995
    Reply to Andrew M
    You just telescoped the step of multiplying by the chance of picking that number.

    Could put & where you have |.
    Andrew M July 29, 2018 at 02:22 ¶ #201042
    Quoting Srap Tasmaner
    You just telescoped the step of multiplying by the chance of picking that number.

    Could put & where you have |.


    Yes, I messed up the math. Have edited...
    Srap Tasmaner July 29, 2018 at 02:29 ¶ #201043
    Quoting Andrew M
    I messed up the math


    You're not in my league at messing up the math!

    It is a nice clear argument, using @JeffJo's multiple sets of envelopes, and makes the point I keep failing to make. P(lower)=1/2, but P(lower | 10) = 1/5.

    I have a feeling though that @Michael will still think that absent knowledge of the distribution, he can turn back to 50% as an assumption.
    Pierre-Normand July 29, 2018 at 02:47 ¶ #201048
    Quoting Srap Tasmaner
    I have a feeling though that Michael will still think that absent knowledge of the distribution, he can turn back to 50% as an assumption.


    The best way to counter that assumption, it seems to me, just is to remind oneself that even though one may not know what the distribution is, assuming only that it is not uniform and unbounded, then, whatever this unknown distribution might be, the raised expectation from switching always is zero. So, it doesn't matter that the actual distribution is unknown. It's still known that it must be such as to make the raised expectation from switching zero, for the reason illustrated by @Andrew M in one specific case.

    On edit: "the raised expectation from switching" is meant to refer to the average expectation of the always-switching strategy. The specific expectation of switching, conditionally on having found some determinate amount X in the first envelope, can only be guessed and can't be assumed to be zero.
    Jeremiah July 29, 2018 at 03:16 ¶ #201051
    Quoting Srap Tasmaner
    I have a feeling though that Michael will still think that absent knowledge of the distribution, he can turn back to 50% as an assumption.


    You have not really proven he can't. You yourself are making your own assumptions when considering expected gain over the two possible cases.

    If a loaded coin flips H 9 out 10 times, without that knowledge, an uninformative 50/50 prior is completely justified.
    Srap Tasmaner July 29, 2018 at 03:22 ¶ #201053
    Quoting Jeremiah
    You have not really proven he can't.


    I know! It's why I'm still here.
    Jeremiah July 29, 2018 at 03:25 ¶ #201054
    Reply to Srap Tasmaner

    Yet you assume he is wrong?
    Pierre-Normand July 29, 2018 at 03:27 ¶ #201056
    Quoting Pierre-Normand
    In this case, it's the fact that the Hotel has countably infinitely many rooms that enables the assumption of equiprobability to hold.


    I was rather careless in this post where I had made use of Hilbert's Grand Hotel for illustrative purpose. In my thought experiment the equiprobability assumption didn't actually hold because, after the guests have moved to their new rooms, they can often deduce from the room number they end up in where it is that they came from. Initially, the guests are equally distributed in the rooms numbered 2,4,6, ... Then, after flipping a coin and moving, accordingly, from room X to either room Y = X/2 or 2*X, there are three cases to consider. They may end up (case A) in a room within the range (1,3,5,...); (case B) within the range (2,6,10,...); or, (case C) within the range (4,8,12,...).

    In case A, the players can deduce from the number Y of the room where they moved being odd that they moved there from room 2*Y and hence will want to move back if given the opportunity.

    In case B also, they can deduce the same thing since, although Y/2 is an integer, it is an odd number and hence not in the initial range. They will also want to move back if given the opportunity.

    Only in case C will they not be able to deduce where it is that they came from. About half of them, on average, will have moved to room Y from room Y/2 and the other half from room 2*Y. Their expectation for moving back to the room where they came from, conditional on them being in room Y, is 1.25Y (whereas, in cases A and B, the guaranteed outcome of moving back was 2Y)

    So, even though the expectation that any guest who starts up in room X, from the initial range (2,4,8,...), is 1.25X after 'switching', the conditional expectations for moving back from Y to the initial room is either 2Y or 1.25Y. Rational (and greedy) guests should always accept the option to move, and then, wherever they end up, provided only that they don't know where they came from, they also should always accept the option to move back. This only makes sense in Hilbert's Grand Hotel, though, and not in any hotel that has a merely finite number of rooms.
    Jeremiah July 29, 2018 at 03:32 ¶ #201058
    It has always been the same error, making assumptions based on Y. Seeing Y does not actually change the contents of the envelopes.
    Srap Tasmaner July 29, 2018 at 03:34 ¶ #201059
    Reply to Jeremiah
    Yes.

    I accept that the expectation of gain would apply whether you looked in the envelope or not, and thus there are symmetrical expectations that each envelope is worth more than the other. I also believe that always switching is equivalent to always sticking in multiple trials. From both of these reasons, I conclude either:

    1. You cannot talk about expectations here at all (which I find troubling); or
    2. The argument is fallacious.
    Pierre-Normand July 29, 2018 at 03:35 ¶ #201060
    Quoting Jeremiah
    If a loaded coin flips H 9 out 10 times, without that knowledge, an uninformative of 50/50 prior is completely justified.


    Yes, for sure, but if someone hands me, as a gift, an envelope containing some unknown amount of dollars for me to keep, an 'uninformative' prior that is a uniform distribution (or continuous probability density function) from zero to infinity isn't reasonable for me to use for almost any purpose.
    Jeremiah July 29, 2018 at 03:37 ¶ #201061
    Reply to Pierre-Normand Never said it was.
    Jeremiah July 29, 2018 at 03:43 ¶ #201065
    Reply to Srap Tasmaner

    Why don't you consider it from a categorical perceptive then. The OP never called for a solution based on expected gains.
    Pierre-Normand July 29, 2018 at 03:44 ¶ #201066
    Quoting Jeremiah
    Never said it was.


    OK. Once one is reminded that such an 'uninformed' prior, regarding the initial possible contents of the envelopes, isn't reasonable, then, it follows that an uninformed prior regarding the conditional probability that one has picked the smallest envelope, conditional on its value being X, is likewise unreasonable for at least some value of X. And that's because an unconditional uninformed prior of 50% (valid for any observed X value) entails a uniform and unbounded distribution for the possible envelope contents.
    Jeremiah July 29, 2018 at 03:48 ¶ #201069
    Reply to Pierre-Normand The filling of the envelopes and the selecting of the envelopes are two separate events.
    Srap Tasmaner July 29, 2018 at 03:50 ¶ #201070
    Quoting Jeremiah
    The OP never called for a solution based on expected gains


    Sure. But I'm not trying to figure out whether I should switch. I'm trying to figure out where the fallacy in the 5/4 argument is, and that's an expected gain argument.
    Pierre-Normand July 29, 2018 at 03:51 ¶ #201072
    Quoting Jeremiah
    The filling of the envelopes and the selecting of the envelopes are two separate events.


    I know that. But assumptions regarding the method for filling up the possible envelope pairs (and hence their distribution) entail logical consequences for the conditional(*) expectations of one having picked either the smallest or the largest one within one given pair. This dependency relation between the two successive events can't be ignored.

    (*) Conditional on the observed value of the first envelope, that is.
    Jeremiah July 29, 2018 at 04:00 ¶ #201077
    Reply to Srap Tasmaner It is a subjective modeling based on expections when viewing Y. It confounds the objective with the subjective. The random event that determined the contents of the envelopes has already occurred and passed. That was the objective event. The selection is a separate event and it is subjective, which means these expectations are half-truths and everyone is just modeling their subjectivity. I am purposefully avoiding expected calculations for that reason. The envelopes are not in a possible state of two cases, they are in one case.
    Jeremiah July 29, 2018 at 04:04 ¶ #201079
    Reply to Pierre-Normand It absolutely can be ignored.
    Pierre-Normand July 29, 2018 at 04:07 ¶ #201081
    Quoting Jeremiah
    It absolutely can be ignored.


    To ignore logical dependencies between claims in rational arguments is a recipe for disaster.

    Jeremiah July 29, 2018 at 04:13 ¶ #201083
    Reply to Pierre-Normand

    I think we are safe, I doubt anything will blow up.
    Pierre-Normand July 29, 2018 at 04:22 ¶ #201085
    Quoting Jeremiah
    I think we are safe, I doubt anything will blow up.


    Things have blown up long ago. It is precisely the endemic oversight of the logical dependency at issue that is the source of the apparent paradox being presented in the OP. There is an illicit move from an assumption of equiprobability regarding the conditional probability of one having picked the smallest envelope (conditional on X, whatever X one might pick) to the assumption that there might be a bounded distribution of possible envelope pairs that is merely unknown. Those two assumptions are logically inconsistent. Either the unknown distribution isn't (as it indeed can't be, in realistic cases) uniform and unbounded or the equiprobability assumption is true. But if the equiprobability assumption is true, then the initial distribution for possible contents of the smallest envelope in each possible pair must be unbounded and uniform.
    Jeremiah July 29, 2018 at 04:58 ¶ #201087
    Reply to Pierre-Normand

    I have two envelopes, one with amount A and one with amount B. I flip a fair coin to choose one. What is my chance of getting B?
    Pierre-Normand July 29, 2018 at 05:00 ¶ #201088
    Quoting Jeremiah
    I have two envelopes, one with amount A and one with amount B. I flip a fair coin to choose one. What is my chance of getting B?


    1/2

    Jeremiah July 29, 2018 at 05:05 ¶ #201090
    Reply to Pierre-Normand

    See that was easy.
    Pierre-Normand July 29, 2018 at 05:11 ¶ #201092
    Quoting Jeremiah
    See that was easy.


    Sure, but that's not what the equiprobability assumption is. What I have been referring to as the equiprobability assumption is the assumption that your credence in having picked the smallest envelope, which is 1/2 before you open it, remains 1/2 conditionally on there being the determinate amount X in it for any X. This is an assumption that can only be reasonably held (if at all) if the distribution of possible envelope contents is assumed to be unbounded and uniform.
    Jeremiah July 29, 2018 at 05:15 ¶ #201093
    Reply to Pierre-Normand

    And I am saying that doesn't really matter because it will always be amount A and amount B.
    Pierre-Normand July 29, 2018 at 05:18 ¶ #201094
    Quoting Jeremiah
    And I am saying that doesn't really matter because it will always be amount A and amount B.


    It doesn't really matter for what? It does matter for invalidating the fallacious argument that purports to show that your expected gain from switching, conditionally on having initially opened an envelope with the determinate amount X in it, is 1.25X.
    Jeremiah July 29, 2018 at 05:33 ¶ #201096
    Reply to Pierre-Normand

    That is what I just did. The envelopes cannot be in both cases at once, therefore it makes no sense to hedge your expections that both cases are possible. You need to either consider each case separately or just go off the fact you have two envelopes in front of you as the end results is the same.
    Pierre-Normand July 29, 2018 at 05:47 ¶ #201098
    Quoting Jeremiah
    That is what I just did. The envelopes cannot be in both cases at once, therefore it makes no sense to hedge your expections that both cases are possible.


    The argument that purports to show that the expectation from switching is 1.25X doesn't rely on both possible cases (possible consistently with the information that is available to you, that is) being actual at once. It only relies on them being equiprobable; or both equally likely to be true, consistently with everything that you know.
    Jeremiah July 29, 2018 at 05:56 ¶ #201099
    Reply to Pierre-Normand Never said anything about both being actual at once. Never meant that at all. Clearly that can't happen so I am not sure how you got that. You have to consider each case on its own and not together. We had this same issue at the start of the thread.
    Pierre-Normand July 29, 2018 at 06:09 ¶ #201100
    Quoting Jeremiah
    Never said any thing about both being actual at once.


    You just said "The envelopes cannot be in both cases at once", followed with the word "therefore...". So it looked like you were making an issue of the fact that they can't be "in both cases" at once. But that is quite uncontroversial.
    Jeremiah July 29, 2018 at 06:12 ¶ #201101
    Reply to Pierre-Normand Do you get the point or not?
    Pierre-Normand July 29, 2018 at 06:24 ¶ #201102
    Quoting Jeremiah
    Do you the the point or not?


    No. You seem to be reaching for an argument that purports to show that your raised expectation from switching, conditionally on having found out that there is some determinate amount X in the first envelope, is zero regardless of the initial envelope pair distribution and regardless of X. I can't see how this argument can work just on the basis that you don't know the initial distribution. While it's true that, on the mere assumption that the initial distribution is bounded, the overall raised expectation of the always-switching strategy is zero, it's not generally true that the expectation, conditional on seeing the amount X in the first envelope, is zero. Although it may not be possible to know, or calculate, what this conditional expectation might be, there is no reason to conclude that it is zero.
    Jeremiah July 29, 2018 at 06:40 ¶ #201103
    Reply to Pierre-Normand I don't really care about things you can't know.

    The 1.25X come from considering expected gains over both cases, the larger and smaller. However, when one case is true the other cannot be true, so since the chance event for the envelope has already been decided it makes no sense to consider expected gains in this fashion. They should to be considered separately.

    Pierre-Normand July 29, 2018 at 07:04 ¶ #201104
    Quoting Jeremiah
    The 1.25X come from considering expected gains over both cases, the larger and smaller. However when one case is true the other cannot be true, so it makes no sense to consider expected gains in this fashion. They should to be considered separately.


    There is a sort a move in philosophy that is called "proving too much". An argument proves to much when it succeeds in proving the thesis that one purported to demonstrate but, unfortunately, it also proves some corollary that this quite embarrassing.

    The trouble with your argument is that, while it indeed (purportedly) concludes that you can't expect to have a positive gain from implementing an always-switching strategy, it also ought to yield this conclusion when the initial distribution is bounded, known, and X is also known.

    Suppose for instance the initial distribution simply is {{5,10},{10,20}} with each pair equally probable. Suppose also you open your envelope and find $10. Should you switch? In this case, you should. Your raised expectation from switching is $2.5. This is what you tend to gain on average when you plays the game several times. But your own argument would lead us to conclude that the expectation from switching is the very same as the expectation from sticking. You are arguing that the two cases must be considered separately rather than being weighted in accordance with their posterior probabilities. Hence, in the case where the envelope contents are {5,10} your gain from switching is $5 when you have $5 and -$5 when you have $10, or, overall zero. And then you likewise would consider the {10,20} case "separately" and conclude that the switching strategy yields no increased expected gain in that case either (you either win or lose $10 from switching, in that case). The trouble is that this way to frame the problem offers you no guidance at all regarding what to do when you know that your envelope contains $10 and you don't know which of the two case {{5,10},{10,20}} is actual. It precludes you from making use of your knowledge that both of those two possible envelope distributions still are equiprobable conditionally on your having found $10 in the first envelope.
    Jeremiah July 29, 2018 at 07:11 ¶ #201105
    Reply to Pierre-Normand Actually only one case is true, while the other one does not exist. So they can't both be possible outcomes, not objectively. Remember the envelopes are already decided. You are modeling your assumption of what you think is possible. However, just because you can think of something that doesn't mean it is objectively a possible outcome.
    Pierre-Normand July 29, 2018 at 07:21 ¶ #201106
    Quoting Jeremiah
    Actually only one case is true, while the other one does not exist. So they can't both be possible outcomes, not objectively. You are modeling your assumption of what you think is possible. However, just because you can think of something that doesn't mean it is objectively a possible outcome.


    Of course "only one case is true" at each iteration of the game. Still, the player doesn't know which one is true at each iteration of the game when he finds $10 in his envelope. But the player does know what the distribution is and, therefore, that, in the long run, each one of the two cases will be realized an approximately equal number of times. This is what allows her to calculate that her average gain from playing the game repeatedly will be $2.5 if she adopts the strategy of switching whenever her envelope contains $10. This is also what makes it rational for her to switch when the game is played only once and she is willing to risk losing $5 for an equal chance of winning $10 since she doesn't know which "one case is true" but knows them to be equally distributed.
    Jeremiah July 29, 2018 at 07:25 ¶ #201107
    Reply to Pierre-Normand

    Already commented on "strategy of switching". You are no longer talking about just probability anymore, since you can now sample the distribution you are now engaged in statistics, which is outside the scope of the OP
    Jeremiah July 29, 2018 at 07:31 ¶ #201108
    You only get one instance of the game. You don't get to open a 100+ envelopes.
    Jeremiah July 29, 2018 at 07:34 ¶ #201109
    You don't know the distribution, you don't know the limits and you only get one chance to switch.
    Pierre-Normand July 29, 2018 at 07:35 ¶ #201110
    Quoting Jeremiah
    You are no longer talking about just probability anymore, since you can now sample the distribution you are now engaged in statistics, which is outside the scope of the OP


    It is rather difficult to divorce discussion of probabilities from discussion of statistics. You can't really build an insulating wall between those two disciplines. It doesn't make much sense to talk about probabilities of events that are singular, unique, occurrences not belonging to any sort of distribution. Probability distributions do have statistical properties. You just seem to want to outlaw, by fiat, arguments that make trouble for your case.
    Pierre-Normand July 29, 2018 at 07:37 ¶ #201111
    Quoting Jeremiah
    You don't know the distribution, you don't know the limits and you only get once chance to switch.


    It is rational to want to maximize your expectation even when you only get one single chance to play, and it is irrational to dismiss your expectation merely on the ground that just one of the possible outcomes will be realized.

    Suppose you are forced to play Russian roulette once. There are two revolvers, one with five bullets in the cylinder (and one empty chamber) and the other one with one bullet (and five empty chambers). The revolvers are truthfully labelled accordingly. You are free to pick any one. Are you arguing that since you only are going to play once, it's irrelevant which revolver you choose?
    Jeremiah July 29, 2018 at 07:55 ¶ #201114
    Reply to Pierre-Normand Statistics is a data science and uses repeated random events to make inference about an unknown distribution. We don't have repeated random events, we have one event. Seems like a clear divide to me. You can't learn much of anything about an unknown distribution with just one event.
    Jeremiah July 29, 2018 at 07:57 ¶ #201115
    Reply to Pierre-Normand It is also rational to want ice-cream on a hot day. You still don't know anything about the distribution.
    Pierre-Normand July 29, 2018 at 07:59 ¶ #201116
    Quoting Jeremiah
    Statistics is a data science and uses repeated random events to make inference about an unknown distribution. We don't have repeated random events, we have one event. Seems like a clear divide to me. You can't learn much of anything about an unknown distribution with just one event.


    None of my arguments relied on being able to lean "much" about a distribution from one single observation. My arguments rather relied entirely on logical relations between definite claims about possible distributions and conditional probabilities.
    Jeremiah July 29, 2018 at 08:00 ¶ #201117
    Reply to Pierre-Normand You are guessing. Then trying to model your guesswork.
    Pierre-Normand July 29, 2018 at 08:02 ¶ #201118
    Quoting Jeremiah
    It is also rational to want ice-cream on a hot day. You still don't know anything about the distribution. You are speculating then trying to model your speculations.


    When I say that this can be inferred from that, or that it is fallacious to infer this from that, then I am either right or wrong about it; and in the case where you think I am wrong, an argument is forthcoming. None of my claims purport to be empirical or speculative (except when I explicitly hedged some as conjectures earlier in the thread).

    I take the two-envelopes paradox to be a puzzle about probability theory and there is little point speculating rather than arguing logically about it. The use of models is perfectly fine for illustrative purposes, for conveying a concept across, or for supplying proofs of existence.
    Jeremiah July 29, 2018 at 08:10 ¶ #201119
    Reply to Pierre-Normand
    Hey, if you feel lucky then switch, if you think you are close to the cap don't, feel this one out, but you are not going to be able to justly quantify a positive gain based on the information we have.
    Pierre-Normand July 29, 2018 at 08:24 ¶ #201120
    Quoting Jeremiah
    Hey, if you feel lucky then switch, if you think you are close to the cap don't, feel this one out, but you are not going to be able to quantify a positive gain based on the information we have.


    This is something I have never disputed. I have never purported to offer an optimal strategy or suggested that there is any way to come up with one. The two-envelopes paradox is, precisely, a paradox because under some widespread interpretations of "don't know" (regarding the prior distribution, and the probability that the open envelope is the smallest one) there appears to be two equally valid arguments that purport to conclude that switching yields a positive expectation or that it yields a null expectation. Since those two conclusions are inconsistent, the resolution of the paradox calls into finding the flaw in (at least) one of the two arguments. Considerations of well defined strategies only are meant (by me) to illustrating flaws in the arguments that purport to lead to two inconsistent conclusions on the basis of a common set of assumptions regarding the possible initial distributions. A few other participants in this thread (such as JeffJo, fdrake and both Andrews) have offered diagnoses similar to mines of the most common mistakes that lead one to the erroneous and paradoxical conclusions.
    Jeremiah July 29, 2018 at 08:29 ¶ #201122
    Reply to Pierre-Normand As far as I am concerned I already found the flaw. Take it or leave it, that is your choice.

    Pierre-Normand July 29, 2018 at 08:33 ¶ #201124
    Quoting Jeremiah
    As far as I am concerned I already found the flaw. Take it or leave it, that is your choice.


    I have chosen a third option, which is to point out the logical flaw in your purported identification of "the flaw". As I suggested earlier, your own resolution of the paradox relies on an argument that proves too much, since it leads to wrong inferences about expectations in specific cases.
    Jeremiah July 29, 2018 at 09:04 ¶ #201126
    Reply to Pierre-Normand

    So you think you always have a 1.25 expected gain in every possible instance?
    Jeremiah July 29, 2018 at 09:18 ¶ #201129
    If you are using the principle of indifference then criticizing people for using the principle of indifference, that is hypocritical.
    Pierre-Normand July 29, 2018 at 09:24 ¶ #201130
    Quoting Jeremiah
    So you think you always have a 1.25 expected gain in every case?


    Not at all. I have rather argued that there is an 1.25X expected gain from switching in one specific case of a known distribution {{5,10},{10,20}} where, by your own argument, switching ought to be no better than sticking since we are ignorant of the case and, according to this argument, the cases therefore can only be treated separately and don't justify the 1.25*$10 expectation.
    Michael July 29, 2018 at 09:34 ¶ #201131
    Quoting Pierre-Normand
    It is rational to want to maximize your expectation even when you only get one single chance to play, and it is irrational to dismiss your expectation merely on the ground that just one of the possible outcomes will be realized.


    So say you know that one envelope contains twice as much as the other and that there's £10 in your envelope (and that you don't know how the amounts are selected). What's the rational decision?

    I would say that knowing that there's £10 in my envelope doesn't provide me with information that allows me to reassess the initial probability of 0.5 that I will pick the smaller envelope, and so I will say that there's a probability of 0.5 that I have picked the smaller envelope, and from that calculate an expected gain of £2.50 for switching.

    You seem to be saying that after picking an envelope (whether opened or not?) I have to go from saying that there's a probability of 0.5 that I will pick the smaller envelope to saying that the probability is unknown that I have picked the smaller envelope.

    But what action does your answer entail? Switching or sticking? If you say it doesn't matter, and so you're being indifferent, isn't that the same as treating it as equally likely that the other envelope contains the larger amount as the smaller amount? And if you're treating them as equally likely then isn't it rational to switch?

    So I would say that if you have no reason to believe that the other envelope is more likely to contain the smaller amount then it's rational to switch (assuming, of course, that you can afford to lose).
    Pierre-Normand July 29, 2018 at 09:38 ¶ #201132
    Quoting Jeremiah
    If you are using the principle of indifference then criticizing people for using the principle of indifference, that is hypocritical. Either accept that as a standard starting point or don't


    What I criticized merely was a failure to draw a logical inference from one particular application of the principle of indifference. The logical inference that must be drawn from the assumption that the principle of indifference can be applied unconditionally on X (the value of the seen envelope) is that the prior distribution must therefore be assumed to be unbounded and uniform. If the player correctly draws this inference, then she can still apply the principle of indifference and expect to gain 0.25X (on average) from switching from her envelope (containing $X) to the other one and this expected gain doesn't yield a paradox since, in the case of such an unbounded distribution, however large X might be, it was infinitely unlikely that it be so small and, also, her average expectation from an always-switching strategy isn't any larger than her average expectation from an always-sticking strategy since both are infinite.
    Pierre-Normand July 29, 2018 at 10:04 ¶ #201134
    Quoting Michael
    You seem to be saying that after picking an envelope I have to go from saying that there's a probability of 0.5 that I will pick the smaller envelope to saying that the probability is unknown that I have picked the smaller envelope.


    If there exists some bounded and normalized (meaning that the probabilities add up to 1) prior probability distribution that represents your expectation for the possible distributions of envelope pairs then, in that case, your average raised expectation for an always-switching strategy is zero, for reasons that many have expounded in this thread. However, any such prior bounded probability distribution which might represent your expectation is inconsistent with your being able to apply the principle of indifference to whatever case of X that you might observe in the first envelope. Your knowledge (or assumption) of this prior distribution rather allows you to calculate exactly the exact expectation conditionally on any X, and this is generally different from 1.25X.

    If, on the other hand, you take the uniform and unbounded distribution to represent your prior expectation, then, in that case, you can apply the principle of indifference whatever X it is that you might observe in the first envelope. Under this wild assumption of a uniform expectation, for any number M, however large, your prior expectation was that it was infinitely more likely that X would turn out to be larger than M rather than smaller or equal to M. So, it is no surprise that you are expecting a gain from switching. (You can refer back to my Hilbert Grand Hotel example, earlier in this thread, for another illustration of the consequences that follow from assuming such a wild unbounded and uniform 'uninformed' probability distribution.)

    In the case where you are confident that there is some bounded, and therefore non-uniform, prior distribution of envelope pairs, but you don't have a clue how to go about estimating what it might look like, the mere assumption that there exists such an unknown prior distribution is enough to rule out the wild degenerate case described in the prior paragraph. When faced with some determinate amount X, you will possibly not have a clue what the expectation from switching might be. But that is no reason for assuming it to be zero. Hence, there is no reason either for assuming (or inferring) that the expectation from switching is exactly 1.25X. What you can reasonably assume, rather, is that the higher the value of X is, the more risky it is to make the switch, and this knowledge that the risk of a loss increases roughly in proportion with the value of X is inconsistent with the unconditional application of the principle of indifference.

    But what action does your answer entail? Switching or sticking? If you say it doesn't matter, and so you're being indifferent, isn't that the same as treating it as equally likely that the other envelope contains the larger amount as the smaller amount? And if you're treating them as equally likely then isn't it rational to switch?


    Yes, it is rational to switch if you are justified in treating them as equally likely. But if it is axiomatic that they are equally likely, as most statements of the two-envelopes paradox seem to make it, then you must also infer that the prior distribution is uniform and unbounded with all the weirdness that such an ill-defined probability distribution entails.
    Michael July 29, 2018 at 10:12 ¶ #201137
    Quoting Pierre-Normand
    Yes, it is rational to switch if you are justified in treating them as equally likely. But if it is axiomatic that they are equally likely, as most statements of the two-envelopes paradox seem to make it, then you must also infer that the prior distribution is uniform and unbounded with all the weirdness that such an ill-defined probability distribution entails.


    So what's the rational decision if you know that the prior distribution isn't uniform and unbounded? There's £10 in your envelope. Should you stick or switch?
    Pierre-Normand July 29, 2018 at 10:18 ¶ #201138
    Quoting Michael
    So what's the rational decision if you know that the prior distribution is isn't uniform and unbounded? There's £10 in your envelope. Should you stick or switch?


    I am fine with acknowledging that there isn't any such thing as the rational decision to make in the vaguely specified case where you merely have a reasonable expectation that the amount of money can't be infinitely large but you don't have any precise idea how very high the distribution might be tailing off.

    Suppose for instance that tomorrow morning you are being called to play this game with real money in the context of some scientific experiment conducted by the psychology department of your local university. You are to play only once and keep the money. Suppose you open your envelope and find $96 in it. Is it rational to expect 1.25*$96 from switching? I am not committed to saying this. What I am committed to say merely is that it is increasingly irrational to expect 1.25*X (or more) from switching as the value that you find in your envelope increases to ever lumpier sums.
    Michael July 29, 2018 at 10:20 ¶ #201139
    Quoting Pierre-Normand
    I am fine with acknowledging that there isn't any such thing as the rational decision to make in the vaguely specified case where you merely have a reasonable expectation that the amount of money can't be infinitely large but you don't have any precise idea how very high the distribution might be tailing off.


    But this just seems to be saying that there's no reason to believe that it's more likely that the other envelope contains the smaller amount and no reason to believe that it's more likely that the other envelope contains the larger amount and so you're effectively treating each as equally likely, in which case it would be rational to switch.
    Michael July 29, 2018 at 10:24 ¶ #201140
    So my takeaway is that if it isn't rational to stick then it's rational to switch. There's no middle ground where it's either/or.
    Pierre-Normand July 29, 2018 at 10:27 ¶ #201141
    Quoting Michael
    But this just seems to be saying that there's no reason to believe that it's more likely that the other envelope contains the smaller amount and no reason to believe that it's more likely that the other envelope contains the larger amount and so you're effectively treating each case as equally likely, in which case it would be rational to switch.


    Yes, that is roughly true for some mid-range values of X. See the second paragraph of my edited post for more discussion about real cases.
    Pierre-Normand July 29, 2018 at 10:32 ¶ #201142
    Quoting Michael
    So my takeaway is that if it isn't rational to stick then it's rational to switch.


    Sure, but it is one thing to say that it is rational (or isn't irrational) to switch when you find X in your envelope ($10,000 say) and it is another to say that it is rational to behave, whatever your personal utility curve might be, as if the expected value(*) from switching always is exactly $12,500. That is rationally unjustified.

    (*) I mean expected value in the technical sense, as the long term expected average of the individual pay offs.
    Michael July 29, 2018 at 10:40 ¶ #201143
    Quoting Pierre-Normand
    Suppose for instance that tomorrow morning you are being called to play this game with real money in the context of some scientific experiment conducted by the psychology department of your local university. You are to play only once and keep the money. Suppose you open your envelope and find $96 in it. Is it rational to expect 1.25*$96 from switching? I am not committed to saying this. What I am committed to say merely is that it is increasingly irrational to expect 1.25*X (or more) from switching as the value that you find in your envelope increases to ever lumpier sums.


    Sure, the practical limitations of real life play a role, but I wonder if such limitations go against the spirit of the problem. What if instead of money it's points, and the goal of the game is to earn the most points? There isn't really a limitation, except as to what can be written on paper, but with such things as Knuth's up-arrow notation, unfathomably large numbers like Graham's number aren't a problem.
    Pierre-Normand July 29, 2018 at 10:49 ¶ #201144
    Quoting Michael
    Sure, the practical limitations of real life play a role, but I wonder if such limitations go against the spirit of the problem. What if instead of money it's points, and the goal of the game is to earn the most points? There isn't really a limit, except as to what can be written on paper, but with such things as Knuth's up-arrow notation, unfathomably large numbers like Graham's number aren't a problem.


    The practical limitations indeed go against the spirit of the idealized two-envelopes problem. That's because if the prior distribution is bounded, albeit unknown, then the paradox doesn't arise. The average raised expectation for the unconditional always-switch strategy, always is zero. In order that the expectation be exactly 1.25X, whatever X, and therefore also, the always-switch strategy superior to the always-stick strategy, then there ought to be no bound to the prior distribution of possible envelope values, not just an unfathomably large albeit finite bound such a Graham's number. If the upper bound is Graham's number, then the average raised expectation from the always-switch strategy still is exactly zero.
    Michael July 29, 2018 at 11:00 ¶ #201146
    Quoting Pierre-Normand
    The average raised expectation for the unconditional always-switch strategy, always is zero. In order that the expectation be exactly 1.25X, whatever X, and therefore also, the always-switch strategy superior to the always-stick strategy, then there ought to be no bound to the prior distribution of possible envelope values, not just an unfathomably large albeit finite bound such a Graham's number. If the upper bound is Graham's number, then the average raised expectation from the always-switch strategy still is exactly zero.


    I thought we were talking about the rational decision for a single play of the game, not the payout for always-switch and always-stick strategies for repeated games?

    My argument is that given how arbitrarily large the numbers in the envelopes can be (using points rather than money), there isn't really a number at which one would consider it more likely that your envelope has the larger value. If my envelope is 10 then it's rational to switch. If it's 1,000 then it's rational too switch. If it's 10[sup]100[/sup] then it's rational to switch.
    Pierre-Normand July 29, 2018 at 11:14 ¶ #201147
    Quoting Michael
    My argument is that given how arbitrarily large the numbers in the envelopes can be (using points rather than money), there isn't really a point at which one would consider it more likely that your envelope has the larger value. If my envelope is 10 then it's rational to switch. If it's 1,000 then it's rational too switch. If it's 10100 then it's rational to switch.


    If the distribution is somewhat uniform with an unfathomably large (albeit finite) upper bound, and you know this, then you can't generally expect to get such puny values. If you do, conditionally on that, then for sure, you ought to switch, and your expectation will be close to or exactly 1.25X. But what are you rationally to do when you get "average" values from the distribution, which are unfathomably large? Is it still rational to switch? On what ground? There will be no reason then to ground your decision of an (average) expectation of 1.25X. The average expectation from switching still will be zero.

    Suppose the expectation is (close to) 1.25X for purpose of reductio. You are being dealt some unfathomably large amount X which is typical from the actual distribution. We suppose that you are generally warranted to switch on the basis of the principle of indifference, and thus the expectation that switching yields the expected value of (roughly) 1.25X. After you've switched, but before you are permitted to look at the content of the second envelope, you are being given to opportunity to switch back. Is it rational for you to switch back? By the very same argument that justified your initial switch, you should deduce that the expectation for switching back is roughly 1.25Y, where Y is the content of the second envelope. But that's an inconsistency.
    Michael July 29, 2018 at 11:16 ¶ #201148
    Quoting Pierre-Normand
    But what are you rationally to do when you get "average" values from the distribution, which are unfathomably large?


    I have no way of knowing that my value is "average". Perhaps the 10[sup]100[/sup] in my envelope is a puny value because the upper bound is Graham's number.
    Pierre-Normand July 29, 2018 at 11:21 ¶ #201149
    Quoting Michael
    I have no way of knowing that my value is "average". Perhaps the 10^100 in my envelope is a puny value because the upper bound is Graham's number.


    Sure, you will never know for sure that the value that you get is close to the top of the distribution. But the main point is that you will have no reason to apply the principle of indifference to justify your switching decision on the basis an expected gain of 1.25X. If you were so justified, then you would be equally justified to switch back, on the ground of the very same argument, before you even looked into the second envelope. That's a reductio of the claim that the expectation of switching is 1.25X.
    Michael July 29, 2018 at 11:28 ¶ #201151
    Quoting Pierre-Normand
    Suppose the expectation is (close to) 1.25X for purpose of reductio. You are being dealt some unfathomably large amount X which is typical from the actual distribution. We suppose that you are generally warranted to switch on the basis of the principle of indifference, and thus the expectation that switching yields the expected value of (roughly) 1.25X. After you've switched, but before you are permitted to look at the content of the second envelope, you are being given to opportunity to switch back. Is it rational for you to switch back? By the very same argument that justified your initial switch, you should deduce that the expectation for switching back is roughly 1.25Y, where Y is the content of the second envelope. But that's an inconsistency.


    If I know there's £10 in my envelope then the expected value for switching is £12.50, and the expected value for switching back is £10.
    fdrake July 29, 2018 at 11:37 ¶ #201154
    When looking at a scenario with randomness in it, it's quite interesting to look at what sources of randomness there are and how they interact.

    (1) In Michael's analysis, the only thing random is the value in the other envelope. The sample space of the random variable is {X/2,2X}

    (2) In every analysis which deals with many possible values for what is contained in an envelope, the amount for one envelope is random, then it is random whether that envelope is X or 2X. The sample space for X is (0,infinity).

    (3) In Jeramiah's analysis, the random thing is which envelope contains which amount. The sample space is {X,2X}.

    (4) In my analysis, which pair of envelopes consistent with an amount U was random, then whether the envelope was U=X or U = 2X was random. The sample space for the first distribution was { {X,2X}, {X,X/2}} and the sample spaces for the conditional distributions were {X,2X} and {X/2,X}.

    These analyses are related through some conditioning operations. In principle, any distribution on the value of X as in (2) can be conditioned upon. This yields case (1) if what Michael is doing with the sample spaces is vindicated or case (3) or (4) if it is not.

    Analysing whether to switch or not comes down to questions on what distribution to consider. This distribution can be different from the one considered in cases (1)->(4).

    In case (1), Michael believes P(X|U=10) distributes evenly over his sample space. In case (2) as far as the thread is considered a diffuse uniform distribution is placed on (0,M) where M is large or the flat prior (y=1) is placed on (0,infinity); this translates to (something like) an equiprobability assumption on the possible values of X - this can be combined with an equiprobability assumption on which envelope the person receives to (wrongly) achieve (1) or to achieve (4) by conditioning. In case (3) an equiprobability assumption is used on which envelope the person receives but not on which set of envelopes the person receives. The conditional distributions for scenario (4) given {X,X/2} or {X,2X} are equivalent to those considered by Jeramiah in case (3).

    The choice to switch in case (2) makes the choice based on an intuition of P(received amount is the smaller value) where the amounts are uniformly distributed in [0,M]; for sufficiently large M this suggests a switch. The choices in (1),(3),(4) instead base the decision on the probability of envelope reception. (1), (3) and (4) are fully consistent with (2) so long as the appropriate P(received amount is smaller value||specific envelope amount) (envelope reception distribution) is considered rather than P(received amount is the smaller value) (amount specification distribution).

    There aren't just disagreements on on how to model the scenario, there are disagreements on where the relevant sources of randomness or uncertainty are. The fundamental questions distinguishing approaches detailed in this thread are (A) where does the randomness come from in this scenario? and (B) what model is appropriate for that randomness?

    Pierre-Normand July 29, 2018 at 11:55 ¶ #201155
    Quoting Michael
    If there's £10 in my envelope then the expected value for switching is £12.50, and the expected value for switching back is £10.


    That's only true if £10 isn't at the top of the distribution. When the bounded and uniform distribution for single envelope contents is for instance (£10, £5, £2.5, £1.25 ...) then the expected value for switching from £10 (which is also a unique outcome) is minus £5 and, when it occurs, it tends to wipe out all of the gains that you made when you switched from smaller amounts. Even if you play the game only once, this mere possibility also nullifies your expected gain. Assuming your goal merely is to maximise your expected value, you have not reason to favor switching over sticking.
    Michael July 29, 2018 at 11:57 ¶ #201156
    Quoting Pierre-Normand
    That's only true if £10 isn't at the top of the distribution. When the distribution for single envelope contents is for instance (£10, £5, £2.5, £1.25 ...) then the expected value for switching from £10 (which is also a unique outcome) is minus £5 and, when it occurs, it tends to wipe out all of the gains that you made when you switched from smaller amounts. Even if you play the game only once, this mere possibility also nullifies your expected gain.


    There's also the possibility that £10 is the bottom of the distribution, in which case the expected value for switching is £20.

    Quoting Pierre-Normand
    Assuming your goal merely is to maximise your expected value, you have not reason to favor switching over sticking.


    Which, as I said before, is equivalent to treating it as equally likely that the other envelope contains the smaller amount as the larger amount, and so it is rational to switch.
    Michael July 29, 2018 at 11:59 ¶ #201157
    If there is no reason to favour sticking then ipso facto there is reason to favour switching.
    Pierre-Normand July 29, 2018 at 12:16 ¶ #201158
    Quoting Michael
    There's also the possibility that £10 is the bottom of the distribution, in which case the expected value for switching is £20.


    Sure. We can consider a distribution that is bounded on both sides, such as (£10,£20,£40,£80), with envelope pairs equally distributed between ((£10,£20),(£20,£40),(£40,£80)).

    The issue is this: are you prepared to apply the principle of indifference, and hence to rely on an expected value of 1.25X, for switching for any value in the (£10,£20,£40,£80) range? In the case where you switch from £10, you will have underestimated your conditional expected gain by half. In the cases where you switch from either £20 or £40, your expectations will match reality. In the case where you switch from £80 then your expected loss will be twice as large as the gain that you expected. The average of the expected gains for all the possible cases still will be zero.

    Assuming your goal merely is to maximise your expected value, you have not reason to favor switching over sticking.
    — Pierre-Normand

    Which, as I said before, is equivalent to treating it as equally likely that the other envelope contains the smaller amount as the larger amount, and so it is rational to switch.


    It is not rational since you are ignoring the errors that you are making when the envelope contents are situated at both ends of the distribution, and the expected loss at the top wipes out all of the expected gains from the bottom and the middle of the distribution. When this is accounted for, the principle of indifference only tells you that while it is most likely that your expected gain is 1.25X, and it might occasionally be 2X, in the cases where it is 0.5X, the loss is so large that, on average, you expected gain from switching still remains exactly X.
    Michael July 29, 2018 at 12:27 ¶ #201160
    Quoting Pierre-Normand
    The issue is this: are you prepared to apply the principle of indifference, and hence to rely on an expected value of 1.25X, for switching for any value in the (£10,£20,£40,£80) range?


    If I don't know the distribution, then yes. For all I know, the distribution could be (£10,£20,£40,£80,£160).

    Quoting Pierre-Normand
    It is not rational since you are ignoring the errors that you are making when the envelope contents are situated at both ends of the distribution, and the negative error at the top wipes out all of the expected gains from the bottom and the middle of the distribution. When this is accounted for, the principle of indifference only tells you that while it is most likely that your expected gain is 1.25X, and it might occasionally be 2X, in the cases where it is 0.5X, the loss is so large that, on average, you expected gain from switching still remains exactly X.


    But we're just talking about the rational decision for a single game. And my point remains that if I have no reason to believe that it's more likely that the other envelope contains the smaller amount than the larger amount (or vice versa) then I am effectively treating both cases as being equally likely, and if I am treating both cases as being equally likely then it is rational to switch.
    Pierre-Normand July 29, 2018 at 12:52 ¶ #201162
    Quoting Michael
    then I am effectively treating both cases as being equally likely, and if I am treating both cases as being equally likely then it is rational to switch.


    Yes, you are justified in treating the "cases" (namely, the cases of being dealt the largest or smallest envelope within the pair) as equally likely but you aren't justified in inferring that, just because the conditional expected gain most often is 1.25X, and occasionally 2X, when X is at the bottom of the range, therefore it is rational to switch rather than stick. That would only be rationally justified if there weren't unlikely cases (namely, being dealt the value at the top of the distribution) where the conditional loss from switching (0.5X) is so large as to nullify the cumulative expected gains from all the other cases.
    Michael July 29, 2018 at 12:59 ¶ #201163
    Quoting Pierre-Normand
    That would only be rationally justified if there weren't unlikely cases (namely, being dealt the value at the top of the distribution) where the conditional loss from switching (0.5X) is so large as to nullify the cumulative expected gains from all the other cases.


    But we're just talking about a single game, so whether or not there is a cumulative expected gain for this strategy is irrelevant.

    If it's more likely that the expected gain for my single game is > X than < X then it is rational to switch.

    Or if I have no reason to believe that it's more likely that the other envelope contains the smaller amount then it is rational to switch, as I am effectively treating a gain (of X) as at least as likely as a loss (of 0.5X).
    Jeremiah July 29, 2018 at 14:37 ¶ #201168
    Reply to Pierre-Normand

    You created a double standard. You can try to bury that in text, but that is what happened.
    Efram July 29, 2018 at 16:16 ¶ #201184
    Reply to Michael

    Quoting Michael
    If there is no reason to favour sticking then ipso facto there is reason to favour switching.


    I've noticed you express this sentiment a couple of times in the thread; could you elaborate further? I'm not sure how you're arriving at "A isn't favourable so B must be" - bypassing "neither A nor B is favourable."

    If I were to borrow your logic, I could say that if given the choice between being shot in the head and having my head cut off, if I conclude that there's no advantage to having my head cut off, I must surely want to be shot in the head? :p

    (Edited to actually add the quote)
    Srap Tasmaner July 29, 2018 at 16:30 ¶ #201185
    Here's the OP:

    Problem A
    1. You are given a choice between two envelopes, one worth twice the other.
    2. Having chosen and opened your envelope, you are offered the opportunity to switch.
    3. You get whichever envelope you chose last.

    Here's a slight variation on Problem A:

    Problem B
    1. You are given a choice between two envelopes, one worth twice the other.
    1.5 Having chosen but before opening your envelope, you are offered the opportunity to switch.
    2. Having chosen and opened your envelope, you are offered the opportunity to switch.
    3. You get whichever envelope you chose last.

    Here's a slight variation on Problem B:

    Problem C
    1. You are given a choice between two envelopes, one worth twice the other.
    1.25 Having chosen but before the envelope being designated "yours" for the next step, you are offered the opportunity to switch.
    1.5 Having chosen but before opening your envelope, you are offered the opportunity to switch.
    2. Having chosen and opened your envelope, you are offered the opportunity to switch.
    3. You get whichever envelope you chose last.

    And we can keep going. Wherever you have been offered the opportunity to switch, we can add a step in which you are offered the opportunity to switch back before moving on to the next step. The number of steps between being offered the first choice and getting the contents of (or receiving a score based on) your last choice can be multiplied without end. At some points, there may be a change in labeling the envelopes (now we call this one "your envelope" and that one "the other envelope"); and at one point, you are allowed to learn the contents of an envelope.

    Suppose you wanted to make a decision tree for the OP, Problem A. You'd have to label things somehow to get started.
    User image
    How to label the nodes after the first choice? We could switch to "YOURS" and "OTHER"; later, once a value has been observed, we could switch to, say, "Y ? {a}" and "U ? {a/2, 2a}" for labels.

    But of course all we're doing is relabeling. This is in fact only a "tree" in a charitable sense. There is one decision, labeled here as a choice between "LEFT" and "RIGHT", and there are never any new decisions after that -- no envelopes added or removed, for instance -- and each step, however described, is just the same choice between "LEFT" and "RIGHT" repeated with new labels. You can add as many steps and as many new labels between the first choice and the last as you like, but there is really only one branching point and two possibilities; it is the same choice between the same two envelopes, at the end as it was at the beginning.
    Michael July 29, 2018 at 16:32 ¶ #201186
    Quoting Efram
    I've noticed you express this sentiment a couple of times in the thread; could you elaborate further? I'm not sure how you're arriving at "A isn't favourable so B must be" - bypassing "neither A nor B is favourable."

    If I were to borrow your logic, I could say that if given the choice between being shot in the head and having my head cut off, if I conclude that there's no advantage to having my head cut off, I must surely want to be shot in the head?


    Say you have £10 in your envelope. If the other envelope contains the larger amount then it contains £20 and if it contains the smaller amount then it contains £5. If it is equally likely to contain the larger amount as the smaller amount then the expected value for switching is £12.50, and so it is rational to switch.

    If you have no reason to believe that it is more likely to contain the smaller amount and no reason to believe that it is more likely to contain the larger amount, then you are effectively applying the principle of indifference, and treating it as equally likely to contain the larger amount as the smaller amount (which is why some are saying that it doesn't matter if you stick or switch). But given the above, if you are treating each outcome as equally likely then you are treating the expected value of the other envelope to be £12.50, and so it is rational to switch.

    For it to be the case that the rational decision is indifference you need to calculate a 2/3 chance that the other envelope contains the smaller amount and a 1/3 chance that the other envelope contains the larger amount. But you can't do that if the only information you have is that your envelope contains £10 and that one envelope contains twice as much as the other.
    JeffJo July 29, 2018 at 16:41 ¶ #201187
    Quoting Michael
    I'm not really sure that this addresses my main question. ... There's a 50% chance of picking the lower-value envelope, and so after having picked an envelope it's in an "unknown state" that has a 50% chance of being either the lower- or the higher-value envelope?

    When all you consider is the relative chances of "low" compared to "high," this is true. When you also consider a value v, you need to use the relative chances of "v is the lower value" compared to "v is the higher value." This requires you to know the distribution of possible values in the envelopes. Since the OP doesn't provide this information, you can't use your solution. and no matter how strongly you feel that there must be a way to get around this, you can't.

    +++++
    Let's step back, and try to establish this in a simpler way. Compare these two solutions:

    1. Say your envelope contains v.
      • There is a 50% chance that the other envelope contains v/2.
      • There is a 50% chance that the other envelope contains 2v.
      • The expected value of the other envelope is (v/2)/2 + (2v)/2 = 5v/4.
      • So switching has an expected gain of 5v/4 - v = v/4.
  • Say the total amount of money in the two envelopes is t.[list]
  • There is a 50% chance that your envelope contains t/3, and the other contains 2t/3.
  • There is a 50% chance that your envelope contains 2t/3, and the other contains t/3.
  • The expected value of your envelope is (t/3)/2 + (2t/3)/2 = t/2.
  • The expected value of the other envelope is (2t/3)/2 + (t/3)/2 = t/2.
  • So switching has an expected gain of t/2 - t/2 = 0.

  • [/list]

    The only difference in the theory behind these two solutions, is that #1 uses an approach that implies different sets of values in the two envelopes, where #2 uses an approach that implies the same set of values.

    The property of probability that you keep trying to define, is that this difference shouldn't matter. But the paradox established in those two solutions proves that it does.
    JeffJo July 29, 2018 at 17:00 ¶ #201189
    Quoting Jeremiah
    Statistics is a data science and uses repeated random events to make inference about an unknown distribution. We don't have repeated random events, we have one event. Seems like a clear divide to me. You can't learn much of anything about an unknown distribution with just one event.

    Statistics uses repeated observations of outcomes from a defined sample space, to make inference about the probability space associated with that sample space.

    In the OP, we don't have an observation. Not even "one event," if that term were correct to use in your context. Which it isn't.

    With one exception, this is why every time you have used words like "statistics" or "statistical" in this thread (which is what I mean by "advocating" it; I know you never advocated it as a solution method, but you did advocate associating the word with distributions in the discussion) has been incorrect.

    The exception is that you can use statistics to verify that your simulation correctly models a proven result. The repeated observations are the results of a single run of the simulation.
    Why you think you should do that is beyond me, but apparently you did.

    The OP deals with a conceptual probability problem. There is no no observational data possible. "Statistics" does not belong in any discussion about it. Nor does "Bayesian," "Frequentist," "objective," "subjective," "inference," and many others.
    Jeremiah July 29, 2018 at 17:33 ¶ #201193
    Quoting JeffJo
    Statistics uses repeated observations of outcomes from a defined sample space, to make inference about the probability space associated with that sample space.


    I just said that. That is exactly what I said.

    Quoting JeffJo
    Not even "one event," if that term were correct to use in your context.


    I already posted the definition of an event from one of my books, which I will refer to over you. I will always go with my training over you.

    Quoting JeffJo
    The OP deals with a conceptual probability problem. There is no no observational data possible. "Statistics" does not belong in any discussion about it.


    I also said that.


    One thing I was taught in my first stats class was that the lexicon was not standardized. They told me to expect different people to use different terminology. I think perhaps you should take a page from that book. In the meantime, in my personal usage, I am sticking with the terminology in my books, no matter how much you protest.
    Jeremiah July 29, 2018 at 17:40 ¶ #201195
    Reply to fdrake

    I noted towards the start of the thread that this had more to with defining the sample space. Calculating expected returns is a futile effort if we cannot agree on the underlying assumptions. The natural device for such a situation would be the Law of Parsimony, but I can't really say my approach makes fewer assumptions than Michael's. I do think, however, Occam's razor does cut additional assumptions about the distribution.
    Michael July 29, 2018 at 18:26 ¶ #201197
    Quoting JeffJo
    The only difference in the theory behind these two solutions, is that #1 uses an approach that implies different sets of values in the two envelopes, where #2 uses an approach that implies the same set of values.


    The other way to phrase the difference is that my solution uses the same value for the chosen envelope (10) and your solution uses different values for the chosen envelope (sometimes 10 and sometimes 20 (or 5)).

    But I’m asking for the rational choice given that there’s 10 in the chosen envelope. It doesn’t make sense to consider those situations where the chosen envelope doesn’t contain 10.

    We should treat what we know as a constant and what we don’t know as a variable. In this case, what we know is that there’s 10 in our envelope and what we don’t know is the value of the envelope that doesn’t contain 10. We consider all the possible worlds where the chosen envelope contains 10, assign them a probability, and then calculate the expected value. And I think that in lieu of evidence to the contrary it is rational to treat them as equally probable.
    JeffJo July 29, 2018 at 19:19 ¶ #201206
    Quoting Jeremiah
    Statistics uses repeated observations of outcomes from a defined sample space, to make inference about the probability space associated with that sample space. — JeffJo

    I just said that. That is exactly what I said.


    What you said was: "... uses repeated random events to make inference about an unknown distribution." Since an event is a set of possible outcomes, and you used the word to mean an experimental result, what you said had no meaning. The point is that it refers to a probability space itself, and not the actions that produce a result described by such a space.

    Since this difference is critical to identifying the misinformation you have been spouting, I corrected it to what you thought you meant. Using correct terminology in place of your incorrect terminology. Which would not have been necessary if what you said meant exactly what I wrote.

    What you refuse to understand, is that it is this misuse of terminology that I've been criticizing. Not your solution, which I have repeatedly said was correct.

    I already posted the definition of an event from one of my books, which I will refer to you over. I will always go with my training over you.

    You may well have. If you did, I accepted it as correct and have forgotten it. If you want to debate what it means, and why that isn't what you said above, "refer it to me over" again. Whatever that means.

    But first, I suggest you read it, and try to understand why it was the wrong word to use in your sentence above.

    One thing I was taught in my first stats class was that the lexicon was not standardized.

    Maybe true in some cases. But "event" is not one of them. Look it up again, and compare it to what I said.

    The first ones I found in a google search (plus one I trust) were:

    • Wikipedia: "an event is a set of outcomes of an experiment (a subset of the sample space) to which a probability is assigned."
    • mathisfun.com: When we say "Event" we mean one (or more) outcomes.
    • icoashmath.com: "An Event is a one or more outcome of an experiment."
    • ucdavis.edu: An event is a specific collection of sample points.
    • intmath.com: Event: This is a subset of the sample space of an experiment.
    • statisticshowto.com: An event is just a set of outcomes of an experiment
    • faculty.math.illinois.edu: any subset E of the sample space S is called an event.
    • mathworld.wolfram.com: An event is a certain subset of a probability space. Events are therefore collections of outcomes on which probabilities have been assigned.

    None of these refer to an event as an actual instance of the process. It is always a way to describe the potential results, if you were to run it. As a potential result, there is no way to apply "repeat" to it.

    JeffJo July 29, 2018 at 19:32 ¶ #201208
    Quoting Michael
    The other way to phrase the difference is that my solution uses the same value for the chosen envelope


    But your expectation uses the value in the other envelope, so this is an incomplete phrasing. That's why it is wrong.

    It doesn’t make sense to consider those situations where the chosen envelope doesn’t contain 10.

    And you are ignoring my comparison of two different ways we can know something about the values.

    Again: if it is valid to use a method that considers one value only, while ignoring how that one value restricts the pair of values, then it is valid to use that method on either the value v in your envelope, or the value t of the total in both.That means that they both should get the same answer.

    They don't. So it isn't valid. If you want to debate this further, find what is wrong with the solution using "t".

    We should treat what we know as a constant and what we don’t know as a variable.

    True. But when that variable is a random variable, we must consider the probability that the variable has the value we are using, at each point where we use one.
    Jeremiah July 29, 2018 at 19:36 ¶ #201209
    Reply to JeffJo I don't really think you know what I said. If you need clarification just ask [remainder of post removed by mod].
    Pierre-Normand July 29, 2018 at 21:40 ¶ #201232
    Quoting Michael
    The other way to phrase the difference is that my solution uses the same value for the chosen envelope (10) and your solution uses different values for the chosen envelope (sometimes 10 and sometimes 20 (or 5)).


    There is another difference between the two methods @JeffJo presented, as both of them would be applied to the determinate value that is being observed in your envelope. The first one only is valid when we dismiss the known fact, in the case where the distribution is merely known to be bounded above (even though the upper bound is unknown), that the loss incurred from switching when the value v happens to be at the top of the distribution cancels out the expected gains from switching when the value v isn't at the top of the distribution. The second method doesn't make this false assumption and hence is valid for all bounded distributions.
    Pierre-Normand July 29, 2018 at 21:59 ¶ #201238
    Quoting Michael
    But we're just talking about a single game, so whether or not there is a cumulative expected gain for this strategy is irrelevant.


    Unless we are considering that the player's preference is being accurately modeled by some non-linear utility curve, as @andrewk earlier discussed, then the task simply is to choose between either sticking or switching as a means to maximizing one's expected value. It's irrelevant that the game is being played once rather than twice, or ten, or infinitely many times. If a lottery ticket costs more than the sum total of the possible winnings weighed by their probabilities, then it's not worth buying such a ticket even only once.

    If it's more likely that the expected gain for my single game is > X than < X then it is rational to switch.


    By that argument, it would be irrational to purchase a $1 lottery ticket that gives you a 1/3 chance to win one million dollars since it is more likely that you will lose $1 (two chances in three) than it is that you will gain $999999. Or, maybe, you believe that it is only irrational to buy such a ticket in the case where you can only play this game once?

    Or if I have no reason to believe that it's more likely that the other envelope contains the smaller amount then it is rational to switch, as I am effectively treating a gain (of X) as at least as likely as a loss (of 0.5X).


    Sure, and in some cases, when your value v=X happens to be at the top of the distribution, you are making an improbable mistake that will lead you to incur a big loss. You are arguing that you can "effectively" disregard the size of this improbable potential loss on the ground that you only are playing the game once; just like, in the lottery case, presumably, you should entirely disregards the size of the improbable jackpot if your argument were sound.
    Michael July 29, 2018 at 22:10 ¶ #201240
    Quoting Pierre-Normand
    By that argument, it would be irrational to purchase for $1 a lottery ticket that gives you a 1/3 chance to win one million dollars since it is more likely that you will lose $1 (two chances in three) than it is that you will gain $999999.


    No, because the expected gain is $333,334, which is more than my $1 bet (333,334X), and so it is rational to play.
    Pierre-Normand July 29, 2018 at 22:14 ¶ #201241
    Quoting Michael
    No, because the expected gain is $333,334, which is more than my 333,334X.


    But then, if you agree not to disregard the amount of the improbable jackpot while calculating the expected value of the lottery ticket purchase, then, likewise, you can't disregard the improbable loss incurred in the case where v is it a the top of the bounded distribution while calculating the expected value of the switching decision.
    Srap Tasmaner July 29, 2018 at 22:14 ¶ #201243
    Here's a reasonable way to fill out the rest of the decision tree.
    User image

    Either you observed value a, and then you stand to gain a by switching, or you observed b, and you stand to lose b/2 by switching.

    If you chose the X envelope, and observed its value, you stand to gain X by switching; if you chose the 2X envelope, and observed its value, you stand to lose X by switching.
    Michael July 29, 2018 at 22:15 ¶ #201244
    Quoting Pierre-Normand
    But then, if you agree not to disregard the amount of the improbable jackpot while calculating the expected value of the lottery ticket purchase, then, likewise, you can't disregard the improbable loss incurred in the case where v is it the top of the bounded distribution while calculating the expected value of the switching decision.


    But I don't know if my envelope contains the upper bound. Why would I play as if it is, if I have no reason to believe so?
    Pierre-Normand July 29, 2018 at 22:22 ¶ #201246
    Quoting Michael
    But I don't know if my envelope contains the upper bound. Why would I play as if it is, if I have no reason to believe so?


    Which is why you have no reason to switch, or not to switch. It may be that your value v is at the top of the distribution, or that it isn't. The only thing that you can deduce for certain, provided only that the distribution is bounded, if you are entirely ignorant of the probability that v might be at the top of the distribution, is that, whatever this probability might be, it always is such that the average expected values of switching, conditional on having been dealt some random envelope from the distribution, is the same as the average expected value of sticking. Sure, most of the time, the conditional expected value will be 1.25v. But some of the times it will be 0.5v.
    Michael July 29, 2018 at 22:31 ¶ #201249
    Quoting Pierre-Normand
    Sure, most of the time, the conditional expected value will be 1.25v. But some of the times it will be 0.5v.


    And some of the time it will be 2v, because it could also be the lower bound. So given that v = 10, the expected value is one of 20, 12.5, or 5. We can be indifferent about this too, in which case we have 1/3 * 20 + 1/3 * 12.5 + 1/3 * 5 = 12.5.
    Pierre-Normand July 29, 2018 at 22:40 ¶ #201254
    Quoting Michael
    And some of the time it will be 2v, because it could also be the lower bound. So given that v = 10, the expected value is one of 20, 12.5, or 5. We can be indifferent about this too, in which case we have 1/3 * 20 + 1/3 * 12.5 + 1/3 * 5 = 12.5.


    No. The conditional expected values of switching conditional on v = 10, and conditional on 10 being either at the top, bottom or middle of the distribution aren't merely such that we are indifferent between the three of them. They have known dependency relations between them. Although we don't know what those three possible conditional expected values are, for some given v (such as v = 10), we nevertheless know that, on average, for all the possible value of v in the bounded distribution, the weighted sum of the three of them is v rather than 1.25v.
    Michael July 29, 2018 at 22:57 ¶ #201257
    Quoting Pierre-Normand
    we nevertheless know that, on average, for all the possible value of v in the bounded distribution, their weighted sum is zero rather than 1.25v.


    This still looks like you're considering what would happen if we always stick or always switch over a number of repeated games. I'm just talking about playing one game. There's £10 in my envelope. If it's the lower bound then I'm guaranteed to gain £10 by switching. If it's the upper bound then I'm guaranteed to lose £5 by switching. If it's in the middle then there's an expected gain of £2.50 for switching. I don't know the distribution and so I treat each case as equally likely, as per the principle of indifference. There's an expected gain of £2.50 for switching, and so it is rational to switch.

    If we then play repeated games then I can use the information from each game to switch conditionally, as per this strategy (or in R), to realize the .25 gain over the never-switcher.
    Srap Tasmaner July 30, 2018 at 00:06 ¶ #201271
    There is a 50% chance that you observed a, because you chose and opened the X envelope; there is a 50% chance that you observed b, because you chose and opened the 2X envelope. The expected value of switching is:

    E = a/2 - b/4

    and since 2a = b
    E = a/2 - a/2 = b/4 - b/4 = 0.
    Pierre-Normand July 30, 2018 at 00:18 ¶ #201272
    Quoting Michael
    This still looks like you're considering what would happen if we always stick or always switch over a number of repeated games. I'm just talking about playing one game. There's £10 in my envelope. If it's the lower bound then I'm guaranteed to gain £10 by switching. If it's the upper bound then I'm guaranteed to lose £5 by switching. If it's in the middle then there's an expected gain of £2.50 for switching. I don't know the distribution and so I treat each case as equally likely, as per the principle of indifference. There's an expected gain of £2.50 for switching, and so it is rational to switch.


    This works if you are treating all the possible lower and upper bounds of the initial distribution as being equally likely, which is effectively the same as assuming a game where the distribution is uniform and unbounded. In that case, your expected value for switching is indeed 1.25 * v, conditionally on whatever value v you have found in your envelope, because there is no upper bound to the distribution. The paradox arises.

    If we then play repeated games then I can use the information from each subsequent game and switch conditionally, as per this strategy (or in R), to realize the .25 gain.


    If there is an upper bound M to the distribution, and you are allowed to play the game repeatedly, then you will eventually realize that the losses incurred whenever you switch after being initially dealt the maximum value M tend to wipe out your cumulative gains from the other situations. If you play the game x times, then your cumulative gain (which will tends towards zero) will tend, as x grows larger, towards being x times the average expected value of the gains for switching while playing the game only once. This average expected value will therefore also be zero. To repeat, conditionally on where v is situated in the bounded distribution, the expected value of switching could be either one of 2*v, 1.25*v or 0.5*v. On average, it will be v.
    Srap Tasmaner July 30, 2018 at 00:36 ¶ #201274
    The fallacious premise of the switching argument is that you could observe a given value, whichever envelope you chose and opened. If the envelopes are {5, 10}, you cannot observe 10 by selecting the smaller envelope; if the envelopes are {10, 20}, you cannot observe 10 by selecting the larger envelope. For each round of the game: X has a single value; there is a single pair of envelopes offered; they are valued at X and 2X; when you select an envelope, you select one valued at X or at 2X.
    Andrew M July 30, 2018 at 04:48 ¶ #201318
    Quoting Michael
    This still looks like you're considering what would happen if we always stick or always switch over a number of repeated games. I'm just talking about playing one game.


    You seem to be saying that with an unknown distribution, there is an expected gain from switching for one game even though over repeated games (with an unknown distribution) there isn't.

    For one game, would you be willing to pay up to 1.25 times the amount in the chosen envelope to switch (say, 1.2 times the amount)?

    Quoting Michael
    If it's in the middle then there's an expected gain of £2.50 for switching


    There is with that distribution but not the {{5,10},{5,10},{5,10},{5,10},{10,20}} distribution. In this case, there is an expected loss of $2 for switching from $10.

    Without knowing the distribution, the player only knows that the unconditional expected gain is zero (i.e., the sum of the expected gains for each possible amount weighted against their probability of being observed). With the above distribution, that is (4 * $5 + 5 * -$2 + 1 * -$10) / 10 = ($20 - $10 - $10) / 10 = $0.

    Quoting Michael
    If we then play repeated games then I can use the information from each game to switch conditionally, as per this strategy (or in R), to realize the .25 gain over the never-switcher.


    The first game does not have any information from previous games so the player should not expect a .25 gain without that information. The player should only expect a gain (or loss) from switching when they know the distribution which is what the information built up over repeated games would provide.
    JeffJo July 30, 2018 at 15:00 ¶ #201420
    Let's just look at our first interaction here:

    Quoting JeffJo
    You can't just enumerate a set of cases, and claim each is equally likely. If you could, there would be a 50% chance of winning, or losing, the lottery.


    By this, I was clearly referring to the valid discrete sample space {"Win", "Lose"}. An event space is a sigma-algebra on this set, and a valid example is {{}, {"Win"}, {"Lose"}, {"Win","Lose"}}. A probability space is the 3-tuple of those two sets and a measure space defined on the event space. By Kolmogorov's axioms, it is valid if it has the form {0,Q,1-Q,1}, where 0<=Q<=1.

    My statement above said that you can't simply apportion probability to the members of a valid sample space. It isn't that such a probability space is invalid in any way, it is because it is impractical,

    Yet you replied:
    Quoting Jeremiah
    That is a very bad understanding of what a sample space and an event is.

    Since my sample space was a perfectly valid sample space, and I never mentioned events at all, it demonstrates your "very bad understanding" of those terms. It was a very bad choice of a sample space for this problem, for the reasons I was trying to point out and stated quite clearly. But you apparently didn't read that.

    You are not applying your Principle of Indifference there,

    Actually, I was applying it. Improperly with the intent to demonstrate why its restriction is important:

    Quoting JeffJo
    The Principle of Indifference places a restriction on the possibilities that it applies to: they have to be indistinguishable except for their names. You can't just enumerate a set of cases, and claim each is equally likely.


    You went on:
    Quoting Jeremiah
    Furthermore, it makes no sense to use a probability density curve on this problem,

    I didn't say we should (A) use a probability (B) density (C) curve. I stated correctly that there (A) must be a probability (B) distribution for the (C) set of possible values, and that any expectation formula must take this distribution into account. Even if you don't know it.

    The reason your solution in post #6 turns out to be correct, is that this probability turns out to have no effect on the calculation: it divides out. That doesn't make it incorrect to use it - in fact, it is technically incorrect to not use it.
    Jeremiah July 30, 2018 at 15:31 ¶ #201430
    Reply to Srap Tasmaner

    There are some interesting aspects to note if you diagram the 1.25X argument in comparison to the other two. Which clearly shows why it is a faulty argument.

    When considering the unselected envelope under the {x,2x} sample space objectively you have one true value and one false.

    Likewise, when considering the unselected envelope under the {x/2.2x} sample space objective, you have one true value and one false.

    However, it get's different when you consider the sample space {{x/2,x},{x,2x}}. Here you have objectively one true set and one false set. If I end up in the false set then I have two statements that are false. If I end up in the true set then I have one statement that is true, which only has a 1/4 weight in my consideration when it should have a 1/2 weight. So I reduce my chance of getting the true value, meaning I inflate my possibility of error.

    Here I sketched it out by hand to show it.

    https://ibb.co/dB7BUT

    I have also been thinking about the [0,M] argument.

    One of my books makes this distinction.

    The probabilist reasons from a known population to the outcome of a single experiment, the sample. In contrast, the statistician utilizes the theory of probability to calculate the probability of an observed sample and to infer from this the characteristics of an unknown population.

    Mathematical Statistics with Applications, Wackerly, Mendenhall, Scheaffer

    I would argue that the known population are the amounts in the envelope x and 2x and the unknown population is the distribution that x was selected from.

    Baden July 30, 2018 at 18:30 ¶ #201452
    Mod note: Personal comments will continue to be removed from this discussion. Please don't give us more work to do by responding to them but report anyone who gets personal with you and we will delete the comment or part thereof.


    JeffJo July 30, 2018 at 18:33 ¶ #201453
    Quoting Jeremiah
    I already figured out that your field was not statistics,

    And it is even more obvious you want to use statistics anywhere you can, no matter how inappropriate. The lexicon of both probability and statistics is the same, since statistics uses probability. It applies it to the experimental data you keep talking about, and of which we have none.

    But if you feel I've mis-used terminology in any way, please point it out. I've pointed out plenty of yours, and you haven't refuted them.
    Srap Tasmaner July 30, 2018 at 19:13 ¶ #201462
    @Jeremiah, @JeffJo
    This pissing contest is detracting from the thread. Both of you quit it.
    Jeremiah July 30, 2018 at 20:19 ¶ #201473
    Reply to JeffJo What is the difference between experimental data and observational data?
    Jeremiah July 30, 2018 at 22:16 ¶ #201504
    Quoting JeffJo
    you haven't refuted them.


    That's because I accept that you use a different vernacular.
    Srap Tasmaner July 31, 2018 at 05:21 ¶ #201572
    What if we did say that all of the player's choices are conditional on the host's choice? That is, suppose we had X = k, where k is some unknown constant. Then, using 'c' for our observed value,

    p = P(Y=X | Y=c, X=k) = P(c=k)

    Now whatever the value k is, the only permissible values for p are 0 and 1.

    The expectation for the unpicked envelope is then

    E(U) = P(c=k)2c + P(c=2k)c/2

    Once you've observed c, you know that either c=k or c=2k, but you don't know which. That is, observing c tells you one of c=k and c=2k is true (and one false), which is more specific than just

    P(X=c | Y=c) + P(X=c/2 | Y=c) = 1
    Srap Tasmaner July 31, 2018 at 10:53 ¶ #201590
    Here's a straightforward revision of the decision tree:
    User image
    Opening an envelope "breaks the symmetry," as the kids say, so that's the point of no return. Colors represent paths you can be on for each case.

    This one also uses 'c' for both branches, which the previous tree deliberately avoided. This time the intention is that either the red or the blue branch is probability 1 and the other 0. They conflict by design.
    Jeremiah July 31, 2018 at 12:06 ¶ #201600
    Something else I would like to point out, is that assuming that the probability of any given x must come from a discrete distribution is not necessarily true. In fact I used a selection method where the actual chance mechanism was applied to a continuous distribution in this very thread.


    two.envelopes <- function(){
    x <- (runif(1))
    x <- (abs(as.numeric(format(round(x, 3)))))*10
    #randomly selects a number
    #limits the number of decimal places x can have and muiltples x by 10 to simluate realistic dollar values.
    p <- c(x,2*x)
    A <- sample(p, 1, replace=F)
    #creates a vector with x and 2x then randomly selects one for A.
    if (A == x) {
    B <- 2*x
    } else {
    (B <- x)
    }
    return(c(A,B))
    }


    I used a continuous uniform distribution to randomly selected an x then formatted it into real dollar values. Now who is to say that such a chance mechanism was not used to fill the envelopes?

    If a probabilistic approach is to reason from a known population then the known population is x or 2x. Where x came from and how it was chosen is something we don't know.
    Jeremiah July 31, 2018 at 12:32 ¶ #201602
    Also. . . ,

    Since I have already displayed in this thread that x can come from any number of continuous distributions, this means we have no clue how and from where x was selected, and if we don't know then we should apply the the principle of indifference, right? Of course there are infinite possible distributions, and one over infinity is 0.
    JeffJo July 31, 2018 at 14:46 ¶ #201637
    I apologize to this forum for allowing myself to be taken off topic by a troll.
    +++++

    The difficulty with the field of probability, is that there can be different ways to correctly address the same problem. Because there is no single sample space that describes a problem. Example:
    • Rolling two six-sided dice can use a set of 11 outcomes for the sum, a set of 21 unordered pairs of values, or a set of 36 ordered pairs.
    • Any of those can be used, but the last one allows you to easily apply the Principle of Indifference to get reasonable probabilities. This is because the PoI requires that we know the causes of the outcomes are all equivalent.


    That example doesn't mean there can't be vastly different solution methods that both get the same answer. There can. You can use a different method than I do, and get the same correct answer.

    The issues comes when two methods get different answers. If Jack says "I use method A and get answer X," while Jill says "I use method B and get answer Y," all we know for sure is that at least one is wrong. Bickering about why A is right does nothing to prove that it is, or that B is wrong.

    To resolve the issue, Jill would need to do two things: find a flaw in A, and identify how B does not make the same mistake. The Two Envelope Problem is trivial once you understand, and apply, these points.

    What is wrong with the 5/4 expectation: Any term in an expectation calculation has to be multiplied by a probability for the entirety of the event it represents.
    • A term that represents your envelope containing a value v, and the other containing v/2, must be multiplied by probability that represents your envelope containing v, and the other containing v/2.
    • A term that represents your envelope containing a value v, and the other containing 2v, must be multiplied by probability that represents your envelope containing v, and the other containing 2v.
    • If you are considering v to be a fixed value, even if that value is unknown, then those two possibilities are different outcomes, and may have different probabilities
    • Even though the chance of picking the lower or the higher is 50%, once you include a fixed value in the the entirety of the event, it can change.
    • Specifically, the unconditional probability that v is in your envelope and v/2 is in the other, is Pr(v/2,v)/2, where Pr(x,y) is the probability that the pair of envelopes were filled with x and y.
    • Similarly, the unconditional probability that v is in your envelope and 2v/is in the other, is Pr(v,2v)/2.
    • To make these conditional probabilities, you divide each by their sum.
    • This gives Pr(v/2,v)/[Pr(v/2,v)+Pr(v,2v)] and Pr(v,2v)/[Pr(v/2,v)+Pr(v,2v)], respectively.
    • Check: they add up to 1 and, if Pr(v/2,v)=Pr(v,2v), each is 50%.
    • The correct expectation by this method is v*[Pr(v/2,v)/2+2*Pr(v,2v)]/[Pr(v/2,v)+Pr(v,2v)].


    This is a correct solution, *if* you know the value in your envelope (even a fixed unknown value v), *and* you know the two probabilities involved (which is much more difficult if v is unknown). For most conceivable distributions, there are even values of v where this correct solution produces a gain.

    But the sticky issues of what the probabilities are is a big one. We can't use the PoI because the requirements I mentioned above are not met. If the supply of money is finite, then there must be some values of v where there is an expected loss, and the expected gain over the entire distribution of v will turn out to be 0.

    The 5v/4 expectation applies this method, but ignores the required terms Pr(v/2,v) and Pr(v,2v). That is its mistake. It would be right if you know, or could assume, these terms are equal. In the OP, we can't assume anything about the distribution, rendering this method useless.

    What is right with my calculation: Say the total in the two envelopes is t. Then one contains t/3, and the other contains 2t/3.
    • The unconditional probability that your envelope contains t/3 is Pr(t/3,2t/3)/2. Notice that this is the exact same formula as before, with the modified values.
    • The unconditional probability that your envelope contains 2t/3 is Pr(t/3,2t/3)/2.
    • To make these conditional probabilities, you divide each by their sum.
    • Since they are the same, this gives 50% each.
    • The expectation is (t/3)/2 + (-t/3)/2 = 0.
    • Even though we wound up not needing Pr(t/3,2t/3), including it made this solution more robust.


    This method is robustly correct. Even though it uses a similar outline to the previous one, it applies to the general problem when you don't know t. Because the unknown probability divides out. And, it gives the intuitive result that switching shouldn't matter. Its only flaw, if you want to call it that, is that it does not apply if you know what is in your envelope - then you need to consider different t's.
    Jeremiah July 31, 2018 at 14:49 ¶ #201638
    Calling me a troll is a personal attack.
    Baden July 31, 2018 at 15:00 ¶ #201640
    Reply to Jeremiah

    You've called yourself a troll several times (posts which I've had to waste time deleting and furthermore trolling is against the rules). Stop this now.
    JeffJo July 31, 2018 at 15:07 ¶ #201642
    There is an interesting distribution proposed at https://en.wikipedia.org/wiki/Two_envelopes_problem#Second_mathematical_variant. Note that, like all distributions discussed so far in this thread, it is a discrete distribution and not a continuous one. Continuous distributions tend to be messy, and not very realistic.

    The envelopes are filled with ($1,$2) with probability 1/3, ($2,$4) with probability 2/9, ($4,$8) with probability 4/27, etc. Unless your envelope has $1, in which case your gain is $1, the expected value of the other envelope always 10% more than yours. But before you get too excited:

    • You can't apply my first method above to switching back.
    • Even though the expected value is at least (remember the $1 envelope?) 110% of yours, method #2 above is still correct. If you don't consider the value v in yours, the expected value of the two envelopes is the same.
    • It is left as an exercise for the reader to determine how the expected value of the other is 110% your value, but the two expected values are the same.
    Srap Tasmaner July 31, 2018 at 20:32 ¶ #201688
    Reply to JeffJo
    My current, and I think "final", position is that this isn't really a probability puzzle at all. Here are my arguments for my view and against yours.

    1. The only probability anyone has ever managed to assign any value to is the probability of choosing the larger (or the smaller) envelope -- and even that is only the simplest noninformative prior.
    2. All other probabilities used in solutions such as yours are introduced only to immediately say that we do not and cannot know what their values are.
    3. The same is true for the sample space for X. Many have been used in examples and solutions but always with the caveat that we do not and cannot know what the sample space for X is.
    4. Much less the PDF on that space.
    5. By the time the player chooses, a value for X has been determined. Whatever happened before that is unknown, unknowable, and therefore irrelevant. As far the player is concerned, the PDF that matters assigns a value of 1 to some unknown value of X and 0 to everything else.
    6. We might also describe that as the host's choice of a value for X. Whatever the host had to choose from (for instance in the real-world example of cash found in my wallet), and whatever issues of probability and gamesmanship were involved, the host makes a choice before the player makes a choice. (In your multiple-and-duplicate envelopes analysis, which I found very helpful, you allow the player to choose the envelope pair and then choose an envelope from that pair. We needn't.)
    7. That choice is the very first step of the game and yet it appears nowhere in the probabilistic solutions, which in effect treat X as a function of the player's choices and what the player observes.
    8. The exact opposite is the case. The player makes choices but the consequences of those choices, what she will observe, is determined by the choice beforehand of the value of X.
    9. The values of the envelopes any player will see are fixed and unknown. We have only chosen to model them as variables as a way to express our uncertainty.
    10. The probabilistic model can safely be abandoned once it's determined that there will never be any evidence upon which to base a prior much less update one.

    Here's my question for you: what is the advantage of saying that the variable X takes a value from an unknown and unknowable sample space, with an unknown and unknowable PDF, rather than saying X is not a variable but simply an unknown?

    In the now canonical example of @Michael's £10, he could say either:

    (a) the other envelope must contain £20 or £5, but he doesn't know which; or
    (b) there's a "50:50 chance" the other envelope contains £20 or £5, and thus the other envelope is worth £12.50.

    I say (a) is true and (b) is false. The other envelope is worth £20 or £5, and he will gain or lose by switching, but we have no reason to think there is anything probabilistic about it, no reason to think that over many rounds Michael would see £20 about half the time and £5 about half the time, or even £20 some other fraction of the time and £5 the rest. What compels us to say that it is probabilistic but Michael assumes a probability he oughtn't, if we're only going to say that the actual probability is unknown and unknowable? Why not just say (a)?
    Srap Tasmaner July 31, 2018 at 21:22 ¶ #201702
    Here's my decision tree again, fleshed out in terms of @Michael's £10.
    User image
    The value of k is either 5 or 10, and you have no way of knowing which.

    k = 5

    If you observe 10, you are in the blue branch: you have picked the higher amount and only stand to lose k by switching with no chance of gaining. You could not have observed 10 in the red branch. At the end, the choice you face between sticking (10) and switching (5) is the exact same choice you faced at the beginning.

    For you, the blue branch is true and the red branch, in which you have the lower amount, and face a choice between sticking (10) and switching (20), is false.

    k = 10

    If you observe 10, you are in the red branch: you have picked the lower amount and only stand to gain k by switching with no chance of losing. You could not have observed 10 in the blue branch. At the end, the choice you face between sticking (10) and switching (20) is the exact same choice you faced at the beginning.

    For you, the red branch is true and the blue branch, in which you have the higher amount, and face a choice between sticking (10) and switching (5), is false.


    There are always only two envelopes with fixed values in play. Any choice you make is always between those same two envelopes with those same two values.


    ((The case descriptions sound like the lamest D&D campaign ever.))
    JeffJo July 31, 2018 at 22:05 ¶ #201711
    Quoting Srap Tasmaner
    My current, and I think "final", position is that this isn't really a probability puzzle at all. Here are my arguments for my view and against yours.

    The puzzling part is about our understanding the mathematics, not how we use it to solve the problem. But that still makes it a probability problem. People who know only a little have difficulty understanding why the simple 5v/4 answer isn't right, and people who know more tend to over-think it, trying to derive more information from it that is there.

    1. The only probability anyone has ever managed to assign any value to is the probability of choosing the larger (or the smaller) envelope -- and even that is only the simplest noninformative prior.

    That's because the higher/lower question is the only one we can assign a probability to. There is on;ly one kind of probability that you can place on values. That's "valid," meaning there is a set of possibilities, and their probabilities sum to 1. Any other kind - frequentiest, bayesian, subjective, objective, informative, non-informative, or [i]any other adjective[i] you can think of - is outside teh scope of the problem.

    2. All other probabilities used in solutions such as yours are introduced only to immediately say that we do not and cannot know what their values are.

    Correct.

    4. Much less the PDF on that space.[/quote
    Careful. "PDF" usually refers to a "Probability Density Function," which means the sample space is continuous. We have a distribution for a discrete sample space.

    Th only thing we can say about it (or the sample space ) is, is that it still must be valid. A valid sample space has a maximum value. A valid distribution implies there are values in the sample space where there is an expected loss.

    5. By the time the player chooses, a value for X has been determined.

    This is a red herring. It only has meaning if we know the distribution, and we don't. So it has no meaning.

    6. We might also describe that as the host's choice of a value for X.

    I assume you mean the amounts the benefactor puts in the envelopes (this isn't presented as a game show). That's why I usually speak generically about values. That can apply to the minimum value, which is usually what x refers to in this thread, the difference d which turns out to be the same thing as x but can be more intuitive, the value v in your envelope which can be x or 2x, and the total t (so x=t/3).

    The point is that you do need to recognize how they act differently. Assuming you are "given" x means that there are to v's possible, and assuming that you are "given" v means there are two x's.

    7. That choice is the very first step of the game and yet it appears nowhere in the probabilistic solutions, which in effect treat X as a function of the player's choices and what the player observes.

    Then I'm not sure what you mean - it appears some of mine. If you are given v, and so have two x's, you have to consider the relative probabilities of those two x's.

    10. The probabilistic model can safely be abandoned once it's determined that there will never be any evidence upon which to base a prior much less update one.

    Please, get "updating" out of your mind here.

    what is the advantage of saying that the variable X takes a value from an unknown and unknowable sample space, with an unknown and unknowable PDF, rather than saying X is not a variable but simply an unknown?

    The point is that I'm saying both. You need to understand the various kinds of "variables."

    • In probability (but not necessarily statistics - this one place where terminology can vary) an experiment is a procedure where the result is not predictable. Not an instance where you perform it. (In statistics, it can refer to repeating the procedure multiple times.)
    • A random variable is an abstract concept only, for a measure you can apply to, and get a value from, every possible instance of the procedure. I represent it with an upper case letter like X.
    • "Random Variable" and "X" do not technically refer to any actual result, although this definition gets blurred in practice. They represent potential only.
    • So a random variable never strictly "has" a specific value. For a given random experiment, the possibilities are listed in a set called its range. So the range for X in our game could be something like {$5,$10,$20}.
    • An unknown is a placeholder for a specific value of a instance of the procedure. I use lower case letters, like x.
    • When we say X=x, what we mean is the event where the measure represented by X has value x.
    • Since X never really has a value, we can use this expression only as the argument for a probability function. We sometimes use the shorthand Pr(x) instead of Pr(X=x), since with the upper/lower case convention it is implied that the unknown x is a value taken from the range of X.


    In the now canonical example of Michael's £10, he could say either:

    (a) the other envelope must contain £20 or £5, but he doesn't know which; or
    (b) there's a "50:50 chance" the other envelope contains £20 or £5, and thus the other envelope is worth £12.50.

    I say (a) is true and (b) is false.


    (A) is true, and (B) cannot be determined as true or false without more information. We can say that there is an unknown probability 0<=q<=1 where the expectation is E=($5)*q + ($20)*(1-q) = $20-$15*q. Or in general, E(v,q(v)) = 2v-3*v*q(v)/2. (Note that q(v) means a function.)

    This is not worthless information, because we can make some deductions about how q varies over the range of V. Specifically, we can say that there must be some values where E(v,q(v)) is less v, others where it must be greater that v, and that the sum of E(v,q(v))*Pr(v) is zero.

    What compels us to say that it is probabilistic ...

    The fact that you use an expectation formula.
    Pierre-Normand July 31, 2018 at 22:25 ¶ #201716
    Quoting Srap Tasmaner
    Here's my decision tree again (...)


    Yours isn't really a decision tree that the player must make use of since there is no decision for the player to make at the first node. Imagine a game where there are two dice, one of which is biased towards six (and hence against one) and the other die is equally biased towards one (and hence against six). None of the dice are biased against any of the other possible results, 2,3,4 and 5, which therefore still have a 1/6 chance of occurring. Suppose the game involves two steps. In the first step, the player is dealt one of the two dice randomly. In the second step the player rolls this die and is awarded the result in dollars. What is the player's expected reward? It is $3.5, of course, and upon playing the game increasingly many times, the player can expect the exact same uniform random distribution of rewards ($1,$2,$3,$4,$5,$6) as she would expect from repeatedly throwing one single unbiased die. Indeed, so long as the two dice look the same, and thus can't be reidentified from one iteration of the game to the next, she would have no way to know that the dice aren't unbiased. There just isn't any point in distinguishing two steps of the "decision" procedure, since the first "step" isn't acted upon, yields no information to the player, and can thus be included into a black box, as it were. Either this game, played with two dice biased in opposite directions, or the same game played with one single unbiased die, can be simulated with the very same pseudo-random number generator. Those two games really only are two different implementations of the very same game, and both call for the exact same strategies being implemented for achieving a given goal.

    In the case of the two envelopes paradox, the case is similar. The player never has the opportunity to chose which branch to take at the first node. So, the player must treat this bifurcation as occurring within a black box, as it were, and assign each branch some probability. But, unlike my example with two equally biased dice, those probabilities are unknown. @JeffJo indeed treats them as unknown, but he demonstrates that, whatever they are, over the whole range of possible dealings of two envelopes that may occur at the first step of the game, they simply divide out in the calculation of the expected gain of the switching strategy, which is zero in all cases of possible (bounded, or, at least, convergent) initial distributions. Where @JeffJo's approach seems to me to be superior to yours is that it doesn't yield an incorrect verdict for the specific cases where the prior distribution is such as to yield envelope pairs where, conditionally on being dealt either the smaller or the larger amount from this pair, the expected gain from switching isn't zero. Your own approach seems to yield an incorrect result, in that case, it seems to me.
    Srap Tasmaner July 31, 2018 at 22:30 ¶ #201719
    Quoting JeffJo
    If you are given v, and so have two x's, you have to consider the relative probabilities of those two x's.


    Except that you cannot, and you know that you cannot.

    Suppose the sample space for X is simply {5}, one sole value. All the probabilities of assignments of values to X must add up to 1, so the assignment of the value 5 gets 1. Suppose the sample space for X is {1, 2, 3, 4, 5, 6, 7, 8, 9, 10} and the probability of each assignment is {0, 0, 0, 0, 1, 0, 0, 0, 0, 0}. What is the difference? Could I ever tell which of these was the case and would it matter to me if I could?

    I appreciate the rest of your comments, and may address some of them.
    Janus July 31, 2018 at 22:37 ¶ #201720
    It's truly remarkable that a question which is of no philosophical significance or interest could generate so many responses on a philosophy forum!
    Srap Tasmaner July 31, 2018 at 22:40 ¶ #201721
    Quoting Pierre-Normand
    Where JeffJo approach seems to me to be superior to yours is that it doesn't yield an incorrect verdict for the specific cases where the prior distribution is such as to yield envelope pairs where, conditionally on being dealt either the smaller or the larger amount from this pair, the expected gain from switching isn't zero. Your own approach seems to yield an incorrect result, in that case, it seems to me.


    Sorry, I'm not following this. This sounds like you think I said your expected gain when you have the smaller envelope is zero, which is insane.

    Quoting Pierre-Normand
    Yours isn't really a decision tree that the player must make use of since there is no decision for the player to make at the first node.


    Well now that's an interesting thing.

    Is it a decision? You may not immediately know the consequences of your decision, and you may have no rational basis for choosing one way or the other, but which way you decide will have consequences, and you will have the opportunity to know what they are.

    I've always thought the odd thing about the Always Switch argument is precisely that the game could well begin "You are handed an envelope ..." because the analysis takes hold whether their decision puts them in possession of the smaller or the larger envelope. That strikes me as fallacious. Your primary interest should be in picking the larger envelope, and having picked, figuring out whether you have the larger envelope. In my little real world example, it turns out gamesmanship played a far larger role than any probability.
    Srap Tasmaner July 31, 2018 at 22:43 ¶ #201723
    Quoting Janus
    no philosophical significance or interest


    Smile when you say that.
    Janus July 31, 2018 at 22:44 ¶ #201724
    Srap Tasmaner July 31, 2018 at 22:46 ¶ #201725
    Reply to Janus
    https://www.urbandictionary.com/define.php?term=smile%20when%20you%20say%20that

    ((Evidently nearly coined by Owen Wister, author of The Virginian, the basis for one of favorite TV shows when I was a kid.))
    Srap Tasmaner July 31, 2018 at 22:52 ¶ #201727
    Once again, @Jeremiah, @JeffJo, @Pierre-Normand, and @andrewk, I'm terribly grateful for the patience you've shown me as I try to learn something about probability.
    Pierre-Normand July 31, 2018 at 22:54 ¶ #201728
    Quoting Janus
    It's truly remarkable that a question which is of no philosophical significance or interest could generate so many responses on a philosophy forum!


    It does have some philosophical implications. Some of @andrewk's replies raised good philosophical points regarding the status and significance of probability distributions, which are being involved in the analysis of this apparent paradox.
    Srap Tasmaner July 31, 2018 at 22:57 ¶ #201729
    Quoting Pierre-Normand
    Yours isn't really a decision tree that the player must make use of since there is no decision for the player to make at the first node.


    I might also have pointed out that when I first started doing this a couple days ago I said

    Quoting Srap Tasmaner
    This is in fact only a "tree" in a charitable sense.


    The point of the tree is to show that the last decision you make in every case is the exact same as the first decision you made, and whatever decisions you were offered in between.
    Janus July 31, 2018 at 22:58 ¶ #201730
    Reply to Pierre-Normand

    I'll admit I probably would not understand the philosophical significance of probability distributions even if I had read the relevant posts. I would have thought this is more math than philosophy. What area of philosophy do you think the significance would obtain?
    Srap Tasmaner July 31, 2018 at 22:59 ¶ #201731
    Quoting Janus
    I'll admit I probably would not understand the philosophical significance of probability distributions even if I had read the relevant posts.


    Some might unkindly note that it hasn't stopped me.
    Janus July 31, 2018 at 23:00 ¶ #201732
    Reply to Srap Tasmaner

    You seem to have made a much better fist of it than I ever could! :smile:
    Janus July 31, 2018 at 23:02 ¶ #201733
    Reply to Srap Tasmaner

    I guess it's just not relevant to my area of interest in philosophy. I still don't believe you were really offended, though. :grin:
    Pierre-Normand July 31, 2018 at 23:05 ¶ #201734
    Quoting Srap Tasmaner
    Sorry, I'm not following this. This sounds like you think I said your expected gain when you have the smaller envelope is zero, which is insane.


    No, that's not what I was saying. I was rather suggesting that, assuming there is some determinate albeit unknown probability distribution of possible envelope pairs, then, conditional on some one specific pair having been selected from this initial range, and consistently with $5 being one of the two amounts within this pair (because $5 is the amount that you have seen in your envelope, say), then, the expected gain of switching appears to be zero, according to your decision tree analysis. According to @JeffJo, it could be $2.5, $6.25, $10, or something else, and not necessarily zero. What it actually is, is unknown to the player. What is known to the player only is the average gain from the unconditional switching strategy. And that is zero.
    Michael July 31, 2018 at 23:16 ¶ #201735
    Quoting Janus
    It's truly remarkable that a question which is of no philosophical significance or interest could generate so many responses on a philosophy forum!


    It's something new. I've been posting here (and on the old place) for 12 years. I've argued over all the typical stuff countless times.
    andrewk July 31, 2018 at 23:17 ¶ #201736
    According to the post counter, this will be the 999th post in this thread.

    I'm rooting* for it to hit the big 1K, as it has been a most interesting discussion when tempers have stayed within bounds.

    * As an Australian resident, I need to point out that I am using the American sense of this word, which is 'hoping for the best for'. In Australia 'rooting' means 'having sex with', which is not what I am doing in relation to this thread.
    Michael July 31, 2018 at 23:17 ¶ #201737
    I wonder if what I've been talking about (made more explicit here), is subjective expected utility.