Ch 2 Basic Structures Section 1 Sets Principles
Ch. 2 Basic Structures Section 1 Sets
Principles of Inclusion and Exclusion n | A B | = | A | + | B | – | A B| n| A B C | = | A | + | B | + | C | – | A B| – | A C | –|B C|+|A B C| n | Ac | = | U | – | A |
Disjoint sets n A & B are disjoint sets iff A B = n Example: n A = {1, 2, 3} n B = { 4, 5, 6}
Power Set n P(A) = The power set of a set A = the set of all subsets of A. n A P(S) iff A S n | P( {{a, {b}}, a, {b} } ) | = 23 n There is no set A s. t. |P(A)| = 0 n There is a set A s. t. |P(A)| = 1 n There is no set A s. t. |P(A)| = 3
Power Set A = B iff P(A) = P(B) Proof “ ” Suppose that A=B. Then P(A) = P(B) “ ” If P(A) = P(B), then A P(A) = P(B) and so A B Similarly, B P(B) = P(A) and so B A Therefore A =B
Some facts n. A B = A B A n. A – B = A A B = n. A – B = B – A A = B n A = A – B (A B)
Ch. 2 Basic Structures Section 2 Set Operations
Set Operations A B Intersection A B Complement Ac = Ā = U – A complement of A w. r. t. to U Difference A – B = A Bc Generalized operations 1. Union 2. 3. 4. 5.
Example n A = set of students who live 1 mile of n 1. 2. 3. school B = set of students who walk to school A B = set of students who live 1 mile of school OR walk to it. A B = set of students who live 1 mile of school AND walk to it. A – B = set of students who live 1 mile of school but not walk to it.
Set Identities n See Table 1 in page 124 n Identity Laws: A =A A U=A n Dominations Laws: A U=U A =
Set Identities n Idempotent Laws: A A=A n Complementation Law: (Ac)c = A n Commutative Laws: A B=B A
Set Identities n Associative Laws: A (B C) = (A B) C n Distributive Laws: A (B C) = (A B) (A C) n De Morgan’s Laws: (A B)c = Bc Ac
Set Identities n Absorption Laws: A (A B) = A A (B C) = A n Complement Laws: A Ac = U
Proof of A=B n Show that A B and B A n Show that x (x A x B) n Direct proof
Examples (A B)c = Bc Ac Proof (A B)c = { x U | x A B } = { x U | (x A B) } ={x U | x A x B} ={x U |x A} {x U |x B} = A c Bc
Another proof of (A B)c = Bc Ac x (A B)c x A B x A or x B x Ac or x Bc x Ac Bc
- Slides: 17