Download presentation
Presentation is loading. Please wait.
Published byEleanor Phelps Modified over 5 years ago
1
Counting Elements of Disjoint Sets: The Addition Rule
Lecture 29 Section 6.3 Mon, Mar 19, 2007
2
Counting Elements in Disjoint Sets
Theorem: Let {A1, …, An} be a partition of a set A. Then |A| = |A1| + … + |An|. Corollary: Let {A1, …, An} be a collection of pairwise disjoint finite sets. Then |A1 … An| = |A1| + … + |An|.
3
Counting Elements in Subsets
Theorem: Let A and B be finite sets with B A. Then |A – B| = |A| – |B|. Proof: {B, A – B} is a partition of A. Therefore, |B| + |A – B| = |A|. So, |A – B| = |A| – |B|.
4
Counting Elements in Unions of Sets
Theorem: Let A and B be any finite sets. Then |A B| = |A| + |B| – |A B|. Proof: One can verify that (A B) – B = A – (A B). Furthermore, B A B and A B A. Therefore, |A B| – |B| = |A| – |A B|. So, |A B| = |A| + |B| – |A B|.
5
Putnam Problem A-1 (1983) How many positive integers n are there such that n is an exact divisor of at least one of the numbers 1040, 2030? Let A = {n | n divides 1040}. Let B = {n | n divides 2030}. Then |A B| = |A| + |B| – |A B|.
6
Putnam Problem A-1 (1983) Prime factorization: 1040 = 240 540.
Therefore, n | 1040 if and only if n = 2a5b where 0 a 40 and 0 b 40. There are 41 41 = 1681 such numbers. Similarly, 2030 = , so there are 61 31 = 1891 divisors of 2030.
7
Putnam Problem A-1 (1983) Finally, an integer is in A B if it divides both 1040 and 2030. That means that it divides the gcd of 1040 and 2030. The gcd of 240 540 and 260 530 is 240 530. Therefore, there are 41 31 = 1271 such numbers.
8
Putnam Problem A-1 (1983) Thus, – 1271 = 2301 numbers divide either 1040 or 2030.
9
Number of Elements in the Union of Three Sets
Theorem: Let A, B, and C be any three finite sets. Then |A B C| = |A| + |B| + |C| – |A B| – |A C| – |B C| + |A B C|. Add sets one at a time, Subtract sets two at a time, Add sets three at a time.
10
Number of Elements in the Union of Three Sets
Theorem: Let A, B, and C be any three finite sets. Then |A B C| = |A| + |B| + |C| – |A B| – |A C| – |B C| + |A B C|. Add sets one at a time, Subtract sets two at a time, Add sets three at a time.
11
Number of Elements in the Union of Three Sets
Theorem: Let A, B, and C be any three finite sets. Then |A B C| = |A| + |B| + |C| – |A B| – |A C| – |B C| + |A B C|. Add sets one at a time, Subtract sets two at a time, Add sets three at a time.
12
Proof, continued Proof: |A B C| = |A B| + |C| – |(A B) C|.
13
Proof, continued Proof: |A B C| = |A B| + |C| – |(A B) C|
= |A| + |B| – |A B| + |C| – |(A B) C|.
14
Proof, continued Proof: |A B C| = |A B| + |C| – |(A B) C|
= |A| + |B| – |A B| + |C| – |(A B) C| = |A| + |B| – |A B| + |C| – |(A C) (B C)|.
15
Proof, continued Proof: |A B C| = |A B| + |C| – |(A B) C|
= |A| + |B| – |A B| + |C| – |(A B) C| = |A| + |B| – |A B| + |C| – |(A C) (B C)| = |A| + |B| – |A B| + |C| – |A C| – |B C| + |(A C) (B C)|.
16
Proof, continued Proof: |A B C| = |A B| + |C| – |(A B) C|
= |A| + |B| – |A B| + |C| – |(A B) C| = |A| + |B| – |A B| + |C| – |(A C) (B C)| = |A| + |B| – |A B| + |C| – |A C| – |B C| + |(A C) (B C)| + |A B C|.
17
Proof, continued Proof: |A B C| = |A B| + |C| – |(A B) C|
= |A| + |B| – |A B| + |C| – |(A B) C| = |A| + |B| – |A B| + |C| – |(A C) (B C)| = |A| + |B| – |A B| + |C| – |A C| – |B C| + |(A C) (B C)| + |A B C|. = |A| + |B| + |C| – |A B| – |A C| – |B C|
18
Proof, continued Proof: |A B C| = |A B| + |C| – |(A B) C|
= |A| + |B| – |A B| + |C| – |(A B) C| = |A| + |B| – |A B| + |C| – |(A C) (B C)| = |A| + |B| – |A B| + |C| – |A C| – |B C| + |(A C) (B C)| + |A B C|. = |A| + |B| + |C| – |A B| – |A C| – |B C|
19
The Inclusion/Exclusion Rule
Theorem: Let A1, …, An be finite sets. Then |A1 … An| = i |Ai| – i j > i |Ai Aj| + i j > i k > j |Ai Aj Ak| : |A1 … An|.
20
The Inclusion/Exclusion Rule
The Inclusion/Exclusion Rule can be proved by induction.
21
Number of Elements in the Union of Four Sets
Let U be the set of all pairs of distinct cards from a deck of 52 playing cards. How many pairs are there in which at least one of the two cards is black or a face card?
22
Number of Elements in the Union of Four Sets
Let A = all pairs where 1st card is black. B = all pairs where 1st card is a face card. C = all pairs where 2nd card is black. D = all pairs where 2nd card is a face card. Find the number of elements in |A B C D|.
23
Number of Elements in the Union of Four Sets
How many pairs are there in which at least one of the two cards is black or a face card?
24
The Inclusion/Exclusion Rule
Suppose five sets intersect as indicated in the following Venn diagram. A B C D E
25
The Inclusion/Exclusion Rule
State the equation of the inclusion/exclusion rule for these sets. A B C D E
26
The Inclusion/Exclusion Rule
Do the same for these sets. A B C D
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.