Skip to main content
Logo image

Section 5.3 Fundamental theorem of calculus

Note: 1.5 lectures
In this section we discuss and prove the fundamental theorem of calculus. The entirety of integral calculus is built upon this theorem, ergo the name. The theorem relates the seemingly unrelated concepts of integral and derivative. It tells us how to compute the antiderivative of a function using the integral and vice versa.

Subsection 5.3.1 First form of the theorem

It is not hard to generalize the theorem to allow a finite number of points in \([a,b]\) where \(F\) is not differentiable, as long as it is continuous. This generalization is left as an exercise.

Proof.

Let \(P = \{ x_0, x_1, \ldots, x_n \}\) be a partition of \([a,b]\text{.}\) For each interval \([x_{i-1},x_i]\text{,}\) use the mean value theorem to find a \(c_i \in (x_{i-1},x_i)\) such that
\begin{equation*} f(c_i) \Delta x_i = F'(c_i) (x_i - x_{i-1}) = F(x_i) - F(x_{i-1}) . \end{equation*}
See Figure 5.5, and notice that the area of the \(i\)th rectangle is \(F(x_{i+1})-F(x_{i-2})\) for all three rectangles. The idea is that by taking smaller and smaller subintervals we prove that this area is the integral of \(f\text{.}\)

Figure 5.5. Mean value theorem on subintervals of a partition approximating the area under the curve.

Using the notation from the definition of the integral, \(m_i \leq f(c_i) \leq M_i\text{,}\) and multiplying by \(\Delta x_i\) gets
\begin{equation*} m_i \Delta x_i \leq F(x_i) - F(x_{i-1}) \leq M_i \Delta x_i . \end{equation*}
We sum over \(i = 1,2, \ldots, n\) to get
\begin{equation*} \sum_{i=1}^n m_i \Delta x_i \leq \sum_{i=1}^n \bigl(F(x_i) - F(x_{i-1}) \bigr) \leq \sum_{i=1}^n M_i \Delta x_i . \end{equation*}
In the middle sum, all the terms except the first and last cancel and we end up with \(F(x_n)-F(x_0) = F(b)-F(a)\text{.}\) The sums on the left and on the right are the lower and the upper sum respectively. So
\begin{equation*} L(P,f) \leq F(b)-F(a) \leq U(P,f) . \end{equation*}
We take the supremum of \(L(P,f)\) over all partitions \(P\) and the left inequality yields
\begin{equation*} \underline{\int_a^b} f \leq F(b)-F(a) . \end{equation*}
Similarly, taking the infimum of \(U(P,f)\) over all partitions \(P\) yields
\begin{equation*} F(b)-F(a) \leq \overline{\int_a^b} f . \end{equation*}
As \(f\) is Riemann integrable, we have
\begin{equation*} \int_a^b f = \underline{\int_a^b} f \leq F(b)-F(a) \leq \overline{\int_a^b} f = \int_a^b f . \end{equation*}
The inequalities must be equalities and we are done.
The theorem is used to compute integrals. Suppose we know that the function \(f(x)\) is a derivative of some other function \(F(x)\text{,}\) then we can find an explicit expression for \(\int_a^b f\text{.}\)

Example 5.3.2.

To compute
\begin{equation*} \int_0^1 x^2 \,dx , \end{equation*}
we notice \(x^2\) is the derivative of \(\frac{x^3}{3}\text{.}\) The fundamental theorem says
\begin{equation*} \int_0^1 x^2 \,dx = \frac{1^3}{3} - \frac{0^3}{3} = \frac{1}{3}. \end{equation*}

Subsection 5.3.2 Second form of the theorem

The second form of the fundamental theorem gives us a way to solve the differential equation \(F'(x) = f(x)\text{,}\) where \(f\) is a known function and we are trying to find an \(F\) that satisfies the equation.

Proof.

As \(f\) is bounded, there is an \(M > 0\) such that \(\abs{f(x)} \leq M\) for all \(x \in [a,b]\text{.}\) Suppose \(x,y \in [a,b]\) with \(x > y\text{.}\) Then
\begin{equation*} \abs{F(x)-F(y)} = \abs{\int_a^x f - \int_a^y f} = \abs{\int_y^x f} \leq M\abs{x-y} . \end{equation*}
By symmetry, the same also holds if \(x < y\text{.}\) So \(F\) is Lipschitz continuous and hence continuous.
Now suppose \(f\) is continuous at \(c\text{.}\) Let \(\epsilon > 0\) be given. Let \(\delta > 0\) be such that for \(x \in [a,b]\text{,}\) \(\abs{x-c} < \delta\) implies \(\abs{f(x)-f(c)} < \epsilon\text{.}\) In particular, for such \(x\text{,}\) we have
\begin{equation*} f(c)-\epsilon < f(x) < f(c) + \epsilon. \end{equation*}
Thus if \(x > c\text{,}\) then
\begin{equation*} \bigl(f(c)-\epsilon\bigr) (x-c) \leq \int_c^x f \leq \bigl(f(c) + \epsilon\bigr)(x-c). \end{equation*}
When \(c > x\text{,}\) then the inequalities are reversed. Therefore, assuming \(x \not= c\text{,}\) we get
\begin{equation*} f(c)-\epsilon \leq \frac{\int_c^{x} f}{x-c} \leq f(c)+\epsilon . \end{equation*}
As
\begin{equation*} \frac{F(x)-F(c)}{x-c} = \frac{\int_a^{x} f - \int_a^{c} f}{x-c} = \frac{\int_c^{x} f}{x-c} , \end{equation*}
we have
\begin{equation*} \abs{\frac{F(x)-F(c)}{x-c} - f(c)} \leq \epsilon . \end{equation*}
The result follows. It is left to the reader to see why is it OK that we just have a non-strict inequality.
Of course, if \(f\) is continuous on \([a,b]\text{,}\) then it is automatically Riemann integrable, \(F\) is differentiable on all of \([a,b]\) and \(F'(x) = f(x)\) for all \(x \in [a,b]\text{.}\)

Remark 5.3.4.

The second form of the fundamental theorem of calculus still holds if we let \(d \in [a,b]\) and define
\begin{equation*} F(x) \coloneqq \int_d^x f . \end{equation*}
That is, we can use any point of \([a,b]\) as our base point. The proof is left as an exercise.
Let us look at what a simple discontinuity can do. Take \(f(x) \coloneqq -1\) if \(x < 0\text{,}\) and \(f(x) \coloneqq 1\) if \(x \geq 0\text{.}\) Let \(F(x) \coloneqq \int_0^x f\text{.}\) It is not difficult to see that \(F(x) = \abs{x}\text{.}\) Notice that \(f\) is discontinuous at \(0\) and \(F\) is not differentiable at \(0\text{.}\) However, the converse in the theorem does not hold. Let \(g(x) \coloneqq 0\) if \(x \not= 0\text{,}\) and \(g(0) \coloneqq 1\text{.}\) Letting \(G(x) \coloneqq \int_0^x g\text{,}\) we find that \(G(x) = 0\) for all \(x\text{.}\) So \(g\) is discontinuous at \(0\text{,}\) but \(G'(0)\) exists and is equal to 0.
A common misunderstanding of the integral for calculus students is to think of integrals whose solution cannot be given in closed-form as somehow deficient. This is not the case. Most integrals we write down are not computable in closed-form. Even some integrals that we consider in closed-form are not really such. We define the natural logarithm as the antiderivative of \(\nicefrac{1}{x}\) such that \(\ln 1 = 0\text{:}\)
\begin{equation*} \ln x \coloneqq \int_1^x \frac{1}{s}\,ds . \end{equation*}
How does a computer find the value of \(\ln x\text{?}\) One way to do it is to numerically approximate this integral. Morally, we did not really “simplify” \(\int_1^x \frac{1}{s}\,ds\) by writing down \(\ln x\text{.}\) We simply gave the integral a name. If we require numerical answers, it is possible we end up doing the calculation by approximating an integral anyway. In the next section, we even define the exponential using the logarithm, which we define in terms of the integral.
Another common function defined by an integral that cannot be evaluated symbolically in terms of elementary functions is the \(\operatorname{erf}\) function, defined as
\begin{equation*} \operatorname{erf}(x) \coloneqq \frac{2}{\sqrt{\pi}} \int_0^x e^{-s^2} \,ds . \end{equation*}
This function comes up often in applied mathematics. It is simply the antiderivative of \(\left(\nicefrac{2}{\sqrt{\pi}}\right) e^{-x^2}\) that is zero at zero. The second form of the fundamental theorem tells us that we can write the function as an integral. If we wish to compute any particular value, we numerically approximate the integral.

Subsection 5.3.3 Change of variables

A theorem often used in calculus to solve integrals is the change of variables theorem, you may have called it \(u\)-substitution. Let us prove it now. Recall a function is continuously differentiable if it is differentiable and the derivative is continuous.

Proof.

As \(g\text{,}\) \(g'\text{,}\) and \(f\) are continuous, \(f\bigl(g(x)\bigr)\,g'(x)\) is a continuous function of \([a,b]\text{,}\) therefore it is Riemann integrable. Similarly, \(f\) is integrable on every subinterval of \([c,d]\text{.}\)
Define \(F \colon [c,d] \to \R\) by
\begin{equation*} F(y) \coloneqq \int_{g(a)}^{y} f(s)\,ds . \end{equation*}
By the second form of the fundamental theorem of calculus (see Remark 5.3.4 and Exercise 5.3.4), \(F\) is a differentiable function and \(F'(y) = f(y)\text{.}\) Apply the chain rule,
\begin{equation*} \bigl( F \circ g \bigr)' (x) = F'\bigl(g(x)\bigr) g'(x) = f\bigl(g(x)\bigr) g'(x) . \end{equation*}
Note that \(F\bigl(g(a)\bigr) = 0\) and use the first form of the fundamental theorem to obtain
\begin{multline*} \qquad \int_{g(a)}^{g(b)} f(s)\,ds = F\bigl(g(b)\bigr) = F\bigl(g(b)\bigr)-F\bigl(g(a)\bigr) \\ = \int_a^b \bigl( F \circ g \bigr)' (x) \,dx = \int_a^b f\bigl(g(x)\bigr) g'(x) \,dx . \qquad \qedhere \end{multline*}
The change of variables theorem is often used to solve integrals by changing them to integrals that we know or that we can solve using the fundamental theorem of calculus.

Example 5.3.6.

The derivative of \(\sin(x)\) is \(\cos(x)\text{.}\) Using \(g(x) \coloneqq x^2\text{,}\) we solve
\begin{equation*} \int_0^{\sqrt{\pi}} x \cos(x^2) \, dx = \int_0^\pi \frac{\cos(s)}{2} \, ds = \frac{1}{2} \int_0^\pi \cos(s) \, ds = \frac{ \sin(\pi) - \sin(0) }{2} = 0 . \end{equation*}
However, beware that we must satisfy the hypotheses of the theorem. The following example demonstrates why we should not just move symbols around mindlessly. We must be careful that those symbols really make sense.

Example 5.3.7.

Consider
\begin{equation*} \int_{-1}^{1} \frac{\ln \abs{x}}{x} \,dx . \end{equation*}
It may be tempting to take \(g(x) \coloneqq \ln \abs{x}\text{.}\) Compute \(g'(x) = \nicefrac{1}{x}\) and try to write
\begin{equation*} \int_{g(-1)}^{g(1)} s \,ds = \int_{0}^{0} s \,ds = 0. \end{equation*}
This “solution” is incorrect, and it does not say that we can solve the given integral. First problem is that \(\frac{\ln \abs{x}}{x}\) is not continuous on \([-1,1]\text{.}\) It is not defined at 0, and cannot be made continuous by defining a value at 0. Second, \(\frac{\ln \abs{x}}{x}\) is not even Riemann integrable on \([-1,1]\) (it is unbounded). The integral we wrote down simply does not make sense. Finally, \(g\) is not continuous on \([-1,1]\text{,}\) let alone continuously differentiable.

Exercises 5.3.4 Exercises

5.3.1.

Compute \(\displaystyle \frac{d}{dx} \biggl( \int_{-x}^x e^{s^2}\,ds \biggr)\text{.}\)

5.3.2.

Compute \(\displaystyle \frac{d}{dx} \biggl( \int_{0}^{x^2} \sin(s^2)\,ds \biggr)\text{.}\)

5.3.3.

Suppose \(F \colon [a,b] \to \R\) is continuous and differentiable on \([a,b] \setminus S\text{,}\) where \(S\) is a finite set. Suppose there exists an \(f \in \sR\bigl([a,b]\bigr)\) such that \(f(x) = F'(x)\) for \(x \in [a,b] \setminus S\text{.}\) Show that \(\int_a^b f = F(b)-F(a)\text{.}\)

5.3.4.

Let \(f \colon [a,b] \to \R\) be a continuous function. Let \(c \in [a,b]\) be arbitrary. Define
\begin{equation*} F(x) \coloneqq \int_c^x f . \end{equation*}
Prove that \(F\) is differentiable and that \(F'(x) = f(x)\) for all \(x \in [a,b]\text{.}\)

5.3.5.

Prove integration by parts. That is, suppose \(F\) and \(G\) are continuously differentiable functions on \([a,b]\text{.}\) Then prove
\begin{equation*} \int_a^b F(x)G'(x)\,dx = F(b)G(b)-F(a)G(a) - \int_a^b F'(x)G(x)\,dx . \end{equation*}

5.3.6.

Suppose \(F\) and \(G\) are continuously
 1 
Compare this hypothesis to Exercise 4.2.8.
differentiable functions defined on \([a,b]\) such that \(F'(x) = G'(x)\) for all \(x \in [a,b]\text{.}\) Using the fundamental theorem of calculus, show that \(F\) and \(G\) differ by a constant. That is, show that there exists a \(C \in \R\) such that \(F(x)-G(x) = C\text{.}\)
The next exercise shows how we can use the integral to “smooth out” a non-differentiable function.

5.3.7.

Let \(f \colon [a,b] \to \R\) be a continuous function. Let \(\epsilon > 0\) be a constant so that \(a+\epsilon < b-\epsilon\text{.}\) For \(x \in [a+\epsilon,b-\epsilon]\text{,}\) define
\begin{equation*} g(x) \coloneqq \frac{1}{2\epsilon} \int_{x-\epsilon}^{x+\epsilon} f . \end{equation*}
  1. Show that \(g\) is differentiable and find the derivative.
  2. Let \(f\) be differentiable and fix \(x \in (a,b)\) (let \(\epsilon\) be small enough). What happens to \(g'(x)\) as \(\epsilon\) gets smaller?
  3. Find \(g\) for \(f(x) \coloneqq \abs{x}\text{,}\) \(\epsilon = 1\) (you can assume \([a,b]\) is large enough).

5.3.8.

Suppose \(f \colon [a,b] \to \R\) is continuous and \(\int_a^x f = \int_x^b f\) for all \(x \in [a,b]\text{.}\) Show that \(f(x) = 0\) for all \(x \in [a,b]\text{.}\)

5.3.9.

Suppose \(f \colon [a,b] \to \R\) is continuous and \(\int_a^x f = 0\) for all rational \(x\) in \([a,b]\text{.}\) Show that \(f(x) = 0\) for all \(x \in [a,b]\text{.}\)

5.3.10.

A function \(f\) is an odd function if \(f(x) = -f(-x)\text{,}\) and \(f\) is an even function if \(f(x) = f(-x)\text{.}\) Let \(a > 0\text{.}\) Assume \(f\) is continuous. Prove:
  1. If \(f\) is odd, then \(\int_{-a}^a f = 0\text{.}\)
  2. If \(f\) is even, then \(\int_{-a}^a f = 2 \int_0^a f\text{.}\)

5.3.11.

  1. Show that \(f(x) \coloneqq \sin(\nicefrac{1}{x})\) is integrable on every interval (you can define \(f(0)\) to be anything).
  2. Compute \(\int_{-1}^1 \sin(\nicefrac{1}{x})\,dx\) (mind the discontinuity).

5.3.12.

(uses Section 3.6)  
  1. Suppose \(f \colon [a,b] \to \R\) is increasing, by Proposition 5.2.11, \(f\) is Riemann integrable. Suppose \(f\) has a discontinuity at \(c \in (a,b)\text{,}\) show that \(F(x) \coloneqq \int_a^x f\) is not differentiable at \(c\text{.}\)
  2. In Exercise 3.6.11, you constructed an increasing function \(f \colon [0,1] \to \R\) that is discontinuous at every \(x \in [0,1] \cap \Q\text{.}\) Use this \(f\) to construct a function \(F(x)\) that is continuous on \([0,1]\text{,}\) but not differentiable at every \(x \in [0,1] \cap \Q\text{.}\)
5.3.13.
For any \(\ell \in \N\text{,}\) show that the following limit exists and find what it is:
\begin{equation*} \lim_{n\to\infty} \sum_{k=1}^n \frac{k^\ell}{n^{\ell+1}} \end{equation*}
For a higher quality printout use the PDF versions: https://www.jirka.org/ra/realanal.pdf or https://www.jirka.org/ra/realanal2.pdf