Professional Documents
Culture Documents
“Mathematics is a language.”
Josiah Willard Gibbs
Sets are building blocks that are used to construct major part of vocabulary
of Mathematical language. In this chapter we introduce Sets, operations on sets,
relations between sets (binary relations) and functions, along with their important
properties. Besides introducing these basic structures that will be used throughout
this book, this chapter aims at developing an understanding of the language of
Mathematics, in which the rest of the book is written. This language is com-
mon among Mathematicians, who use it to analyze and convey Mathematical
ideas. For a student of Mathematics, understanding this language is inevitably
important, while writing Mathematics is an art and thus requires a lot of practice.
1 Sets
Set is a basic concept that is used everywhere in Mathematics. Theory of sets
serves as a language that is used by mathematicians to understand and express
mathematical concepts in a precise way. In this chapter, we introduce sets and
related basic structures of Mathematics, which serve as tools to describe most
of mathematical concepts that will be discussed throughout this book. The
following is an intuitive definition of the term set.
Definition 1.1. A set is a well-defined and unordered collection of distinct
objects.
1
According to the informal definition stated above, a set comprises objects,
which are said to be members or elements of the set. There is no point in repeat-
ing an element more than once in a list, which is why a set constitutes distinct
objects. The term unordered in the definition tells that the order one chooses
for listing the objects does not matter provided that the elements remain the
same. The term well-defined means that for a collection of objects to qualify as
a set, it should be clear whether or not an object is in the set or not. We shall
mostly use uppercase letters of English alphabets to denote a set and lowercase
for elements. If an object a is in set S, we denote it as a ∈ S, and read it as a
belongs to S, while to denote that a does not belong to S we write as a ∈ / S.
Examples are indispensable tools that facilitate understanding of ideas and con-
cepts in Mathematics. For this, we make sure to present a bunch of examples
in this book along with definitions. It might be a useful exercise for the reader
to construct own examples and test them for correctness with definitions.
Example 1.1. Following are some examples of sets.
• The numbers 4, 7 and 9 can be combined to form a set X, denoted as
X = {4, 7, 9}.
• Set E of lowercase alphabets in English
• Students enrolled in a particular course
• Cities of Pakistan
Note that in the first example the elements are explicitly stated, enclosed in
braces and separated by commas. On the other hand, in the rest of the three
examples, rather than listing the objects, they are described in words. The set
E can also be written as E = {a, b, c, ..., z}.
2
Examples are helpful to elucidate mathematical concepts, but sometimes
negative examples are more illustrative.
Example 1.3. Following are collections of objects that do not qualify as sets.
• Collection C of some negative numbers
Definition 1.3.
• A set A is said to be a subset of B, if every element of A is in B. We
write as A ⊆ B and read as A is a subset of B.
• Two sets A and B are equal if every element of A is in B and vice versa
is also true. This is denoted as A = B.
1N is double-struck N for natural. In some books the number 0 is also included in N.
2Z is for zählen, which is German word for numbers.
3 Q is for quotient. Rational numbers are called so since they can be written as “ratio” of
integers.
3
The definitions stated above can also be written mathematically as follows:
• Set A is a subset of B if and only if x ∈ A ⇒ x ∈ B
• Set A is equal to set B if and only if x ∈ A ⇔ x ∈ B
Last definition can be equivalently written as:
• Set A is equal to a set B if and only if they are subsets of each other, or
A ⊆ B and B ⊆ A.
The symbol ⊂ is also used in place of ⊆ in some texts, though we prefer the
latter. Whereas, the symbol * is used to denote that a set is not a subset of
the other. In order to emphasize that a set is a subset of the other, and they
are not equal the symbol ( is used.
Example 1.5.
• If A = {1, 2, 3, 4} and B = {0, 1, 2, ..., 10}, then A ⊆ B. However, if
C = {0, 3, 4}, then C * A because 0 ∈
/ A. Also, C ( B because the sets B
and C are not equal.
• N ⊆ Z but Q * Qc . Note that one can also write as N ( Z.
• If Z+ is the set of positive integers, then Z+ = N.
a
• Z ⊆ Q, since every integer a can be written as 1.
4
1.1 Operations on Sets
In this section, we describe ways in which two or more sets can be combined to
form new sets.
Definition 1.4.
• Union of two sets A and B is a set containing all the elements that are
either in A or in B and is denoted as A ∪ B. Mathematically, A ∪ B =
{x | x ∈ A or x ∈ B}
• Intersection of two sets A and B is a set containing all the elements that
are common in both A and B and is denoted as A ∩ B. Mathematically,
A ∩ B = {x | x ∈ A and x ∈ B}
Example 1.6. Consider the following:
• Q ∪ Qc = R • N∪Z=Z
• Q ∩ Qc = ∅ • N∩Z=N
Following are some important properties of the subset relation, which hold
true for any set A.
• A ∪ ∅ = A. • A∩U =A
• A∩∅=∅ • A∪U =U
• A∩A=A∪A=A
When the intersection of two sets is equal to the empty set, there is no
element in common to both the sets and we say that the sets are disjoint,
while if the intersection is non-empty, the sets are said to be overlapping. For
example, Z and N are overlapping sets and Q and Qc are disjoint.
Definition 1.5. Difference of sets A and B is denoted as A \ B and comprises
elements of A that are not in B. Complement of a set A is the set comprising
all the elements (of universal set U) that are not in A. Complement of set A is
denoted as Ac .
Example 1.7.
• If Z≤0 is the set of non-positive integers, then Z≤0 = Z \ N .
• Let Z− be the set of negative integers, and Z≥0 be the set of non-
negative integers. Then we have, Z≥0 = Z \ Z− .
Alternative ways of writing these sets using unions and intersections are:
Z≥0 = N ∪ {0} and Z≤0 = Z− ∪ {0}.
5
1.2 Classes of sets
Set is a collection of objects, and also an object in its own right. We have some
sets containing other sets as elements. The set ∅ does not contain anything,
but the set {∅} is a singleton set. A similar example is the set {1, 2, 3} and
the set {{1, 2, 3}}, which are different from one another, and have cardinalities
3 and 1, respectively, because the latter set contains the former set as an el-
ement. It might be difficult for a beginner to understand that the statement
{1, 2, 3} ⊆ {{1, 2, 3}} is wrong. This can be understood by pondering over the
definition (1.3) of subset. The statement can be seen to be wrong by realizing
that 1 ∈ {1, 2, 3} but 1 ∈ / {{1, 2, 3}}. This shows the importance of definitions
in presenting precise arguments in Mathematics.
A set that contains other set(s) is called class of sets, collection of sets or
family of sets. These terms are used to avoid the term like “set of sets”. Power
sets and partitions of sets, introduced in this section, are important examples
of classes of sets.
Definition 1.6. Power set of a set A is the class of all subsets of A. It is
denoted as P(A).
Example 1.8. Following are Power sets of some sets.
• P({1, 2}) = {∅, {1}, {2}, {1, 2}}.
• P(∅) = {∅}, since the only subset of ∅ is itself.
• P(P(∅)) = P({∅}) = {∅, {∅}}, since every non-empty set has at least two
subsets, namely ∅ and itself.
It is important to note that Cardinality of power set of a set A, where
|A| = n, is given as |P(A)| = 2n . This can be verified for the above mentioned
examples.
Definition 1.7. Partition of a set A is a class of nonempty and mutually
disjoint subsets of A such that their union is the set A itself.
Partition of a set is subset of power set of the set.
Example 1.9. Consider the following examples and non-examples of partitions
on the set X = {a, b, c, d, e, f }
• The set {{a, c}, {b, e, f }, {d}} is a partition on X.
• The class of all singletons {{a}, {b}, {c}, {d}, {e}, {f }} is a partition on
the set X. This can be generalized as follows: For any set A, the set
{{x} | x ∈ A} is a partition on A.
• The class {X} is another partition on X. In general, for any set A, the
set {A} is a partition on A.
Last two examples of partitions are called trivial partitions of a set.
6
• The collection {∅, {a, c, e}, {b, d, f }} is not a partition on X, since it con-
tains the empty set.
• The collection {{a, d}, {b, e, f }} is a subset of P(X) but not a partition on
X, since it does not have a set containing c ∈ X.
Exercise
1. Determine the cardinalities of the following sets. Assume that the cardi-
nalities of the sets A and B are m and n, respectively.
3. List the element(s), if any, of the following sets. In case the set is infinite,
list at least five elements. Let E be the set of all positive even integers.
7
(a) {u, v, w} = {u, u, v, w, u, w} (h) {a, b} ⊆ {a, {b}, {a, b}}
(b) {u, v, w} = {v, u, w, u, v} (i) ∅ ∈ {∅}
(c) A ⊆ {A} (j) ∅ ⊆ {∅}
(d) A ∈ {A} (k) ∅ ∈ {{∅}}
(e) a ∈ {{a}} (l) ∅ ⊆ {{∅}}
(f) {a} ∈ {{a}} (m) {∅} ⊆ {{∅}}
(g) {a} ⊆ {{a}} (n) {∅} ∈ {{∅}}
5. Consider set A = {a, b, c}. Give an example of set B such that A ∈ B and
A ∩ B 6= ∅.
6. Symmetric difference of two sets A and B, is denoted as A⊕B and defined
as: A ⊕ B = (A \ B) ∪ (B \ A). An alternative definition of symmetric
difference of A and B is A ⊕ B = (A ∪ B) \ (A ∩ B). It can be noted that
A ⊕ B consists of elements that are either in A or in B but not in both of
them. Write the set A ⊕ B, where A and B are given as follows:
(a) A = {a, b, c, d, e}, B = {a, c, e, g}
(b) A = {a, b, c, d, e}, B = ∅
(c) A = {a, b, c, d, e}, B = {a, b}
7. Find (A ⊕ B) ⊕ B for each of the sets given in Question 6.
8. Give an example of nonempty sets A, B and C such that:
8
(e) A = Z, C = {Z+ , Z− }
(f) A = Z, C = {Z≤0 , Z≥0 }
(g) A = R, C = {Q, Qc }
(h) A = C, C = {{a + bi | a, b ∈ R, a, b > 0}, {a + bi | a, b ∈ R, a, b ≤ 0}},
where i2 = −1
(i) A = C, C = {R, {ai | a ∈ R, i2 = −1}}
Definition: A partition P1 on a set A is called refinement of the partition
P2 , if every set in P1 is a subset of some set in P2 .
10. Consider set A = {1, 2, 3, 4, 5} and partitions P1 = {{1, 2, 3}, {4}, {5}}
and P2 = {{1, 2}, {3}, {4, 5}}, P3 = {{1, 2, 3}, {4, 5}}. Determine whether
the following statements are true or false.
(a) P1 is a refinement of P2
(b) P2 is a refinement of P1
(c) P1 is a refinement of P3
(d) P2 is a refinement of P3
(e) P3 is a refinement of P2 .
(f) P3 is a refinement of P3 .
11. Determine whether the following are true or false.
(a) Every partition is a refinement of itself.
(b) Empty set is a refinement of every partition.
(c) If P1 is a refinement of P2 and P2 is a refinement of P1 , then P1 = P2 .
(d) Set of all singletons of a set is a refinement of every partition on the
set.
add :
Venn Diagrams
2 Binary relations
When we say that a number is less than the other, we are in fact describing
a relation between two elements of a particular set of numbers. This is one
out of many examples, where one uses binary relations, without formalizing the
concept. Other examples of relations between elements of sets include “being
the subset of ” between sets, “being parallel to” between lines and “being the
square of ” between numbers.
Many important Mathematical structures that will appear in upcoming
chapters are based on sets and tools that relates elements of sets, i.e., binary
relations. It will be made clear in the subsequent sections that functions and
operations are all special cases of binary relations.
9
Definition 2.1. A binary relation from a set A to a set B is a subset of the
Cartesian product A × B.
A binary relation can simply be called as relation.
Example 2.1. Following are examples of relations.
• Consider sets X = {u, v, w} and Y = {1, 2, 3, 4}. The set R = {(u, 1),
(u, 2), (v, 3), (w, 1)} is a relation from set X to Y .
Consider a following relations from a set A = {1, 2, 3, 4} to a set B = {1, 2, 3,
..., 10}.
• R1 = {(x, y) ∈ A × B | x2 = y}
• R2 = {(x, y) ∈ A × B | y = 2x}.
• R3 = {(x, y) ∈ A × B | x ≥ y}.
• R4 = {(x, y) ∈ A × B | x < y}.
The relation R3 (and R4 ) is called ‘ greater than or equal’ relation (and ‘ less
than’ relation, respectively). The above relations could also be written as follows:
• R1 = {(1, 1), (2, 4), (3, 9)}
• R2 = {(1, 2), (2, 4), (3, 6), (4, 8)}
• R3 = {(1, 1), (2, 1), (2, 2), (3, 1), (3, 2), (3, 3), (4, 1), (4, 2), (4, 3), (4, 4)}
Last one is left as an exercise for the reader.
If (a, b) ∈ R, we may also write as a R b and read it as a is related to b by
R. And if (a, b) ∈
/ R, we may write as a R6 b and read it as a is not related to b
by R.
10
• A relation R on a set A is said to be transitive, if it satisfies the following:
for all a, b, c ∈ A, if the ordered pairs (a, b) ∈ R and (b, c) ∈ R, then the
ordered pair (a, c) ∈ R.
• A relation R on a set A is said to be antisymmetric, if it satisfies the
following: for all a, b ∈ A, if the ordered pairs (a, b) ∈ R and (b, a) ∈ R,
then a = b.
Example 2.2. dsds
• Consider set A = {a, b, c, d} and following relations on A.
R1 = {(a, a), (a, b), (a, c), (b, a), (c, a)}
R1 is not reflexive because (b, b), (c, c), (d, d) ∈
/ R.
R1 is symmetric and transitive.
R1 is not antisymmetric because (a, b), (b, a) ∈ R1 but a 6= b and also
(a, c), (c, a) ∈ R1 but a 6= c.
Note that we stated three reasons why R1 is not reflexive, and two
reasons why R1 is not antisymmetric, where only one reason for each
of the statements is sufficient.
R2 = {(a, a), (b, a), (b, b), (c, c), (d, a), (d, d)}
R2 is reflexive and transitive. However R2 is not symmetric because,
for example, (b, a) ∈ R but (a, b) ∈ / R.
R2 is antisymmetric, because there is no pair of ordered pairs that
violates the definition of antisymmetric relation (see Definition 2.2).
For example, (b, a) ∈ R but since (a, b) ∈ / R, we do not need a = b.
R3 = {(a, c), (c, b)}
R3 is not reflexive, symmetric or transitive.
However, R3 is antisymmetric for the same reason as that for R2 .
• Empty relation: The empty set ∅ is a relation between any two sets, and
is called empty relation.
Definition 2.3.
• A relation R on a set is said to be equivalence relation, if it is reflexive,
symmetric and transitive.
• A relation R on a set is said to be partial ordering, if it is reflexive, anti-
symmetric and transitive.
Example 2.3.
11
• R1 = {(α, α), (β, β), (γ, γ)}.
R1 is an equivalence relation as well as partial ordering on A.
This special relation can be defined on any set and is called identity re-
lation on the set.
• R2 = {(α, α), (α, β), (β, β), (β, α), (γ, γ)}
R2 is an equivalence relation but not a partial ordering on A. R2 is not
antisymmetric which disqualifies it from being a partial ordering on A.
• R3 = {(α, α), (α, β), (α, γ), (β, β), (β, γ), (γ, γ)}
R3 is a partial ordering on A but not an equivalence relation. R3 is not
symmetric which disqualifies it from being an equivalence relation on A.
12
We can compose a relation on a set with itself, which gives powers of a
relation on a set, as shown in the following definition.
Definition 2.5. If R is a relation on a set, then R2 = R ◦ R, R3 = R2 ◦ R and
so on.
Remark 2.1. The above can be generalized as: Rn+1 = Rn ◦R, for n = 1, 2, 3, . . .
Example 2.6. Consider the set A and relations R1 , R2 and R3 of Example 2.2.
R12 = {(a, a), (a, b), (a, c), (b, a), (b, b), (b, c), (c, a), (c, b), (c, c)},
R13 = R12 ,
R22 = {(a, a), (b, a), (b, b), (c, c), (d, a), (d, d)},
R23 = R22
R32 = {(a, b)},
and R33 = ∅.
One can verify that: R1n = R12 , R2n = R22 , while R3n = ∅ for n = 3, 4, 5, . . .,
Definition 2.6. sdf
Exercise
Consider the following relations on set A = {2, 4, 6}.
R1 = {(2, 4), (2, 6), (4, 2), (6, 2), (6, 6)}
R2 = {(2, 2), (6, 6)}
R3 = {(2, 4), (4, 6)}
3. If the relations R1 , R2 and R3 are not symmetric, determine which are the
minimum possible elements of A × A that should be added to the relation
to get a symmetric relation.
4. If the relations R1 , R2 and R3 are not transitive, determine which are the
minimum possible elements of A × A that should be added to the relation
to get a transitive relation.
13
5. If the relations R1 , R2 and R3 are not antisymmetric, determine which are
the minimum possible elements that should be removed from the relation
to get an antisymmetric relation.
6. Compute the following:
7. Determine whether the relation R on the set of reals R defined as: xRy
iff x − y ∈ Z, is an equivalence relation.
8. Determine whether the relation R on the set of positive integers defined
as: xRy iff y/xisaninteger is an equivalence or not.
3 Functions
Basic definition of a function that one encounters at high school level is given
as follows.
insert illustrations, applications
practical examples in this section
STORY: Teacher and student grade assignment problem, Problem 1: student
name is missing, Problem 2: Student name appears twice
Definition 3.1. Consider non-empty sets A and B. A function from A to B is
a rule that assigns to each element of A exactly one element of B.
A function is a special case of binary relation. In this context following
definitions of function are equivalent to each other and to Definition 3.1.
Definition 3.2. sdsd
• A function is a relation f defined from a set A to a set B as for all x ∈ A
there exist a unique y ∈ B such that (x, y) ∈ f .
14
• A relation R from a set A to set B is a function if it satisfies: For all
x ∈ A if xRy1 and xRy2 then it implies that y1 = y2 .
In the first one of Definitions 3.2, the term ‘unique’ means a finite (less
than infinity) and definite (one and only one) value. One can observe that
Definitions 3.2 are just formal versions of Definition 3.1. Functions are also
called as “mappings”4 or “transformations”5 . We usually denote a function by
lower-case English alphabets f ,g,h etc.
Remark 3.1.
• A function from set A to set B is denoted as f : A → B.
ematics that deals with certain mathematical structures called Vector spaces (introduced in
Chapter ???)
15
to simple words by saying that a surjective function is one in which every element
of the codomain is image of some element of domain. At this point, it might
be interesting to compare the definition of a function (Definition 3.2), with the
definitions of injective and surjective (bijective) functions. For a relation to be
a function, two conditions on domain are required: every element of domain
should have an image in the codomain, and the image of every element in the
domain should be unique. On the other hand, for a function to be bijective,
two conditions on codomain are required: every element of codomain should be
an image of element of domain (due to surjectivity), and the preimage of every
element of codomain should be unique (due to injectivity). Thus bijectivity of a
function guarantees that the inverse relation of the function is a function itself.
Remark 3.2. If a function is bijective it gives us the guarantee of existence of
inverse of the function.
Interesting facts If |A| = n and |B| = m, then how many functions can
be defined from A to B. How many of them would be injective, surjective and
bijective. If m = n and f is injective then f is bijective. for injective function
n < m, for onto function n > m, if codomain is singleton set then the function
is always onto exercises!.
16
composition of functions. f og and gof theorems for injective, surjec-
tive and bijective functions. f (A ∪ B), f −1 (A ∪ B), f of −1 is identity,
f (f −1 (A ∪ B)), f og 6= gof but (f og)oh = f o(gof ), cancelation law does
not hold, f ≤ g, constant function, inverse of a function,
For the section on real-valued functions: sum, difference, product,
quotient and , linear function, increasing function, natural domain,
range and bounded and unbounded function, even function/odd func-
tion etc.
Existence of Inverse function
For any bijective function there exist an inverse function. For example f : A →
B is a bijective function, then there exist an inverse function of the function f
defined as f −1 : B → A (Prof. Oleg exercises)
Inverse of a function
How to find inverse Algebraically
Method: First interchange y and x in bijective function y = f (x), i.e., x = f (y)
and then solve the equation for y in terms of x. The resulting equation would be
the inverse of the original function. For example, for the function f : R → R≥0
such that√f (x) = x2 . Now let x = y 2 , and solving the equation for y we
get y =√ x. The resulting inverse function f −1 : R≥0 → R is defined to be
f −1 = x.
Exercise
1. Choose the best answer.
(a) If f (2x) = 6x + 4, then f (x) =
17
x √ √
x
√ ln x
(A) e 2 (B) ln x (C) e (D) ln x (E) 2
√
(c) If f (ex ) = x for x ≥ 1, then find f −1 (x).
5
(A) x − 3 (B) 3 − x (C) 2 (D) 8 (E) x+3
x
4. Let f be a function defined as f (x) = for x 6= 1.
1−x
Show that:
x x
(i) f −1 (x) = f (x) (ii) f (f (x)) = (iii) f n (x) =
1 − 2x 1 − nx
where f n (x) = f (f (f (· · · (f (x)) · · · ))) for n-compositions
(iv) Find f (3x) in terms of y = f (x)
x+1
5. Let f be a function defined as f (x) = for x 6= 1. Determine which of
x−1
the following is not equal to f (x)
1−x
6. Do the same question as previous one with f (x) = for x 6= −1.
1+x
7. (i) If for x ∈ Z, f (x) = 21 f (x − 1) + 12 f (x + 1), then which of the following
assertions are true:
(A) f is constant (B) The graph of f is a subset of a line (C) f is injective
(D) f is a strictly increasing function.
(ii) what can we conclude about the first part if the domain of the function
is set of real numbers. requires supporting theory
18
8. If domain of a function f is [0, 1], then what would be the domain of the
function g(x) = f (x + 14 ) + f (x − 14 ).
9. (i)If a < f (x) < x for all x ∈ (a, b), then can we conclude about the function
f that
(A) f is bounded/unbounded (B) f is constant/nonconstant (C) f is posi-
tive/negative (D) f is increasing/decreasing (E) f is polynomial of degree
1.
(ii) What would we have if a ≤ f (x) ≤ x for all x ∈ (a, b) in part (i).
2
10. Let a and b be two constants. If f (x) = ae−x +bx tan x−|x| and if f (7) = 5,
then f (−7) is
(A) −5 (B) 5 (C) −2 (D) undefined (E) cannot be uniquely determined by
information given. The reader might not be aware of exponential and trig
functions
19