Probability/Combinatorics: # ways of picking 5 from 3 groups of 6

  • Thread starter Master1022
  • Start date
  • Tags
    Groups
In summary, the conversation discusses a probability question involving selecting 5 marbles from a bag of 18 with 6 of each color (red, blue, yellow). Two methods of solving the problem are presented, one using a counting argument and the other using equations. Further explanation is given by another participant, who simplifies the equation to P = 3P(R+B) = 3(P(RB) - 2P(R)). However, there is confusion about the final term in the equation.
  • #1
Master1022
611
117
Homework Statement
We have a bag of 18 marbles: 6 red, 6 blue, and 6 yellow. Now I randomly select 5 marbles from the bag without replacement. What is the probability that I have picked out EXACTLY 2 colors?
Relevant Equations
Combinatorics
Hi,

I was attempting the following question and was getting slightly stuck.

Question: We have a bag of 18 marbles: 6 red, 6 blue, and 6 yellow. Now I randomly select 5 marbles from the bag without replacement. What is the probability that I have picked out EXACTLY 2 colors?

Attempt: I tried to think about this problem in two different ways:

1) Pure counting argument such that ##p = \frac{\text{Number of ways which we pick 2 colors}}{\text{Total number of ways of picking 5 from 18}} ##

So my logic was as follows:
- there are ##\begin{pmatrix} 3 \\ 2 \end{pmatrix}## ways of picking 2 out of the three colors
- Then for each of those pairs of colors (let us call them A and B), we can do: (1 from A, 4 from B), (2 from A, 3 from B), (3 from A, 2 from B), (4 from A, 1 from B). This can be written more formally as:
[tex] \begin{pmatrix} 6 \\ 1 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 4 \end{pmatrix} + \begin{pmatrix} 6 \\ 2 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 3 \end{pmatrix} + \begin{pmatrix} 6 \\ 3 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 2 \end{pmatrix} + \begin{pmatrix} 6 \\ 4 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 4 \end{pmatrix} [/tex]

and thus this becomes:
[tex] \begin{pmatrix} 3 \\ 2 \end{pmatrix} \left( \begin{pmatrix} 6 \\ 1 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 4 \end{pmatrix} + \begin{pmatrix} 6 \\ 2 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 3 \end{pmatrix} + \begin{pmatrix} 6 \\ 3 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 2 \end{pmatrix} + \begin{pmatrix} 6 \\ 4 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 4 \end{pmatrix} \right) [/tex]

I am slightly confused on how to get the total number of ways of picking 5 from 3 groups of 6. I mean I can see the obvious ## \begin{pmatrix} 18 \\ 5 \end{pmatrix} ##, but doesn't that double count some groupings?? This was asked as an interview question, so I don't think I would have time to write down very elaborate alternative methods.

This would lead to:
[tex] p = \frac{\begin{pmatrix} 3 \\ 2 \end{pmatrix} \left( \begin{pmatrix} 6 \\ 1 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 4 \end{pmatrix} + \begin{pmatrix} 6 \\ 2 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 3 \end{pmatrix} + \begin{pmatrix} 6 \\ 3 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 2 \end{pmatrix} + \begin{pmatrix} 6 \\ 4 \end{pmatrix} \cdot \begin{pmatrix} 6 \\ 4 \end{pmatrix} \right)}{\begin{pmatrix} 18 \\ 5 \end{pmatrix}} = \frac{65}{238} [/tex]

2) The other 'method' was to frame the problem like: "how many solutions are there to the equation ## x_1 + x_2 = 5 ## where ## x_1 \geq 1 ## and ## x_2 \geq 1 ##.
- so there are still ##\begin{pmatrix} 3 \\ 2 \end{pmatrix}## ways of picking 2 out of the three colors
- then there would be ##\begin{pmatrix} (5 - 2) + (2 - 1) \\ (2 - 1) \end{pmatrix} = \begin{pmatrix} 4 \\ 1 \end{pmatrix} ## ways choosing the groups...

- For the total number of ways to pick 5 from 18, we could use a similar framing of ## x_1 + x_2 + x_3 = 5 ##, but instead just have ## x_1 , x_2, x_3 \geq 0 ##. This leads to ## \begin{pmatrix} 5 + (3 - 1) \\ (3 - 1) \end{pmatrix} = \begin{pmatrix} 7 \\ 2 \end{pmatrix} ##

This would lead to:
[tex] p = \frac{\begin{pmatrix} 4 \\ 1 \end{pmatrix} \cdot \begin{pmatrix} 3 \\ 2 \end{pmatrix}}{\begin{pmatrix} 7 \\ 2 \end{pmatrix}} = \frac{4}{7} [/tex]

Can anyone help to reconcile which one of these methods is more appropriate for this problem?

Many thanks.
 
  • Like
Likes Delta2
Physics news on Phys.org
  • #2
I would simply do:$$P = 3P(R+B) = 3(P(RB) - 2P(R))$$I'll let you work out the notation!
 
  • #3
PeroK said:
I would simply do:$$P = 3P(R+B) = 3(P(RB) - 2P(R))$$I'll let you work out the notation!
Thanks @PeroK ! Unfortunately, I have been looking at this for a while and am a bit confused. Here is what I have made of it. We are using the probability rule:

[tex] P(A \cup B) = P(A) + P(B) - P(A \cap B) [/tex]

You have P(R + B) as the ##P(R \cup B)##, but then I don't understand why the final term in the equation is ## P(R \cap B) - 2 \cdot P(R) ## instead of ## 2 P(R) - P(R \cap B) ##? (is that a correct understanding?
 
  • #4
Master1022 said:
Thanks @PeroK ! Unfortunately, I have been looking at this for a while and am a bit confused. Here is what I have made of it. We are using the probability rule:

[tex] P(A \cup B) = P(A) + P(B) - P(A \cap B) [/tex]

You have P(R + B) as the ##P(R \cup B)##, but then I don't understand why the final term in the equation is ## P(R \cap B) - 2 \cdot P(R) ## instead of ## 2 P(R) - P(R \cap B) ##? (is that a correct understanding?
Well, ##R + B## must indicate one of the events you are looking for; namely, only Red and Blue balls and at least one of each. I'm not sure I understand the idea of translating to set notation? Why not leave things as they are?

Do you understand the factor of ##3##?

I didn't want to make it too easy, so I wrote ##-2P(R)## instead of the more suggestive ##-P(R) - P(B)##.
 
  • Like
Likes Master1022
  • #5
PS I just checked the answer: ##65/238## is correct.
 
  • #6
PeroK said:
Well, ##R + B## must indicate one of the events you are looking for; namely, only Red and Blue balls and at least one of each.
Oh I was thinking in terms of Venn diagrams, when R + B (with + being a union), but I guess that isn't what you meant? Then what does (RB) represent - I would have thought that meant both red and blue colored balls.

PeroK said:
I'm not sure I understand the idea of translating to set notation? Why not leave things as they are?
Hmm, that is what came to mind when I saw the form of that equation...

PeroK said:
Do you understand the factor of ##3##?
I think that is from the 3C2 = 3 (i.e. the number of ways to choose 2 colors from 3)

PeroK said:
I didn't want to make it too easy, so I wrote ##-2P(R)## instead of the more suggestive ##-P(R) - P(B)##.
I understood the symmetry part of it (##P(R) = P(B)##) so we can combine them. I think my question was why the equation was ##P(RB) - 2P(R)## instead of the other way around (i.e. ##2P(R) - P(RB)##)
 
  • #7
Master1022 said:
I understood the symmetry part of it (##P(R) = P(B)##) so we can combine them. I think my question was why the equation was ##P(RB) - 2P(R)## instead of the other way around (i.e. ##2P(R) - P(RB)##)
I guess I should come clean:

##R + B## was only red and blue with at least one of each.

##RB## was only red and blue (i.e. no yellows) and includes the cases of all red and all blue. I guess I could have used ##no \ Y## instead.

##R## is all red.
 
  • #8
Actually the 18C5 makes sense if I think about the Vandermonde Identity.
 

FAQ: Probability/Combinatorics: # ways of picking 5 from 3 groups of 6

1. How many ways can 5 items be chosen from 3 groups of 6?

There are 216 possible ways to choose 5 items from 3 groups of 6. This can be calculated using the combination formula nCr = n!/(r!(n-r)!), where n is the total number of items (18 in this case) and r is the number of items being chosen (5 in this case).

2. Can the items be chosen from any group or are there restrictions?

The items can be chosen from any group without restrictions. As long as there are 5 items chosen in total, they can come from any of the 3 groups of 6.

3. What if there are more than 3 groups of 6 items?

If there are more than 3 groups of 6 items, the number of ways to choose 5 items will increase. For example, if there are 4 groups of 6 items, there will be 4C5 = 4 ways to choose 5 items.

4. Can the same item be chosen more than once?

No, in this scenario, each item can only be chosen once. If an item is chosen from one group, it cannot be chosen again from another group.

5. How does this relate to real-life situations?

This type of problem is commonly used in probability and combinatorics to calculate the number of possible outcomes in a given scenario. It can be applied to various real-life situations such as selecting a team from a pool of players or choosing a combination of items from a menu.

Back
Top