Tree Diagram & Counting Methods Prob & Stats Tree Diagrams When calculating probabilities, you need to know the total outcomes number of _____________ in the ______________. sample space Tree Diagrams Example Use a TREE DIAGRAM to list the Sample sample space of 2 coin flips. Space H H you could got H get… NowIf you T YOU On the first flip you could get….. H NowIfyou youcould got Tget… T T A tree diagram is a way of describing all the possible outcomes from a series of events A tree diagram is a way of calculating the probability of all the possible outcomes from a series of events A list of possible events could include • Picking a square on a chess board Black or white • Flipping a coin Head or tail • Taking a sweet from a jar of red, yellow and green sweets What is There different are 3 about outcomes the outcome here? or green Red, yellow All these events have definite outcomes CLICK Each event can be represented by a tree diagram Picking a sweet from a jar containing red, yellow and green sweets Picking a square on a chess board Flipping a coin REMEMBER – there are 3 outcomes BLACK HEAD RED WHITE TAIL YELLOW The diagram shows you have a choice of 2 paths (branches) The diagram shows you GREEN have a choice of 2 paths (branches) The diagram shows you have a choice of 3 paths (branches) CLICK The list of possible events and their outcomes are Probability of black = 0.5 • Picking a square on a chess board Probability of white = 0.5 Black or white Equal number of black and white squares Probability of head = 0.5 • Flipping a coin Therefore Equalofchance probability of head or Probability tailthe = 0.5 Head or tail of tails each outcome is • Picking a sweet from a jar of red, yellow and green sweets 0.5 Therefore the probability of each outcome is The remaining event needs more or green Red, 0.5 yellow investigation All these outcomes have definite probabilities CLICK EVENT : Picking a sweet from a jar of coloured sweets In the jar there are 12 red sweets 5 yellow sweets 8 green sweets Probability of picking a red is 12 out of 25 0.48 Probability of picking a yellow is 0.20 Probability of picking a green is 0.32 CLICK The tree diagrams can now be completed Picking a square on a chess board Probability of BLACK = 0.5 0.5 Probability of WHITE = 0.5 0.5 BLACK WHITE 0.5 0.5 Now we add the probabilities THE TREE DIAGRAM IS NOW COMPLETE CLICK Similarly, the tree diagram for flipping a coin is Picking a sweet from a jar of red,yellow and green sweets Probability of RED = 0.48 RED 0.48 Probability of yellow 0.2 YELLOW = 0.2 0.32 Probability of GREEN = 0.32 These are the outcomes The tree diagram is compete We must add the probabilities GREEN Tree Diagram Example Mr. Arnold’s Closet 3 Shirts 2 Pairs of Shoes 2 Pants Dress Mr. Arnold List all of Mr. Arnold’s outfits 1 2 Dress Mr. Arnold List all of Mr. Arnold’s outfits 1 2 3 4 Dress Mr. Arnold List all of Mr. Arnold’s outfits 1 2 3 4 5 6 Dress Mr. Arnold List all of Mr. Arnold’s outfits 1 2 3 4 5 6 7 8 Dress Mr. Arnold List all of Mr. Arnold’s outfits 1 2 3 4 5 6 7 8 9 10 Dress Mr. Arnold List all of Mr. Arnold’s outfits 1 2 3 4 5 6 7 8 9 10 11 12 Dress Mr. Arnold List all of Mr. Arnold’s outfits If Mr. Arnold picks an outfit with his eyes closed……. 1 2 P(brown shoe) = 3 6/12 1/2 4 P(polo) = 5 1/3 4/12 6 7 8 9 10 11 12 P(lookin’ cool) = 1 Multiplication Rule of Counting The size of the sample space is denominator of our the ___________ probability So we don’t always need to know what each outcome is, just the number of outcomes. Multiplication Rule of Compound Events If… X = total number of outcomes for event A Y = total number of outcomes for event B Then number of outcomes for A times y followed by B = x_______ = (x )(y) Multiplication Rule: Dress Mr. Arnold Mr. Reed had 3 EVENTS 2 shoes 2 pants 3 shirts How many outcomes are there for EACH EVENT? 2(2)(3) = 12 OUTFITS Permutations Sometimes we are concerned with how many ways a group of arranged objects can be __________. •How many ways to arrange books on a shelf •How many ways a group of people can stand in line •How many ways to scramble a word’s letters Example: 3 People, 3 Chairs Hercules driving We has 3 chairs. There are 3 people who need a lift. How many seating options are there? of each chair as 6 Think Seating Options! an EVENT 3 2 1 How many ways the Now Now that thethe first1st2 could is are filled? filled. st chair be filled? ndrd 1many 3(2)(1) = options 6ways OPTIONS How How many to forfill2 3 ?? Superman driving Batman driving Example: 5 People, 5 Chairs 5 4 3 The batmobile has 5 chairs. There are 5 people who need a lift. How many seating options are there? 2 1 =120 Seating Options Multiply!! This is a PERMUTATION of 5 objects Commercial Break: FACTORIAL denoted with ! 5! Multiply all integers ≤ the number 5! = 5(4)(3)(2)(1) = 120 0! = 1 1! = 1 Calculate 6! 6! = 6(5)(4)(3)(2)(1) = 720 What is 6! / 5!? Commercial Break: FACTORIAL denoted with ! 5! Multiply all integers ≤ the number 0! = 1 1! = 1 Calculate 6! What is 6! / 5!? 6(5)(4)(3)(2)(1) 5(4)(3)(2)(1) =6 Example: 5 People, 5 Chairs The batmobile has 5 chairs. There are 5 people who need a lift. How many seating options are there? 5! 5 4 3 2 1 =120 Seating Options Multiply!! This is a PERMUTATION of 5 objects Permutations: Not everyone gets a seat! It’s time for annual Justice League softball game. How many ways could your assign people to play 1st, 2nd, and 3rd base? What if I choose these 3? You have to choose 3 AND arrange them Think of the possibilities! Permutations: Not everyone gets a seat! It’s time for annual Justice League softball game. How many ways could your assign people to play 1st, 2nd, and 3rd base? What if I choose these 3? You have to choose 3 AND arrange them Think of the possibilities! Permutations: Not everyone gets a seat! It’s time for annual Justice League softball game. How many ways could your assign people to play 1st, 2nd, and 3rd base? What if I choose these 3? You have to choose 3 AND arrange them Think of the possibilities! Permutations: Not everyone gets a seat! It’s time for annual Justice League softball game. How many ways could your assign people to play 1st, 2nd, and 3rd base? BUT… What if I choose THESE 3? You have to choose 3 AND arrange them Think of the possibilities! Permutations: Not everyone gets a seat! It’s time for annual Justice League softball game. How many ways could your assign people to play 1st, 2nd, and 3rd base? BUT… What if I choose THESE 3? You have to choose 3 AND arrange them Think of the possibilities! Permutations: Not everyone gets a seat! It’s time for annual Justice League softball game. How many ways could your assign people to play 1st, 2nd, and 3rd base? BUT… What if I choose THESE 3? You have to choose 3 AND arrange them Think of the possibilities! Permutations: Not everyone gets a seat! It’s time for annual Justice League softball game. How many ways could your assign people to play 1st, 2nd, and 3rd base? BUT… What if I choose THESE 3? This is going to take FOREVER You have to choose 3 AND arrange them Think of the possibilities! You have 3 EVENTS? How many outcomes for each event How many outcomes for this event! 5 You have to choose 3 AND arrange them You have 3 EVENTS? How many outcomes for this event! 4 Now someone is on FIRST 5 You have to choose 3 AND arrange them You have 3 EVENTS? 5(4)(3) = 60 POSSIBLITIES And on SECOND 4 Now someone is on FIRST 3 How many outcomes for this event! You have to choose 3 AND arrange them 5 Permutation Formula You have n objects You select r objects This is the number of ways you could select and arrange in order: n! P (n r )! n r Another common notation for a permutation is nPr Softball Permutation Revisited n 5!! 5(4)(3)(2)(1) n people to choose from 5 n= Pr 2!3)! r )! r = 3 spots to fill ((5n –2(1) 5(4)(3) = 60 POSSIBLITIES You have to choose 3 AND arrange them Combinations Sometimes, we are only concerned with selecting a group and not the order in which they are selected. A combination gives the number of ways to select a sample of r objects from a group of size n. Combination: Duty Calls There is an evil monster threatening the city. The mayor calls the Justice League. He requests that 3 members be sent to combat the menace. The Justice League draws 3 names out of a hat to decide. Does it matter who is selected first? NOPE Does it matter who is selected last? NOPE Combination: Duty Calls Let’s look at the drawing possibilities STOP! This is a waste of time These are all the SAME: We’ll count them as ONE OUTCOME The monster doesn’t care who got drawn first. All these outcomes = same people pounding his face These are all the SAME: The monster doesn’t care who got drawn first. We’ll count them as ONE OUTCOME All these outcomes = same people pounding his face Combination: Duty Calls Okay, let’s consider other outcomes 10 Possible Outcomes! Combination Formula You have n objects You want a group of r objects You DON’T CARE what order they are selected in n! C r!(n r )! n r Combinations are also denoted nCr Read “n choose r” Duty Calls: Revisited to choose from n = 5 people ORDER DOESN’T MATTER r = 3 spots to fill C n r 5(4)(3)(2)(1) n! 5! 3(2)(1)(2)(1) 3!(5 r!(3!(2)! n -3)! r )! 10 Possible Outcomes! Now we can go save the city 20 2 Permutation vs. Combination Order matters Permutation Order doesn’t matter Combination