3

In an urn there are $n$ red balls and $m$ blue balls. I extract them without replacement. Let $X$=time of first blue. What is $E(X)$?

I found PMF of $X$ and it is, if $k > n+1$

$$P(X=k) =\frac{n(n-1) \dots (n-k+1)m}{(m+n)(m+n-1) \dots (n+m-k+1)}$$

How could I evaluate $E(X)$?

Edit: I'm looking for an explicit form of $E(X)$

N. F. Taussig
  • 76,571
ictibones
  • 1,914

2 Answers2

2

For clarity, let there be $b$ blue balls and $r$ red ones.

By symmetry the gaps between the blue balls should be of equal length. Thus the answer is $$\boxed{E[r,b]=\frac r{b+1 }+1}$$

Sanity check: suppose there are $1$ red balls and $2$ blue ones. Then the answer is $1$ with probability $\frac 23$ and $2$ with probability $\frac 13$ so $E=\frac 43$ and of course $\frac {1}{1+2}+1=\frac 43$. More generally, with $1$ red and $b$ blue then the answer is $$E=1\times \frac b{b+1}+2\times (1-\frac b{b+1})=\frac {b+2}{b+1}=\frac 1{b+1}+1$$

lulu
  • 70,402
  • @drhab Didn't look at your answer. Will now. – lulu Sep 26 '17 at 13:26
  • @drhab The recursion I see is $E[n,m]= \frac {m}{m+n}\times 1+ \frac n{m+n}\times (E[m-1,n]+1)$ . Is this the same as yours? – lulu Sep 26 '17 at 13:29
  • 1
    @drhab Ah, I think I've mangled $n,m$. (why on earth wouldn't one use $r,b$?) I meant what you wrote. – lulu Sep 26 '17 at 13:39
  • @drhab Yes...I don't see what I am saying incorrectly, but I am increasingly unhappy with my result. Seems to be wrong for $n=2,m=2$ for example. Yet I am sure I have the symmetry principle right. Will delete while I check. – lulu Sep 26 '17 at 13:49
  • @drhab the problem, as usual, is that I am an idiot. I have corrected the error (though of course might have made others). – lulu Sep 26 '17 at 13:56
  • I will delete my comments and have a second look (or later perhaps). You are a what?... Well, if it comes to probability theory than I strongly disagree with that. I still am in fear that my answer could be wrong. If you find an error (don't feel forced to search for it) in it then please let me know. Thanks! – drhab Sep 26 '17 at 14:08
  • I have found a mistake in mine. Working out of recursion is more complicated. It should have been $1+\frac{n}{n+m}+\frac{n}{n+m}\frac{n-1}{n-1+m}+\cdots$ – drhab Sep 26 '17 at 14:21
  • You could have linked your answer in this post or perhaps marked this question as a duplicate. – StubbornAtom Sep 26 '17 at 17:08
  • I am embarrassed to state that I didn't even recall my prior answer. – lulu Sep 26 '17 at 17:18
1

Assume there are $r$ red and $b$ blue balls. We define the random variables as

$X_1$ : number of red balls preceding the first blue ball.

$X_i$ : number of red balls drawn following the appearance of the $(i-1)$th blue but before the appearance of the $i$th blue ball,$\quad i=2,3,...$

$X_{b+1}:$ number of red balls drawn following the appearance of the $b$th blue.

So, $X_1+X_2+...+X_{b+1}=r$; note that the $(X_{i})_{i=1,2,...,b+1}$'s are identically distributed.

Thus from the linearity of expectation, $(b+1)\mathbb{E}(X_1)=r\Rightarrow \mathbb{E}(X_1)=\dfrac{r}{b+1}$

Now, let $Y:$ number of draws needed to get the first blue ball.

Then, $Y=X_1+1\Rightarrow \mathbb{E}(Y)=\mathbb{E}(X_1)+1$, which is the required answer.


We can also calculate $\mathbb{E}(X_1)$ directly from the pmf

$$\mathbb{P}(X_1=k)=\frac{b}{r+b}.\frac{(r)_k}{(r+b-1)_k}\quad,k=0,1,...,r$$

StubbornAtom
  • 17,052
  • So...you agree the answer is just $\frac r{b+1}+1$ as follows from symmetry? – lulu Sep 26 '17 at 14:40
  • 2
    @lulu Believe it or not, my intuition is not that great to see the symmetry. Hence the crass analytical approach. – StubbornAtom Sep 26 '17 at 14:43
  • Oh, that's not my point at all. I just was confused by your answer. Wanted to confirm that you were agreeing with the basic formula. – lulu Sep 26 '17 at 14:53
  • @lulu Of course our final answers are correct. – StubbornAtom Sep 26 '17 at 15:01
  • 1
    For intuition: suppose that there was one Green marble and that the marbles were arrayed in a necklace. Then you'd agree that the strings of reds should have the same expected length. And there are $b+1$ strings of reds. That's the entire symmetry argument. – lulu Sep 26 '17 at 15:02