2 problems found
A biased coin has probability \(p\) of showing a head and probability \(q\) of showing a tail, where \(p\ne0\), \(q\ne0\) and \(p\ne q\). When the coin is tossed repeatedly, runs occur. A straight run of length \(n\) is a sequence of \(n\) consecutive heads or \(n\) consecutive tails. An alternating run of length \(n\) is a sequence of length \(n\) alternating between heads and tails. An alternating run can start with either a head or a tail. Let \(S\) be the length of the longest straight run beginning with the first toss and let \(A\) be the length of the longest alternating run beginning with the first toss.
Solution:
A biased coin, with a probability \(p\) of coming up heads and a probability \(q=1-p\) of coming up tails, is tossed repeatedly. Let \(A\) be the event that the first run of \(r\) successive heads occurs before the first run of \(s\) successive tails. If \(H\) is the even that on the first toss the coin comes up heads and \(T\) is the event that it comes up tails, show that \begin{alignat*}{1} \mathrm{P}(A|H) & =p^{\alpha}+(1-p^{\alpha})\mathrm{P}(A|T),\\ \mathrm{P}(A|T) & =(1-q^{\beta})\mathrm{P}(A|H), \end{alignat*} where \(\alpha\) and \(\beta\) are to be determined. Use these two equations to find \(\mathrm{P}(A|H),\) \(\mathrm{P}(A|T),\) and hence \(\mathrm{P}(A).\)
Solution: \begin{align*} && \P(A|H) &= \P(\text{achieve }r\text{ heads immediately}) + \P(\text{don't and then achieve it from having flipped a tail}) \\ &&&= p^{r-1} + (1-p^{r-1}) \cdot \P(A|T) \\ && \P(A|T) &= (1-q^{s-1})\P(A|H) \\ \\ &&\P(A|H) &= p^{r-1}+(1-p^{r-1})(1-q^{s-1})\P(A|H) \\ \Rightarrow && \P(A|H) &= \frac{p^{r-1}}{1-(1-p^{r-1})(1-q^{s-1})} \\ && \P(A|T) &= \frac{(1-q^{s-1})p^{r-1}}{1-(1-p^{r-1})(1-q^{s-1})} \\ && \P(A) &= \frac{(2-q^{s-1})p^{r-1}}{2(1-(1-p^{r-1})(1-q^{s-1}))} \end{align*}