Sets PDF

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 34

MTH 212: Logic & Set Theory

Sets

Prepared by:
Tom Paulie Tongol
Set Theory
• A set is a collection of objects called elements.
• A set is usually represented by a capital letter.
• Sets can be finite or infinite.

Example:
A = {1,2,3,4,5,6,7,8,9,10}
𝑍 + = {1,2,3,4,5,……}
Set Theory
• A set is a collection of objects called elements.
• A set is usually represented by a capital letter.
Example: A = {1,2,3,4,5}
• Repeated elements are listed once.
Example: {a,b,c,b,c,a} = {a,b,c}
• There is no order in a set.
Example: {3,2,1} = {1,2,3}
• A set is well-defined if we know precisely the object/s that
comprise a set.
Example: (1) The set of months of the year.
(2) The set of positive natural numbers.

• Otherwise, it is not well-defined.


Example: (1) The set of beautiful ladies.
(2) The set of delicious desserts.
What are the Elements of a Set?
• Let us take an example: A = {1, 2, 3, 4, 5}
• A is the set and 1, 2, 3, 4, 5 are the elements of the set or
members of the set.
• The elements that are written in the set can be in any order
but cannot be repeated.
• All the set elements are represented in small letter in case of
alphabets.
• Also, we can write it as 1 ∈ A, 2 ∈ A etc.
What are the Elements of a Set?
• Let us take an example: A = {1, 2, 3, 4, 5}
• The cardinal number (number of elements in a set) of the set is 5.
• Some commonly used sets are as follows:
N: Set of all natural numbers
Z: Set of all integers
Q: Set of all rational numbers
R: Set of all real numbers
C: Set of all complex numbers
W: Set of all whole numbers
Representation of Sets
• The sets are represented in curly braces, {}.

• Example: {2,3,4} or {a,b,c} or {Bat, Ball, Wickets}.

• The elements in the sets are depicted in either


the Descriptive form, Roster Form or Set Builder Form.
1.) Descriptive Form – a set written in a statement form.
Example: The set of colors found in the rainbow.

2.) Roster Form – all elements of a set are listed and enclosed in braces.
Example: B = {red, orange, yellow, green, blue, indigo, violet}

3.) Set-builder Form – it is when a common property of all the elements


of a set is written.
Example: B = {x: x is a color in the rainbow}
Example: A = {x: x ∈ Z and -4 < x < 4}
Example: B = {x: x is a color in the rainbow}
“B is a set of all objects such that x is a color in the rainbow.”
“B is a set of all x’s such that x is a color in the rainbow.”

Example: A = {x: x ∈ Z and -4 < x < 4}


“A is set of all numbers such that x is an element of integers where
x is greater that -4 but less than 4.”
“A is set of all x’s such that x is an element of integers where x is
greater that -4 but less than 4.”
Representation of Sets
Types of Sets
1.) Empty Set or Null Set – a set with no element/s.
Example: (1) E = { } or E = ∅; n(E) = 0
(2) {x| x ∈ day of the week starting with A}

2.) Singleton Set – a set with one element.


Example: (1) S = {3}; n(S) = 1
(2) {x| x ∈ even prime number}
Types of Sets
3.) Finite Set – a set with limited elements (countable).
Example: Set F is the set of counting numbers less than 6.
F = {1,2,3,4,5}; n(F) = 5

4.) Infinite Set – a set with unlimited elements.


Example: Set N is the set of counting numbers.
N = {1,2,3,4,5,….}; n(N) = ∞
Types of Sets
5.) Equal Sets – sets with the same element.
Example: A = {1,2,3,4,5} & B = {1,2,3,4,5}; A=B

6.) Equivalent Sets – sets with different element but with equal
cardinality.
Example: J = {1,2,3,4,5} & K = {a,b,c,d,e}; J≈K
Types of Sets
7.) Universal Set – the set containing all elements of subsets.
Example: U = {a,e,i,o,u}; A={a,e,i}; B={o,u}
Set U is the set of counting numbers.
A = {1,3,5,7}
B = {2,4,6}
C = {1,2,3,4,5,6,7,8,9,10}
Types of Sets
8.) Subset – set A is a subset of set B, if and only if, every element in A
is also element in B.
Example: List all the subsets of set A: A = {i,c,e}
1. {i,c,e} 5. {i,c} n(A) = 3
2. {i} 6. {c,e} 2³ = 8
3. {c} 7. {i,e}
Formula:
4. {e} 8. { } 𝒏
𝟐 , where n is the
number of elements.
Types of Sets
9.) Proper Subset – set A is a proper subset of set B if there is at least
one element in B not contained in A. (A ⊆ B)
Example: M={a,e,i,o,u}; N={o,u}; (N ⊆ M)
Example: List all the proper subsets of set A: A = {i,c,e}
1. {i} 5. {c,e} n(A) = 3
2. {c} 6. {i,e} 2³-1 = 7
3. {e} 7. { } Formula:
4. {i,c} 𝟐𝒏 − 𝟏, where n is the
number of elements.
Subset vs Proper Subset
Note:
• A subset of a set A can be equal to set A but a proper subset
of a set A can never be equal to set A.
• A proper subset of a set A is a subset of A that cannot be
equal to A.
• In other words, if B is a proper subset of A, then all elements
of B are in A but A contains at least one element that is not
in B.
Types of Sets
10.) Superset – a set containing all of the elements of another set. A is a
superset of B if every element of B is also in A. (A ⊇ B)
Example: M={a,e,i,o,u}; N={o,u}; (M ⊇ N)

11.) Proper Superset – A is a proper superset set of B if A ⊇ B and A≠B.


(A⊃B)
Example: M={a,e,i,o,u}; N={o,u}
M ⊇ N and M ≠ N. Thus, M⊃N.
Types of Sets
12.) Power Set – the set of all subsets of a set.
Example: If A = {i,c,e}, then what is P(A)?
P(A) = { {i,c,e}, {i,c}, {c,e}, {i,e}, {i}, {c}, {e}, {} }

How many elements does the power set of A have?


n[P(A)] = 2³ = 8
Formula:
𝟐𝒏 , where n is the
number of elements.
Algebra of Set
• Complement of a Set – a set that contains the elements
present in the universal set but not in another set.

• Union of a Set – a set that contains the combined elements


of two sets.

• Intersection of a Set – a set that contains the common


elements of two sets.
Example:
U = { 1, 3, 5, 7, 9, 11, 13, 15 }

A = { 1, 5, 11 } B = { 5, 7, 9, 13 } C = { 1, 3, 7, 11 }
Complement of a Set

U = { 1, 3, 5, 7, 9, 11, 13, 15 }

A = { 1, 5, 11 } B = { 5, 7, 9, 13 } C = { 1, 3, 7, 11 }

𝐴𝑐 = { 3, 7, 9, 13, 15 }

𝐵𝑐 = { 1, 3, 11, 15 }

𝐶 𝑐 = { 5, 9, 13, 15 }
Union of a Set

U = { 1, 3, 5, 7, 9, 11, 13, 15 }

A = { 1, 5, 11 } B = { 5, 7, 9, 13 } C = { 1, 3, 7, 11 }

A ∪ B = { 1, 5, 7, 9, 11, 13 }
B ∪ C = { 1, 3, 5, 7, 9, 11, 13 }
A ∪ C = { 1, 3, 5, 7, 11 }
Intersection of a Set

U = { 1, 3, 5, 7, 9, 11, 13, 15 }

A = { 1, 5, 11 } B = { 5, 7, 9, 13 } C = { 1, 3, 7, 11 }

A∩B ={5} A ∩ C = { 1, 11 }

B∩C ={7} A∩𝐵 ∩𝐶 ={ }


Difference of a Set

U = { 1, 3, 5, 7, 9, 11, 13, 15 }

A = { 1, 5, 11 } B = { 5, 7, 9, 13 } C = { 1, 3, 7, 11 }

A − B = { 1, 11 } A−C ={5}

B − C = { 5, 9, 13 } 𝐶 − 𝐵 = { 1, 3, 11 }
Try this!
U = { 1, 3, 5, 7, 9, 11, 13, 15 }

A = { 1, 5, 11 } B = { 5, 7, 9, 13 } C = { 1, 3, 7, 11 }

C = { 1, 3, 7, 9, 11, 13, 15 }
A∩B

A∩B ={5}
Try this!
U = { 1, 3, 5, 7, 9, 11, 13, 15 }

A = { 1, 5, 11 } B = { 5, 7, 9, 13 } C = { 1, 3, 7, 11 }

(A ∪ B) ∩ (A ∪ C) = { 1, 5, 7, 11 }

A ∪ B = { 1, 5, 7, 9, 11, 13 }
A ∪ C = { 1, 3, 5, 7, 11 }
Laws of Algebra of Sets
1.) Commutative Law
Let A and B be any two finite sets
i. A ∪ B = B ∪ A
ii. A ∩ B = B ∩ A

2.) Associative Law


For any three finite sets A, B and C
i. (A ∪ B) ∪ C = A ∪ (B ∪ C)
ii. (A ∩ B) ∩ C = A ∩ (B ∩ C)
Laws of Algebra of Sets
3.) Idempotent Law
For any finite set A
i. A ∪ A = A
ii. A ∩ A = A

4.) Distributive Law


For any three finite sets A, B and C
i. A ∪ (B ∩ C) = (A ∪ B) ∩ (A ∪ C)
ii. A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C)
Cartesian Product
• If A and B are sets, then the Cartesian product, AxB, of A and B is the
set of all ordered pairs (x, y) where x ∈ A and y ∈ B.

• We use the notation AxB for the Cartesian product of A and B, and
using set builder notation, we can write AxB = {(x,y)| x∈A and y∈B}.

• We used to read AxB as “A cross B”. In the case where the two sets are
the same, we write A² for AxA. That is A² = AxA = {(x,y)| x∈A and y∈A}.
• Cartesian Product is not commutative for any sets A
and B.

• That is AxB = BxA, if and only if A = B.

Example: Let A = {a,b} and B = {1,2}. We have


AxB = {(a,1), (a,2), (b,1), (b,2)}
BxA = {(1,a), (1,b), (2,a), (2,b)}

You might also like