Marble question - hypergeometric/binomial hybrid

Hi there everyone,

Usually these standard draw x red marbles and y blue marbles from a box questions are no issue but here is a variant and friend asked me which I'm scratching my head about a bit:

You have a box with 10 blue marbles and 5 red marbles. When you draw a blue marble you keep it (without replacement) but when you draw a red marble you put it back in the box (replacement).

When you draw 3 blue marbles the game is over.

What is the average number of marbles expected to be drawn per game?

Now, obviously the drawing process for blue marbles would be a simple hypergeometric distribution if there were no red marbles. But the red marbles are going to skew this.

My initial thoughts were something like this:

- We know that the game is always going to end when we draw the 3rd blue marble so we will always have exactly 2 blue marbles and some number between 0 and infinity or red marbles (should be monitonically decreasing after a certain point).

- P[3 Blues|No Reds] = (10/15) * (9/14) * (8/13) = 0.2637

- P[3B|1R] = ((10C2 * 5C1(the 1 red))/(15C3) ) * (8/13) = 0.3043

- P[3B|2R] = ((10C2 * 6C2)/(16C4)) * (8/13) = 0.2282

- P[3B|3R] = ((10C2 * 7C3)/(17C5)) * (8/13) = 0.15663

- P[3B|4R] = ((10C2 * 8C4)/(18C6)) * (8/13) = 0.1044

Basically it is (combination without repetition -for blues) * (combination with repetition - for reds) / total combination) * (8/13).

Then I would muliply the number of marbles * probability to get expected number of total balls drawn per game.

But this way won't work as the probabilities (although diminishing) are going to total over 1.

Any one have any thoughts on this? Probably something very simple I'm overlooking. I'm stumped all the same!

Thanks very much for any and all help.

Re: Marble question - hypergeometric/binomial hybrid

You draw a sea of reds, with blues on the i-th, j-th, and n-th (terminating) draws

1<=i < j < n

Ex: i = 4, j = 10, n = 15: R R R B R R R R R B R R R R B

The probabilitiy of such an string, is:

.

Therefore .

Thus

where .

Therefore

Have .

Thus

Therefore .

Therefore

But .

So .

Thus

Conclude that the expectation is .

(I'm going to double check this later - it took too long. However, it looks like a reasonable result.)

Re: Marble question - hypergeometric/binomial hybrid

Wow, thats an impressive answer. Thanks for taking the time out to respond, I really appreciate it.

Intuitively I would have thought it would have been slightly lower but I suppose if the Probability[n] does not tend to zero too rapidly it could easily cause the expectation to be higher than first guess. As you said, 10 is a pretty reasonable result.

I'm still reviewing your answer, but I can follow the logic down to P[i,j,n] without a problem. I'll go through the rest of the derivation now.

I'll just add, I'm surprised at how much meat there is in this question. My friend said this was asked at an interview (without a calculator I presume) - this would make me think that there is some recursive trick I'm not thinking of that might solve this quite elegantly but for now this is the best I've seen.

Thanks again

Re: Marble question - hypergeometric/binomial hybrid

Wow. I never before saw so much LaTeX in a forum post.

I wrote a quick simulation yesterday. I think I got an answer of about 4.68 marbles.

Re: Marble question - hypergeometric/binomial hybrid

Let's say E(R,B,n) is the expected number of draws required to draw n blue marbles, starting with R red marbles and B blue marbles; so we want to find E(5,10,3).

Starting with 5 reds and 10 blues, with probability 5/15 the first marble drawn is red. We then are then right back where we started, and on average we require a total of 1 + E(5,10,3) draws to draw a total of 3 blues. With probability 10/15, we draw a blue. We then require, on average, a total of 1 + E(5,9,2) draws to complete. So

Now suppose we have 5 red marbles and 9 blue marbles. Reasoning as before,

If we have 5 red marbles and 8 blue marbles,

Solving these equations from last to first, we find

which is close to the answer found by "a tutor" via simulation.