# “Incremental” hypergeometric distribution?

Box contains $5$ yellow and $3$ red balls. $4$ balls are drawn without replacement. Let $X$ be the number of yellow balls appearing in the first two draws, and let $Y$ be the number of yellow balls appearing in total. Give the joint probability distribution of $X$ and $Y$.

-

We want to find, for all relevant $x$ and $y$, the probability that $X=x$ and $Y=y$. Call this number $f_{X,Y}(x,y)$, or, for simplicity, $f(x,y)$.

There are not many possible values of $x$ and $y$, so we can find $f(x,y)$ for each combination. (Alternately, we can find a general formula for $f(x,y)$. For these small numbers, that is probably not worthwhile.)

We show how to find $f(0,y)$ for all possible values of $y$. The probability that $X=0$ (no yellow on the first two trials) is $\frac{3}{8}\cdot\frac{2}{7}$.

Given that there were no yellow on the first two trials, the probability that $Y=0$ is $0$, since there must be at least $1$ yellow in the next two trials. Thus $f(0,0)=0$.

Suppose there were no yellow on the first two. Then the probability of $1$ yellow overall is $\frac{1}{6}+\frac{5}{6}\cdot\frac{1}{5}=\frac{2}{6}$. Thus $f(0,1)=\frac{3}{8}\cdot\frac{2}{7}\cdot\frac{2}{6}$. This can, if we wish, be simplified. Now we have found $f(0,1)$.

Suppose there were no yellow on the first two trials. Then the probability of $2$ yellow in the next two trials is $\frac{5}{6}\frac{4}{5}=\frac{4}{6}$. Thus $f(0,2)=\frac{3}{8}\cdot\frac{2}{7}\cdot\frac{4}{6}$.

We may want to note that $f(0,3)=f(0,4)=0$.

Now you can do the same sort of calculations for $f(1,y)$ and $f(2,y)$.

Added: We develop a formula. There are $\binom{8}{2}\binom{4}{2}$ equally likely ways to choose $2$ balls and then $2$ mre. There are all equally likely. (Think of the balls as having invisible ID numbers.) This will be the denominator in all our probabilities.

For the numerator, we find the number of ways to have $x$ yellow in the first two, and $y$ yellow overall, so $y-x$ in the next two.

The $x$ yellow can be chosen in $\binom{5}{x}$ ways. The accompanying $2-x$ red can be chosen in $\binom{3}{2-x}$ ways. Now the $y-x$ yellow can be chosen from the $5-x$ remaining yellows in $\binom{5-x}{y-x}$ ways. And the $2-(y-x)$ red can be chosen from the $3-(2-x)$ remaining reds in $\binom{3-(2-x)}{2-(y-x)}$ ways. That gives a total of $$\binom{5}{x}\binom{3}{2-x}\binom{5-x}{y-x} \binom{3-(2-x)}{2-(y-x)} .$$ (In the formula, we use the convention that $\binom{a}{b}=0$ if $a\lt b$.)

-
I'd rather want to see a derivation of a general formula. – user54609 Apr 15 '13 at 2:00
I will add one, about $10$ minutes. – André Nicolas Apr 15 '13 at 2:02
For the denominator, shouldn't it be $\binom{8}{2}\binom{6}{2}$ – le.trong Nov 12 '13 at 5:58