Live data from Hacker News

Two envelopes problem

en.wikipedia.org

91–100 of 318 posts

Re: Two envelopes problem

#91
post #33

Earlier quoted context omitted.

This reminds me of how chess tactics feel so obvious when I’m on a tactics trainer, yet I can’t identify them in games where they actually happen. Or code that “obviously” has a bug only after it caused an issue in production. Would be nice if someone warned me before I do a PR: “ok, fyi there is a subtle but devastating bug in the new_feature.cpp”

Well if debugging is the process of removing bugs from code, then logically the act of writing the code must be called "bugging" and the probability of having a bug in any new piece of code asymptotically approaches 1 with increasing SLOC ;^)

Every program has bugs, every program has inefficiencies. Therefore every program can be eventually reduced down to a single instruction, which will be incorrect.

Re: Two envelopes problem

#92
post #68

Earlier quoted context omitted.

Basically the sleight of hand trick is using a random variable A as though it was a constant. Yes, B = A/2 or B = 2A with probability .5 each, but not for the same value of A.

Why not?

A is the starting value, in the one case it's half as much as in the other case.

Re: Two envelopes problem

#93
I wrote up a pretty detailed analysis of this problem a while back here: https://mindbowling.wordpress.com/2020/09/14/two-envelope-pa...

At the end I constructed a super weird example where regardless of what you see in your envelope, you should switch (this seems to go against the symmetry argument, but is sort of saved by a divergence in the expectation value).

Re: Two envelopes problem

#94
post #41
post #18

Earlier quoted context omitted.

Is there actually some way to guess with better than 50% chance? I'm pretty sure this could be reduced to the secretary problem where there's a pool of 2 candidates, which yields an optimal hire with probability 50%. Maybe you play word games and say, "I guess the other number is not higher," or "I guess the other number is not lower." Since the number you observed was produced once, there is some non-zero probabilit…

Yes, there is a way to guess better than 50%. But it's a bit weird: You pick an arbitrary threshold, if your envelope is below the threshold, you switch. (You can add randomness as necessary.)

A very general solution, which works regardless of how the numbers in the envelope are picked:

Choose a monotonically increasing function f with values between 0 and 1. Choose one of the envelopes at random. Then look at the number x in the envelope. Then, with probability f(x) say that you have the larger envelope.

Re: Two envelopes problem

#95

This line of reasoning isn't possible if you have specific amounts (eg £50 and £100) for the envelopes, which suggests that the variable A is being misused somehow. `B = (2A if A=50, A/2 if A=100)`. Simplifying this to `B = 2A or A/2` loses important information: namely that when B is smaller, you expect A to be larger. Or alternatively, treating A as fixed (say A=100) conflates two different situations: one where th…

This is the “simple resolution” presented in the linked article. What “line of reasoning” are you responding to?

Re: Two envelopes problem

#96
post #89

This line of reasoning isn't possible if you have specific amounts (eg £50 and £100) for the envelopes, which suggests that the variable A is being misused somehow. `B = (2A if A=50, A/2 if A=100)`. Simplifying this to `B = 2A or A/2` loses important information: namely that when B is smaller, you expect A to be larger. Or alternatively, treating A as fixed (say A=100) conflates two different situations: one where th…

The correct answer is described here: https://www.youtube.com/watch?v=_NGPncypY68 TL;DR (Spoiler alert): the expected value of the amount of money you end up with is an infinite series whose sum changes depending on the order in which you add up the terms, and so you can choose an order that makes this value come out to be positive, negative, or zero.

[deleted]

Re: Two envelopes problem

#97
Once you pick an envelope, you no longer stand to only gain money.

You can lose money and that has to be reflected in the potential value of each envelope.

After the first selection, you must express the envelope value as the potential of what each envelope holds (the probabilities from the initial selection) which makes selecting again a wash.

Let A = 50 Envelope 1 is 100 Envelope 2 is 25

First selection 1/2(100) + 1/2(25) = 62.5

Great! Do it! 62.5 is bigger than 0, which is the expected value of not playing at all.

After that, it makes no difference to switch (the envelope value is recursive):

1/2(62.5) + 1/2(62.5) = 62.5

or

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

and the trick is that’s now the potential expected value you have (you now have 5/4A in your envelope), so switching is a wash. You never really “had” A as a value to compare against (by evaluating that 5/4A is bigger than A), we just get tripped up with the doubling and halving at the outset.

Said another way, the fact that 5/4A is bigger than A is irrelevant, no envelope contains A, they both contain the expected value of 5/4A.

Re: Two envelopes problem

#98

I must admit I don't find the "compelling line of reasoning" all that compelling; to me it seems the "paradox" has more to do with the meaning of probability than with its calculation. That is, the probability is 1/2. That's all that matters to the decision making. Calculating an "expected value" at all is completely useless, whether or not you do it "correctly". Am I missing something?

Calculating an expected value is meaningful and regular and does affect decisions. If you were told that you could pay £1 to flip a coin and heads would pay out 50p and tails would pay out £2, then playing it you would expect to make £1.25 (£0.25 profit) per play, on average. Many people interpret the envelope problem as being the same situation.

> Many people interpret the envelope problem as being the same situation.

It just seems obvious to me that it's not the same situation. That is, I think the "paradox" is ultimately about the temptation to treat these as similar problems in the first place.

Re: Two envelopes problem

#99

This line of reasoning isn't possible if you have specific amounts (eg £50 and £100) for the envelopes, which suggests that the variable A is being misused somehow. `B = (2A if A=50, A/2 if A=100)`. Simplifying this to `B = 2A or A/2` loses important information: namely that when B is smaller, you expect A to be larger. Or alternatively, treating A as fixed (say A=100) conflates two different situations: one where th…

This is the “simple resolution” presented in the linked article. What “line of reasoning” are you responding to?

Right. I mean the original, paradoxical line of reasoning – "the switching argument".

I see that the article also says "commonly one writer proposes a solution to the problem as stated, after which another writer shows that altering the problem slightly revives the paradox." But it doesn't seem to elaborate on where the simple resolution falls down, if it does.

Re: Two envelopes problem

#100

Earlier quoted context omitted.

Well, the simple way to put is that "A" isn't fixed. The "expected value" argument in steps 6-7 is acting like "A" is a single value when "A" will be larger or smaller depending on what envelope you picked.

Yeah, that's obvious when they say "one envelope contains 2*A and the other A/2". Well no, one doesn't contain one fourth of the other.

It doesn't actually say that. It says the other envelope will either contain 2A or A/2. The envelope you're holding is A. The other envelop is either twice that, or half that.
Post reply on HN