Expected consecutive heads (with bias?)

264 Views Asked by At

When flipping a fair coin, getting three heads in a row is pretty likely, getting 10 is pretty unlikely, but getting 100 or even more seems (almost) impossible in real life. Is there a way to calculate the probability distribution that shows the likelihood of flipping some $n$ heads in a row?

I'm interested in calculating the average number of consecutive heads one might expect when starting a series of coin flips until a tails comes up. And subsequently, if this idea can be extended to a biased coin.

In the comments, Henry says that the probability of getting exactly $n$ consecutive heads with a fair coin is $P(n) = 1/2^{n+1}$, of which the discrete sum is equal to $1$ (thanks Jaap for the correction).

So is it correct then correct to say that the expected value of $P(n)$ is $\sum_{n=0}^{+\infty} \frac{n}{2^{n+1}}=2$?

1

There are 1 best solutions below

0
On

Say that $X$ denotes the number of consecutive heads and we want to find $E(X)$. In the first toss there are two possibilities; we get tail i.e. zero consecutive heads or we get head and continue to play and possibly get more heads with expected value $E(X)$. Therefore we get the following equation for $p$ as the probability of getting head:

$$ E(X)=p\cdot\left(1+E(X)\right)+\left(1-p\right)\cdot 0 $$

For fair coin, $p=0.5$ and $E(X)=1$