 Here we go. So what we're going to try to do today is to go beyond two cards. You've seen trees are nice, hopefully you've done a bunch of the trees and you're getting a hang of them. They're very visual. And in fact, they're still my fallback for if it's the same event over and over and over. Even if it's five E cards, as long as it's the same event over and over and over, I'll solve it with a tree approach. But today we're going to say, what if it's not? So for experiments with only a few draws from a deck of cards or pot, it's usually easiest to use a tree. My rule of thumb, Luke, two or three. Two always, three usually. More than two or three things, we're going to use a permutation combination approach. We're going to start out by looking at two cards, getting an answer, and seeing if we can get that same answer using permutations and combinations. So suppose two cards are drawn without replacement from a shuffle deck of 52 cards. Calculate the probability that they're both aces. Let's fill in this tree. So it will be ace, not ace, ace, not ace, ace, not ace. How many aces are there in the deck? Four out of. So this first level would be four out of 52 and 48 out of 52, right? Now, masked Avenger. Down this branch here, I've picked an ace, oh, masked Avenger. How many aces are now left in the deck? Who was that masked man? We'll forever wonder. How many non-aces are in the deck? Double check adds to one. Pretty sure we're right. Down this branch, down this branch, oh, French made, we did not get an ace. How many aces are left in the deck, madam? Out of 52 cards, 51. How many non-aces, 48 out of, no, not 48, Mr. Deweyke, we didn't get an ace. So 47 out of 51 and I could tell I'd written the wrong thing because I did my little adding check and I got 52 over 51 and I said, oh, I goofed. Now the probability that they're both aces, that's the probability that the first card is an ace and the probability that the second card is an ace given that the first card is an ace, that's the formula approach. I'm pretty sure it's that branch. The tree approach to me is much more visual, right? Ace, ace. What times what? 4 out of 52 times 3 out of 51. Now I know this is 12 out of 26, 52, but this time I'd like you to get your calculators out and reduce that for me, please, because when we use the combination approach it's going to give us reduced fractions or decimals. So now we're going to start to finally reduce our fractions at the very, very end. What is 12 over 26, 52, and lowest terms? 1 over 2, 2, and 1, okay. This is nothing new. In fact, I gave you this on your last quiz. I don't know if it was two aces, but I gave you questions like this. What we want to do is see if we can take a combinatorics approach. So using combinations, it says this. How many unordered, that's how I know it's a combination, unordered. How many unordered ways are there to pick 2 from 52? Well that's from 52 choose unordered 2. On your calculator, what is 52 choose? Someone crunched that for me, please? Sorry? 1, 3, 2, 6, okay. That's the total number of ways to pick 2 cards. You know how many ways you can get 2 cards? That many ways. Remember I've said to you if we can count it, we can solve it. We're going to use that here. How many ways are there to get 2 aces? Well, how many aces are there in the deck? 4 choose 2 of them. What is 4 choose 2? 6? Can someone check is 6 over 1326? Does that reduce to 1 over 221? It does. So my point here Chelsea is it looks like there is a way to get here with chooses. Now it's going to seem a little confusing still on this page. I'm going to give you an easy way to get to the equation on the next page. All I'm trying to convince you right now, Chelsea, is we got the same answer with two different methods. And I think this can be extended to more than 2 cards because it's not a tree. You could also have got there with permutations. You could have said I'd like to find the number of ordered ways to pick 2 from 52, which is 52p2. What is 52p2? 2652? I happen to notice that that's the bottom of my original list. I happen to notice that that's the bottom of my original fraction way up here. How many ways are there to permutate 2 aces? How many aces are in the deck? 4p2. How much do you want to bet that that's 12? Is it? So you could say 12 out of 2652, the number of aces divided by the number of cards, if you can count it you can solve it. And that also works to 1 over 221. So Matt, all I'm trying to do right now is convince you, apparently I can get the same answer with combinations or permutations. Now, I'm going to be honest, I almost never use permutations. Combinations are card questions. Because when you're dealing a deck of cards, when you're dealing a poker hand stuff, you don't care when you got the ace. You only care if you got the ace. Whether it was your last card or your first, who cares as long as it's in there? So what we're going to do is we're going to do some 5 card hands, and I'm going to give you a better way than this little scroll to do multi-card hands. Or if we're picking marbles, what if we're picking 5 marbles like the marble questions? What if we want 4 or 5 colored marbles instead of just 2 or 1? Example 1. Hannah, how many cards are we picking in example 1? What's the first word? 5. Tree? Say no. No. 2 cards? Yeah. 3 maybe. 5? No. Cards though, the order does not matter. What's the first hand they want me to get? Part A says, what do we want? A spade flush. Here is how I'm going to solve this. I'm going to bring back because it's a choose, it's a combination. Our old friend, the bucket. Over here I'm going to draw spades and not spades. How many spades are there in the deck, Greg? How many non-spades? 39, compliment. How many spades do they want me to choose? 5. How many non-spades do they want me to choose? Trick question. 0. Put your pencils down and look up once you've written that. Here is how you can calculate the odds of getting 5 spades. It's going to be the total number of ways to get 5 spades divided by the total number of ways to get 5 any cards. Let me say that again. It's going to be the total number of ways to get 5 spades divided by the total number of ways to pick 5 any cards. 13 choose 5 and 39 choose 0 divided by 52 choose 5. 5 spades and 0 others divided by all the cards. Which is what? Go to your calculator please and this time it's going to be a decimal but give me the answer to a decimal. Is a spade flush a good hand? The answer should be small then. I think you're going to get an answer in scientific notation. Are you not? And you need to practice doing this on your calculator which is why you want to try this. Otherwise you'll be able to write the equation but you won't be able to get the right answer. Kellen what'd you get? Oh never mind. Caught you zoning. Alex what'd you get? Round it off properly, 9.5. 4.95 times 10 to the... So I'm going to go like this. 4.95 times 10 to the negative 4 or 0.123495. The odds of getting a spade flush small. Why it's a good hand. What I'm going to do for a card or a marble question if order doesn't matter I'm going to draw a bucket. B. B. Chelsea can you read B to me please? This bucket's going to have 3 compartments. Spades, hearts and others. Chelsea how many spades are there in the deck? How many hearts? How many left over others? Yep. How many spades do they want me to choose? 3. How many hearts? How many others? Trick question. Here's what the equation's going to look like. 13 spades choose 3 and 13 hearts choose 2 and 39 Mr. Dewitt and 26 others choose none divided by 52 cards choose 5. Now before you start typing look up. What is 26 choose 0? 1. Well I typed that then. No did you guys type 39 choose 0 last time? Don't need to but I'm always going to write it here's why. Look up before you're typing Steph look up. Here is your built in error check for this method. If you add the first number look up look up look up Chelsea. If you add the first number and the first number you get the first number. If you add the last number and the last number you get the last number. Don't believe me? Add first plus first plus first it's first. Add last plus last plus last it's last. There is your built in error check to see if you've missed something. Did you follow that Chelsea? Handy. Also if you're not sure what goes on the bottom. That. That. You're ever wondering. Now start typing. Don't bother typing the 26 choose 0. So it's going to be 13 choose 3 and 13 choose 2 divided by 52 choose 5 not great odds 0.00858 00858 which actually kind of makes sense to me because how many different suits are there for if we're picking five cards shouldn't we on average have one of each and this is saying what are the odds of only two very good see three spades and two non spades once again bucket but here I'm only going to have two categories because it spades and non spades Leslie how many spades are in the deck kiddo how many non spades 39 right how we doing compliment right we're not counting right 52 minus 30 whatever how many spades do they want us to choose how many non spades what's the equation 13 choose 3 and 39 choose 2 that's how many ways to get three spades and non spades that's what we did last unit to turn it into a probability all we do is divide by the total number of outcomes Oh 52 choose 5 13 choose 3 times 39 choose 2 52 choose 5 0.0815 round it off properly mr. do it yes okay so this is there are exactly three spades D there are exactly how many spades two now it's going to be a very similar bucket spades and non spades let's see if we can use this bucket to get the equation let's see if we can jump straight to the punchline here it's going to be from 13 spades choose how many 2 and from 39 remaining choose how many 3 divided by that's how many different ways to get that hand divided by the total number of ways to get any hand 52 choose 5 I think I can just go second function enter change that 3 to a 2 change that 2 to a 3 0.2743 about a 27% chance that makes a bit more sense to me because getting 2 of the same color isn't that unlikely you okay there okay I have no idea what happened but I'm going to pick 5 cards 1 2 3 4 5 I've got about a 1 in 4 chance 27% of getting exactly 2 spades did I nope well actually that makes sense so I got about a 3 out of 4 chance of not getting exactly 2 spades in this case I got 1 getting 2 spades is not a good poker hand let's actually look at a half decent poker hand E 2 pair aces and kings bucket this is going to have 3 categories aces kings and the compliment whatever is left over other Sally how many aces are in the deck 4 how many kings are in the deck 4 how many others are left over compliment yes 44 how many aces did you want me to choose how many kings did you want me to choose how many others must I choose by default then 1 so this is gonna end up being 4 choose 2 and 4 choose 2 and from the remaining 44 choose 1 divided by divided by what well if you add the first numbers you do get 52 choose 5 this is a good hand odds should be small like I'm guessing less than 1% what do you get 6.09 times 10 to the negative 4 or .000609 um what's a better hand a flush or 2 pair a flush so check out your odds which one has a smaller number A or E A does just slightly doesn't it yep could you extend this to 7 Luke yeah fine I'm not going to bother 5 cards is kind of what I set up most of my stuff for but 7 cards your bucket would be maybe one more category and it would be 52 choose 7 on the bottom turn the page now when would you use permutations Hannah there's two answers to that the first answer is when it's clear the order matters but the second answer is really not very often and I'll show you what I mean example 2 says 3 prizes are awarded in a raffle 100 people each hold one ticket what's the probability that A B and C when first second and third places respectively what is the word respectively mean in that order it is a permutation okay and I'm going to show you how we can solve this with a permutation in just a second but remember I said not very often I can do this with a tree and it's a three level tree but I'm only going to draw one branch I'm going to draw Alice Ben and Conchetta that's the only branch I'm interested in Luke that's the only branch I'm interested in and the reason I can draw a tree for this one Leslie even though it's three levels is because each event is the same win win win I can keep track of one branch I think okay in fact how many Alice's are there in the group one out of how many people bought a ticket 100 okay Alice one how many Ben's are there in the card deck one out of how many cards are left 99 see where I'm going how many Conchettas are there in the card deck one out of how many cards are left 98 so one way of doing this is to go 1 over 100 times 1 over 99 times 1 over 98 and that ties into what you've already done but there is another way to do this that's shorter does order matter in this question Greg then out of 100 people there are 100 p3 ways to pick three winners where the order matters how many of those are our winning group of Alice, Ben and Conchetta only one by the way 100 p3 is 100 times 99 times 98 what do we get 1 over what is 100 p3 or what is 100 times 99 times 98 Alyssa read it to me 907,000 97 is that right ok now compare a blame with b does order matter in b blame my friend how do you know because it says not necessarily in that order cards is almost always order doesn't matter so if it's card question don't use choose here then I'm going to use a bucket and in my bucket I'm going to have winners and losers not winners how many winners are there in our bucket three how many losers are there in this group 97 how many winners do I want to choose all three how many losers do I want to choose none what's the equation going to be Conor the unmasked no the unmasked the unmasked oh now everyone knows your identity way to go you're doing so well go ahead Conor 3 choose 3 and divided by what 100 choose 3 did you actually go 100 choose 3 or did you use my first first last last either it works by the way what is 3 choose 3 1 what's 97 choose 0 this is going to be over whatever the heck 100 choose 3 is what is 100 choose 3 stuff oh we still haven't found a work around for that yet have we we may have to trade off on the test that day I think I might have made the test up so that all the questions will work but if not remind me on test day Sally 1 6 1 7 0 0 and what this lets us do is finally at long last finally get to Lotto 649 okay in Lotto 649 there's 49 numbers to pick from and how many do you have to get right to win the grand prize 6 that's why it's called 649 so let's figure out the probability that we win the grand prize first of all it doesn't matter what order they choose your numbers all that matters is did your numbers get chosen so this is a bucket question we have 2 groups of numbers winners losers how many winning numbers are there 6 how many losers are there 43 for the grand prize how many winning numbers do I want to get how many losers do I want to pick so I think it's going to be 6 choose 6 and 43 choose 0 divided by what choose what from 49 random numbers choose any 6 and if you weren't sure Hannah first plus first equals first last plus last equals last by the way what is 6 choose 6 on the top 1 what's anything choose 0 okay the top works out to 1 so just type in the bottom 49 choose 6 what is your chance of winning the grand prize it's just below 14 million read me the numbers 1 3 3 8 1 6 I'm missing the comma there chance of winning 1 and 14 million is what they say oh actually this isn't quite right this is the chance of winning the grand prize and they just said chance of winning you could win by getting 6 numbers 5 or 4 or 3 I think not sure what does or mean yet you could do each of them separately and then just add them up not that hard but that's where that number on the back of the lotto ticket comes from or as my and I think I've passed this on to you already but as my math prof used to always say I win $7 a week a lotto 649 because I don't buy a ticket each day that was back when they were $1 they were saying if you're buying a lotto to get expected to get any kind of money back you're throwing away money you may as well just toss your money in the trash with odds of 1 and 14 million he is correct Luke what was your question pardon me I held your hand yeah a lot of things would be really cool it would be cool if you combed your hair you could come here and totally make fun of me by the way numerous studies numerous studies have shown that the vast majority of people who win a big lottery within five years regret it because it changes their life so negatively very few people can deal with that bigger lifestyle change they lose all their friends because all their friends start asking them for money often if it's a couple there's an ugly divorce or a split because they don't know how to deal with money numerous studies have shown that in all honesty if I wanted to win a lottery I would like to win enough to buy a house but still work because honestly I've missed this job little advice for you don't go for the grand prize try and win a prize that will make things a bit easier but won't so change things that suddenly your whole life is messed up on your own right now try B exactly 3 how many winners does that mean if they pick only 3 numbers 3 how many losers 3 3 what do you get 0177 round it off properly so you got about 1% chance of getting 3 numbers right I don't think I'm trying to remember they give a $10 prize that might be for matching 3 I think it's for matching 4 though I don't think you do that's the last thing they want to do because that might mean that free ticket you win the big bucks and they didn't get any of the lottery money they're very reluctant to give up free tickets I told you guys though a guy in Toronto this is about 2 months old now a guy in Toronto cracked the bar codes on the scratch and win so he was able to identify winners about 80% of the time before scratching them and in fact he taught it to his 10 year old kid he's a mathematician he taught it to his 10 year old kid so she would go in the store and point to the winners so he reported it to the Ontario Lotto Company Google because they haven't changed much of it scratch and win are made by 2 major companies and the first major company denied that there was any sort of pattern I'm not a big fan of lotteries they're tax on the stupid I really think but such as like hey workbook open please are you saying you're not stupid I'm saying that you don't have good math skills you know what they're tax on people with bad math that's what I really should have said can you turn please to page 473 page 473 and we're going to jump right down to example three and in example three we have a bag of marbles Kim read carefully how many marbles are we choosing three tree probably not probably not look at A does the order matter and I'm going to say no look at B does the order matter I'm going to say no and here's how I know that it doesn't matter in A and B look at C does the order matter there so you know what for A and B bucket and I'm going to do my bucket over here and it looks like I'm going to have red green and blue marbles how many red marbles in the bucket five how many greens three how many blues six Kim how many marbles did you say that we were taking okay no how many marbles are we choosing to start out grand total three what does part A want okay so from six blues choose two and I'm going to treat this as one bin and call it others how many other marbles are there eight choose how many one divided by what hey how about using first plus first equals and last plus last divided by what fourteen choose three are you guys okay in typing these in so you can find the answer later Steph I just because the hard part of the equation B at least one is blue now what does that mean that means one or or so we could do it that way what would be a more clever way to do it what's the opposite of at least one is blue Greg what's the opposite of at least one is blue Sally none you know it'd be way easier to do the compliment we could go one or two or three Sally what does or mean and you'd have one of these plus one of these plus one of the which works fine oh and by the way two would be exactly this but I think it's going to be one minus the probability of none way easier one minus how many blue do I want to get how many blue were there six choose zero and from the remaining others eight choose all three divided by fourteen choose three Hannah way faster either method you'll get full marks for by the way one or two or three works fine but you know what compliment nicer see choose or permutation does order matter or not how can you tell K words like first second and first a third or if they say followed by or that something something and then something if order clearly matters you know what we're going to do we're going to visualize the tree this is going to be the probability of red on the first green on the second blue on the third let's see if we can just walk down this tree this is why I don't do a big song and dance about permutations trees actually are permutations and we've been doing trees for a while we've been doing trees for a while Matt how many red marbles are there in the bag at the very beginning out of grand total fourteen and okay we picked a red marble what do we want next Matt how many greens are left out of how many marbles are left see where we're going and okay now we want to pick a blue marble for the third one how many blues are left out of that's how I would do a permutation question it is true that 14 times 13 times 12 is 14 p3 I'm not so sure that's a big time savings one is red one is green and one is blue that would be five choose one three choose one six choose one over 14 choose three right oh because it didn't say the first is red the second is green and the third is blue just in any order so that's a choose again it's a bucket very handy turn the page example four city council consists of nine men and six women we're going to pick three representatives how many representatives Kellan tree no she I maybe I could do with a tree but for three people or more I'll use permutations and chooses and buckets I know three and tree sound the same I know I know okay a what's the probability that mayor Jim and two women are chosen does this mention order at all so this is a bucket except I'm going to have to modify my bucket I can't just have nine guys and six girls because they've singled out a specific person who have they singled out in this question okay my buckets going to have three categories mayor Jim I'll use a letter J for mayor Jim how many mayor Jim's are there one and then males how many males are there left over once we assuming mayor Jim is of male eight and how many females are there six how many mayor Jim's do we want to choose one how many of the remaining men do we want to choose zero because how many females do we want to choose can you see what the top row is going to be one choose one and eight choose zero and six choose two all over all over what 15 choose three by the way what is one choose one one what is eight choose zero one I would just go six choose two over 15 choose three again you guys have said that you're typing these in okay I'm not going to worry about the typing you'll do that in the homework B what's the difference between A and B in B they're telling you we already know the mayor is on the committee in A we were asking what are the odds that he shows up B they're saying yes be on there has to be there he is so my buckets going to get modified just a little bit my buckets only going to have two categories it's going to have males and females eight of them not nine because mayor Jim is already on the committee and six how many males do we want to choose still zero how many females still two it's going to be eight choose zero and six choose two divided by 15 choose not three two 14 sorry 14 choose two how did you spot that Sally because first plus first that's a handy built in arrow check 14 choose two and if you really want it to be fussy you could say and 100% that the mayor is on there and 100% chance is one so there the mayor for sure and two girls from the remaining 14 people we've done card questions we'll finish off with birthdays and this will help explain the weird answers that I was telling you occur says this in a class of 30 students find the probability that everyone has a different birthday okay so let's start with step we're going to start out using the fundamental counting principle we have 30 different birthdays that we want to fill in how many choices do you have starting out you have 365 days to pick from because no one overlaps with you yet but once you picked your day you how many days that Leslie has to pick from 360 4 and you know how many days that Kellan has to pick from for his to be different from both of yours 360 I'm going to go dot dot dot and we're going to do this for 30 students there would be a 362 and we do it 30 times you know what actually what we're saying is go like this from 365 days permutate 30 of them that's how many different ways out of the year that we can spread 30 days among 30 students what is 365 permutate 30 2.17 times 10 to the 76 is that right folks no oh yes that's how many different ways we can 2.17 times 10 to the 76 okay now that's the number of ways without overlapping what's the total number of ways well the total number of ways is again I could draw 30 blanks I'm just going to draw 4 365 365 365 because that's how many days you have to choose from if we didn't have any restrictions how many 365s would I write a row for 30 students okay this is going to be 365 to the 30th here's your actual answer if you want the number of the probability that they all have different birthdays it's going to be 365 p 30 divided by 365 to the 30th it's going to be 365 p 30 divided by 365 to the power of 30 the odds that they're all different 0.29 so that's the odds that everyone is different what are the odds that at least two of them have the same birthday how can I use this number to figure out if this is all different 0 having the same how can I find at least two of them having the same compliment this is going to be 1 minus 0.29 what are the odds if I had 30 of you guys of me winning my bet 0.71 so really quickly let's fix the numbers for what we had how many were in this class did we say 23 what was it 21 what was it 21 so 21 21 21 that's the odds of all different so if I go 1 minus that's the odds of two or more of the same I won when I should not have sorry Alyssa what's the magic number the odds of winning when there's 24 slightly above 50% oh if there's like 36 people not very big house party or whatever and you can get somebody to make this bet I'll take that bet anytime anytime by the time you get to 40 it's like 99 points something essentially as guaranteed to win as you'll ever get the probability theory the birthday problem now I've showed you the birthday problem because of its nerdiness I will not ask you it I think in terms of difficulty this is just a little bit high for what I'm asking you to deal with although it is a neat application of permutations and fundamental counting principle for more than two objects I'm not going to throw that one at you on the test but certainly something like number five or what's your homework okay one is good now to be how many marbles are we taking in question number two two you can do it with a tree and that's what I would do on a test but for practice try it with combinations and permutations three is good nine A and C so skip B and ten one more lesson although it'll probably take me two days to get through it your guys test block D is going to be next Friday a week from three days from now I will probably be doing a tutorial next week Wednesday or Tuesday I'm not sure I'll let you know next Friday that's why I'm trying to give you no homework for your grad now if you're not going to be here because it's going to take you all day to get your hair done it means you're going to have to find a time to write it Thursday after school or Thursday during the day during one of your many study blocks unless you feel like writing it after grad I'd write it before we're running into may long weekend and stuff and I can't bump things much further than that okay the what it's not a video