[Math] Average number of tries needed before success

probability

  • there is a 3% chance of success
  • there are a thousand people trying over and over until they succeed
    how many tries will it take on average for the last person to achieve this success?

I know that the average person will need between 22 and 23 tries, and I think a normal distribution could be utilized to look at that 0.1% lowest percentile.
But I'm stuck on how to construct this curve and how to calculate the value linked to that 0.1% percentile.
(It's been 4 years since i've had statistics in college, so obviously i could be way off)

Best Answer

Let the probability of success on any one trial be $p=0.03$, and suppose there are $n=1000$ people. We assume independence.

For $i=1$ to $n$, let $X_i$ be the number of trials the $i$-th person makes before she succeeds. Let $Y=\max(X_1,\dots,X_n)$. We want $E(Y)$.

We have $Y\le k$ if and only if $X_i\le k$ for all $i$. The probability that $X_i\le k$ is $1-\Pr(X_i\gt k)$, what is, $1-(1-p)^k$. It follows that $\Pr(Y\le k)=(1-(1-p)^k)^n$. But $\Pr(Y=k)=\Pr(Y\le k)-\Pr(Y\le k-1)$. Now we can write down an infinite sum for $E(Y)$. I don't see how to put this in closed form. There may not be a closed form.

Remark: If, as is possibly the case, you are interested in the median number of trials of the least lucky person, we want to find the largest $k$ such that $\Pr(Y\le k)\le \frac{1}{2}$. So, roughly speaking, we want to solve the equation $$(1-(1-p)^k)^n =\frac{1}{2}.$$ This can be done using logarithms.

Related Question