lecture_notes_real_analysis
lecture_notes_real_analysis
1 Preliminaries
Let N := {1, 2, . . .} denote the countably infinite set of natural numbers. For any natural
number K ∈ N, the K-dimensional real (Euclidean) space is the K-fold Cartesian product of
R. We denote this space by RK , so that x ∈ RK is (x1 , x2 , . . . , xK ) = (xi )K
i=1 . Sometimes we
abuse notation by letting K denote the set {1, 2, . . . , K}. Then the typical member of RK
can be denoted by (xi )i∈K .
The origin of RK is the vector 0 whose components (0, 0, . . . , 0) are all zero. Given any
pair a, b ∈ R there are four different possible inequalities, namely: a > b, a ≥ b, a ≤ b and
a < b. If a 6= b, exactly one of these holds. But if a = b, then both a ≥ b and a ≤ b.
Given any pair x, y ∈ RK where K ≥ 2, there are six different possible inequalities, namely:
x y, x > y, x = y, x 5 y, x < y, and x y. The first three inequalities are defined so
that:
1. x y iff xi > yi for all i ∈ K;
2 Vector Spaces
Much of economics, especially at the undergraduate level, relies only on vectors in a finite-
dimensional Euclidean space RK . But this is a prominent example of the much more ex-
tensive class of real linear spaces, some of them infinite-dimensional, which arise naturally
when economists consider difference and differential equations, optimal control problems, and
dynamic programming.
Definition 1. A real linear (or vector) space is a set L equipped with the two binary operations
(x, y) 7→ x + y from L × L to L and (λ, x) 7→ λx from R × L to L, as well as a unique null
vector θ ∈ L, which for all x, y, z ∈ L and all λ, µ ∈ R must satisfy:
1
Based on notes by Andrés Carvajal
1
1. x + y = y + x (addition commutes);
3. x + θ = x (additive identity);
6. 0x = θ;
7. 1x = x;
Exercise 1 (Stokey and Lucas, exercise 3.2). Show that the following are vector spaces:
For the moment, we are going to work with a particular type of correspondences where
the set f (x) is a singleton.
Definition 3. Let X and Y be two nonempty sets. A function f from a set X into a set Y ,
denoted f : X → Y , is a rule that assigns to each x ∈ X a unique f (x) ∈ Y
Here, set X is said to be the domain of f , and Y its target set or co-domain. If f : X → Y
and A ⊆ X, the image of A under f , denoted by f [A], is the set
In particular, the image f [X] of the whole domain is called the range of f .
2
Definition 4. Function f : X → Y is said to be:
f (x1 ) = f (x2 ) ⇒ x1 = x2 .
Example 1. The function f : R2 7→ R defined by f (x1 , x2 ) = x21 +x22 is neither one-to-one nor
onto. It is not one-to-one because f (1, 0) = f (0, 1) = 1. It is not onto because [R] = R+ 6= R.
Example 2. The function f (x) : R \ {0} 7→ R defined by f (x) = x1 is one-to-one but not
onto. It is one-to-one since x1 = y1 ⇔ x = y. Graphically, any horizontal line that intersects
the graph, it does it at only one point. The function is not onto as f [R] = R \ {0}.
From now on, we only concentrate on definitions and concepts in Euclidean spaces and
maintain the assumption that K ∈ N.
3
y1 )2 + (x2q− y2 )2 + (x3 − y3 )2 . All of these three cases are covered by the single formula
P
d(x, y) = (x − y )2 .
i∈K i i
More generally, any function that satisfies three intuitive properties is called a metric or
distance function.
3.2 Norms
For vector spaces, metrics are usually defined in such a way that the distance between any
two points is equal to the distance of their difference from the zero point. That is, since for
any points x and y in a vector space X, the point x − y is also in X, the metric on a vector
space is usually defined in such a way that d(x, y) = d(x − y, 0). To define such a metric we
need the concept of a norm.
Definition 6. Given any vector space X, a norm on X is a function k·k : X 7→ R such that
for all x, y ∈ X and α ∈ R:
In order to measure how far from 0 an element x of RK is, we use the Euclidean norm
which is defined as2 !1/2
XK
2
kxk = xk .
k=1
It is obvious that when K = 1 the Euclidean norm corresponds to the absolute value.
2
To avoid confusion, you can be explicit about the dimension for which the norm is being used, by adopting
the notation k · kK instead. Also, we will simplify the notation by not always writing the limits in the index of
P 2 1/2
a summation, when it is obvious what these limits are; for instance, we may write k xk for the definition
that follows.
4
4 Metric Spaces and Normed Vector Spaces
The space X = RK equipped with its Euclidean distance d : X × X → R is a prominent
example meeting the next definition.
Exercise 2 (Stokey and Lucas, exercise 3.3). Show that the following are metric spaces:
c. the set of all continuous, strictly increasing functions on [a, b], with d(x, y) = maxa≤t≤b |x(t)−
y(t)|.
Definition 8. A normed vector space is a pair (X, k·k) where X is a set and k·k) : X 7→ R
is a norm.
It is standard to view any normed vector space (X, k·k) as a metric space where the metric
is taken to be d(x, y) = kx − yk for all x, y ∈ X.
Exercise 3 (Stokey and Lucas, exercise 3.4). Show that the following are normed vector
spaces:
hP i1
K 2 2
a. Let X = RK , with kxk = x
k=1 k (Euclidean Space)
5
4.1 Sequences
A sequence in RK is a function f : N → RK . If no confusion is likely, the space in which a
sequence lies is omitted. Following usual notation in mathematics, we can express sequences
as (a1 , a2 , . . .) or (an )∞
n=1 , where an = f (n), for n ∈ N.
√
Example 7. Suppose √ ( n, 1/n, 3) ∈ R3 , for
that f (n) = √ √ all n ∈ N. Then we can express the
∞
sequence as ((1, 1, 3), ( 2, 1/2, 3), ( 3, 1/3, 3), . . .) or ( n, 1/n, 3)n=1 .
It is very important to notice that a sequence has more structure than a set (i.e., it is more
complicated). Remember that a set is completely defined by its elements, no matter how
they are described. For example, the set {0, 3, 8, 15, 24} is the same as the set {24, 15, 8, 3, 0}.
However, the sequences (0, 3, 8, 15, 24, . . .) and (24, 15, 8, 3, 0, . . .) are clearly different: in a
sequence, the order matters!
Using the structure that a sequence has, (an )∞ n=1 is nondecreasing if for all n ∈ N, an+1 ≥ an
and nonincreasing if for all n, an+1 ≤ an . If all the inequalities in the first definition are strict,
the sequence is increasing. while if all the inequalities in the second definition are strict, the
sequence is decreasing.
Theorem 2. (an )∞
n=1 in R
K
is bounded if and only if (ak,n )∞
n=1 in R is bounded for all k =
1, . . . , K.
That is, a subsequence is a selection of some (possibly all) members of the original sequence
that preserves the original order.
√ √
Example 8. Consider the sequence (1/ n)∞ ∞
n=1 , and note that (1/ 2n + 5)n=1 is a subse-
quence of the former. To see why, consider the sequence (nm )∞ ∞
m=1 = (2m + 5)m=1 .
√
Exercise 4. Is (1/ n)∞ ∞
n=1 a subsequence of (1/n)n=1 ? How about the other way around?
When (an )∞
n=1 converges to a, the following notation is also sometimes used: an → a, or
limn→∞ an = a.
6
It is convenient to allow +∞ and −∞ to be limits of sequences. Thus, we extend the
definition as follows: for a sequence (an )∞
n=1 in R, we say that limn→∞ an = ∞ when for
all ∆ > 0 there exists some n∗ ∈ N such that an > ∆ for all n ≥ n∗ ; we also say that
limn→∞ an = −∞ when limn→∞ (−an ) = ∞.
Exercise 6. Does the sequence ( √3nn )∞
n=1 have a limit? Does it converge?
This Theorem simplifies the search for limits of vectors as it tell us that the limit of the
vector is equal to the vector of limits of its components.
Theorem 4. (an )∞ n=1 in R
K
converges to a if and only if (ak,n )∞
n=1 in R converges to ak for
all k = 1, . . . , K.
Proof: Let us prove√sufficiency first. Given any > 0, for each k there is some n∗k ∈ N such
that |ak,n − ak | < / K whenever n ≥ n∗k . Letting n∗ = max{n∗1 , . . . , n∗K } ∈ N and n ≥ n∗ ,
by construction,
X X
kan − ak = ( (ak,n − ak )2 )1/2 < ( 2 /K)1/2 = .
k k
For necessity, fix k and let > 0. By assumption, there is n∗ ∈ N after which kan − ak < ,
which suffices to imply that |ak,n − ak | < . Q.E.D.
A very useful property of limits (for both sequences and functions) is that they preserve
weak inequalities.
Theorem 6. Consider a sequence (an )∞n=1 in R and a number a ∈ R. If an ≤ α for all n ∈ N
and limn→∞ an = a, then a ≤ α. Similarly, if an ≥ α, for all n ∈ N, and limn→∞ an = a, then
a ≥ α.
Proof: Let’s show that an ≤ α for all n ∈ N and limn→∞ an = a, then a ≤ α. The other
result follows by an analogous reasoning. Suppose a > α. Let ε = a − α > 0. Since an → a,
there exists N such that |an − a| < 2ε for all n ≥ N . But then, an > a − 2ε ≥ α for all n ≥ N ,
a contradiction. Q.E.D.
7
The following theorem is also very useful:
Proof: Let us prove the sufficiency statement, leaving necessity as an exercise. Suppose that
limn→∞ (1/an ) = 0 and fix ∆ > 0. Then, for some n∗ ∈ N one has that |1/an − 0| < 1/∆ when
n ≥ n∗ ; since each an > 0, it follows that an > ∆. Q.E.D.
1. limn→∞ (an + bn ) = a + b;
Proof: To show 1., let ε > 0 be arbitrary. We need to show that there exists N ∈ N such
that |an + bn − a − b| < ε for all n ≥ N . Since an → a and bn → b, there exists Na ∈ N and
Nb ∈ N such that |an − a| < 2ε for all n ≥ Na and |bn − b| < 2ε for all n ≥ Nb . But then, by
the triangle inequality:
ε ε
|an + bn − a − b| ≤ |an − a| + |bn − b| ≤ + = ε.
2 2
Q.E.D.
Proof: Suppose (an )∞ n=1 converges to a ∈ R. Then there exists N ∈ N such that |an − a| ≤ 1
for all n ≥ N . Note that
8
Proof: Suppose (an )∞n=1 is monotone and bounded. Then it has a supremum, say c. Let ε > 0
be arbitrarily chosen. By definition of supremum, there exists N ∈ N such that aN > c − ε.
Since (an )∞
n=1 is monotone, it follows that 0 < c − an < c − aN < ε. Thus, |an − c| < ε for all
n ≥ N. Q.E.D.
An informal argument for the Bolzano-Weierstrass Theorem for sequences defined into R
is as follows: if (an )∞
n=1 is bounded, then it lies in some bounded interval I1 . Slice that interval
in halves. At least one of the halves will contain infinitely many terms of the sequence. Call
that interval I2 , slice it in halves, and let I3 be a half that contains infinitely many elements...
By doing this indefinitely, we construct intervals I1 , I2 , ... such that each In contains infinitely
many terms of the sequence and In+1 ⊆ In . By construction, we can find a subsequence
(xnm )∞m=1 such that for all m ∈ N, anm ∈ Im . This subsequence will have the property that
their elements get arbitrarily close to one another as we move along the sequence (because,
by construction, our “sequence” of intervals is in fact shrinking to zero diameter as m goes
to ∞). Sequences with this property are said to be Cauchy and, in Euclidean spaces, are
guaranteed to converge.
√
Exercise 9. Does the sequence (1/ n)∞ √ ∞
3n
n=1 have a limit? Is it Cauchy? How about ( n+ n )n=1 ?
Exercise 10. Repeat the last part of Exercise 9, using Theorem 7. Is it easier?
Proof: Suppose a sequence {an }∞ n=1 is Cauchy. Let ε = 1. Then there exists N such that
|an − am | < 1 for all n, m ≥ N . Let B = max {a1 , ..., aN }. Now let’s show that |an | ≤ 1 + B
for all n ∈ N. This is obvious for n ≤ N . For n > N , |an − aN | < 1. Hence,
Q.E.D.
9
Definition 13. A metric space (X, d) is complete if every Cauchy sequence in X converges
to an element of X.
Verifying the completeness of particular spaces can take some work. We take as given the
following:
Fact: R with d(x, y) = |x − y| is a complete metric space.
The punctured open ball of radius δ around x, denoted Bδ0 (x), is the set Bδ0 (x) = Bδ (x) \ {x}.
Definition 15. A point x̄ ∈ RK is a limit point of X ⊆ RK if for every ε > 0, Bε0 (x̄)∩X 6= ∅
Exercise 12. Prove the following: Let X ⊆ R. A point x̄ ∈ R is a limit point of X iff there
exists a sequence (xn )∞
n=1 in X \ {x̄} that converges to x̄.
Another type of limit has to do with functions, although not directly with sequences.
Definition 16. Consider a function f : X → R, where X ⊆ RK . Suppose that x̄ ∈ RK is a
limit point of X and that ȳ ∈ R. We say that limx→x̄ f (x) = ȳ if for every ε there exists δ > 0
such that d(f (x), ȳ) < ε for all x ∈ Bδ0 (x̄) ∩ X.
It is important to notice that we do not require x̄ ∈ X in our previous definition, so that
f (x̄) need not be defined. Also, one should notice that even if x̄ ∈ X, x̄ is not always a limit
point of X, in which case the definition does not apply. Finally, notice that even if x̄ ∈ X
and x̄ is a limit point of X, it need not be the case that limx→x̄ f (x) = f (x̄).
Definition 17. Consider a function f : X → R, where X ⊆ RK . Suppose that x̄ ∈ RK is a
limit point of X. We say that limx→x̄ f (x) = ∞ if for every ∆ > 0, there exists δ > 0 such that
f (x) ≥ ∆ for all x ∈ Bδ0 (x̄) ∩ X. We say that limx→x̄ f (x) = −∞ when limx→x̄ (−f )(x) = ∞.
Exercise 13. Suppose that X = R and f (x) = x + a for some a ∈ R. What is limx→0 f (x)?
Exercise 14. Suppose that X = R and f : X → R is defined by
1/x, if x 6= 0,
f (x) =
0, otherwise.
10
Example 9. Let X = R \ {0} and f : X → R is defined by
1, if x > 0,
f (x) =
−1, otherwise.
In this case, we claim that limx→0 f (x) does not exist. To see why, fix 0 < ε < 1, and notice
that for all δ > 0, there are x1 , x2 ∈ Bδ (0) such that f (x1 ) = 1 and f (x2 ) = −1, and, hence,
|f (x1 ) − f (x2 )| = 2 > 2ε. Because of triangle inequality, it is thus impossible that for some
ȳ ∈ R, we have |f (x1 ) − ȳ| < ε and |f (x2 ) − ȳ| < ε. Also, it is obvious that limx→0 f (x) = ∞
and limx→0 f (x) = −∞ are both impossible.
There exists a tight relationship between limits of functions and limits of sequences, which
is explored in the following theorem.
Proof: (⇐) Suppose that for every sequence (xn )∞ n=1 in X\{x̄} that converges to x̄, limn→∞ f (xn ) =
ȳ but limx→x̄ f (x) 6= ȳ. Then, there must exist some ε > 0 such that for every δ > 0, there
exists x ∈ Bδ0 (x̄) ∩ X satisfying
|f (x) − ȳ| ≥ ε.
0
Thus, for each n ∈ N there is xn ∈ B1/n (x̄) ∩ X for which |f (xn ) − ȳ| ≥ ε. So, we can
∞
construct a sequence (xn )n=1 in X \ {x̄} and limn→∞ xn = x̄. But then limn→∞ f (xn ) 6= ȳ,
which contradicts the initial hypothesis.
(⇒) Consider any sequence (xn )∞ n=1 in X \ {x̄} that converges to x̄. Fix ε > 0. Since
limx→x̄ f (x) = ȳ ∈ R, then, there is some δ > 0 such that |f (x) − ȳ| < ε for all x ∈ Bδ0 (x̄) ∩ X.
Since limn→∞ xn = x̄, there is N ∈ N such that xn ∈ Bδ (x̄) for all n ≥ N . Moreover, since
each xn ∈ X \ {x̄}, we have that xn ∈ Bδ0 (x̄) ∩ X and, therefore, |f (xn ) − ȳ| < ε for all n ≥ N .
Since ε > 0 was arbitrarily chosen, this implies that limn→∞ f (xn ) = ȳ. Q.E.D.
Theorem 15. Let f : X → R and g : X → R. Let x̄ be a limit point of X. Suppose that for
number ȳ1 , ȳ2 ∈ R one has that limx→x̄ f (x) = ȳ1 and limx→x̄ g(x) = ȳ2 . Then,3
11
Proof: Let us prove only the first two statements of the theorem. The proof of the last two
parts is left as an exercise. For the first statement, we have that for all ε > 0, there exist
δ1 , δ2 > 0 such that |f (x) − ȳ1 | < ε/2 for all x ∈ Bδ0 1 (x̄) ∩ X, and |g(x) − ȳ2 | < ε/2 for all
x ∈ Bδ0 2 (x̄) ∩ X. Let δ = min{δ1 , δ2 } > 0. Then, by construction, for all x ∈ Bδ0 (x̄) ∩ X we
have that |f (x) − ȳ1 | < ε/2 and |g(x) − ȳ2 | < ε/2, which implies, by triangle inequality, that
For the second statement, note first that if α = 0 the proof is trivial. Then, consider
α 6= 0. Since limx→x̄ f (x) = ȳ1 ∈ R, then for all ε > 0, there is some δ > 0 such that, for all
x ∈ Bδ0 (x̄) ∩ X, |f (x) − ȳ1 | < ε/|α|. This implies that
|(αf )(x) − αȳ1 | = |α(f (x) − ȳ1 )| = |α||f (x) − ȳ1 | < ε,
The next result is the counterpart of Theorem 6, that “weak inequalities are preserved
under limits” for sequences, for limits of functions; again, the proof is left as an exercise.
Exercise 15. The previous theorem can be proved by two different arguments. Can you give
them both? (Hint: one argument is by contradiction; the other one uses Theorem 6 directly.)
5 Topology of RK
From now on, we deal only with subsets of RK , for a finite number K; that is, whenever we
introduce sets X or Y , we assume that X, Y ⊆ RK and use all the algebraic structure of
RK . We also use the structure induced in RK by the Euclidean norm. Whenever we take
complements, they are relative to RK .
Definition 18. Set X is open if for every x ∈ X, there is some ε > 0 such that Bε (x) ⊆ X.
Example 10 (Open intervals are open sets in R). We define an open interval, denoted (a, b),4
where a, b ∈ R, as {x ∈ R|a < x < b}. To see that these are open sets (in R), take x ∈ (a, b),
and define ε = min{x − a, b − x}/2 > 0. By construction, Bε (x) ⊆ X. As a consequence,
notice that open balls are open sets in R. The same is true in RK , for any K.
4
Sometimes open intervals are denoted by ]a, b[ rather that (a, b) in order to distinguish them from two-
element sequences. We will, however, follow the more standard notation.
12
It is easy to see that if we extend the definition of the open interval (a, b) to {x ∈ R|a <
x < b} where a, b ∈ R ∪ {+∞, −∞}, then it continuous to be true that open intervals are
open sets. The following theorem is a specific instance of a more general principle: in any
space, the empty set and the universe are open sets.
Theorem 17. The empty set and RK are open.
Proof: A set X fails to be open if one can find x ∈ X such that for all ε > 0 one has that
Bε (x) ∩ X c 6= ∅. Clearly, ∅ cannot exhibit such property. The argument that RK is open is
left as an exercise. Q.E.D.
Theorem 18. The union of any collection of open sets is an open set. The intersection of
any finite collection of open sets is an open set.
Proof: For the first statement, suppose that Z is the union of a given collection of open sets
(whether finite or infinite doesn’t matter), and suppose that x ∈ Z. By definition, then, there
exists a member X of the collection of sets such that x ∈ X. By assumption, X is open, so
that ∃ε > 0 for which Bε (x) ⊆ X, and it follows, then, that Bε (x) ⊆ Z.
For the second part, suppose that Z is the intersection of a finite collection of open sets,
say {X1 , X2 , . . . , Xn∗ }, and suppose that x ∈ Z. By definition, then, for each n = 1, 2, . . . , n∗ ,
it is true that x ∈ Xn . By assumption, each Xn is open, so that there exists εn > 0 such that
Bεn (x) ⊆ Xn . Let ε = min{ε1 , ε2 , . . . , εn∗ } > 0. By construction, for each n, we have that
Bε (x) ⊆ Bεn (x) ⊆ Xn and therefore Bε (x) ⊆ Z. Q.E.D.
Definition 19. We say that point x is an interior point of the set X, if there is some ε > 0
for which Bε (x) ⊆ X.
The set of all the interior points of X is called the interior of X, and is usually denoted
int(X).5 Note that int(X) ⊆ X.
Exercise 16. Show that for every X, int(X) is open and that X is open if and only if
int(X) = X.
Exercise 17. Prove the following: “If x ∈ int(X), then x is a limit point of X.”
Exercise 18. Did we really need finiteness in the second part of Theorem 18? Consider the
following infinite collection of open intervals: for all n ∈ N, define In = (− n1 , n1 ). Find the
intersection of all those intervals, denoted ∩∞
n=1 In . Is it an open set?
As before, the empty set and the universe are closed sets. In RK these are the only two
sets that have both properties, but this principle does not generalize to other spaces.
5
Alternative, but usual, notation is X o .
6
Alternative notation is X̄.
13
Theorem 19. The empty set and RK are closed.
Proof: In order for set X to fail to be closed, there has to exist (xn )∞
n=1 satisfying that all
xn ∈ X, and that xn → x̄, yet x̄ ∈
/ X. Clearly, one cannot find such sequence if X = ∅. The
argument that RK is left as an exercise. Q.E.D.
Exercise 19. If a, b ∈ R∪{−∞, ∞}, a < b, is (a, b) closed? We define the half-closed interval
(a, b], where a ∈ R ∪ {−∞}, b ∈ R, a < b, as (a, b] = {x ∈ R|a < x ≤ b}. Similarly, we define
the half-closed interval [a, b) where a ∈ R, b ∈ R∪{∞}, a < b, as [a, b) = {x ∈ R | a ≤ x < b}.
Are half-closed intervals closed sets? Are they open? If x ∈ RK , is {x} an open set, a closed
set or neither?
Proof: Suppose that X c is open, and consider any sequence (xn )∞n=1 satisfying that all xn ∈ X
and converging to some x̄; we need to show that x̄ ∈ X. In order to argue by contradiction,
suppose that x̄ ∈ X c . Since X c is open, there is some ε > 0 for which Bε (x̄) ⊆ X c . Since
xn → x̄, there is n∗ ∈ N such that kxn − x̄k < ε when n ≥ n∗ . Then, for any n ≥ n∗ , we have
that xn ∈ Bε (x̄) ⊆ X c , which is impossible.
Suppose now that X is closed, and fix x ∈ X c . We need to show that for some ε > 0
one has that Bε (x) ⊆ X c . Again, suppose not: for all ε > 0, it is true that Bε (x) ∩ X 6= ∅.
Clearly, then, for all n ∈ N we can pick xn ∈ B1/n (x) ∩ X. Construct a sequence (xn )∞ n=1 of
such elements. Since 1/n → 0 it follows that xn → x, and all xn ∈ X and X is closed, then
x ∈ X, contradicting the fact that x ∈ X c . Q.E.D.
Theorem 21. The intersection of any collection of closed sets is closed. The union of any
finite collection of closed sets is closed.
Exercise 20. Prove the following: “Given a set X ⊆ RK , one has x ∈ cl(X) if and only if
there exists a sequence (xn )∞
n=1 in X such that xn → x.”
Exercise 21. Prove the following: “For every set X ⊆ RK , X ⊆ cl(X), and X is closed if
and only if X = cl(X).”
Example 11. Closed intervals are closed sets. We define an closed interval, denoted [a, b],
where a, b ∈ R and a ≤ b as {x ∈ R|a ≤ x ≤ b}. To see that these are closed sets, notice that
[a, b]c = (−∞, a) ∪ (b, ∞), and conclude based on previous results.
Exercise 22. Did we really need finiteness in the second part of Theorem 21? Consider the
following infinite collection of closed intervals: for all n ∈ N, define Jn = [1 + n1 , 3 − n1 ]. Find
the union of all those intervals, denoted ∪∞ n=1 Jn . Is it a closed set?
Exercise 23. Given X ⊆ RK , define the boundary of X as bd(X) = cl(X) \ int(X). Prove
the following statements: “X is closed if and only if bd(X) ⊆ X. It is open if and only if
bd(X) ∩ X = ∅.” Also, prove that
14
5.3 Compact sets
A set X ⊆ RK is said to be bounded above if there exists α ∈ RK such that x ≤ α for all
x ∈ X; it is said to be bounded below if for some β ∈ RK one has that x ≥ β is true for all
x ∈ X; and it is said to be bounded if it is bounded above and below.
Exercise 24. Show that a set X is bounded if and only if there exists α ∈ R+ such that
kxk ≤ α for all x ∈ X.
Definition 21. A set X ⊆ RK is said to be compact if it is closed and bounded.
Exercise 25. Prove the following statement: if (xn )∞ n=1 is a sequence defined on a compact
set X, then it has a subsequence that converges to a point in X.
6 Continuity
6.1 Continuous functions
Definition 22. Function f : X → R is continuous at x̄ ∈ X if for all ε > 0, there exists
δ > 0 such that |f (x) − f (x̄)| < ε for all x ∈ Bδ (x̄) ∩ X. It is continuous if it is continuous
at all x̄ ∈ X.
Note that continuity at x̄ is a local concept. Second, note that x̄ in the definition may
but need not be a limit point of X. Therefore, two points are worth noticing: if x̄ is not a
limit point of X, then any f : X → R is continuous at x̄ (why?); and if, on the other hand,
x̄ is a limit point of X, then f : X → R is continuous at x̄ if and only if limx→x̄ f (x) = f (x̄).
Intuitively, this occurs when a function is such that in order to get arbitrarily close to f (x̄)
in the range, all we need to do is to get close enough to x̄ in the domain. By Theorem 14, it
follows that when x̄ ∈ X is a limit point of X, f is continuous at x̄ if and only if whenever
we take a sequence of points in the domain that converges to x̄, the sequence formed by their
images converges to f (x̄) (that in this case the concept is not vacuous follows from Exercise
12).
Exercise 26. Consider the function introduced in Exercise 14. Is it continuous?
Exercise 27. Consider the function introduced in Example 9. Is it continuous? What if we
change the function, slightly, as follows: f : R → R, defined as
1, if x > 0;
f (x) = 0, if x = 0;
−1, if x < 0.
Is it continuous?
15
Theorem 23. Fucntion f : RK → R is continuous if and only if, for every open set U ⊆ R,
the set f −1 [U ] is open.
Proof: Fix x̄ ∈ RK and ε > 0. By Example 10, we know that Bε (f (x̄)) is open and, therefore,
so is f −1 [Bε (f (x̄))]. Since x̄ ∈ f −1 [Bε (f (x̄))], we have that there exists some δ > 0 for which
Bδ (x̄) ⊆ f −1 [Bε (f (x̄))]. For such δ, the latter means that that for all x ∈ Bδ (x̄) one has that
|f (x) − f (x̄)| < ε.
Now, let U ⊆ R be an open set, and let x̄ ∈ f −1 [U ]. By definition, f (x̄) ∈ U , and since U
is open, there is some ε > 0 for which Bε (f (x̄)) ⊆ U . Since f is continuous, there exists δ > 0
such that |f (x) − f (x̄)| < ε for all x ∈ Bδ (x̄). The latter implies Bδ (x̄) ⊆ f −1 [U ]. Q.E.D.
Theorem 25. The image of a compact set under a continuous function is compact.
Definition 23. One says that limx&x̄ f (x) = `, when for every ε > 0 there is a number δ > 0
such that |f (x) − `| < ε for all x ∈ X ∩ Bδ (x̄) satisfying x > x̄. In such case, function f
is said to converge to ` as x tends to x̄ from above. Similarly, limx%x̄ f (x) = `, if for every
ε > 0 there is δ > 0 such that |f (x) − `| < ε for all x ∈ X ∩ Bδ (x̄) satisfying that x > x̄. In
this case, f is said to converge to ` as x tends to x̄ from below.
Exercise 28. Consider the function introduced in Exercise 27. Is it right-continuous? Left-
continuous? What if, keeping the rest of the function unchanged, we redefine f (0) = −1? Is
it left- or right-continuous? What if f (0) = 1.
6.4 Derivatives
Definition 25. Let f : R 7→ R be a function defined in a neighbourhood of x0 . Then f is
said to be differentiable at x0 with derivative equal to the real number f 0 (x0 ) if for every ε > 0
there exists δ > 0 such that |x − x0 | < δ implies
f (x) − f (x0 )
− f 0 (x0 ) ≤ ε
x − x0
7
It does not matter whether f (a) ≥ f (b) or f (a) < f (b) – we could simply have written that γ ∈
[f (a), f (b)] ∪ [f (b), f (a)].
16
Now observe that since x − x0 6= 0, we can multiply the inequality above by |x − x0 | to
obtain
|f (x) − f (x0 ) − f 0 (x0 )(x − x0 )| ≤ ε |x − x0 |
This new inequality admits and interesting interpretation. We think of f (x) − f (x0 ) −
f 0 (x0 )(x − x0 ) as the difference of two functions – the original function f (x) and the function
f (x0 ) + f 0 (x0 )(x − x0 ). Here x0 is thought of as a constant, as are f (x0 ) and f 0 (x0 ), so this
second function is simply and affine function ax+b, where a = f 0 (x0 ) and b = f (x0 )−x0 f 0 (x0 )..
Now the existence of the derivative of f at x0 is a statement about the difference between the
original function and the affine function g(x) = f (x0 ) + f 0 (x0 )(x − x0 ) which we will think
of as a statement of how well g(x) approximates f . However, there are many affine functions
whose graph crosses the graph of f at the point (x0 , f (x0 )). These functions have the form
f (x0 ) + a(x − x0 ) for any real constant a. The property that f (x) − g(x) tends to 0 as x → x0
is not what distinguish g(x) from other affine functions as that would have happened with
any choice of a. The important difference is that f (x) − g(x) goes to zero faster than for any
other choice of a in the sense that it goes faster than |x − x0 |.
17