Page 229, question 21: runner goes from front or back door, prob 1/2 each. Returns front or back, prob 1/2 each. Has k pairs of shoes, wears pair if any at departure door, leaves at return door. No shoes? Barefoot. Long run fraction of time barefoot?
Solution: Let Xn be number of shoes at front door on day n. Then Xn is a Markov Chain.
Transition probabilities:
k pairs at front door on day n. Xn+1 is k if goes out back door (prob is 1/2) or out front door and back in front door (prob is 1/4). Otherwise Xn+1 is k-1.
0 < j < k pairs at front door on day n. Xn+1 is j+1if out back, in front (prob is 1/4). Xn+1 is j-1 if out front, in back. Otherwise Xn+1 is j.
0 pairs at front door on day n. Xn+1 is 0 if out front door (prob 1/2) or out back door and in back door (prob 1/4) otherwise Xn+1 is 1.
Transition matrix :
Doubly stochastic: row sums and column sums are 1.
So for all i is stationary initial distribution.
Solution to problem: 1 day in k+1 no shoes at front door. Half of those go barefoot. Also 1 day in k+1 all shoes at front door; go barefoot half of these days. Overall go barefoot 1/(k+1) of the time.
Insurance company's reserves fluctuate: sometimes up, sometimes down. Ruin is event they hit 0 (company goes bankrupt). General problem. For given model of fluctuation compute probability of ruin either eventually or in next k time units.
Simplest model: gambling on Red at Casino. Bet $1 at a time. Win
$1 with probability p, lose $1 with probability 1-p. Start with
k dollars. Quit playing
when down to $0 or up to N. Compute
Xn = fortune after n plays. X0=k.
Transition matrix:
Middle equation is
For k=N we get
Notice that if p=1/2 our formulas for the sum of the geometric series
are wrong. But for p=1/2 we get