Download presentation
Presentation is loading. Please wait.
1
Chapter 3. Sets & Combinatorics
Section 3.2 Counting
2
Combinatorics is a branch of mathematics that deals with counting
Combinatorics is a branch of mathematics that deals with counting. Counting is important: e.g. How much money I have? What’s the size of my computer memory? How may elements (integers) are between i and j? How many combinations to arrange 3 numbers? ……
3
e. g. A child can choose one jellybean out of
e.g. A child can choose one jellybean out of jellybeans(red, black), and one gummy bear out of three gummy bears(yellow, green, white). How many different sets of candy can the child have? 2 stages: Y: R, Y R G: R, G W: R, W choose choose jellybean gummy bear Y: B, Y B G: B, G W: B, W 6 outcomes
4
Multiplication principle:
n1 outcomes for 1st event, n2 outcomes for 2nd event. Then there are n1 * n2 outcomes for the sequence of the 2 events. e.g. The last part of your phone # contains 4 digits. How many four-digit numbers are there? (Select a password of 4 digits, how many possible passwords?) 9933, 1982, 2017, 1016, 0007, … 10 * 10 * 10 * 10 = 10,000 different numbers outcomes
5
e. g. 10 toppings available in a pizza store, and the customer
e.g. 10 toppings available in a pizza store, and the customer can choose any # of toppings, how many different pizza the store can make? Toppings … choose it * * * … * = 210 or w/o it =1,024 (In Section 3.4 Permutations and Combinations)
6
Addition principle: If A and B are disjoint events with n1 and n2 possible outcomes, respectively, then the total # of outcomes for event A or B = n1 + n2. e.g. A customer wants to buy a vehicle from a dealer. The dealer has 23 autos and 14 trucks in stock. How many selections the customer have? = 37
7
e.g. | A B | = |A| + |B| if A and B are disjoint sets.
In general, | A B | = |A| + |B| - | A B | | A – B | = |A| - | A B | (In Section 3.3 Principle of Inclusion and Exclusion) e.g. How many four-digit number begin with a 4 or 5? 2 disjoint cases: numbers begin with 4 = 1*10*10*10=1000 numbers begin with 5 = 1000 The answer is = 2000
8
decision tree: e.g.: use x, y and z to construct strings of length 3.
How many strings do not have a z following y. x z y z x y z x y x y z x z z x y x x y z x y x z x x y y y y y = 21
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.