Ways of selecting 6 random balls from 6 blue, 9 red and 8 white balls

combinatorics

I'm studying probability from probabilitycourse.com and was reading the "Unordered sampling without replacement" section for a motivation on combinations. It's very nicely explained as follows: suppose there's $n$ items from which $k$ must be selected and order doesn't matter. Then the number of ordered samples would be $n(n-1)\ldots(n-k+1)$ and each unordered sample would've been overcounted by a factor of $k!$, so we divide by that, getting the usual $\binom{n}{k}$.

Now we turn to the question in the title and for the life of me, I can't apply the same kind of logic in this scenario. The answer seems to be $\binom{23}{6}$ but I can't understand why.

Another question relevant to this post is here: You have 6 red balls, 6 blue, and 6 white. You randomly select a sample of 5 balls. The number of ways to select $5$ balls from $6$ red, $6$ blue and $6$ white seems to be $\binom{18}{5}$

To make life easier I considered a simpler case – if there are $3$ red balls and $3$ yellow balls, and we have to randomly select $3$ from them.

Let's label the balls $a,b,c,d,e$ and $f$, and suppose the first three are red and the last three are yellow. The number of ordered pairs would be $6\times 5\times 4$. Adjusting for overcounting for triplets like $(a,d,e),(a,e,d),(e,a,d),(e,d,a),(d,a,e),(d,e,a)$, etc., we divide the whole thing by $3!$.

But haven't we still not adjusted for another kind of overcounting? Considering all triplets with, e.g., one red and two yellow as equivalent, triplets such as $(a,d,e)$ and $(b,d,f)$ are still overcounts, because all of them have one red and two yellow. So wouldn't $\binom{6}{3}$ be an overestimation? And is there a way to arrive at the correct answer without considering counts for individual cases like "two red, one yellow", "one red, two yellow", "three red", etc. and adding them up?

Best Answer

It all depends on what a "way" is. When do we consider two selections the same? Take the case of selecting $6$ balls from $23$ mentioned in the title. We might consider that all the balls are distinguishable, for example, they might be number from $1$ to $23$. Then the colors are red herrings. All we care about is the numbers, and the answer is indeed $\binom{23}{6}$. You can use your unordered sampling logic to arrive at this answer.

On the other hand, perhaps balls of the same color are indistinguishable. Then we simply want to know how many balls of each color we chose. So, as long as we have at least $6$ balls of each color, as we do in this case, the question is, how many solutions in nonnegative integers has the equation $$b+r+w=6$$ The answer is $$\binom 82$$ given by stars and bars.

Imagine the we put the select balls in a line. First the red balls then a divider, then the blue balls, then a divider, then the white balls. We have $8$ objects, and the answer is completely determined by which two of them are the dividers. Hence the answer.

If there were fewer than $6$ balls of one of the colors, then we'd have to make some adjustments. So long as the number is close to $6$ we can use stars and bars. If the discrepancy is larger, say we wanted to count the ways to choose $40$ balls from $30$ indistinguishable balls of each of $3$ colors, then a different method is advisable.