Download presentation
Presentation is loading. Please wait.
1
Sets Section 2.1
2
Sets Set - a collection of unordered objects
Element /member - an object in a set Two ways of describing a Set: Specifying the elements explicitly V = {a, e, i, o, u} Specifying the property/properties of the elements (Set Builder notation) P = {x | x is a positive integer less than 10}
3
Set membership and common sets
a A a is an element of set A b A b is not an element of set A Some notations: N Set of natural numbers Z Set of integers Z+ Set of positive integers Q Set of rational numbers R Set of real numbers
4
Set Definitions Equal sets
Two sets are equal iff they have the same elements Order means nothing Listing an object more than once does not change the set
5
Set Definitions (Cont..)
Empty set or Null set Set that has no elements Denoted by or { } Singleton Set that has one element Example: A = {2}
6
Set Definitions (Cont..)
The set A is a subset of B iff every element of A is also an element of B. A B The null set is a subset of every set. A Every set is a subset of itself. A A A is a proper subset of B, if A is a subset of B and A is not equal to B. A B
7
Set Definitions (Cont..)
Cardinality The number of distinct elements in a set Denoted by |S|, for the set S
8
Power Set Power Set The set of all subsets of a set
Denoted by P(S), for the set S If a set has n elements, then the power set has 2n elements, i.e., |P(S)| = 2|S|
9
Example Let L = {a, b, c, d} What is the cardinality of L?
How many elements does the power set of L have? What is the power set of L?
10
Venn Diagram Universal set U is represented by rectangle
Circles or other geometrical figures inside the rectangle represent sets B A U
11
Cartesian Product The Cartesian product of two sets A and B (denoted by A B) is the set of all ordered pairs (a,b) where a is an element of A and b is an element of B. A B = {(a,b) | aA bB} Example: A = {x, y, z} B = {1, 2} A B = {(x,1),(x,2),(y,1),(y,2),(z,1),(z,2)} B A = {(1,x),(1,y),(1,z),(2,x),(2,y),(2,z)}
12
Set Operations Section 2.2
13
Set Union Union of two sets A and B is denoted by AB
AB contains elements that are either in A or in B or in both AB = {x | xA xB} A = {1,3,5}, B = {2,3,4} A B A AB = {1,2,3,4,5}
14
Set Intersection Intersection of two sets A and B is denoted by AB
AB contains elements that are in both A and B AB = {x | xA xB} A = {1,3,5}, B = {1,2,3} A B AB = {1,3}
15
Disjoint Sets Two sets are called disjoint if their intersection is the empty set. A = {1,3,5}, B = {1,2,3}, C = {6,7,8} NO Are A and B disjoint? Are A and C are disjoint? YES A C
16
Cardinality of union of sets
Exercise: How many elements does A U B have?? |AB| = |A|+|B|-|A B|
17
Set Difference Difference of two sets A and B is denoted by AB
AB contains elements that are in A but not in B. AB = {x | xA xB} A = {1,3,5}, B = {1,2,3} A B A B AB = {5}
18
Complement of a Set U A Complement of a set A is denoted by
Done with respect to a Universal set U contains elements that are not in A, but in U. U A = U A = {x | xU xA}
19
Set Identities A A Identity A U A A U U Domination
A A A Idempotent A A A = A Double Complement
20
Set Identities (Cont ..) A B B A Commutative A B B A
A (B C) (A B) C Associative A (B C) (A B) C A (B C) (A B) (A C) Distributive A (B C) (A B) (A C) A (A B) A Absorption A (A B) A De Morgan's
21
Examples Use set builder notation to prove that
Use set identities to prove that
22
More Exercises Describe the following sets using the set
builder notation: 1. The set of all positive integers between 1 and 99. 2. 3. 4. 5. Use set builder notation to prove
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.