Chapter 3 Combiatorics 3.1 Permutatios Readig questios 1. Defie what a permutatio is i your ow words. 2. What is a fixed poit i a permutatio? 3. What do we assume about mutual disjoitedess whe creatig a tree diagram? 4. What is the Birthday Problem? 5. Reflectio: Tell me at least oe questio you have, or at least oe thig you foud uclear, related to this sectio. 6. Try this problem (iclude your work i the assigmet): Exercise 3.1.2. Coutig Problems Cosiderig a experimet that is carried out i stages, each stage with some umber (ot ecessarily the same umber) of possible outcomes which are idepedet of the outcomes of previous stages. We wat to cout the umber of ways the experimet ca be performed. Example 24. Coutig Techique: The Product Rule Theorem 3.1.1 (The Product Rule). If a task is to be completed i r stages, where the first stage ca be doe i 1 ways, the secod i 2 ways, ad i geeral the ith ca be doe i i ways, ad the way i which the ith stage is completed 23
24 CHAPTER 3. COMBINATORICS does t affect the umber of ways to complete the remaiig stages, the the r stages ca be completed i 1 2 r ways. Tree Diagrams to com- Nodes ad leaves represet probabilities, braches labeled with outcomes. We pute the probability of each path. Aother Coutig Techique: The Sum Rule Theorem 3.1.2 (The Sum Rule). If exactly oe task i a set of k tasks must be doe, where the first task ca be doe i 1 ways, the secod i 2 ways, ad i geeral the ith ca be doe i i ways, ad the way i which the ith task is completed does t affect the umber of ways to complete the remaiig tasks, the the umber of ways to choose ad perform that oe task is 1 + 2 + + k. Example 25 (Exercise 3.1.16). Birthday Problem How may people do we eed i a room i order to have a greater tha 0.5 chace that at least two people share the same birthday (day ad moth)? What is the probability that o two people i this room share the same birthday?
3.1. PERMUTATIONS 25 Permutatios ad Factorials Defiitio 15. Let A be ay fiite set. A permutatio of A is a of A oto itself. Notatio Theorem 3.1.3. The total umber of permutatios of a set A of elemets is ( 1) ( 2) 2 1 =!. Theorem 3.1.4. Let A be a -elemet set ad let 0 k. The the total umber of k-permutatios of A is This umber is deoted by () k, P (, k), P k, or P k. Example 26 (Exercise 3.1.14). ( 1) ( 2) ( k + 1) =! ( k)!.
26 CHAPTER 3. COMBINATORICS Fixed Poits ad Records Defiitio 16 (Fixed Poit of a Permutatio). A fixed poit of a permutatio is a elemet of the set A which is mapped to itself. Example 27. Defiitio 17 (Record). Let σ be a permutatio of the set {1, 2,..., }. σ(j) < σ(i) for every j < i. The i is a record of σ if either i = 1 or Example 28.
3.2. COMBINATIONS 27 3.2 Combiatios Readig questios 1. How are biomial coefficiets related to Pascal s Triagle? 2. Defie Beroulli Trials i your ow words. 3. Give a example (ot from the book) of a Beroulli trials process. 4. Give oe real life applicatio of a Galto board. 5. Reflectio: Tell me at least oe questio you have, or at least oe thig you foud uclear, related to this sectio. 6. Try these problems (iclude your work i the assigmet): Exercise 3.2.1(a)(b). I the previous sectio we looked at permutatios, which ca be thought of as ways of choosig elemets from a set. I this sectio we will look at combiatios, which ca be though of as ways of choosig elemets of a set. Example 29. How may ways are there to seat 4 people aroud a roud table? Example 30. A coach must pick three differet startig pitchers for the ext three games. If he has te pitchers i all, i how may ways ca he choose differet pitchers for the ext three games? Biomial Coefficiets Defiitio 18 (Biomial Coefficiets). The umber of distict subsets with j elemets that ca be chose from a set of elemets is deoted by (or or or ). This umber is called the biomial coefficiet. Theorem 3.2.1. The biomial coefficiets are give by the formula Corollary 3.2.2. Note that ( 0) = ( ) = 1.
28 CHAPTER 3. COMBINATORICS Theorem 3.2.3. For itegers ad j, where 0 < j <, the biomial coefficiets satisfy the equatio Proof. (Sketch) Q.E.D. Pascal s Triagle The th row of Pascal s Triagle has the etries Poker Hads Example 31. (a) How may 5-card hads are there i a stadard deck of 52 cards? (b) How may four-of-a-kid hads are there? (c) How may full house hads are there? (d) How may oe-pair hads are there? (e) How may two-pair hads are there?
3.2. COMBINATIONS 29 Example 32. There are 12 meats ad sausages available at a deli 1. How may ways ca you choose two of them? Example 33. How may 5-card hads are there i a stadard deck of 52 cards? Example 34. How may 16-bit strigs are there whose last six bits cotai four or more zeros? Example 35. How may 12-bit strigs are there with exactly seve zero bits? Example 36. How may words ca you make from the letters of MISSISSIPPI? Beroulli Trials Defiitio 19 (Beroulli Trials Process). A Beroulli trials process is a sequece of chace experimets such that 1. Each experimet has two possible outcomes, which we typically deote as ad. 2. The probability p of success o each experimet is the same for each experimet, ad this probability is ot affected by ay kowledge of previous outcomes. The probability q of failure is. 1 Cored beef, bologa, chorizo, prosciutto, salami, blood puddig, pacetta, leberkäse, headcheese, brauschweiger, baco wrapped baco, ad Spam.
30 CHAPTER 3. COMBINATORICS Biomial Probabilities ad the Biomial Distributio Theorem 3.2.4. Give Beroulli trials with probability of success p o each, the probability of exactly j successes is where q = 1 p. b(, p, j) = Example 37. Suppose we toss a [fair] coi three times. What is the probability that exactly oe head turs up? Defiitio 20 (Biomial Distributio). Let B be the radom variable that couts the umber of successes i a Beroulli trials process with parameters ad p. The the distributio b(, p, k) of B is called the. Example 38. Supposed that a lot of 5000 fuses cotais 5% defective fuses. 1. If a sample of five fuses is tested, what is the probability that at least oe will be defective? 2. If a sample of 20 fuses is tested, what is the probability that at least four will be defective? Example 39. Supposed we draw a card at radom from a deck 10 times (with replacemet ad shufflig betwee each draw) 1. What is the probability that we draw exactly four hearts? 2. What is the probability that we draw at most four hearts?
3.2. COMBINATIONS 31 Example 40. Supposed that experiece has show that 30% of all persos afflicted by a certai illess recover. A drug compay has developed a ew medicatio that they claim is effective to treat the disease.te people with the illess were selected at radom ad received the medicatio; ie recovered shortly thereafter (but all died evetually, sice... it is appoited for ma to die oce, ad after that comes judgmet ). Supposed the medicatio was absolutely worthless. What is the probability that at least ie of te receivig the medicatio will recover? Biomial Expasio Theorem 3.2.5 (The Biomial Theorem). Let x ad y be variables ad N. The ( ) (x + y) = x j y j j j=0 ( ) ( ) ( ) ( ) ( ) = x + x 1 y + x 2 y 2 + + xy 1 + y 0 1 2 1 ( ) ( ) ( ) ( ) ( ) or = x + x 1 y + x 2 y 2 + + xy 1 + 1 2 1 0 Proof. We ca prove this theorem usig a combiatorial (coutig) argumet: y Example 41. Fid the coefficiet of x 3 y 7 i (x + y) 10. Q.E.D.
32 CHAPTER 3. COMBINATORICS Corollary 3.2.6 (Let x = y = 1). k=0 ( ) = 2 k Corollary 3.2.7 (Let x = 1, y = 1). ( ) ( 1) k = 0 k k=0 Corollary 3.2.8 (Let x = 2, y = 1). ( ) 2 k = 3 k k=0 (There are may other similar corollaries.) Example 42. Fid 5 k=0 4 k( k).
3.2. COMBINATIONS 33 Iclusio-Exclusio Recall Theorem 1.2.5: Theorem 3.2.9. For A, B Ω, P (A B) = P (A) + P (B) P (A B) This geeralizes as the followig: Theorem 3.2.10 (The Priciple of Iclusio/Exclusio). Let P be a probability distributio o a sample space Ω ad let {A 1, A 2,..., A } be a fiite set of evets (i.e., A 1, A 2,..., A Ω). The P (A 1 A 2 A ) = For three sets this looks like P (A 1 A 2 A 3 ) = P (A 1 ) + P (A 2 ) + P (A 3 ) P (A 1 A 2 ) P (A 1 A 3 ) P (A 2 A 3 ) + P (A 1 A 2 A 3 ). Example 43. A survey of a large umber of magazie subscribers idicates that 40% subscribe to Cook s Illustrated, 30% to The Ecoomist, 50% to Cosumer Reports, 10% to both Cook s Illustrated ad The Ecoomist, 25% to both Cook s Illustrated ad Cosumer Reports, 15% to both The Ecoomist ad Cosumer Reports, ad 5% to all three. (a) What is the probability that a perso subscribes to at least oe magazie? (b) What is the probability that a perso subscribes to two magazies? (c) What is the probability that a perso subscribes to at least two magazies?
34 CHAPTER 3. COMBINATORICS Hat-Check Problem A group of hat-wearig people eter a restaurat ad leave their hats with the hat check girl, who is ew o the job ad forgets to put the ticket stubs with the correct hats. As a result, whe the group leaves everyoe is give a radom hat from the hats. What is the probability that o oe gets his ow hat back? If we view this through the les of permutatios, we are tryig to fid the probability that a radom permutatio (o a set A = {a 1, a 2,..., a } of elemets) cotais.