# AP Stats homework

Probability questions, a die is thrown repeatedly....

Calculate the probability generator for the number of the throw on which the $r^\text{th}$ sixth appears.

Therefore calculate the probability that the fifth six occurs on the 20th throw, and find the mean, and standard deviation for the number of the throw on which the $r^\text{th}$ six appears...

Hints greatly appreciated! And some final answers to check against.

Let random variable $X$ be the total number of throws until the $r$-th $6$ appears. We find the probability that $X=n$.

The $r$-th $6$ appears on the $n$-th throw if the following two events happen:

(i) There are exactly $r-1$ $6$'s in the first $n-1$ throws;

(ii) There is a $6$ on the $r$-th throw.

The probability of (i) can be computed by using the binomial distribution. We want the probability of exactly $r-1$ "successes" in $n-1$ independent trials, where the probability of success is $1/6$, and therefore the probability of failure is $5/6$. So the probability of (i) is $$\binom{n-1}{r-1}\left(\frac{1}{6}\right)^{r-1}\left(\frac{5}{6}\right)^{(n-1)-(r-1)}.$$

Given that (i) has happened, the probability of (ii), by independence, is $1/6$. So we multiply the result of (i) by $1/6$, and find that $$\Pr(X=n)=\binom{n-1}{r-1}\left(\frac{1}{6}\right)^{r}\left(\frac{5}{6}\right)^{n-r}.$$ Note that this formula holds only for $n\ge r$. For $n\lt r$, the probability that $X=n$ is $0$.

We have used the notation $\binom{a}{b}$ for what may be called $C(a,b)$ in your course, or perhaps $C_b^a$.

Remark: The mean and standard deviation are somewhat complicated to get at. There are standard formulas, that you can look up by searching for the negative binomial distribution.

I am not familiar with the AP Stats curriculum, so do not know what method they use, and am concerned about using techniques you have not met.

For the probability generating function, we want to evaluate the sum $$\sum_{n=r}^\infty \binom{n-1}{r-1}p^{r}(1-p)^{n-r}t^n,$$ where $p=1/6$. You can take a common factor $\frac{p^r}{(1-p)^r}$ from each term, and obtain $$\frac{p^r}{(1-p)^r}\sum_r^\infty \binom{n-1}{r-1} ((1-p)t)^n.$$ Let $x=(1-p)t$. Perhaps you will recognize the sum as coming from Newton's generalized Binomial Theorem.