3. (ii) As an example, we compute the probability of obtaining 5 consecutive H in 100 tosses of
a fair coin. We do this by defining six states of the experiment. |
S1 : 5 consecutive H have not occurred, and the previous toss is T |
S2 : 5 consecutive H have not occurred, and the previous two tosses are T, H |
S3 : 5 consecutive H have not occurred, and the previous three tosses are T, H, H |
S4 : 5 consecutive H have not occurred, and the previous four tosses are T, H, H, H |
S5 : 5 consecutive H have not occurred, and the previous five tosses are T, H, H, H, H |
S6 : 5 consecutive H have occurred |
Each successive coin toss moves the experiment from one state to one or two other states: |
Next toss is T | Next toss is H |
S1 -> S1 | S1 -> S2 |
S2 -> S1 | S2 -> S3 |
S3 -> S1 | S3 -> S4 |
S4 -> S1 | S4 -> S5 |
S5 -> S1 | S5 -> S6 |
S6 -> S6 | S6 -> S6 |
|
We represent the probabilities of the transitions in a matrix |
M = |
.5 | .5 | 0 | 0 | 0 | 0 |
.5 | 0 | .5 | 0 | 0 | 0 |
.5 | 0 | 0 | .5 | 0 | 0 |
.5 | 0 | 0 | 0 | .5 | 0 |
.5 | 0 | 0 | 0 | 0 | .5 |
0 | 0 | 0 | 0 | 0 | 1 |
|
|
Suppose we start in state S1, represented by [1 0 0 0 0 0]. |
After one coin toss, the system is in state S1 or S2, both with probability 0.5. We can obtain this by |
[1 0 0 0 0 0]M = [.5 .5 0 0 0 0] |
After two coin tosses, the system is in state S1, S2, or S3, with probability 0.5, 0.25, and 0.25.
We can obtain this by |
[1 0 0 0 0 0]M2 = [.5 .25 .25 0 0 0] |
After 100 tosses the distrbution of states is |
[1 0 0 0 0 0]M100 = [.097 .049 .025 .013 .006 .810] |
So in 100 tosses of a fair coin we see an 81% probability of seeing 5 consecutive heads. |