Operations on Sets The complement of a set A refers to all
elements not in A, assuming a universal set U.
Sets can be combined in a number of ways to construct A'= {x | x ∈ U and x € A}
another set. Set operations allow us to combine or
compare different sets in various ways. Example:
set operations: Let U = {1, 2, 3, 4, 5} and A = {1, 2, 3} B = {4, 5}
1. Union (A U B) UB) The complement is A' = {4, 5}
2. Intersection (A∩B) The complement is B' = {1, 2, 3}
3. Difference (A - B) 5. Cartesian Product (A × B)
4. Complement (4') The Cartesian product of two sets A and B is the
set of ordered pairs (a, b), where a comes from
5. Cartesian Product (A × B) A and b comes from B.
A x B = {(a, b) l a ∈ A, b ∈ B}
1. Union (A U B) Example:
The union of two sets is a set that contains all Let A = {1, 2} and B = (a, b)
elements from both sets, without duplicates. A x B= (1, b), (2, a), (2, b)}
AUB = {x | x ∈ A or x ∈ B}
Example 1:
Example:
Let the following sets be defined:
Let A= (1, 2, 3) and B = (3, 4, 5}
A = {1, 2, 3, 4, 5}
The union is (A U B) = {1, 2, 3, 4, 5)
B = {4, 5, 6, 7}
2. Intersection (A∩B)
C = {2, 4, 6, 8}
The intersection of two sets is a set that
contains only the elements common to both U = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}
sets.
A ∩ B = {xlx ∈ A and x ∈ B} 1. (AUB) ∩ (AUC)
Example: (AUB) = (1, 2, 3, 4, 5, 6, 7)
Let A = {1,2, 3) and B = (3, 4, 5} The intersection is (A ∩ (AUC) = (1, 2, 3, 4, 5, 6, 8)
B) ={3} (AUB) ∩ (AUC) = {1, 2, 3, 4, 5, 6}
3. Difference (A - B) Example 2:
The difference between two sets is a set that Let the following sets be defined:
contains the elements of A that are not in B.
A-B=(xlx ∈ A and x € B} A = {1, 2, 3, 4, 5, 6, 7}
Example: B = {5, 6, 7, 8, 9}
Let A = {1, 2, 3} and B = {3, 4, 5} C = {2, 4, 6, 8}
The difference is A - B ={1, 2} B - A = {4, 5} D = {1, 3, 5, 7, 9}
4. Complement (A') U = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}
2. ((A ∩ B) - (CUD)) U (B' ∩ D)
A ∩ B = {5, 6, 7} (A U B) U C={1,2,3} U {3, 4} = {1, 2, 3, 4}
C U D = \{1, 2, 3, 4, 5, 6, 7, 8, 9\} A U (B U C)={1,2}U{2, 3, 4} = {1, 2, 3, 4}
(A∩B)-(CUD) = Ø 3. Distributive Laws
B' = {1, 2, 3, 4, 10) Intersection distributes over Union: A∩(BUC) = (A∩B) U
(A∩C)
B' ∩ D = {1, 3}
Union distributes over Intersection: AU(B∩C) = (AUB) ∩
((A∩B) - (CUD)) U (B'∩D) = {1,3} (AUC)
Laws of Operations on Sets Example:
The laws of set operations are fundamental rules that Let A = {1, 2} B = {2, 3} and C = {3, 4}
govern how sets behave under operations like union,
intersection, and complement. These laws are A ∩(B U C)={1,2}∩{2, 3, 4} = {2}
analogous to algebraic laws and help simplify complex
set expressions. (A∩B) U (A∩C) = ({1, 2} ∩ {2, 3}) U ({1, 2} ∩ (3, 4}) = {2}
U Ø= {2}
1. Commutative Laws
4. Identity Laws
2. Associative Laws
Union with the empty set: A U Ø=A
3. Distributive Laws
Intersection with the universal set: A ∩ U = A
4. Identity Laws
Example:
5. Complement Laws
Let A = {1, 2, 3} and U = {1, 2, 3, 4, 5}
6. Idempotent Laws
A U Ø = {1, 2, 3}
7. Absorption Laws
A ∩U = {1, 2, 3}
8. De Morgan's Laws
5. Complement Laws
1. Commutative Laws
Union with complement: A U A' = U
Union: A U B= B U A
Intersection with complement: A ∩ A' = Ø
Intersection: A ∩ B=B ∩ A
Example:
Example:
Let A = {1, 2, 3} and U = {1, 2, 3, 4, 5}
Let A = {1, 2, 3} and B = {3, 4, 5} then:
A' = {4, 5}
A U B = {1, 2, 3, 4, 5}
A U A' = {1, 2, 3, 4, 5} =U
B U A = {1, 2, 3, 4, 5}
Α∩Α=Ø
2. Associative Laws
6. Idempotent Laws
Union: (AUB) U C=A U (B U C)
Union of a set with itself: A U A=A
Intersection: (A∩B) ∩ C = A ∩ (B∩C)
Intersection of a set with itself: A ∩ A' = A
Example:
Example:
Let A = {1, 2} B = {2, 3} and C = {3, 4}
Let A = {1, 2, 3}
A U A = {1, 2, 3}
A ∩ A= {1, 2, 3}
7. Absorption Laws
AU(A∩B)=A
A∩(AUB)=A
Let A = {1, 2} and B = {2, 3}
A ∩ (A U B)={1,2} ∩{1, 2, 3} = {1, 2} = A
8. De Morgan's Laws
(AUB)' = A' ∩ B'
(A ∩ B)' = A'U B'
Let A = {1, 2, 3}B = {3, 4, 5}and U = {1, 2, 3, 4, 5}
A' ={4, 5} B' = {1, 2}
(A U B)'= ({1, 2, 3, 4, 5})'= Ø
A' ∩ B' = {4, 5} ∩ {1, 2} = Ø
Let U = {1, 2, 3, 4, 5, 6, 7, 8, 9} be the universal set.
Define the sets:
A = {1, 3, 5, 7, 9}
B = {2, 3, 5, 8}
C = {1, 2, 6, 8, 9}
Find the elements of the set expression:
(AUB)-(A∩C)
AUB (Union)
A U B={1,3,5,7,9} U {2, 3, 5, 8} = {1, 2, 3, 5, 7, 8, 9}
A∩C (Intersection)
A ∩ C={1,3,5,7,9} ∩ {1, 2, 6, 8, 9} = {1, 9}
(AUB)-(A∩C)
(Set Difference)
(A U B)-(A∩C)= {1, 2, 3, 5, 7, 8, 9} - {1, 9}
={2, 4,6,8}