1

A person tosses a fair coin until a tail appears for the first time. If the tail appears on the $n$th flip, the person wins $2^n$ dollars. Would you be willing to pay $1$ million for each game if you could play as long as you liked and only had to settle up when you stopped playing?

I thought about this question and ran a computer simulation, except with the entry fee being $100$ dollars each round and ran $100000000000$ rounds, and stopped if there was any profit. In almost each run, there seemed to be a net profit. However, I couldn't mathematically produce the same result.

I read the following quote: "But after a very long time, you will win so much money that is sufficient for you to pay off this large debt and still purchase the whole world. As @IanColey put it, this is because the chances of winning so much money are very, very tiny, but the payoffs associated with these very, very tiny probabilities are much, much, much more enormous than the probabilities are tiny.

I couldn't fathom that one single round would be able to earn so much money to pay off the debt that had been accumulating. So I tried making an equation for Money Earned - Money Spent. Money Spent = $1000000k$, where $k$ is the number of rounds played.

Expected Value[Number of Flips to get $a$ heads in a row] = $E_a =\frac{E_a+1}2+\frac{E_a+2}4+...+\frac{E_a+a}a+\frac a{2^a} = 2(2^a-1) $

Since tails is expected to occur on the second flip, the expected number of flips in $k$ rounds is $2k$. Now, we have $a = \log_2(E_a+2)-1$ and you win $2^{n+1}$ dollars in a round, where $n$ is the number of heads before the first tails. Therefore, you have the expected highest winning after $k$ rounds to be $2^{(\log_2(2k+2)-1)+1} = 2k+2$.

Therefore, after $k$ rounds, you would be expected to lose $9999998k -2$ dollars.

What am I doing wrong? I know a huge oversight in this math is to only account for the total gain for one (largest) flip. However, I made this assumption based on the above quote that after a while, you will win so much that you will pay off the large debt.

RobPratt
  • 45,619
  • Please don't use images of text: type the text up with MathJax. Thanks – Adam Rubinson Jan 30 '23 at 08:27
  • It might be useful that I simulate thousands of games and plot the distribution of the highest amount won in a game in a single round. – Random user33 Jan 30 '23 at 08:29
  • I do not comprehend the following sentence:" Since tails is expected to arrive... ' – callculus42 Jan 30 '23 at 08:39
  • Hopefully my edit fixed the issue? – Random user33 Jan 30 '23 at 08:47
  • 3
    "I thought about this question ... ...In almost each run, there seemed to be a net profit."

    This paragraph doesn't make sense to me. You pay $ $100$ to play each round, and if a tail appears on the $n$th flip, the person wins $2^n$ dollars. But then, in each round, there is a $50$% chance you walk away with $ $-98$, there is a $25$% chance you walk away with $ $-96,$ a $12.5$% chance you walk away with $ $-92,$ etc. Is this correct? If so, how did you get that, "In almost each run, there seemed to be a net profit." ? Surely, in almost each run, you get a net loss...

    – Adam Rubinson Jan 30 '23 at 08:47
  • By each run, I meant for every time a new game (which has up to 1000000000 rounds) is entered. In other words, every time a player starts afresh. – Random user33 Jan 30 '23 at 09:02
  • Well, obviously if you run $100000000000$ rounds, it is overwhelmingly likely that one of those rounds with give a profit. To gain a profit, all you need is for the first $8$ tosses to all be heads, which has a $1/64 > 1$% chance of happening, and so we expect to get a profit in more than $1$% of the $100000000000$ rounds. It is almost impossible (ridiculously unlikely) to not get a profit in at least one of those $100000000000$ rounds. – Adam Rubinson Jan 30 '23 at 09:18
  • That is not what I meant. For my simulation, I measured that the cumulative profit was positive, as in the (money won - money spent) that had been building up from round 1, was positive. – Random user33 Jan 30 '23 at 09:54
  • I am not sure if I understand the rules of the game. Suppose I throw 5 times, 4 heads and one tail. I win 32 dollar. But do I have to pay 100 dollar for the five throws or 500 dollar? – Vincent Jan 30 '23 at 10:57
  • 1
    Hi, the rules of the game are here: https://en.wikipedia.org/wiki/St._Petersburg_paradox.

    For example, let's say you pay 1,000,000 dollars for each round. I get Heads-Heads-Tails in the first round and win 8 dollars. I am now 999,992 dollars in debt. I play a second round that costs another 1,000,000 dollars. I get Heads-Tails in the second round and win 4 dollars. I am now 1,999,990 dollars in debt. I need to prove that as this game goes on, I will actually come out with a profit as long as I have infinite rounds to play.

    – Random user33 Jan 30 '23 at 11:04
  • Did you try to calculate how much you win on average in this game? Just forget your entry fee. – nicola Jan 30 '23 at 13:57
  • @nicola The average winning in this game is infinite. However, the average entry fee cannot be forgotten as that goes to infinity too. – Random user33 Jan 30 '23 at 17:35
  • 2
    The average entry fee certainly does not go to infinity. The average of any number of occurrences of $10^6$ is still $10^6.$ You seem to be mistaking "average" for "cumulative." In fact, throughout this exercise you use language that is ambiguous about how many things are being counted and in what way they are being counted. There are some obvious errors, but possibly also some errors hidden by this use of language. – David K Jan 30 '23 at 18:49
  • 1
    Let's start with a "game." Is that a single sequence where you pay an entry fee at the start of the game, you flip until the coin comes up tails, then you are paid out and the game is over? Next, what is a "round"? Is it the same as a game? Then, in $10^{11}$ rounds where you "stopped if there was any profit", what exactly is the stopping condition? A single game in which the payout of that game is more than the entry fee? A game after which the total of all winnings for all games so far exceeds the total of all entry fees so far? Those are very different conditions. – David K Jan 30 '23 at 18:56
  • 1
    It is also quite possible that your simulation code is simply incorrect. It is hard to write correct code for a mathematical problem when you cannot write a rigorous specification of the problem in the first place. – David K Jan 30 '23 at 18:58
  • 2
    If the fee is huge , we need long chains of "heads" to win. It is not clear whether a pseudorandom generator actually produces chains of length $45-50$ should they be necessary. The numbers are not actually random. Therefore , it is much better to calculate the expectation than to rely on a simulation here. – Peter Jan 31 '23 at 10:34

2 Answers2

1

You're on the right track but you didn't account for the total winnings, only the highest. Try computing the ratio between the total winnings, and the highest winning for a particular round. As $k\to \infty$, this ratio becomes greater than $\log_2(k)$. As such, your Expected Profit is at least $(2k+2)(\log_2(k)) - 1000000k$.

Yash Jain
  • 135
0

Half the time, tails happens first, you receive $\$2$, which averages out to $\$1$ per game.
A quarter of the time, tails happens second, you receive $\$4$, which averages out to another $\$1$ per game.
You get another dollar per game from the times tails is third, and fourth, and so on.
Your $100000000000$ games is around $2^{37}$, so the first $\$37$ per game is likely to appear. Any more than $37$ is a bit hit and miss. Try charging $\$30$ per game, you are likely to see a profit over $100000000000$ games.

Empy2
  • 50,853
  • I already recieve profit even each time a game is simulated even if the entrance fee is $100. Which is what I don't understand and is the premise of the paradox. – Random user33 Jan 30 '23 at 10:24