Steven R. Dunbar
Department of Mathematics
203 Avery Hall
University of Nebraska-Lincoln
Lincoln, NE 68588-0130
http://www.math.unl.edu
Voice: 402-472-3731
Fax: 402-472-8466
Stochastic Processes and
Advanced Mathematical Finance
__________________________________________________________________________
Ruin Probabilities
_______________________________________________________________________
Note: These pages are prepared with MathJax. MathJax is an open source JavaScript display engine for mathematics that works in all browsers. See http://mathjax.org for details on supported browsers, accessibility, copy-and-paste, and other features.
_______________________________________________________________________________________________
Mathematically Mature: may contain mathematics beyond calculus with proofs.
_______________________________________________________________________________________________
What is the solution of the recurrence equation ${x}_{n}=a{x}_{n-1}$ where $a$ is a constant? What kind of a function is the solution? What more, if anything, needs to be known to obtain a complete solution?
_______________________________________________________________________________________________
__________________________________________________________________________
__________________________________________________________________________
We consider a sequence of Bernoulli random variables, ${Y}_{1},{Y}_{2},{Y}_{3},\dots $ where ${Y}_{i}=+1$ with probability $p$ and ${Y}_{i}=-1$ with probability $q$. We start with an initial value ${T}_{0}>0$. We deﬁne the sequence of sums ${T}_{n}={\sum}_{i=0}^{n}{Y}_{i}$. We are interested in the stochastic process ${T}_{1},{T}_{2},{T}_{3},\dots $. It turns out this is a complicated sequence to understand in full, so we single out particular simpler features to understand ﬁrst. For example, we can look at the probability that the process will achieve the value $0$ before it achieves the value $a$. This is a special case of a larger class of probability problems called ﬁrst-passage probabilities.
Consider a gambler who wins or loses a dollar on each turn of a game with probabilities $p$ and $q=1-p$ respectively. Let his initial capital be ${T}_{0}>0$. The game continues until the gambler’s capital either is reduced to $0$ or has increased to $a$. Let ${q}_{{T}_{0}}$ be the probability of the gambler’s ultimate ruin and ${p}_{{T}_{0}}$ the probability of his winning. We shall show later that (see also Duration of the Game Until Ruin..)
so that we need not consider the possibility of an unending game.
Theorem 1. The probability of the gambler’s ruin is
if $p\ne q$ and
if $p=q=1\u22152$.
Proof. The proof uses a ﬁrst step analysis considering how the probabilities change after one step or trial. After the ﬁrst trial the gambler’s fortune is either ${T}_{0}-1$ or ${T}_{0}+1$ and therefore we must have
$${q}_{{T}_{0}}=p{q}_{{T}_{0}+1}+q{q}_{{T}_{0}-1}$$ | (1) |
provided $1<{T}_{0}<a-1$. For ${T}_{0}=1$, the ﬁrst trial may lead to ruin, and (1) is replaced by
Similarly, for ${T}_{0}=a-1$ the ﬁrst trial may result in victory, and therefore
To unify our equations, we deﬁne as a natural convention that ${q}_{0}=1$, and ${q}_{a}=0$. Then the probability of ruin satisﬁes (1) for ${T}_{0}=1,2,\dots ,a-1$. This deﬁnes a set of $a-1$ diﬀerence equations, with boundary conditions at $0$ and $a$. If we solve the system of diﬀerence equations, then we will have the desired probability ${q}_{{T}_{0}}$ for any value of ${T}_{0}$.
Note that we can rewrite the diﬀerence equations as
Then we can rearrange and factor to obtain
This says the ratio of successive diﬀerences of ${q}_{{T}_{0}}$ is constant. This suggests that ${q}_{{T}_{0}}$ is a power function,
since power functions have this property.
We ﬁrst take the case when $p\ne q$. Then based on the guess above (or also on standard theory for linear diﬀerence equations), we try a solution of the form ${q}_{{T}_{0}}={\lambda}^{{T}_{0}}$. That is
This reduces to
Since $p+q=1$, this factors as
so the solutions are $\lambda =q\u2215p$, and $\lambda =1$. (One could also use the quadratic formula to obtain the same values.) Again by the standard theory of linear diﬀerence equations, the general solution is
$${q}_{{T}_{0}}=A\cdot 1+B\cdot {\left(q\u2215p\right)}^{{T}_{0}}$$ | (2) |
for some constants $A$, and $B$.
Now we determine the constants by using the boundary conditions:
$$\begin{array}{llll}\hfill {q}_{0}& =A+B=1\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\\ \hfill {q}_{a}& =A+B{\left(q\u2215p\right)}^{a}=0.\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\end{array}$$Solving, substituting, and simplifying:
(Check for yourself that with this expression $0\le {q}_{{T}_{0}}\le 1$ as it should be a for a probability.)
We should show that the solution is unique. So suppose ${r}_{{T}_{0}}$ is another solution of the diﬀerence equations. Given an arbitrary solution of (1), the two constants $A$ and $B$ can be determined so that (2) agrees with ${r}_{{T}_{0}}$ at ${T}_{0}=0$ and ${T}_{0}=a$. (The reader should be able to explain why by reference to a theorem in Linear Algebra!) From these two values, all other values can be found by substituting in (1) successively ${T}_{0}=1,2,3,\dots $ Therefore, two solutions which agree for ${T}_{0}=0$ and ${T}_{0}=1$ are identical, hence every solution is of the form (2).
The solution breaks down if $p=q=1\u22152$, since then we do not get two linearly independent solutions of the diﬀerence equation (we get the solution $1$ repeated twice). Instead, we need to borrow a result from diﬀerential equations (from the variation-of-parameters/reduction-of-order set of ideas used to derive a complete linearly independent set of solutions.) Certainly, $1$ is still a solution of the diﬀerence equation (1). A second linearly independent solution is ${T}_{0}$, (check it out!) and the general solution is ${q}_{{T}_{0}}=A+B{T}_{0}$. To satisfy the boundary conditions, we must put $A=1$, and $A+Ba=0$, hence ${q}_{{T}_{0}}=1-{T}_{0}\u2215a$. □
We can consider a symmetric interpretation of this gambling game. Instead of a single gambler playing at a casino, trying to make a goal $a$ before being ruined, consider two gamblers Alice and Bill playing against each other. Let Alice’s initial capital be ${T}_{0}$ and let her play against adversary Bill with initial capital $a-{T}_{0}$ so that their combined capital is $a$. The game continues until one gambler’s capital either is reduced to zero or has increased to $a$, that is, until one of the two players is ruined.
Proof. The probability ${p}_{{T}_{0}}$ of Alice’s winning the game equals the probability of Bill’s ruin. Bill’s ruin (and Alice’s victory) is therefore obtained from our ruin formulas on replacing $p$, $q$, and ${T}_{0}$ by $q$, $p$, and $a-{T}_{0}$ respectively. That is, from our formula (for $p\ne q$) the probability of Alice’s ruin is
and the probability of Bill’s ruin is
Then add these together, and after some algebra, the total is $1$. (Check it out!)
For $p=1\u22152=q$, the proof is simpler, since then ${p}_{{T}_{0}}=1-\left(a-{T}_{0}\right)\u2215a$, and ${q}_{{T}_{0}}=1-{T}_{0}\u2215a$, and ${p}_{{T}_{0}}+{q}_{{T}_{0}}=1$ easily. □
Proof. In the game, the gambler’s ultimate gain (or loss!) is a Bernoulli (two-valued) random variable, $G$, where $G$ assumes the value $-{T}_{0}$ with probability ${q}_{{T}_{0}}$, and assumes the value $a-{T}_{0}$ with probability ${p}_{{T}_{0}}$. Thus the expected value is
$$\begin{array}{llll}\hfill \mathbb{E}\left[G\right]& =\left(a-{T}_{0}\right){p}_{{T}_{0}}+\left(-{T}_{0}\right){q}_{{T}_{0}}\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\\ \hfill & ={p}_{{T}_{0}}a-{T}_{0}\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\\ \hfill & =\left(1-{q}_{{T}_{0}}\right)a-{T}_{0}.\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\end{array}$$ □Now notice that if $q=1\u22152=p$, so that we are dealing with a fair game, then $\mathbb{E}\left[G\right]=\left(1-\left(1-{T}_{0}\u2215a\right)\right)\cdot a-{T}_{0}=0$. That is, a fair game in the short run (one trial) is a fair game in the long run (expected value). However, if $p<1\u22152<q$, so the game is not fair then our expectation formula says
$$\begin{array}{llll}\hfill \mathbb{E}\left[G\right]& =\left(1-\frac{{\left(q\u2215p\right)}^{a}-{\left(q\u2215p\right)}^{{T}_{0}}}{{\left(q\u2215p\right)}^{a}-1}\right)a-{T}_{0}\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\\ \hfill & =\frac{{\left(q\u2215p\right)}^{{T}_{0}}-1}{{\left(q\u2215p\right)}^{a}-1}a-{T}_{0}\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\\ \hfill & =\left(\frac{\left[{\left(q\u2215p\right)}^{{T}_{0}}-1\right]a}{\left[{\left(q\u2215p\right)}^{a}-1\right]{T}_{0}}-1\right){T}_{0}\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\end{array}$$The sequence $\left[{\left(q\u2215p\right)}^{n}-1\right]\u2215n$ is an increasing sequence, so
This shows that an unfair game in the short run (one trial) is an unfair game in the long run.
Corollary 3. The probability of ultimate ruin of a gambler with initial capital ${T}_{0}$ playing against an inﬁnitely rich adversary is
and
Proof. Let $a\to \infty $ in the formulas. (Check it out!) □
Remark. This corollary says that the probability of “breaking the bank at Monte Carlo” as in the movies is zero, at least for the simple games we are considering.
$p$ | $q$ | ${T}_{0}$ | $a$ | Probability | Probability | Expected | |
of Ruin | of Victory | Gain | |||||
0.5 | 0.5 | 9 | 10 | 0.1000 | 0.9000 | 0 | |
0.5 | 0.5 | 90 | 100 | 0.1000 | 0.9000 | 0 | |
0.5 | 0.5 | 900 | 1,000 | 0.1000 | 0.9000 | 0 | |
0.5 | 0.5 | 950 | 1,000 | 0.0500 | 0.9500 | 0 | |
0.5 | 0.5 | 8,000 | 10,000 | 0.2000 | 0.8000 | 0 | |
0.45 | 0.55 | 9 | 10 | 0.2101 | 0.7899 | -1 | |
0.45 | 0.55 | 90 | 100 | 0.8656 | 0.1344 | -77 | |
0.45 | 0.55 | 99 | 100 | 0.1818 | 0.8182 | -17 | |
0.4 | 0.6 | 90 | 100 | 0.9827 | 0.0173 | -88 | |
0.4 | 0.6 | 99 | 100 | 0.3333 | 0.6667 | -32 | |
We often hear from people who consistently win at the casino. How can this be in the face of the theorems above?
A simple illustration makes clear how this is possible. Assume for convenience a gambler who repeatedly visits the casino, each time with a certain amount of capital. His goal is to win 1/9 of his capital. That is, in units of his initial capital ${T}_{0}=9$, and $a=10$. Assume too that the casino is fair so that $p=1\u22152=q$, then the probability of ruin in any one year is:
That is, if the working capital is much greater than the amount required for victory, then the probability of ruin is reasonably small.
Then the probability of an unbroken string of ten successes in ten years is:
This much success is reasonable, but simple psychology would suggest the gambler would boast about his skill instead of crediting it to luck. Moreover, simple psychology suggests the gambler would also blame one failure on oversight, momentary distraction, or even cheating by the casino!
Another common interpretation of this probability game is to imagine it as a random walk. That is, we imagine an individual on a number line, starting at some position ${T}_{0}$. The person takes a step to the right to ${T}_{0}+1$ with probability $p$ and takes a step to the left to ${T}_{0}-1$ with probability $q$ and continues this random process. Then instead of the total fortune at any time, we consider the geometric position on the line at any time. Instead of reaching ﬁnancial ruin or attaining a ﬁnancial goal, we talk instead about reaching or passing a certain position. For example, Corollary 3 says that if $p\le q$, then the probability of visiting the origin before going to inﬁnity is $1$. The two interpretations are equivalent and either can be used depending on which is more useful. The problems below use the random walk interpretation, because they are more naturally posed in terms of reaching or passing certain points on the number line.
The fortune in the coin-tossing game is the ﬁrst and simplest encounter with two of the most important ideas in modern probability theory.
We can interpret the fortune in our gambler’s coin-tossing game as a Markov process. That is, at successive times the process is in various states. In our case, the states are the values of the fortune. The probability of passing from one state at the current time $t$ to another state at time $t+1$ is completely determined by the present state. That is, for our coin-tossing game
$$\begin{array}{llll}\hfill \mathbb{P}\left[{T}_{t+1}=x+1|{T}_{t}=x\right]& =p\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\\ \hfill \mathbb{P}\left[{T}_{t+1}=x-1|{T}_{t}=x\right]& =q\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\\ \hfill \mathbb{P}\left[{T}_{t+1}=y|{T}_{t}=x\right]& =0\text{forall}y\ne x+1,x-1\text{}\phantom{\rule{2em}{0ex}}& \hfill & \phantom{\rule{2em}{0ex}}\end{array}$$The most important property of a Markov process is that the probability of being in the next state is completely determined by the current state and not the history of how the process arrived at the current state. In that sense, we often say that a Markov process is memory-less.
We can also note the fair coin-tossing game with $p=1\u22152=q$ is a martingale. That is, the expected value of the process at the next step is the current value. Using expectation for estimation, the best estimate we have of the gambler’s fortune at the next step is the current fortune:
This characterizes a fair game, after the next step, one can neither expect to be richer or poorer. Note that the coin-tossing games with $p\ne q$ do not have this property.
In later sections we have more occasions to study the properties of martingales, and to a lesser degree Markov processes.
This section is adapted from W. Feller, in Introduction to Probability Theory and Applications, Volume I, Chapter XIV, page 342, [1]. Some material is adapted from [3] and [2]. Steele has an excellent discussion at about the same level as here, but with a slightly more rigorous approach to solving the diﬀerence equations. He also gives more information about the fact that the duration is almost surely ﬁnite, showing that all moments of the duration are ﬁnite. Karlin and Taylor give a treatment of the ruin problem by direct application of Markov chain analysis, which is not essentially diﬀerent, but points to greater generality.
_______________________________________________________________________________________________
The goal is to simulate the probability function for ruin with a given starting value. First set the probability $p$, number of Bernoulli trials $n$, and number of experiments $k$. Set the ruin and victory values $r$ and $v$, the boundaries for the random walk. For each starting value from ruin to victory, ﬁll an $n\times k$ matrix with the Bernoulli random variables. For languages with multi-dimensional arrays each the data is kept in a three-dimensional array of size $n\times k\times \left(v-r+1\right)$. Cumulatively sum the Bernoulli random variables to create the fortune or random walk. For each starting value, for each random walk or fortune path, ﬁnd the step where ruin or victory is encountered. For each starting value, ﬁnd the proportion of fortunes encountering ruin. Finally, ﬁnd a least squares linear ﬁt of the ruin probabilities as a function of the starting value.
R script for ruin probabilities.
Octave script for ruin probabilities.
Perl PDL script for ruin probabilities.
Scientiﬁc Python script for ruin probabilities.
__________________________________________________________________________
Use “ﬁrst step analysis” to write three equations in three unknowns (with two additional boundary conditions) that give the probability that the gambler will be ruined. Solve the equations to ﬁnd the ruin probability.
Compute the expected number of visits $\mathbb{E}\left[N\right]$ to level $a$.
Consider a naive model for a stock that has a support level of $20/share because of a corporate buy-back program. (This means the company will buy back stock if shares dip below $20 per share. In the case of stocks, this reduces the number of shares outstanding, giving each remaining shareholder a larger percentage ownership of the company. This is usually considered a sign that the company’s management is optimistic about the future and believes that the current share price is undervalued. Reasons for buy-backs include putting unused cash to use, raising earnings per share, increasing internal control of the company, and obtaining stock for employee stock option plans or pension plans.) Suppose also that the stock price moves randomly with a downward bias when the price is above $20, and randomly with an upward bias when the price is below $20. To make the problem concrete, we let ${S}_{n}$ denote the stock price at time $n$, and we express our stock support hypothesis by the assumptions that
$$\begin{array}{rcll}\mathbb{P}\left[{S}_{n+1}=21|{S}_{n}=20\right]& =& 9\u221510& \text{}\\ \mathbb{P}\left[{S}_{n+1}=19|{S}_{n}=20\right]& =& 1\u221510& \text{}\end{array}$$
We then reﬂect the downward bias at price levels above $20 by requiring that for $k>20$:
$$\begin{array}{rcll}\mathbb{P}\left[{S}_{n+1}=k+1|{S}_{n}=k\right]& =& 1\u22153& \text{}\\ \mathbb{P}\left[{S}_{n+1}=k-1|{S}_{n}=k\right]& =& 2\u22153.& \text{}\end{array}$$
We then reﬂect the upward bias at price levels below $20 by requiring that for $k<20$:
$$\begin{array}{rcll}\mathbb{P}\left[{S}_{n+1}=k+1|{S}_{n}=k\right]& =& 2\u22153& \text{}\\ \mathbb{P}\left[{S}_{n+1}=k-1|{S}_{n}=k\right]& =& 1\u22153& \text{}\end{array}$$
Using the methods of “single-step analysis” calculate the expected time for the stock to fall from $25 through the support level all the way down to $18. (Because of the varying parameters there is no way to solve this problem using formulas. Instead you will have to go back to basic principles of single-step or ﬁrst-step analysis to solve the problem.)
__________________________________________________________________________
[1] William Feller. An Introduction to Probability Theory and Its Applications, Volume I, volume I. John Wiley and Sons, third edition, 1973. QA 273 F3712.
[2] S. Karlin and H. Taylor. A Second Course in Stochastic Processes. Academic Press, 1981.
[3] J. Michael Steele. Stochastic Calculus and Financial Applications. Springer-Verlag, 2001. QA 274.2 S 74.
__________________________________________________________________________
__________________________________________________________________________
I check all the information on each page for correctness and typographical errors. Nevertheless, some errors may occur and I would be grateful if you would alert me to such errors. I make every reasonable eﬀort to present current and accurate information for public use, however I do not guarantee the accuracy or timeliness of information on this website. Your use of the information from this website is strictly voluntary and at your risk.
I have checked the links to external sites for usefulness. Links to external websites are provided as a convenience. I do not endorse, control, monitor, or guarantee the information contained in any external website. I don’t guarantee that the links are active at all times. Use the links here with the same caution as you would all information on the Internet. This website reﬂects the thoughts, interests and opinions of its author. They do not explicitly represent oﬃcial positions or policies of my employer.
Information on this website is subject to change without notice.
Steve Dunbar’s Home Page, http://www.math.unl.edu/~sdunbar1
Email to Steve Dunbar, sdunbar1 at unl dot edu
Last modiﬁed: Processed from LATEX source on July 18, 2016