Lesson 2
Lesson 2
In ITE 1812, you learnt about sets, set operations and identities. Here, the aim is to provide a
quick recap of the following.
Defining a set, finite sets, infinite sets, null sets, subsets, proper set, equality of sets
and disjoint sets.
Representing a set using set builder notation and tabular form.
Using Venn diagrams to represent real world applications and to solve them.
Definition 2.1.1
A set is an unordered collection of objects.
Ex: All students currently taking a course in discrete mathematics at any school
Definition 2.1.2
The objects in a set are called the elements or members, of the set.
We write a A to denote that a is an element of the set A . The notation a A denotes that
a is not an element of the set A .
Definition 2.1.3
The set with no element is called the empty set or null set. It is denoted by or {}.
Ex: The set of dogs with six legs
1
Extra Examples
Some sets that occur frequently in mathematics:
{x : x } the set of real numbers
={...,-3,-2,-1,0,1, 2,3,...} the set of integers
{1, 2,3,...} the set of positive integers
{1, 2, 3,...} the set of negative integers
0 {0,1, 2,3,...} the set of natural numbers with zero=Whole numbers
{1, 2,3,...} the set of natural numbers
{x : x p q | p , q ,and q 0} the set of rational numbers
Real
Rational
Integers
Whole
1 Natural
2 …,-3,-2,-1, 0, 1, 2, 3,…
−5
9
3
8
Definition 2.1.4
Two sets are equal if and only if they have the same elements. That is if A and B are sets
then, A=B if x( x A x B) is true.
Ex: The sets {1, 3, 5} and {3, 5, 1} are equal because they have the same elements. Note that
the order in which the elements are listed does not matter.
Remark
If an element of a set is listed more than once, ex: {1,3,3,3,5,5,5,5} is same as the set {1,3,5}
because they have the same elements.
2
Definition 2.1.5- Subset
The set A is said to be a subset of B if and only if every element of A is also an element of B.
We write A B to indicate that A is a subset of the set B.
A B if and only if A B and B A
Example 2.1.6.1
If A= {1, 3, 5} and B= {1, 5}, then B is a proper subset of A. Denoted by B A.
The set C= {3, 1, 5} is a subset of A (C A) , but it is not a proper subset of A since C=A.
The set D= {1,4} is not even a subset of A, since 4 is not an element of A. Thus we write
Example 2.1.6.2
List all subsets of the set A={a, b, c}
There is one subset consisting of no elements—namely, the empty set .
observe that there are three subsets consisting of one element,
{a},{b},{c}
three subsets consisting of two elements,
{a, b},{a, c},{b, c}
and one subset consisting of three elements, the set A itself. Therefore, the subsets of A are
,{a},{b},{c},{a, b},{a, c},{b, c},{a, b, c}
3
Section 2.2: Venn Diagrams
A visual representation of sets is realized through the use of Venn diagrams, which are of
considerable help in understanding the concepts introduced earlier as well as in solving
problems involving sets. The universal set U is represented by a rectangle, and subsets of U are
represented by regions lying inside the rectangle
U U U
A, B A B B A
Self-Assessment Exercises
1. Write the set in set-builder notation.
a) The set of football teams in the NFL
b) {3, 4, 5, 6, 7}
c) {1, 3, 5, 7, 9, 11, . . . , 39}
4
Section 2.3: Set Operations
Having introduced the concept of a set, our next task is to consider operations on sets—that
is, to consider ways in which sets can be combined to yield other sets.
Let A and B be sets. The union of A and B, written A B, is the set of all elements that
belong to either A or B or both.
A B {x | x A or x B or both}
A B
Let A and B be sets. The set of elements common to the sets A and B, written A B, is called
the intersection of A and B.
A B {x | x A and x B }
A B
5
If U is a universal set and A is a subset of U, then the set of all elements in U that are not in A
Ac {x | x U and x A}
Ac
The difference of A and B denoted by is the set of elements which belongs to A but which
do not belong for B.
A \ B {x | x A, x B}
A B
6
Example 2.3.1
Let A= {a, b, c} and B= {a, c, d}. Then
∪ { }
{ }
{ }
{ }
Example 2.3.2
Let A= {1, 3, 5, 7, 9} and B= {2, 4, 6, 8,10}. Then
The following rules hold for the operation of complementation. See whether you can verify
them.
7
Let A and B be sets. Then
∪
∪
Example 2.3.3
Let {1 2 3 4 5 6 7 8 9 1 }, {1 2 4 8 9} and {3 4 5 6 8}. Verify by direct
computation that ∪
Solution:
A B {1, 2,3, 4,5,6,8,9}
so ( A B)c {7,10}
Ac {3,5,6,7,10}
Bc {1, 2,7,9,10}
so Ac Bc {7,10}. Thus the required result follows.
Example 2.3.4
Let U denote the set of all cars in a dealer’s lot, and let
A {x U | x is equipped with automatic transmission}
B={x U | x is equipped with air conditioning}
C={x U | x is equipped with side air bags}
Find an expression in terms of A, B, and C for each of the following sets:
a) The set of cars with at least one of the given options
b) The set of cars with exactly one of the given options
c) The set of cars with automatic transmission and side air bags but no air conditioning
Solution:
a) The set of cars with at least one of the given options is ∪ ∪ (Figure 2.6a)
b) The set of cars with automatic transmission only is given by .
Similarly, we find that the set of cars with air conditioning only is given by
, while the set of cars with side air bags only is given by . Thus, the set
of cars with exactly one of the given options is
∪ ∪ (Figure 2.6b)
c) The set of cars with automatic transmission and side air bags but no air conditioning
is given by (Figure 2.6c)
8
U U
B A B A
C C
b) The set of cars with at least one option a) The set of cars with exactly one option
U
B A
Self-Assessment Exercises
1. Shade the portion of the accompanying figure that represents each set.
a) A B C
b) A B C U
A B
c) A B C c
d ) Ac Bc C c C
e) ( A B)c C
f ) A ( B C )c
g ) ( A B C )c
h) ( A B) \ C
9
2. Let U denote the set of all employees in a hospital. Let
N {x U | x is a nurse}
D={x U | x is a doctor}
A={x U | x is an administrator}
M={x U | x is a male}
F={x U | x is a female}
Describe each set in words.
a ) Dc b) N c
c) N D d) N M
e) D M c f ) D A
g ) ( D N )c
3. Let U denote the set of all students in the business college of a certain university. Let
A {x U | x had taken a course in accounting}
B={x U | x had taken a course in economics}
C={x U | x had taken a course in marketing}
Write the set that represents each statement.
a) The set of students who have not had a course in economics
b) The set of students who have had courses in accounting and economics
c) The set of students who have had courses in accounting and economics but not
marketing
4. Determine whether each statement is true or false. If it is true, explain why it is true. If it
is false, give an example to show why it is false.
a) A set is never a subset of itself.
b) If A B , then A and B
c) If A B , then either A or B
d) (A Ac )c
10
Section 2.4: Number of Elements in a Finite Set
Definition
Let S be a set. If there are exactly n distinct elements in S where n is a nonnegative integer,
we say that S is a finite set and that n is the cardinality of S. The cardinality of S is denoted
by | S | .
Ex: Let A be the set of odd positive integers less than 10. Then | A | 5.
Because the null set has no elements, it follows that | | 0.
Suppose A and B are finite sets. Then ∪ and are finite and
Example 2.4.1
In a survey of 100 coffee drinkers, it was found that 70 take sugar, 60 take cream, and 50 take
both sugar and cream with their coffee.
a) How many coffee drinkers take only sugar?
b) How many coffee drinkers take only cream?
c) How many coffee drinkers take sugar or cream with their coffee?
d) How many coffee drinkers use exactly one item?
Solution:
Let U denote the set of 100 coffee drinkers surveyed and let
A {x U | x takes sugar}
B={x U | x takes cream}
Figure 2.7 shows the Venn diagram for the above problem.
11
A=70 B=60
50
Self-Assessment Exercises
1. Suppose A, B and C are finite sets. Obtain a relationship involving the number of
elements in the sets A, B and C.
Suggested Readings:
Chapter 2: Sections 2.1 & 2.2, Kenneth Rosen, (2011) Discrete Mathematics and Its
Applications, 7th Edition, McGraw-Hill Education
13