# Explain whether or not the three probabilities add to unity. Combinations with replacement?

Problem (1): A storage contains 200 computers; 5 are defective and 195 are fine. Two computers are selected randomly with replacement.

1. Calculate the probability that neither computer is defective (correct?) $$\frac {\binom {195+2-1}{2}}{\binom {200+2-1}{2}}$$
2. Calculate the probability that exactly one computer is defective (correct?) $$\frac {\binom {5+1-1}{1}\binom {195+1-1}{1}}{\binom {200+2-1}{2}}$$
3. Calculate the probability that both computers are defective (correct?) $$\frac {\binom {5+2-1}{2}}{\binom {200+2-1}{2}}$$
4. Explain whether or not the three probabilities you have just calculated should add to unity

Question 4 I don't really understand.

Problem (2): ...without replacement.

1. Calculate the probability that neither computer is defective $$\frac {\binom {195}{2}}{\binom {200}{2}}$$
2. Calculate the probability that exactly one computer is defective $$\frac {\binom {5}{1}\binom {195}{1}}{\binom {200}{2}}$$
3. Calculate the probability that both computers are defective $$\frac {\binom {5}{2}}{\binom {200}{2}}$$
4. Explain whether or not the three probabilities you have just calculated should add to unity

All three add to 1. Should these three add to unity because of their mutual exclusiveness and exhaustiveness? Please clarify my thoughts.

Edited: Much thanks for every single answer and comment! In the mean time I came up with the tree diagram to visualize the solutions: • In your first problem, you say you don't understand question 4, but in the second problem you write "All three add to 1. Should these three add to unity because of their mutual exclusiveness and exhaustiveness." Apply that thought process to the first problem. That being said they should have added to one, but looking at your work for the first problem the numbers all look to be off. Ask yourself again what the sample space is and what the sample space size is. Remember, if you are drawing with replacement it might help to temporarily assume that order matters to make things easier. – JMoravitz Aug 9 '17 at 13:31
• Hi. Thanks for commenting. It's because I don't get the combinations with repetition – maliiaButterfly Aug 9 '17 at 13:35
• Your error seems to come from the fact that you are trying to use the "combinations with repitition" formulas (though you forgot to do so for the denominator as well) however those are not going to be equally likely to occur (you can convince yourself of this with a smaller example). Like I suggested, take order as being relevant. There are $200$ options for the first computer and $200$ options again for the second computer. Apply multiplication principle. Of these, if neither is defective the first isn't defective (195 options) and the second isn't defective (195 options)... – JMoravitz Aug 9 '17 at 13:41
• The only especially challenging fix that needs to be done in this is correctly interpreting the phrase "exactly one is defective" in the scenario that we consider order to be relevant. Here, we recognize that with order being relevant this corresponds to the first being defective and the second working properly or the first working properly and the second being the one that is defective. – JMoravitz Aug 9 '17 at 13:44
• Adding to unity is just a fancier way of saying adding to $1$. You already gave a good and correct explanation yourself for the second half (i.e. pointing out the mutual exclusiveness and exhaustiveness of the three cases) and that explanation is equally valid for the first half. As for question 2, I already began explaining that a few comments ago. Pick whether the defective is the first or the second (2 options). Pick which defective computer it is (5 options). Pick which working computer it is (195 options). Remember $200^2=(195+5)^2=195^2+2\cdot 195\cdot 5+5^2$ – JMoravitz Aug 9 '17 at 14:48

In the first problem, sampling is done with replacement (which is not the best way to check for defective products). Therefore, we can use the binomial distribution.

The probability of selecting $k$ good computers and $n - k$ bad computers when $n$ computers are selected with replacement is $$\binom{n}{k}p^k(1 - p)^{n - k}$$ where $\binom{n}{k}$ represents the number of orders in which exactly $k$ good computers can be selected in $n$ trials, $p$ is the probability that a good computer is selected, and $1 - p$ is the probability that a defective computer is selected.

Two good computers are selected: Using the formula given above with $n = k = 2$ and $p = 195/200$ yields $$\binom{2}{2}\left(\frac{195}{200}\right)^2\left(\frac{5}{200}\right)^0 = \left(\frac{39}{40}\right)^2$$

One good and one defective computer are selected: Using the formula given above with $n = 2$, $k = 1$, and $p = 195/200$ yields

$$\binom{2}{1}\left(\frac{195}{200}\right)^1\left(\frac{5}{200}\right)^1 = 2\left(\frac{39}{40}\right)\left(\frac{1}{40}\right)$$

Two defective computers are selected: Using the formula given above with $n = 2$, $k = 0$, and $p = 195/200$ yields

$$\binom{2}{0}\left(\frac{195}{200}\right)^0\left(\frac{5}{200}\right)^2 = \left(\frac{1}{40}\right)^2$$

Since the three events described above are mutually exclusive and exhaustive, their probabilities should add to $1$, which you should check.

• The combinations with repetition method is not valid since the individual events are not equally likely. The calculation $$\frac{195}{200} \cdot \frac{5}{199} + \frac{5}{200} \cdot \frac{195}{199} = \frac{1950}{39800} \approx 0.0489949748744$$ gives the probability of selecting one good computer and one defective computer when selections are made without replacement. If you want to do the calculation with replacement, you should have $$\frac{195}{200} \cdot \frac{5}{200} + \frac{5}{200} \cdot \frac{195}{200} = 0.04875$$ which agrees with the binomial distribution calculation. – N. F. Taussig Aug 9 '17 at 17:08