postillan4

2021-08-22

This is a discrete math (combinatorics and discrete probability) problem. Please explain each step in detail and do not copy solutions from Chegg.
Consider the random process where a fair coin will be repeatedly flipped until the sequence TTH or THH appears. What is the probability that the sequence THH will be seen first? Explicitly state the value of this probability and walk through the development of the calculation that lead to this value.

bahaistag

Step 1
Let A be the event that THH comes before TTH:
According to law of total probability:
$P\left\{A\right\}=P\left\{A\mid H\right\}P\left\{H\right\}+P\left\{A\mid T\right\}P\left\{T\right\}$
As: $P\left\{H\right\}=P\left\{T\right\}=\frac{1}{2}$
$P\left\{A\right\}=\frac{1}{2}P\left\{A\mid H\right\}+\frac{1}{2}P\left\{A\mid T\right\}$
Also $P\left\{A\mid H\right\}=P\left\{A\right\}$, Therefore $P\left\{A\mid H\right\}=P\left\{A\mid T\right\}$
$P\left\{A\mid T\right\}=P\left\{A\mid \mathrm{\top }\right\}P\left\{T\right\}+P\left\{A\mid TH\right\}P\left\{T\right\}\dots \dots ..\left(1\right)$
$P\left\{A\mid T\right\}=0×\frac{1}{2}+P\left\{A\mid TH\right\}×\frac{1}{2}$
$2P\left\{A\mid T\right\}=P\left\{A\mid TH\right\}\dots \dots \dots ..\left(2\right)$
Step 2
Now for second condition:
$P\left\{A\mid TH\right\}=P\left\{A\mid THH\right\}P\left\{H\right\}+P\left\{A\mid THT\right\}P\left\{T\right\}$
$P\left\{A\mid TH\right\}=1×\frac{1}{2}+\frac{1}{2}P\left\{A\mid T\right\}$
$2P\left\{A\mid T\right\}=\frac{1}{2}+\frac{1}{2}P\left\{A\mid T\right\}$....From equation (2)
$P\left\{A\mid T\right\}=\frac{1}{3}$ and $P\left\{A\mid T\right\}=P\left(A\right)\dots \dots \left(3\right)$
Therefore:
$P\left(A\right)=\frac{1}{3}$
So, TTH is more likely to appear first and it appears 2/3 of time.

Do you have a similar question?