STAT 400

Mon. February 3rd, 2020


Permutations vs. Combinations

There’s an important distinction between the experiments “Toss a coin three times” and “Toss three identical coins at once”.

For the first, the outcomes are distinct, so we can use tuples to represent the events (thus ordering the outcomes) and use the product rule to count the sample space: S={HHH, HHT, HTH, HTT, THH, THT, TTH, TTT}S=\{HHH,\ HHT,\ HTH,\ HTT,\ THH,\ THT,\ TTH,\ TTT\}

For the second, the outcomes are not distinct, so our sample space is different: S={HHH, HHT, HTT, TTT}S=\{HHH,\ HHT,\ HTT,\ TTT\}

Definition. An ordered sequence is called a permutation. An unordered subset is called a combination.
We denote by Pk,nP_{k,n} the number of permutations of size kk that can be made with nn objects, and likewise by Ck,nC_{k,n} (or (nk){n \choose k}) the number of combinations.


Ex. A match between two teams has 5 rounds. Each round is one-on-one. The coach needs to pick 5 players out of 9 team members to play. How many choices do they have in total?

The rounds are ordered, so we need to count permutations: N(S)=P5,9N(S)=P_{5,9}. P5,9=98765=9!4!.P_{5,9}=9\cdot 8\cdot 7\cdot 6\cdot 5=\frac{9!}{4!}.
By this logic, we see that in general, Pk,n=n(n1)(n2)...(nk+1)=n!(nk)!.P_{k,n}=n(n-1)(n-2)...(n-k+1)=\frac{n!}{(n-k)!}.


Ex. Draw four cards from a standard deck of cards, including two jokers (54 cards in total). What is the probability that all four cards are the same rank?

A={four of the same rank}N(A)=13 (since there’s 13 ranks)\begin{gathered} A=\{\text{four of the same rank}\}\\ N(A)=13\ \text{(since there's 13 ranks)} \end{gathered}

The order of the cards doesn’t matter, so to find the size of the whole sample space we need to count combinations: N(S)=C4,54N(S)=C_{4,54}.
For each combination of 44 elements, there are 43214\cdot 3\cdot 2\cdot 1 permutations that represent it. P4,54=C4,544!C4,54=P4,544!=54!50! 4!P_{4,54}=C_{4,54}\cdot 4!\rightarrow C_{4,54}=\frac{P_{4,54}}{4!}=\frac{54!}{50!\ 4!}
By this logic, we see that in general, Ck,n=Pk,nk!=n!(nk)! k!.C_{k,n}=\frac{P_{k,n}}{k!}=\frac{n!}{(n-k)!\ k!}.

Returning to the problem, since each rank is equally likely to be selected, our final probability is simply P(A)=N(A)N(S)=1350!4!54!.P(A)=\frac{N(A)}{N(S)}=\frac{13\cdot 50!\cdot 4!}{54!}.


Ex. Suppose a music playlist contains 100 songs. Ten of them are by The Cranberries. Songs are selected randomly from the list and played. What is the probability that the first Cranberries song played is the sixth song played?

We can represent the playlist as an ordered sequence. Since we only care about the songs up to and including the sixth, we can ignore the rest of the list, giving us a sequence of length 6. Thus, N(S)=P6,100N(S)=P_{6,100}.

In order for our event to succeed, the first five songs need to be not by The Cranberries, and the sixth one does. Thus, N(A)=P5,9010N(A)=P_{5,90}\cdot 10. (Note that even though the order of these songs doesn’t matter, we’ve represented our sample space with permutations, so we must represent the event with permutations as well. Otherwise we’re comparing apples to oranges.)

Finally, P(A)=N(A)N(S)=P5,9010P6,100.P(A)=\frac{N(A)}{N(S)}=\frac{P_{5,90}\cdot 10}{P_{6,100}}.


Conditional Probability

If you want to know the probability that some event AA occurred, and you already know that another event BB occurred in the same experiment, then you can shrink your sample size to accommadate for this extra information, which affects the probability.

Definition. For any two events AA and BB with P(B)>0P(B)\gt 0, the conditional probability of AA, given that BB occurred, is defined by P(AB)=P(AB)P(B).P(A\mid B)=\frac{P(A\cap B)}{P(B)}.

Ex. A store is analyzing the behavior of its shoppers, focusing on the purchase of milk products and diapers. They sampled 100 customers:

  1. What is the probability that a customer bought milk products (AA)?
    • P(A)=18100P(A)=\frac{18}{100}.
  2. What is the probability that a customer bought diapers (BB)?
    • P(B)=12100P(B)=\frac{12}{100}.
  3. If a customer bought diapers, what is the probability that they will buy milk products?
    • P(AB)=P(AB)P(B)=1012P(A\mid B)=\frac{P(A\cap B)}{P(B)}=\frac{10}{12}.