Unit I_Set Theory
Unit I_Set Theory
◼ Examples:
1. The set of vowels of Alphabets
2. The set of the states in India
3. The set of the rivers in Maharashtra
1
Representation of a set
There are two ways to represent a set
◼ Roster or Tabular form
◼ Set builder form
4
Universal Set & Subset
◼ A set is called universal set if it includes every set under
discussion. It is denoted by U.
◼ A set A is said to be subset of a set B iff every element of
A is also an element of B.
Symbolically, it is written as A⊆ B, if x ∈ A and x ∈ B.
B
U
Venn Diagram for Subset 5
Proper Subset & Equal Sets
◼ A set A is said to be proper subset of another set B iff
every element of A is also an element of B but there is at
least one element of B that is not in A.
i.e. if A⊆ B but A ≠ B.
It is written as A ⊂ B.
◼ Union: A ∪ B = {x : x ∈ A or x ∈ B}
eg. If A = {-3, 0, 1, 2} and B = {1, 2, 3, 4}
then A ∪ B = {-3, 0, 1, 2, 3, 4}
◼ Intersection: A ∩ B = {x : x ∈ A and x ∈ B}
eg. If A = {-3, 0, 1, 2} and B = {1, 2, 3, 4}
then A ∪ B = {1, 2}
8
Operation on sets
Let A & B be two sets and U is universal set.
◼ Complement: A’= {x : x ∈ U and x ∉ A}
eg. If A = {1, 2} and U= {1, 2, 3, 4, 5} then A’ = {3, 4, 5}
◼ Relative Complement: A - B = {x ∈ A and x ∉ B}.
eg. If A = {-3, 0, 1, 2} and B = {1, 2, 3, 4}
then A - B = {-3, 0}
◼ Symmetric Difference:
A Δ B = (A - B) ∪ (B – A)= {x ∈ exactly one of A and B}
eg. If A = {-3, 0, 1, 2} and B = {1, 2, 3, 4}
then A Δ B = {-3, 0, 3, 4}
9
Some Examples
◼ Ex. 1. If A = {1, 2, 3, 4}, B = {2, 4, 6, 8} and C = {3, 4, 5, 6}
then verify that A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C)
10
Some Examples
◼ Ex. 2. If A = {1, 2, 3, 4}, B = {2, 3, 5} and U = {1,2, 3, 4, 5, 6}
then verify that (i) (A ∪ B)’ = A’ ∩ B’ (ii) (A ∩ B)’ = A’ ∪ B’
14
15
16
17
18
19
20
21
22
23
24
25
26
Ordered pair and Cartesian
Product
◼ An ordered pair is a pair of objects whose components
occur in a special order.
In the ordered pair (a, b), a is called the first component
and b is called the second component.
27
Properties of Cartesian Product
For the four sets A, B,C and D
◼ (A ∩ B) x (C ∩ D) = (A x C) ∩ (B x D)
◼ (A – B) x C = (A x C) – (B x C)
◼ (A ∪ B) x C = (A x C) ∪ (B x C)
◼ A x (B ∩ C) = (A x B) ∩ (A x C)
28
29
30
31
Cardinal Number in a Set
◼ The cardinal number of a set A is the number of
elements in the set A. It is denoted by |A| or n(A).
◼ Properties:
1. |A ∪ B|= |A| + |B|- |A ∩ B|
2. |A – B|= |A|- |A ∩ B|
|B – A|= |B|- |A ∩ B|
3.|A ∪ B ∪ C|= |A| + |B| + |C|-| A ∩ B|- |A ∩ C|-
|B ∩ C|+ |A ∩ B ∩ C|
32
33
Examples
◼ In a group of 70 persons, 37 like coffee, 52 like tea and
each person likes at least one of the two drinks. Calculate
i) number of person who like both coffee and tea
ii) number of person who like coffee but not tea
◼ Solution: Let A be the set of person who like coffee and B
be the set of person who like tea.
Given that,|A| = 37,|B|= 52 & |A ∪ B |= 70
|A ∩ B |= |A| + |B|- |A ∪ B|= 19
Number of person who like both coffee and tea = 19
|A – B|= |A|- |A ∩ B|= 18
Number of person who like coffee but not tea = 18 34
35
36
37
Computer Representation of Sets
◼ Let U = { 1, 2, 3, 4, 5, 6}, A = {1, 2}, B = {2, 4, 6} then the bit
strings for A and B are as follows:
◼ A is represented as 110000
◼ B is represented as 010101
38
Complement, Union & Intersection
using bit strings
◼ The complement of a set can be obtained by simply
changing 1 to 0 and 0 to 1.
39
Example
◼ If U = {1, 2, 3, 4, 5, 6}, A = {1, 2, 3, 4} and B = {3, 4, 5, 6}.
Find the bit string for the set A and B and use bit string
to find A’, union, intersection of sets A and B.
◼ Solution: The bit string is of length 6.
A is represented as 111100
B is represented as 001111
A’ is represented as 000011, A’ = {5, 6}
Union: 111100 ∪ 001111 = 111111, A ∪ B = {1, 2, 3, 4, 5, 6}
Intersection: 111100 ∩ 001111 = 001100, A ∩ B = {3, 4}
40
Partition of a Set
◼ Partition of a set A is a collection of nonempty subsets
A1, A2, ……, An called blocks such that each element of
A is in exactly one of the blocks. That is
1. A is the union of all the subsets, A1∪A2∪……∪An=A
2. The subsets are pair wise disjoint, Ai ∩ Aj= Φ for i ≠ j
◼ Example: Find all the partitions of S = {2, 3, 4}
◼ Solution: Partitions of S are as follows:
1. {{2, 3, 4} 2. {{2}, {3, 4}}
3.{{3}, {2, 4}} 4.{{4}, {2, 3}}
5.{{2}, {3}, {4}}
41
Partition of a Set
42
43
44
Relation
45
Properties of Relation
46
Equivalence Relation
47
48
49
50
Equivalence Class
51
52
53
54
55
56
57
58
59
60
61
Representation of relation by Graph
Node/Vertex
Edge
loop
62
Representation of relation by Matrix
1 3 4
1 1 1 0
𝑀𝑅 = 3 0 1 0
4 0 0 1
63
64
65
66
67
68
69
70
71
72
73
74
75
Function
76
One-to-one Function
77
Onto Function
78
Bijective Function
79
80
81
82
83
84
85
86
87
88
89
90
91
92
Hasse Diagram
93
94
Peano axioms
96
97
98
99
◼ Prove by principal of mathematical
induction that is a multiple of
14 for n ≥ 0.
100
101