\chapter{The Fundamental Theorem}

The so-called \index{``fundamental theorem of calculus''} ``fundamental theorem of calculus'' says that taking the
derivative and taking the integral are inverse processes.  More precisely,
suppose you define a function using a definite integral as follows:
\[
        F(u)=\int_a^u f(x)\,dx\,,
\]
where $u$ is the variable and $x$ is only a \index{``dummy
variable''} ``dummy
variable'' (variable of integration).  This $F(u)$ is simply the ``area
function'' we defined before (except that we called it $A(u)$ rather than
$F(u)$ in the last section).  In the last section we showed that the
derivative of this area function is $f(u)$.  Thus, taking the derivative of
$F$ returns us to the original function $f$ that we integrated to get $F$.
In words, the fundamental theorem says that {\it if a function is defined
by taking the definite integral from a fixed lower limit of integration up
to a variable upper limit of integration, then its derivative is obtained
by simply dropping the integral sign and taking the integrand with the
dummy variable replaced by the variable in the upper limit of integration}.
In symbols,
\[
\frac{d}{ du}F(u)=\frac{d}{ du}\int_a^uf(x)dx=f(u).
\]
%%%% To update! This is all very loose again. Continuity needs to come in!
% Example 1
\begin{example}
Find $d/du$ of the function $F(u)$ defined as 
\[
\text{(a)}\int_0^u x^2\,dx; 
\text{ (b)}\int_1^ux^2\,dx; 
\text{ (c)}\int_0^u\sqrt{1+\tan x}\,dx. 
\]
In parts (a)--(b), check your answer by finding a formula for $F(u)$ and
computing the derivative of this formula.

\smallskip

(a) By the fundamental theorem, $\frac{d}{ du}\int_0^ux^2dx=u^2$.  Let us
check this by finding $F(u)=\int_0^ux^2dx=\frac{1}{ 3}x^3\bigm|_0^u =\frac{1}{
3}u^3$.  Since $\frac{d}{ du}\left(\frac{1}{ 3}u^3\right)=u^2$, the answer
checks.

\smallskip

(b) By the fundamental theorem, $\frac{d}{ du}\int_1^ux^2dx=u^2$, the same
answer as in part (a).  But our function $F(u)$ is not quite the same.
Namely, 
\[
F(u)=\int_1^u x^2 \, dx= \left.\frac{1}{ 3}x^3\,\right|_1^u
=\frac{1}{ 3}u^2-\frac{1}{3}\,.
\]
Of course, this $F(u)$ still has derivative $u^2$.  This example
illustrates the fact that the derivative of a function of the form
$F(u)=\int_a^uf(x)dx$ does not depend on what constant value we choose for
the lower limit of integration $a$.

\smallskip

(c) By the fundamental theorem, $\frac{d}{ du}\int_0^u\sqrt{1+\tan x}\,dx=
\sqrt{1+\tan u}$.  Here we cannot find a formula for $F(u)$, since
we do not know how to find the anti-derivative of a complicated function
like $\sqrt{1+\tan x}$.  But thanks to the fundamental theorem, if all
we want is the {\it derivative} of $F(u)$ (and not $F(u)$ itself), we
never have to worry about anti-derivatives.  The derivative of $F(u)$
can be determined right away without any work.

\end{example}


\section[Chain rule]{The Fundamental Theorem together with the Chain Rule}

Suppose that $u$ is a function of some other variable, like time, and we
want to find $\frac{d}{ dt}F(u(t))=\frac{d}{ dt}\int_a^{u(t)}f(x)dx$.  This can
be done using the chain rule:
\[
\frac{dF}{ dt}=\frac{dF}{ du}\cdot\frac{du}{ dt}=f(u(t))u'(t).
\]


% Example 2
\begin{example}

Suppose that in Example 1(c) we have $u=t^2$, and we want to find the time
derivative of the integral.  Then
\[
\frac{d}{ dt}\int_0^{t^2}\sqrt{1+\tan x}\,dx=
  \left(\frac{d}{ du}\int_0^u\sqrt{1+\tan x}\,dx\right)\frac{du}{ dt}=
  \sqrt{1+\tan u}\>2t=2t\sqrt{1+\tan(t^2)}.
\]

\smallskip

If the function $F(u(t))$ is defined by an integral in which $u(t)$ occurs
in the {\it lower} \index{limit of integration} limit of integration, then simply reverse the upper and
lower limits, and put in a minus sign, i.e.,
$\int_u^af(x)dx=-\int_a^uf(x)dx$ (see property (3) of definite integrals).
What if a function appears in {\it both} limits of integration, i.e., what
if you want to take $d/dt$ of $\int_{u(t)}^{v(t)}f(x)dx$, where $u$ and $v$
are each functions of $t$?  Then choose a constant $c$ and use properties
(2) and (3) of definite integrals with $a$ replaced by $u$ and $b$ replaced
by $v$:
\[
    \int_u^v f(x) \,dx=\int_c^v f(x) \, dx+\int_u^c f(x) \,dx
                  =\int_c^v f(x) \, dx-\int_c^u f(x) \,dx \,.
\]
We already know how to take the derivative of each of the two terms on the
right.  Thus,
\[
\frac{d}{ dt}\int_{u(t)}^{v(t)}f(x)dx=f(v(t))\frac{dv}{ dt}-f(u(t))\frac{du}{
dt}.
\]

\end{example}

\medskip

% Example 3
\begin{example}
Suppose that the curve $\sqrt{1+\sin x}$ forms the top of a shape that is
bounded below by the $x$ axis and on the left and right by vertical lines
whose position changes with time. Suppose that the vertical line on the
left is moving 


\begin{rightindent}{2.25in}
\noindent
steadily to the right at speed 0.1, starting at $-1$ at time $t=0$.
Meanwhile, the vertical line on the right is oscillating between 1 and 3
according to the formula $2+\sin(0.25\pi(t-6))$.  Find a formula in terms
of $t$ for the rate of change of the area of the shape between the two
vertical lines.

\medskip

We have 
\end{rightindent}
\hfill
%--- figure SA (Fundamental Theorem)--------------------
%
\begin{psfigure}{2.5in}{1.75in}{figSA.ps}
\puttext{-47.5, -25.}{\Small$u(t)$}
\puttext{50., -25.}{\Small$v(t)$}
\puttext{10, 37.}{\Small$y = \sqrt{1 + \sin x}$}
\end{psfigure}
%------------------------------


\begin{align*}
\frac{d}{ dt}&\int_{-1+0.1t}^{2+\sin(0.25\pi(t-6))}\sqrt{1+\sin x}\,
dx\\
&=\sqrt{1+\sin(2+\sin(0.25\pi(t-6)))}\left(\frac{d}{ dt}
(2+ \sin(0.25\pi(t-6))\right)\\
&\quad\quad-\sqrt{1+\sin(-1+0.1t)}\left(\frac{d}{ dt}(-1+0.1t)\right)\\
&=
0.25\pi\cos(0.25\pi(t-6))\sqrt{1+\sin(2+\sin(0.25\pi(t-6)))}\\
&\quad\quad-0.1\sqrt{1+\sin(-1+0.1t)}.
\end{align*}

\end{example}



