16

I have $50$ dollars and I’m gambling on a series of coin flips. For each head I win $2$ dollars and for each tail I lose $1$ dollar. What’s the probability that I will run out of money?

Hint: Suppose we have $x$ dollars, then the probability of ruin satisfies the recursive equation

$$p(x+2) - p(x) = p(x) - p(x-1)$$

Find function $p(x)$.

RobPratt
  • 50,938
henry21
  • 305
  • 1
  • 4
  • 5
  • 7
    The recursion comes from $p(x) = \frac12 p(x+2) + \frac12 p(x-1)$, if that helps. – Math1000 Jun 09 '15 at 03:43
  • Are you only gambling with the original 50 dollars, or also with the dollars you win? Because the two current answers are making opposite assumptions on that. – celtschk Jan 11 '17 at 07:50
  • No, both answers consider the initial 50 + any winnings. @MartinBladt however, does not explain this, as he simply solves the recurrence equation. @ BruceZ starts from zero, but with very limited explanation. The key insight behind his reasoning is that losing at the $50-game is equivalent to losing at 50 repeated $1-games. – Johannes Gerer Feb 15 '17 at 00:56

4 Answers4

8

As indicated, the following recursion holds $$p(n+2)-2p(n)+p(n-1)=0.$$ It only has a solutions on the form $r^n$, where $r$ is a root of the characteristic polynomial $$r^3-2r^1+r^0=0.$$ Finding the roots one has that a general solution of $p$ is given by $$p(n)=A1^n+B\left(\frac{-1+\sqrt{5}}{2}\right)^n+C\left(\frac{-1-\sqrt{5}}{2}\right)^n.$$ Since the underlying random walk has increments with positive mean, $p(n)\rightarrow 0$, as $n\rightarrow\infty$. This gives $A=C=0$. Further, $p(0)=1$, so $B=1$. In conclusion, $$p(n)=\left(\frac{\sqrt{5}-1}{2}\right)^n.$$ $p(50)$ is now easy to calculate.

mbe
  • 957
7

We only need find the probability $r$ that you lose 1 dollar since the probability that you lose 50 dollars is $r^{50}$ since you must lose 1 dollar 50 times. We can write $$ r = 0.5 + 0.5r^3 $$

since half the time we lose on the first flip, and half the time we win on the first flip, thereby increasing our 1 dollar bankroll to 3 dollars, at which point our risk of ruin becomes $r^3$ since we must now lose 1 dollar 3 times. This has solutions $r = (\sqrt{5}-1)/2$ and $r = 1$. We obviously want the first of these since we have the advantage, and our opponent's $r$ is 1. So $$ P(lose \: 50) = \left(\frac{\sqrt{5}-1}{2}\right)^{50} $$ or about $3.55e^-11$.

BruceZ
  • 1,217
  • Thanks! But how do you know the solutions of that cubic? – Ferdinando Randisi Feb 26 '18 at 01:49
  • 2
    To get the solutions to $r^3-2r+1=0$ you can guess that $r=1$ is a solution, and then divide the polynomial by $(r-1)$. You should get $r^3-2r+1=(r-1)(r^2+r-1)$ and the quadratic part you can solve. You should get 2 more roots: $\frac{-1\pm \sqrt{5}}{2}$. – bobsacameno Mar 03 '18 at 08:33
2

Here's an alternative approach (which appears on the surface to be very similar to the recurrence + characteristic polynomial approach) using Martingales.

Let $S_i=X_1+\dots+X_i$ be your money at time $i$; here the $X_j$'s are random variables for the profit (or loss) you make at time $j$. We will find $c$ such that $c^{S_i}$ is a martingale, and then use the Optional Stopping Theorem. Note we need

$$\mathbb{E}[c^{S_{i+1}}|M_1,\dots,M_i]=c^{S_i}\implies \mathbb{E}[c^{X_i}]=\frac{1}{2}c^2+\frac{1}{2}c^{-1}=1\implies c^3-2c+1=0$$ We will take the root $c=\frac{\sqrt{5}-1}{2}$ as it is positive and strictly less than 1, thus for stopping time $T$ representing the first time we hit $0$, $|M_{\min(T,t)}|\leq 1$ for all $t$ is strictly bounded by a finite constant, and thus we can apply Optional Stopping Theorem:

$$\mathbb{E}[M_T]=p\cdot c^0+(1-p)\cdot 0 = M_0=c^{50}\implies p=c^{50}$$

Max
  • 1,436
1

@Johannes Gerer:

I think that a short answer is: If root 1 is not excluded (by setting A=0), $p(n)$ doesn't decrease to zero as $n\to\infty$.

Now why $p(n)$ should decrease to zero as $n\to\infty$.

$\mathbb P$(lose after starting with $0)=1$, since having 0 means loosing by the definition. Also notice that $\forall n>0:p(n)<1$, since there is a chance of not loosing ever. Now since $\mathbb P$(get $+\$2)=\mathbb P($get $-\$1)=0.5$, hence after having 1 we either get 0 (with $\mathbb P=0.5$) or get 3 (with $\mathbb P=0.5$),

So $\mathbb P$(loose after starting with 1)$=:p(1)=$ $0.5p(0)+0.5p(3)=$ $0.5+0.5p(3)>$ $0.5p(3)+0.5p(3)=p(3)$, so $p(1)>p(3)$.

By induction we can show that $p(n)$ is decreasing with $n$. We can see that $p(n)\rightarrow0,n\to\infty$.

We can also see it from the following. We are equally likely moving up and down. But steps up are twice bigger then down, so our game (which is a random walk) has a positive drift, and further we are from 0 more likely that we will never have enough steps down to lose.

  • this should be the accepted answer. both the starting conditions for 0$ and 1$ to solve the characteristic polynom and the induction for p(n) -> 0, n -> inf are very important to understand the solutions. – Dorian Sep 06 '22 at 15:46
  • This argument doesn't really work as it is written here, because a sequence can be strictly decreasing and still not converge to $0$. In fact, I don't see how your argument avoids for example the case $A = B = 1/2$. – Leo Aug 26 '24 at 15:58