



















Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




















Sum Rule
Product Rule
Inclusion-Exclusion
Basic pigeonhole principle
Generalized pigeonhole principle
Interested in answering questions such as:
How many ways are there to buy 13 different bagels from a shop that sells 17 types? How many bit strings of length 11 contain a streak of one type of bit of exact length 7? How many ways can a dating service match 13 men to 17 women?
COMMON THEME: convert to set cardinality problems so each question above is a about counting the number of elements in some set:
Q: What is the corresponding set in each case?
L17 5
A: The set to measure the cardinality of is…
{bit strings of length n} How many ways are there to buy 13 different bagels from a shop that sells 17 types?
How many bit strings of length 11 contain a streak of one type of bit of exact length 7? {length 11 bit strings with 0-streak of length 7} {length 11 bit strings with 1-streak of length 7} How many ways to match 13 M to 17 W?
times
n
n n
No!, longest streak has length 2.
{length 11 bit strings with 0-streak of length 7}
{length 11 bit strings with 1-streak of length 7}
Break up
0-streak of length exactly 7}
into more cases and use sum rule:
Apply sum rule:
L17 14
So let’s count each set.
Therefore answer is 56.
L17 19
| | | | | |
(| | | |) (| | | |) | |
| | | | | | | |
A B A B
A A B A B B A B A B A B
A B A A B A B B A B
Problem 4.1.19 (a,b,c,f). How many positive integers with exactly three decimal digits are… …divisible by 7? …odd? …have the same 3 digits? …are not divisible by 3 or 4? Problem 4.1.49. How many ways can the letters a,b,c,d be arranged such that a is not immediately followed by b? Link to worked out problems