A box contains $w$ white balls and $b$ black balls. Each time we pick a ball without replacement until there are no white balls left. What is the expected number of black balls remaining in the box ?
[Math] Expected number of balls remaining
expectationprobability
Related Solutions
First, we need the probability that among the first five balls, excactly three were black (and therefore two were white). This is a standard hypergeometric probability exercise, and the answer is $$ \frac{\binom53\binom72}{\binom{12}5} = \frac{35}{132} $$ Then, the probability that after this, the sixth ball is white. At this point there are seven balls left, and five of them are white. So the probability of drawing one of them as the seventh ball is $$ \frac{5}{7} $$ Now just multiply these two probabilities together, and you get your $\frac{25}{132}$.
As other people have pointed out, choosing 3 balls to remove from the box, or choosing 3 balls to leave behind in the box, can be done in the same number of ways, so the answers to (a) and (b) should be equal. But let's check directly that they are the same. For convenience's sake, assume the balls are distinguishable (eg: numbered 1-10 on the white, and 11-25 on the black).
Part (a): There are $\binom{25}{3}$ ways to choose 3 balls out of 25. The number of ways to pick exactly 2 white and 1 black is $\binom{10}{2} * \binom{15}{1}$, so our overall answer is
$$\frac{\binom{10}{2} * \binom{15}{1}}{\binom{25}{3}} = \frac{45*15}{2300} = \frac{27}{92}.$$
Part (b): There are $\binom{25}{22}$ ways to choose 22 balls out of 25. If 2 balls left are white and 1 is black, that means we chose 8 white balls and 14 black balls in our set of 22, and there are $\binom{10}{8}*\binom{15}{14}$ ways to make those picks. But since $\binom{n}{r} = \binom{n}{n-r}$:
- $\binom{25}{22} = \binom{25}{3}$
- $\binom{10}{8} = \binom{10}{2}$
- $\binom{15}{14} = \binom{15}{1}$
and the probability is, once again,
$$\frac{\binom{10}{8} * \binom{15}{14}}{\binom{25}{22}} = \frac{\binom{10}{2} * \binom{15}{1}}{\binom{25}{3}} = \frac{27}{92}.$$
Best Answer
Let $X$ be the number of black balls remaining when the last white ball is drawn. We wish to find $E[X]$.
Number the black balls; call them $B_1,B_2,\dots,B_b$. For $1\le j\le b$, let $X_j$ be the "indicator variable" which takes the value $1$if $B_j$ remains in the box when the last white ball is drawn, $0$ otherwise. Observe that $X=\sum_{j=1}^bX_j$. By linearity of expectation, $E[X]=\sum_{j=1}^bE[X_j]=bE[X_1]=bP(X_1=1)=bp$, where $p$ is the probability that $B_1$ is still in the box when the last white ball is drawn.
We have to determine the value of $p$. What is the probability that all of the white balls are drawn ahead of $B_1$? Note that the other black balls are irrelevant; we may as well throw them away. The box contains one black ball, $B_1$, and $w$ white balls. What is the probability that the black ball is drawn last? Plainly that probability is $\frac1{1+w}$, so the final answer is $E[X]=\frac b{1+w}$.