2k likes | 2.44k Vues
AoPS:. Introduction to Counting & Probability. Chapter 2. Basic Counting Techniques. CASEWORK - Problem 2.1. On the island of Mumble, the Mumblian alphabet has only 5 letters, and every word in the Mumblian language has no more than 3 letters in it. How many words are possible?
E N D
AoPS: Introduction to Counting & Probability
Chapter 2 Basic Counting Techniques
CASEWORK - Problem 2.1 On the island of Mumble, the Mumblian alphabet has only 5 letters, and every word in the Mumblian language has no more than 3 letters in it. How many words are possible? (A word can use a letter more than once, but zero letters does not count as a word.)
Solution 2.1 Case 1: 1-letter words; there are 5 1-letter words Case 2: 2-letter words; we have 5 choices for 1st letter & 5 choices for 2nd letter = 5x5 = 25 Case 3: 3-letter words: 5 choices for the 1st, 2nd, and 3rd letters so 5 x 5 x 5 = 125 3-letter words Therefore, 5 + 25 + 125 = 155 words possible.
Problem 2.2 How many pairs of positive integers (m, n) satisfy m2 + n < 22?
Solution 2.2 Since 0 < m2 < 22, m must be one of 1,2,3, or 4. Case 1: When m = 1, then n < 22 – 1 = 21, so there are 20 possible choices for n when m = 1. Case 2: When m = 2, then n < 22 – 4 = 18, so there are 17 possible choices for n when m = 2.
Solution 2.2 Since 0 < m2 < 22, m must be one of 1,2,3, or 4. Case 3: When m = 3, then n < 22 – 9 = 13, so there are 12 possible choices for n when m = 3. Case 4: When m = 4, then n < 22 – 16 = 6, so there are 5 possible choices for n when m = 4. There are 20 + 17 + 12 + 5 = 54 possible pairs.
Problem 2.3 How many squares of any size can be formed by connecting dots in the grid shown? . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 1: 1 x 1 horizontal sqs – there are 16 1 x 1 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 2: 2 x 2 horizontal sqs – there are 9 2 x 2 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 3: 3 x 3 horizontal sqs – there are 4 3 x 3 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 4: 4 x 4 horizontal sqs – there is 1 4 x 4 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 There are 16 + 9 + 4 + 1 = 30 horizontal squares. Does that cover all cases? . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 There are 16 + 9 + 4 + 1 = 30 horizontal squares. Does that cover all cases? NO, Diagonal sqs . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 5: √2 x √2 diagonal sqs – there are 9 √2 x √2 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 6: √5 x √5 horizontal sqs – there are 8 √5 x √5 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 And √5 x √5 diagonal sqs – these √5 x √5 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 7: √8 x √8 diagonal sqs – there is 1 √8 x √8 square . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 8: √10 x √10 diagonal sqs – there are 2 √10 x √10 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Solution 2.3 Case 8: √10 x √10 horizontal sqs – there are 2 √10 x √10 squares . . . . . . . . . . . . . . . . . . . . . . . . .
Think about this: There are 30 horizontal squares + (9+8+1+2) diagonal squares = 50 squares in the grid. But how do you know that we have ALL of the squares? We’re pretty sure we have all the squares with integers side lengths. But what about the squares with sides that are irrational?
Think about this: We can prove from the Pythagorean Theorem that we have all the diagonal squares, because they must have side lengths that equal √ m2 + n2 , where m and n are positive integers less than 4. mn Side Length 1 1 √2 1 2 √5 1 3 √10 2 2 √8
Exercises 2.1 How many 3-letter words can we make from the letters A, B, C, and D, if we are allowed to repeat letters, and we must use the letter A at least once?
Exercises: Case 1: 3 letter word that contains one A. The letter A can be in 1st, 2nd, or 3rd position. Each of the other positions can be B, C, or D. There are 3 x 3 x 3 = 27 words for this case.
Exercises: Case 2: 3 letter word that contains two A’s. The letter that is not A can be in 1st, 2nd, or 3rd position. It can be one of B, C, or D. There are 3 x 3 = 9 words for this case.
Exercises: Case 3: 3 letter word that contains three A’s. There is only 1 such word, namely AAA. The total # of words is 27 + 9 +1 = 37
Exercise 2.2 I have two hats. In one hat are balls numbered 1-15. In the other hat are balls numbered 16-25. I first choose a hat, then from the hat, I choose 3 balls, without replacing the balls between selections. How many different ordered selections of 3 balls are possible?
Exercise 2.2 Case 1: The first hat is picked. There are 15 balls in the 1st hat. The 1st ball can be any of the 15 balls. The 2nd ball can be any of the 14 remaining balls. The 3rd ball can be any of the remaining 13 balls, so the number of ordered selections of three balls is 15 x 14 x 13 = 2730.
Exercise 2.2 Case 2: The second hat is picked. There are 10 balls in the 1st hat. The 1st ball can be any of the 10 balls. The 2nd ball can be any of the 19 remaining balls. The 3rd ball can be any of the remaining 8 balls, so the number of ordered selections of three balls is 10 x 9 x 8 = 720. The total of possible selections is 2730 + 720 = 3450
Exercise 2.3 How many paths are there from A to H in the diagram shown, if we can only travel in the direction of the arrows? E G B C A D F H
Go through either B or C to get to D. The # of paths going from A to D through B is 2 x 1 and the # of paths going from A to D through C is 2 x 3. So the total # of paths from A to D is (2 x 1) + (2 x 3) = 8.
Go through either B or C to get to D. The # of paths going from A to D through B is 2 x 1 and the # of paths going from A to D through C is 2 x 3. So the total # of paths from A to D is (2 x 1) + (2 x 3) = 8. Similarly to get from D to H, we go through one of E, F, or G. The three cases give a total of (1 x 1) + (2 x 3) + (2 x 1) = 9 paths from D to H.
Similarly to get from D to H, we go through one of E, F, or G. The three cases give a total of (1 x 1) + (2 x 3) + (2 x 1) = 9 paths from D to H. The path choice from A to D is independent of the path choice from D to H . So we multiply the # of paths from A to D by the # of paths from D to H to get the # of paths from A to H. 8 x 9 = 72
Problem 2.4 How many triangles appear in the diagram?
Problem 2.4 Case 1: The triangle is one of the smallest triangles. There are 1 + 3 + 5 + 7 = 16 smallest triangles. 1 3 5 7
Problem 2.4 Case 2: The triangle is composed of 4 of the smallest triangles. There are 7 such triangles, 6 pointing up and 1 pointing down.
Problem 2.4 Case 3: The triangle is composed of 9 of the smallest triangles. There are 3 such triangles, all pointing up.
Problem 2.4 Case 4: The triangle is the biggest triangle. There’s 1. The total # of triangles is 16 + 7 + 3 + 1 = 27.
Complementary Counting Complementary Counting refers to the general technique of counting what we don’t want to count. This is often easier than counting what we actually want to count.
Problem 2.6 How many 3-digit numbers are not multiples of 7?
Problem 2.6 It’s easy to count the # of 3-digit numbers which are multiples of 7: the smallest multiple of 7 which is a 3-digit # is 15 x 7 = 105 and the largest multiple of 7 which is a 3-digit # is 142 x 7 = 994.
Problem 2.6 It’s easy to count the # of 3-digit numbers which are multiples of 7: the smallest multiple of 7 which is a 3-digit # is 15 x 7 = 105 and the largest multiple of 7 which is a 3-digit # is 142 x 7 = 994. So there are 142 – 15 + 1 = 128 3-digit #s which are multiples of 7.
Problem 2.6 So there are 142 – 15 + 1 = 128 three-digit #s which are multiples of 7. There are 900 three-digit #s in total from 100 to 999, so 900 – 128 = 772 three-digit #s which are not multiples of 7.
Problem 2.7 The Smith family has 4 sons and 3 daughters. In how many ways can they be seated in a row of 7 chairs such that at least 2 boys are next to each other?
Problem 2.7 There is only one way to assign genders to the seating so that no two boys are next to each other, and that is BGBGBGB.
Problem 2.7 There is only one way to assign genders to the seating so that no two boys are next to each other, and that is BGBGBGB. If we seat the kids as BGBGBGB, then there are 4! orderings for the 4 boys, and 3! orderings for the 3 girls, giving a total of 4! X 3! = 144 seatings for the 7 kids.
Problem 2.7 If we seat the kids as BGBGBGB, then there are 4! orderings for the 4 boys, and 3! orderings for the 3 girls, giving a total of 4! X 3! = 144 seatings for the 7 kids. These are seatings that we don’t want, so to count the seatings that we do want, we need to subtract these seatings from the total # of seatings without any restrictions.
Problem 2.7 These are seatings that we don’t want, so to count the seatings that we do want, we need to subtract these seatings from the total # of seatings without any restrictions. Since there are 7 kids, there are 7! ways to seat them. So the answer is 7! – (4! X 3!) = 5040 – 144 = 4896
Exercises • How many 4-letter words with at least one vowel can be constructed from the letters A, B, C, D, & E? (Note that A & E are vowels.) 2. How many 5-digit #s have at least one zero? • I have 6 shirts, 6 pairs of pants, and 6 hats. Each item comes in the same 6 colors (so that I have one item of each color). I refuse to wear an outfit which all 3 items are the same color. How many choices for outfits do I have? • In how many ways can 7 people be seated in a row of chairs if two people, Wilma & Fred, refuse to sit next to each other?
1. First count all the # of all 4-letter words with no restrictions. Then count the # of 4-letter words with no vowels, then subtract to get the answer.