Discrete Math Module 1

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

Discrete Mathematics

in the Modern World


2nd Semester S.Y. 2023-2024
Module 1
Sets

Encouragement: It's not how good you are, it's how good you want to be. -- unknown

Wilfred H. Maru

Instructor
Course Communication

Post question of general interest any time in my Google classroom; replys will be
posted there within 24 hours, so that all classmate can see the answers. But if the
nature of the question or concern is more personal or you are not comfortable
having classmates see the message, you should use another means of
communication.

Communication Protocol

If sending message, consider stating the need for putting course name and issue in
the subject of the message and for adding the student's full name to the close of
the message.

As for all communication, you are expected to follow ethical standards for use of
computer technology and electronic communication.

Module Learning Objective

In this module you will learn:

 Definition of Discrete Mathematics


 Notation
 Relationships Between Sets
 Operations On Sets

Module Readings

Levin, Oscar (2013). Discrete Mathematics. School of Mathematical Science:


University of Northern Colorado Greeley.
Module Content

dis·crete / dis’krët.

Adjective: Individually separate and distinct.

Synonyms: separate - detached - distinct - abstract.

Defining discrete mathematics is hard because defining mathematics is hard.

What is mathematics? The study of numbers? In part, but you also study functions
and lines and triangles and parallelepipeds and vectors and . . . . Or perhaps you
want to say that mathematics is a collection of tools that allow you to solve
problems. What sort of problems? Okay, those that involve numbers, functions,
lines, triangles, . . . . Whatever your conception of what mathematics is, try
applying the concept of “discrete” to it, as defined above. Some math
fundamentally deals with stuff that is individually separate and distinct.

In an algebra or calculus class, you might have found a particular set of


numbers (maybe the set of numbers in the range of a function). You would
represent this set as an interval: [0, ∞) is the range of f (x) = x2 since the set of
outputs of the function are all real numbers 0 and greater. This set of numbers is
NOT discrete. The numbers in the set are not separated by much at all. In fact,
take any two numbers in the set and there are infinitely many more between them
which are also in the set. Discrete math could still ask about the range of a function,
but the set would not be an interval. Consider the function which gives the number
of children of each person reading this. What is the range? I’m guessing it is
something like {0, 1, 2, 3}. Maybe 4 is in there too. But certainly there is nobody
reading this that has 1.32419 children. This output set is discrete because the
elements are separate. The inputs to the function also form a discrete set because
each input is an individual person.

Sets

The most fundamental objects we will use in our studies (and really in all of math)
are sets. Much of what follows might be review, but it is very important that you
are fluent in the language of set theory. Most of the notation we use below is
standard, although some might be a little different than what you have seen before.

For us, a set will simply be an unordered collection of objects. Two examples:
we could consider the set of all actors who have played The Doctor on Doctor Who,
or the set of natural numbers between 1 and 10 inclusive. In the first case, Tom
Baker is an element (or member) of the set, while Idris Elba, among many others,
is not an element of the set. Also, the two examples are of different sets. Two sets
are equal exactly if they contain the exact same elements. For example, the set
containing all of the vowels in the declaration of independence is precisely the same
set as the set of vowels in the word “questionably” (namely, all of them); we do not
care about order or repetitions, just whether the element is in the set or not.

Notation

We need some notation to make talking about sets easier. Consider,

A = {1, 2, 3}.

This is read, “A is the set containing the elements 1, 2 and 3.” We use curly braces
“{, }” to enclose elements of a set. Some more notation:

a ∈ {a, b, c}.

The symbol “∈” is read “is in” or “is an element of.” Thus the above means that a is
an element of the set containing the letters a, b, and c. Note that this is a true
statement. It would also be true to say that d is not in that set:

d < {a, b, c}.

Be warned: we write “x ∈ A” when we wish to express that one of the elements of


the set A is x. For example, consider the set,

A = {1, b, {x, y, z}, ∅ }.

This is a strange set, to be sure. It contains four elements: the number 1, the letter
b, the set {x, y, z}, and the empty set ∅ = {}, the set containing no elements. Is x
in A? The answer is no. None of the four elements in A are the letter x, so we must
conclude that x ∉ A. Similarly, consider the set B = {1, b}. Even though the
elements of B are elements of A, we cannot say that the set B is one of the
elements of A. Therefore B ∉ A. (Soon we will see that B is a subset of A, but this is
different from being an element of A.)

Specification of Sets

There are three main ways to specify a set:

1. List Notation/Roster Method-by listing all its members—list names of


elements of a set, separate them by commas and enclose them by braces:
Examples:

a. {1, 12, 45}

b. {George Washington, Bill Clinton}.

c. {a, b, d, m}

d. “Three-dot abbreviation”: {1, 2, …, 100}

2. Predicate Notation/Rule Method/Set-Builder Notation-by stating a


property of its elements. It has a property that the members of the set share a
condition or a predicate which holds for members of this set.

Examples:

a. {x/x ∈ of natural number and x < 8} means “the set of all x such that x is
element of natural number and is less than 8”

b. {x/x is a letter of Russian alphabet}

c. {y/y is a student of MCC and y is older than 25}

3. Recursive Rules-by defining a set of rules which generates or defines its


members.

Examples:

a. The set E of even numbers greater than 3:

(1) 4 ∈ E

(2) If x ∈ E, then x + 2 ∈ E

(3) Nothing else belongs to E.


Here are some more exmaples:

Example

Describe each of the following sets both in words and by listing out enough
elements to see the pattern.

1. {x : x + 3 ∈ N}.

2. {x ∈ N : x + 3 ∈ N}.

Solution.

1. This is the set of all numbers which are 3 less than a natural number (i.e., that if
you add 3 to them, you get a natural number). The set could also be written as {−3,
−2, −1, 0, 1, 2, . . .} (note that 0 is a natural number, so −3 is in this set because
−3 + 3 = 0).

2. This is the set of all natural numbers which are 3 less than a

natural number. So here we just have {0, 1, 2, 3 . . .}.

We already have a lot of notation, and there is more yet. Below is a

handy chart of symbols. Some of these will be discussed in greater detail

as we move forward.

Special set

∅ The empty set is the set which contains no elements.

U The universe set is the set of all elements.

ℕ The set of natural numbers. That is, N = {0, 1, 2, 3 . . .}.

ℤ The set of integers. That is, Z = {. . . , −2, −1, 0, 1, 2, 3, . . .}.

ℚ The set of rational numbers.

ℝ The set of real numbers.

P(A) The power set of any set A is the set of all subsets of A.
Set Theory Notation.

{, } We use these braces to enclose the elements of a set. So {1, 2, 3} is the


set containing 1, 2, and 3.

: {x : x > 2} is the set of all x such that x is greater than 2.

∈ 2 ∈ {1,2, 3} asserts that 2 is an element of the set {1, 2, 3}.

∉ 4 ∉ {1, 2, 3} because 4 is not an element of the set {1, 2, 3}.

⊆ A ⊆ B asserts that A is a subset of B: every element of A is also an


element of B.

⊂ A ⊂ B asserts that A is a proper subset of B: every element of A is also


an element of B, but A , B.

∩ A ∩ B is the intersection of A and B: the set containing all elements


which are elements of both A and B.

∪ A ∪ B is the union of A and B: is the set containing all elements which


are elements of A or B or both.

× A × B is the Cartesian product of A and B: the set of all ordered pairs


(a, b) with a ∈ A and b ∈ B.

\ A \ B is set difffference between A and B: the set containing

all elements of A which are not elements of B.

� The complement of A is the set of everything which is not

an element of A.

|A| The cardinality (or size) of A is the number of elements in A.

Operations On Sets

Is it possible to add two sets? Not really, however there is something similar. If we
want to combine two sets to get the collection of objects that are in either set, then
we can take the union of the two sets. Symbolically,

C = A ∪ B,
read, “C is the union of A and B,” means that the elements of C are exactly the
elements which are either an element of A or an element of B (or an element of
both). For example, if A = {1, 2, 3} and B = {2, 3, 4}, then

A ∪ B = {1, 2, 3, 4}.

The other common operation on sets is intersection. We write,

C=A∩B

and say, “C is the intersection of A and B,” when the elements in C are precisely
those both in A and in B. So if A = {1, 2, 3} and B = {2, 3, 4},

then A ∩ B = {2, 3}.

Often when dealing with sets, we will have some understanding as

to what “everything” is. Perhaps we are only concerned with natural

numbers. In this case we would say that our universe is N. Sometimes

we denote this universe by U. Given this context, we might wish to

speak of all the elements which are not in a particular set. We say B is the

complement of A, and write,

B= �

when B contains every element not contained in A. So, if our universe is

{1, 2, . . . , 9, 10}, and A = {2, 3, 5, 7}, then � = {1, 4, 6, 8, 9, 10}. Of course


we can perform more than one operation at a time. For example, consider

A∩�.

This is the set of all elements which are both elements of A and not elements of B.
What have we done? We’ve started with A and removed all of the elements which
were in B. Another way to write this is the set difference:

A ∩ B = A \ B.

It is important to remember that these operations (union, intersection, complement,


and difference) on sets produce other sets. Don’t confuse these with the symbols
from the previous section (element of and subset of). A ∩ B is a set, while A ⊆ B is
true or false. This is the same difference as between 3 + 2 (which is a number) and
3 ≤ 2 (which is false).
Exercises

Copy and answer.

1. Let A = {1, 4, 9} and B = {1, 3, 6, 10}. Find each of the following sets.

(a) A ∪ B.

(b) A ∩ B.

(c) A \ B.

2. Find the least element of each of the following sets, if there is one.

(a) {n ∈ N : n2 − 3 ≥ 2}.

(b) {n ∈ N : n2− 5 ∈ N}.

(c) {n2 + 1 : n ∈ N}.

2. Find the following cardinalities:

(a) |A| when A = {4, 5, 6, . . . , 37}.

(b) |A| when A = {x ∈ Z : −2 ≤ x ≤ 100}.

(c) |A ∩ B| when A = {x ∈ N : x ≤ 20} and B = {x ∈ N : x is prime}

Prepared by Wilfred H. Maru.

You might also like