Calculating the expected winner of a Penney's Game using a Markov Chain.

989 Views Asked by At

I am trying to calculate the probability that one sequence of coin tosses is more likely to win than the other in a game of Penney's. The sequences are: HTHT and THTT.

So far I've come up with the following:
$q_0=P_H*q_1+P_T*q_5$
$q_1=P_H*q_1+P_T*q_2$
$q_2=P_H*q_3+P_T*q_5$
$q_3=P_H*q_1+P_T*q_4$
$q_4=1$
$q_5=P_H*q_6+P_T*q_5$
$q_6=P_H*q_1+P_T*q_7$
$q_7=P_H*q_3+P_T*q_8$
$q_8=1$

After some cleaning up we can see that:

$q_0=0.5(q_1+q_5)$
$q_1=\frac{P_{T}*q_{2}}{1-P_{H}}=q_2$
$q_2=0.5(q_3+q_5)$
$q_3=0.5(q_1+q_4)$
$q_4=1$
$q_5=\frac{P_{H}*q_{6}}{1-P_{T}}=q_6$
$q_6=0.5(q1+q7)$
$q_7=0.5(q_3+q_8)$
$q_8=1$

$q_2$ and $q_6$ were left out at first, my mistake. Thanks @SteveKass for pointing that out.

But this is where I get stuck. Trying to solve as a system of linear equations gets me no where since I have too many unknown variables.

I want to figure out the possibilities being absorbed in either state $q_4$ or $q_8$ given the current state. Should it really be this difficult?

1

There are 1 best solutions below

2
On BEST ANSWER

First off, you need to choose one and only one absorbing state $a$ for your equations. Let's pick state #4, so in the first set of equations, $q_4=1$, but $q_8=0$.

More importantly for where you're stuck, you seem to have just thrown away two of your equations when you "cleaned up": $q_2=\frac{1}{2}(q_3+q_5)$ and $q_6=\frac{1}{2}(q_1+q_7)$. If you put those back, you'll have nine equations in nine unknowns, and the system will have a solution (for the particular absorbing state I chose, #4). Here's a snapshot of Mathematica's solution.

enter image description here

(Your Dropbox link took me to a login page, by the way, so I couldn't see your drawing.)