Probability of arriving H before A

131 Views Asked by At

I m in the point X. I m 2 blocks up from a point A and 3 blocks down from my home H. Every time I walk one block i drop a coin.

H . . . X . . A

If the coin is face I go one block up and if it is not face I go one block down.

Which is the probability of arriving home before the point A?


What I really want to do is to solve that problem in a recursive way. Maybe it can be solved with a binomial distribution... But is it also recursive?

2

There are 2 best solutions below

0
On BEST ANSWER

Forming a Stochastic Matrix, with the first row being the pub and the last row being home.

$$A=\begin{bmatrix}1&0&0&0&0&0\\\frac{1}{2}&0&\frac{1}{2}&0&0&0\\0&\frac{1}{2}&0&\frac{1}{2}&0&0\\0&0&\frac{1}{2}&0&\frac{1}{2}&0\\0&0&0&\frac{1}{2}&0&\frac{1}{2}\\0&0&0&0&0&1\end{bmatrix}$$ We are solving: $$\lim_{x\to\infty}(A^x\begin{bmatrix}0&0&1&0&0&0\end{bmatrix})$$ $$=\begin{bmatrix}1&0&0&0&0&0\\0.8&0&0&0&0&0.2\\0.6&0&0&0&0&0.4\\0.4&0&0&0&0&0.6\\0.2&0&0&0&0&0.8\\0&0&0&0&0&1\end{bmatrix}\begin{bmatrix}0&0&1&0&0&0\end{bmatrix}$$ $$=\begin{bmatrix}0.6&0&0&0&0&0.4\end{bmatrix}$$ The last column represents the probability we are at home, which is $0.4$.

1
On

Denote your current position by $S_0=0$, and let the pub be $2$ and home $-3$. Define the probability $$ P(\text{A before H} \mid S_n = x)=:p(x) $$ This probability satisfies $$ p(x) = \frac{1}{2}p(x+1) + \frac{1}{2}p(x-1) $$ As a difference eqution: $$ p_{n+2}-2p_{n+1}+p_{n}=0 $$ which has a single root $1$ so the solution is $$ p_n = c_1 + c_2n $$ now plug in the boundaries $p(-3)=0$ and $p(2)=1$ and evaluate at $n=0$ which yields $$ p(0) = \frac{3}{5} $$ (edit: I solved for the opposite event of what you wanted)