Bounded functions
Learning Objectives
- State the definitions of upper bound, lower bound, and bounded function.
- Decide whether a given function is bounded above, below, or both.
- Identify the maximum and minimum of a function, when they exist.
- Relate boundedness to the image of the function.
Motivation
In Course 2 we called a sequence \((a_n)\) bounded if its values stayed within some fixed range — never larger than some \(M\), never smaller than some \(m\). Since a sequence is a function from \(\mathbb{N}\) to \(\mathbb{R}\), that was secretly a definition about a special kind of function.
The same question makes sense for any real-valued function: do its values stay below some fixed ceiling? Above some fixed floor? Both? Neither? When at least one of these holds, we say the function is bounded in the corresponding direction. The vocabulary will appear repeatedly in the courses that follow: the quadratic function will turn out to have a minimum or a maximum depending on its leading coefficient, and the trigonometric functions \(\sin\) and \(\cos\) are bounded between \(-1\) and \(1\).
Upper bound, lower bound
Let \(f \colon D \to \mathbb{R}\) be a function.
A number \(M \in \mathbb{R}\) is an upper bound for \(f\) if \(f(x) \leq M\) for every \(x \in D\).
A number \(m \in \mathbb{R}\) is a lower bound for \(f\) if \(f(x) \geq m\) for every \(x \in D\).
If \(f\) has an upper bound, we say \(f\) is bounded above; if it has a lower bound, it is bounded below.
Bounds are not unique. If \(M\) is an upper bound, so is any \(M' > M\) — for example, if \(f(x) \leq 5\) for all \(x\), then also \(f(x) \leq 100\). The interesting question is whether any finite bound exists, not what the smallest one is.
Bounded function
A function \(f \colon D \to \mathbb{R}\) is bounded if it is bounded both above and below — that is, if there exist \(m, M \in \mathbb{R}\) such that
\[m \leq f(x) \leq M \quad \text{for every } x \in D.\]
Equivalently (and often more convenient): \(f\) is bounded if there is some \(K \geq 0\) such that
\[|f(x)| \leq K \quad \text{for every } x \in D.\]
The two formulations are equivalent: from \(m \leq f(x) \leq M\) take \(K = \max(|m|, |M|)\); conversely, \(|f(x)| \leq K\) means \(-K \leq f(x) \leq K\).
A function that is not bounded — that is, lacks either an upper bound, or a lower bound, or both — is called unbounded.
Three examples
Bounded. The function \(f \colon [-1, 1] \to \mathbb{R},\; f(x) = \sqrt{1 - x^2}\) (the upper semicircle from Unit 1) is bounded. Its image is the interval \([0, 1]\): every value satisfies \(0 \leq f(x) \leq 1\), so \(0\) is a lower bound and \(1\) is an upper bound.
Bounded below only. The function \(g \colon \mathbb{R} \to \mathbb{R},\; g(x) = x^2\) is bounded below (by \(0\), or by any negative number), since every square is non-negative. But it is not bounded above: for any candidate upper bound \(M\), the value \(g(M + 1) = (M + 1)^2\) is larger than \(M\) (when \(M \geq 0\)), so \(M\) fails to bound. The parabola climbs forever.
Unbounded. The identity function \(h \colon \mathbb{R} \to \mathbb{R},\; h(x) = x\) is unbounded in both directions. Whatever upper bound \(M\) we try, the input \(M + 1\) gives \(h(M + 1) = M + 1 > M\). Similarly for any lower bound. The graph extends indefinitely upward and downward.
Boundedness and the image
The cleanest way to phrase boundedness uses the image. The function \(f \colon D \to \mathbb{R}\) is:
bounded above iff \(\mathrm{Im}(f)\) has an upper bound (as a set of real numbers);
bounded below iff \(\mathrm{Im}(f)\) has a lower bound;
bounded iff \(\mathrm{Im}(f)\) is contained in some bounded interval \([m, M]\).
So boundedness of \(f\) is a property of the set of values it produces, regardless of which inputs produce them. Once we identify the image of a function, we can read off its boundedness directly: \(\mathrm{Im}(x^2) = [0, +\infty)\) has a lower bound but no upper bound; \(\mathrm{Im}(\sqrt{1 - x^2}) = [0, 1]\) is bounded; \(\mathrm{Im}(x) = \mathbb{R}\) has neither.
Maximum and minimum
A bound need not be attained by the function. If \(f(x) \leq 5\) for all \(x\), it is consistent with \(f\) only ever reaching, say, \(3\). When the bound is in fact attained — when some input produces the bound as an output — we give it a special name.
\(M \in \mathbb{R}\) is the maximum of \(f\) if \(M\) is an upper bound and there exists \(x_0 \in D\) with \(f(x_0) = M\). We write \(\max f = M\).
\(m \in \mathbb{R}\) is the minimum of \(f\) if \(m\) is a lower bound and there exists \(x_0 \in D\) with \(f(x_0) = m\). We write \(\min f = m\).
When a maximum exists, it is unique (and likewise for the minimum) — it is the largest value that the function actually achieves. A function can have a maximum, a minimum, both, or neither.
Maxima and minima of familiar functions
The semicircle. The semicircle above has both. The maximum is \(1\), attained at \(x = 0\). The minimum is \(0\), attained at \(x = \pm 1\).
The squaring function. The squaring function above has a minimum (\(0\), attained at \(x = 0\)) but no maximum (it is unbounded above).
The identity. The identity has neither — it is unbounded in both directions.
Constant functions. A constant function \(c(x) = k\) on any non-empty domain has both maximum and minimum, and they are equal: \(\max c = \min c = k\). Every input gives the same value, so the value is simultaneously the largest and the smallest.
Connection to Computer Science
Boundedness is the property that makes computation possible. Every numeric data type — 32-bit integer, 64-bit float, and so on — has a fixed range, and any function whose values stay inside that range can be computed without overflow. A function known to be bounded by, say, \(\pm 1\) (like \(\sin\) and \(\cos\)) can be stored in tighter-than-default representations. And in practical contexts — physics simulations, animation, machine learning — values that "should" stay in a range are routinely clamped with \(\min\) and \(\max\) to ensure the bound holds even if the underlying formula doesn't guarantee it.
Bounded is not the same as "has a maximum"
It is tempting to think that a bounded function must attain its upper and lower bounds — that is, must have a maximum and a minimum. This is true for many functions we will meet in this course (linear, quadratic, polynomial functions on closed intervals), but it is not true in general.
Consider \(f \colon (0, 1) \to \mathbb{R},\; f(x) = x\), where the domain is the open interval \((0, 1)\) (endpoints excluded). The image is also the open interval \((0, 1)\). The function is bounded — every value is between \(0\) and \(1\) — but it has no maximum: there is no \(x_0 \in (0, 1)\) with \(f(x_0) = 1\). For any value the function actually attains, there is always another value slightly larger that it also attains. Similarly there is no minimum.
The smallest upper bound (here \(1\)) is called the supremum; the largest lower bound (here \(0\)) is the infimum. When the supremum is attained, it equals the maximum; when it is not, the function is still bounded but the maximum simply does not exist. The full theory of suprema and infima belongs to analysis; for our purposes, it is enough to know that "bounded" is the weaker condition and "has a maximum" is the stronger one.
Exercises
Exercise 1
For each function, decide which of the four descriptions fits best.
Exercise 2
Each function below has both a maximum and a minimum on the given domain. Enter the values.
Exercise 3
Decide whether each statement is true or false.
Exercise 4
For each function, the image is given. Decide on the boundedness.
Exercise 5
Decide whether each statement is true or false.
Summary
\(M\) is an upper bound for \(f\) if \(f(x) \leq M\) for every \(x \in D\); \(m\) is a lower bound if \(f(x) \geq m\).
\(f\) is bounded if both an upper and a lower bound exist — equivalently, if \(|f(x)| \leq K\) for some \(K \geq 0\) and every \(x \in D\).
Boundedness of \(f\) is exactly a property of the image: \(f\) is bounded iff \(\mathrm{Im}(f)\) is contained in a bounded interval.
The maximum (when it exists) is an upper bound that is actually attained. Similarly for the minimum. A bounded function need not have a maximum or a minimum.
Reference cases: \(\sqrt{1 - x^2}\) on \([-1, 1]\) — bounded; \(x^2\) — bounded below only; \(x\) — unbounded.