2
$\begingroup$

So I've read this explanation and the answer given by Andi R helped to give me some intuition of my problem. Now would like to understand it more mathematically rigorously.

Suppose we have a jar of marbles with $r$ red balls and $w$ white balls. We draw n balls. Find the expected number of red balls. From the expectation of a hypergeometric random variable know that the expected number of red balls is going to be $\frac{nr}{r + w}$

Let's now use the method of indicators random variables to point at my problem. Let $X$ be the number of red balls.

$$X = X_1 + X_2 + X_3 +... + X_n$$

$$\begin{align*} X_i&=\begin{cases} 1,&\text{if }i\text{-th ball selected is red}\\ 0,&\text{otherwise} \end{cases}\\ \end{align*}$$

By linearity of expectation,

$$E[X] = \sum_i{E[X_i]} = \sum_i {P(X_i = 1)}$$ That all makes sense to me. Here's where I start to get confused. $$P(X_i = 1) = \frac{r}{r+w}\quad \forall i$$

However let's look at our second ball for example, using the law of total probability: $$P(X_2 = 1) = P(X_2 = 1| X_1 = 1)P(X_1 = 1) + P(X_2 = 1| X_1 = 0)P(X_1 = 0)$$ $$P(X_2 = 1) = \frac{r - 1}{r + w - 1}\frac{r}{r+w} + \frac{r}{r + w - 1}\frac{w}{r+w} \neq \frac{r}{r+w}$$

Where am I going wrong? Did I use the total law of probability wrong? We draw the balls successively so the probabilities can't be the same, can it?

$\endgroup$
4
  • 2
    $\begingroup$ I can only find one mistake which (fortunately) is $\cdots\neq\cdots$. $\endgroup$
    – drhab
    Jun 24, 2020 at 13:58
  • 1
    $\begingroup$ $(r-1)r+rw=r(r+w-1)$ $\endgroup$
    – saulspatz
    Jun 24, 2020 at 13:59
  • $\begingroup$ You two are totally correct, I made a algebraic error on my scrap paper! $\endgroup$
    – BigBear
    Jun 24, 2020 at 14:01
  • $\begingroup$ Thank you so much! $\endgroup$
    – BigBear
    Jun 24, 2020 at 14:02

1 Answer 1

1
$\begingroup$

OP here- I made an algebraic error as @drhab and @saulspatz pointed out.

From what I wrote:

$$P(X_2 = 1) = \frac{r - 1}{r + w - 1}\frac{r}{r+w} + \frac{r}{r + w - 1}\frac{w}{r+w} \\ = \frac{r(r-1)}{(r+w-1)(r+w)} + \frac{rw}{(r+w-1)(r+w)} \\ = \frac{r(r-1) + rw}{(r+w-1)(r+w)} \\ = \frac{r^2 +rw-r}{(r+w-1)(r+w)}\\ = \frac{r(r + w-1)}{(r+w-1)(r+w)}\\ = \frac{r}{r+w} $$

And a very similar algebraic motions can be followed for $X_3 = 1$, $X_4 = 1$, and so forth...

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.