%% LyX 2.0.0 created this file.  For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[english]{beamer}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\setcounter{secnumdepth}{3}
\setcounter{tocdepth}{3}
\usepackage{amsmath}
\usepackage{graphicx}

\makeatletter
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Textclass specific LaTeX commands.
 % this default might be overridden by plain title style
 \newcommand\makebeamertitle{\frame{\maketitle}}%
 \AtBeginDocument{
   \let\origtableofcontents=\tableofcontents
   \def\tableofcontents{\@ifnextchar[{\origtableofcontents}{\gobbletableofcontents}}
   \def\gobbletableofcontents#1{\origtableofcontents}
 }
 \long\def\lyxframe#1{\@lyxframe#1\@lyxframestop}%
 \def\@lyxframe{\@ifnextchar<{\@@lyxframe}{\@@lyxframe<*>}}%
 \def\@@lyxframe<#1>{\@ifnextchar[{\@@@lyxframe<#1>}{\@@@lyxframe<#1>[]}}
 \def\@@@lyxframe<#1>[{\@ifnextchar<{\@@@@@lyxframe<#1>[}{\@@@@lyxframe<#1>[<*>][}}
 \def\@@@@@lyxframe<#1>[#2]{\@ifnextchar[{\@@@@lyxframe<#1>[#2]}{\@@@@lyxframe<#1>[#2][]}}
 \long\def\@@@@lyxframe<#1>[#2][#3]#4\@lyxframestop#5\lyxframeend{%
   \frame<#1>[#2][#3]{\frametitle{#4}#5}}
 \def\lyxframeend{} % In case there is a superfluous frame end

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.

\usepackage{appearance}\newcommand{\reals}{\mathbb R}

\makeatother

\usepackage{babel}
\begin{document}
%MODULE 1: Epsilon-Delta limits


%USER DEFINED COMMANDS
\global\long\def\ds{{\displaystyle }}
 \global\long\def\nsp{\hspace{1em}*{9pt}}
 \global\long\def\lns{\rule{0pt}{11pt} }
 \global\long\def\xp{\mbox{\Large\sl e} }


%INPUT THE INSTRUCTIONS PAGE 


%BUILD  TITLE PAGE 



\title{A precise notion of limits}


\subtitle{We move from the \emph{intuitive} notion of a limit (which until
now has been numerical and/or geometric) to the \emph{precise} notion
of a limit (which is logical and algebraic). }

\makebeamertitle

\lyxframeend{}\lyxframe{{A Sample problem}}

\noindent Let 
\begin{itemize}
\item ${\displaystyle {\ec f\left(x\right)=\frac{x^{2}-x}{x}}}$, and 
\item ${\displaystyle {\ec w\left(x\right)=\sin\left(\frac{1}{x}\right)}}$. 
\end{itemize}
Our goal is to find a \emph{precise} way to explain our intuitions
that 
\[
{\ec\lim_{x\rightarrow0}f(x)=-1}\mathrm{\ but\ }{\ec\lim_{x\rightarrow0}w(x)}\mathrm{\ does\ not\ exist.}
\]



\lyxframeend{}\lyxframe{SAGE worksheets}

\noindent In this lab you will need the SAGElet {}``Limits: $\epsilon$-$\delta$''.
Open it in SAGE.


\lyxframeend{}\lyxframe{{Setup Limits: $\epsilon$-$\delta$}}

\noindent First we will set up the applet. When you first start it,
you should see something like this:

\begin{center}
\includegraphics[scale=0.2]{figures/worksheet_startup_small} 
\par\end{center}


\lyxframeend{}\lyxframe{Setup Limits: $\epsilon$-$\delta$}

\noindent We will set up the applet to work with $\ec f(x)$ first.
Make the following assignments: 
\begin{itemize}
\item $\ec f\rightarrow(x^{2}-x)/x$ 
\item $\ec a\rightarrow0$ 
\item $\ec L\rightarrow-1$ 
\item $\ec\delta\rightarrow0.1$ 
\item $\ec\epsilon\rightarrow0.1$ 
\item $\ec x_{\mathrm{m}in}\rightarrow-1$ 
\item $\ec x_{\mathrm{m}ax}\rightarrow1$ 
\end{itemize}

\lyxframeend{}\lyxframe{{The precise definition of a limit}}
\begin{overlayarea}
{\textwidth}{6in}

\noindent We want to express the idea that as $\ec x$ draws near
to $\ec a$, the $y$ values $\ec f(x)$ draw so near to $\ec L$
that you cannot find any \emph{meaningful} distance between them.
\begin{onlyenv}%{}
<1>

\noindent Stated precisely,
\begin{definition}%{}
$\ec\lim_{x\rightarrow a}f(x)=L$ if 
\begin{itemize}
\item for any measurable distance $\ec\epsilon$, 
\item we can find a neighborhood around $\ec x=a$ 
\item such that for any $x$ value in that neighborhood (except maybe $\ec x=a$), 
\item the distance between the $y$ value of $\ec f$ and $\ec L$ is less
than $\ec\epsilon$. 
\end{itemize}
\end{definition}%{}
\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<2>

\noindent Written more precisely,
\begin{definition}%{}
$\ec\lim_{x\rightarrow a}f(x)=L$ if 
\begin{itemize}
\item for all $\ec\epsilon>0$,\\
({}``any measurable distance $\ec\epsilon$'') 
\item there exists $\ec\delta>0$\\
({}``a neighborhood around $\ec x=a$'') 
\item such that for all $\ec x\in(a-\delta,a+\delta)$ (except maybe $\ec x=a$),\\
({}``any $x$ value in that neighborhood'') 
\item $\ec|f(x)-L|<\epsilon$.\\
({}``the distance between the $y$ values is less than $\ec\epsilon$'') 
\end{itemize}
\end{definition}%{}

Switch back and forth between these two slides to see how the words
translate into symbols.

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<3>

\noindent Rewritten slightly, we have
\begin{definition}%{}
[(Precise definition of the limit)]$\ec\lim_{x\rightarrow a}f(x)=L$
if 
\begin{itemize}
\item for all $\ec\epsilon>0$, 
\item there exists $\ec\delta>0$ 
\item such that for all $\ec x$ satisfying $\ec|x-a|<\delta$ (except maybe
$\ec x=a$), 
\item $\ec|f(x)-L|<\epsilon$. 
\end{itemize}
\end{definition}%{}
\end{onlyenv}%{}
\end{overlayarea}

\lyxframeend{}\lyxframe{{Example with $f(x)$}}
\begin{overlayarea}
{\textwidth}{6in}

\noindent We illustrate this precise definition of a limit using $f(x)$.
\begin{onlyenv}%{}
<1>

\begin{center}
\includegraphics[scale=0.3]{figures/good_outermost} 
\par\end{center}


Currently, SAGE should show the output above. Right now we set the
precision to $\ec\epsilon=0.1$. The goal is that $\ec|f(x)-L|<\epsilon$,
or that \emph{the distance between the $y$ values of $\ec f$ and
$L$ is smaller than $\ec\epsilon$.}


Geometrically, you see that the graph of $f(x)$ does not stray into
the pink regions of the plane. How does this reflect the definition?

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<2>

\begin{center}
\includegraphics[scale=0.3]{figures/good_outermost} 
\par\end{center}


{\dims Geometrically, you see that the graph of $f(x)$ does not
stray into the pink regions of the plane. How does this reflect the
definition?}


The distance between the $y$ values of points in the pink regions
and $\ec L$ is larger than $\ec\epsilon$. This would violate the
desired outcome of a limit: that $y$ values grow very close to $\ec L$.


What about smaller values of $\ec\epsilon$, say $\ec\epsilon=0.01$?
Change the value of $\ec\epsilon$ in the SAGElet.

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<3>

\begin{center}
\includegraphics[scale=0.3]{figures/zoom_bad} 
\par\end{center}


{\dims Geometrically, you see that the graph of $f(x)$ does not
stray into the pink regions of the plane. How does this reflect the
definition?}


When we make $\ec\epsilon$ smaller, we have a problem: the blue curve
of $\ec f$ now passes in the pink regions of the plane. For these
points, $\ec|f(x)-L|\mathbf{>}\epsilon$.

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<4>

\begin{center}
\includegraphics[scale=0.3]{figures/zoom_bad} 
\par\end{center}


{\dims Geometrically, you see that the graph of $f(x)$ does not
stray into the pink regions of the plane. How does this reflect the
definition?}


When we make $\ec\epsilon$ smaller, we have a problem: the blue curve
of $\ec f$ now passes in the pink regions of the plane. For these
points, $\ec|f(x)-L|{\mathbf{>}}\epsilon$.


However, the phrasing of the definition is that {}``there exists
$\ec\delta$''. Can we find a value of $\ec\delta$ so the curve
no longer enters the pink region? Zoom in on the graph. Change the
max and min $x$ values so that we zoom into $\ec[-0.2,0.2]$.

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<5>

\begin{center}
\includegraphics[scale=0.3]{figures/zoom_bad2} 
\par\end{center}


{\dims Geometrically, you see that the graph of $f(x)$ does not
stray into the pink regions of the plane. How does this reflect the
definition?}


It looks like we could make it work by choosing a smaller value of
$\ec\delta$. Let's try $\ec\delta=0.01$.

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<6>

\begin{center}
\includegraphics[scale=0.3]{figures/zoom_good} 
\par\end{center}

\end{onlyenv}%{}

{\dims Geometrically, you see that the graph of $f(x)$ does not
stray into the pink regions of the plane. How does this reflect the
definition?}


In this case it worked out. Notice that we have $\ec\delta=\ec\epsilon$.

\end{overlayarea}

\lyxframeend{}\lyxframe{{Proving it}}
\begin{overlayarea}
{\textwidth}{6in}

\noindent We can show this rigorously by falling back on the definition.
We remind you that the definition is 
\begin{itemize}
\item For all $\ec\epsilon>0$, 
\item there exists $\ec\delta>0$ 
\item such that for all $\ec x$ satisfying $\ec|x-a|<\delta$ (except maybe
$\ec x=a$), 
\item $\ec|f(x)-L|<\epsilon$. \end{itemize}
\begin{onlyenv}%{}
<1>

We want to rewrite
\begin{align*}
\ec|f(x)-L| & {\ec<\epsilon}\phantom{\mathrm{,\ or\ }{\ec\left|x\right|<\epsilon}.}
\end{align*}
 so that it resembles $\ec|x-a|<\mathrm{something}$, or $\ec|x-0|<\mathrm{something}$.
Then we could just pick $\ec\delta=\mathrm{something}$.

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<2>

That is,
\begin{align*}
\dims|f(x)-L| & {\dims<\epsilon}\phantom{\mathrm{,\ or\ }{\ec\left|x\right|<\epsilon}}\\
\ec\left|\frac{x^{2}-x}{x}-(-1)\right| & {\ec<\epsilon}.
\end{align*}
 \begin{explanation}Substituted $f$ and $L$.\end{explanation}

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<3>

That is,
\begin{align*}
\dims|f(x)-L| & {\dims<\epsilon}\phantom{\mathrm{,\ or\ }{\ec\left|x\right|<\epsilon}}\\
\dims\left|\frac{x^{2}-x}{x}-(-1)\right| & {\dims<\epsilon}\\
\ec\left|\frac{x(x-1)}{x}+1\right| & {\ec<\epsilon}.
\end{align*}
 \begin{explanation}Factored the numerator.\end{explanation}

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<4>

That is,
\begin{align*}
\dims|f(x)-L| & {\dims<\epsilon}\\
\dims\left|\frac{x(x-1)}{x}+1\right| & {\dims<\epsilon}\\
\ec\left|(x-1)+1\right| & {\ec<\epsilon}\mathrm{,\ or\ }{\ec\left|x-0\right|<\epsilon}.
\end{align*}
 \begin{explanation}Division by $x$ when $x\neq0$.\end{explanation}

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<5->

What value of $\ec\delta$ should we choose? We want 
\[
{\ec\left|x-0\right|<\delta\quad\Longrightarrow\quad\left|x-0\right|<\epsilon}.
\]
 Choosing $\ec\delta=\epsilon$ makes it easy.

\end{onlyenv}%{}

\pause{}


We saw this in the SAGElet: when $\ec\epsilon=.1$ we chose $\ec\delta=.1$,
and when $\ec\epsilon=.01$ we chose $\ec\delta=.01$.

\end{overlayarea}

\lyxframeend{}\lyxframe{{Smaller $\delta$ works, too!}}

\noindent Of course you could have chosen a $\ec\delta$ that was
even \emph{smaller} than the one required. Try changing $\ec\delta$
to .005 in the SAGE worksheet, and see if the curve passes through
the pink region.


\pause{}

You should see something like this:

\begin{center}
\includegraphics[scale=0.3]{figures/zoom_good_smaller_delta} 
\par\end{center}

So smaller values of delta work just as well.


\lyxframeend{}\lyxframe{{General functions}}
\begin{overlayarea}
{\textwidth}{6in}

\noindent It is not easy to determine a correct value of $\ec\delta$
for every function. Even {}``simple'' functions require care.


\pause{}


Suppose $\ec f(x)=x^{2}$. How can we show that $\ec\lim_{x\rightarrow1}f(x)=1$?


Falling back on the definition, let $\ec\epsilon$ be an arbitrary
distance. We want
\[
{\ec|x-a|=|x-1|<\delta\qquad\Longrightarrow\qquad|f(x)-L|=|x^{2}-1|<\epsilon}.
\]



\pause{}
\begin{onlyenv}%{}
<3>

We'll try again to rewrite the second inequality in the form
\[
{\ec|x-a|=|x-1|<\mathrm{something}}.
\]
 Then we can set $\ec\delta=\mathrm{something}$ and satisfy the definition.

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<4>

The second inequality can be rewritten as
\begin{align*}
\ec-\epsilon & {\ec<x^{2}-1<\epsilon}.
\end{align*}
 \begin{explanation}Property of the absolute-value inequality $<$.\end{explanation}

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<5>

The second inequality can be rewritten as
\begin{align*}
\dims-\epsilon & {\dims<x^{2}-1<\epsilon}\\
\ec1-\epsilon & {\ec<x^{2}<1+\epsilon}.
\end{align*}
 \begin{explanation}Isolated $x^{2}$.\end{explanation}

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<6>

The second inequality can be rewritten as
\begin{align*}
\dims1-\epsilon & {\dims<x^{2}<1+\epsilon}\\
\ec\sqrt{1-\epsilon} & {\ec<x<\sqrt{1+\epsilon}}.
\end{align*}
 \begin{explanation}Took square root of both sides.\\
 In a {}``small enough'' neighborhood of $x=a=1$,\\
 $x$ is positive, so we don't need $\pm\sqrt{}$.\end{explanation}

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<7>

The second inequality can be rewritten as
\begin{align*}
\dims\sqrt{1-\epsilon} & {\dims<x<\sqrt{1+\epsilon}}\\
\ec\sqrt{1-\epsilon}-1 & {\ec<x-1<\sqrt{1+\epsilon}-1}.
\end{align*}
 \begin{explanation}Subtracted $1$ from all sides. Why?\\
 To find a value for $\delta$ we need the form $|x-1|$.\end{explanation}

\end{onlyenv}%{}

\pause{}
\begin{onlyenv}%{}
<8>

 The second inequality can be rewritten as
\begin{align*}
\dims\sqrt{1-\epsilon} & {\dims<x<\sqrt{1+\epsilon}}\\
\ec\sqrt{1-\epsilon}-1 & {\ec<x-1<\sqrt{1+\epsilon}-1}.
\end{align*}


\end{onlyenv}%{}

\noindent Which value gives a \emph{smaller} neighborhood around $\ec x=a=1$?
Some algebra shows that $\ec\sqrt{1+\epsilon}-1$ (we skip that step
here).


\pause{}
\begin{onlyenv}%{}
<9>

The second inequality can be rewritten as
\begin{align*}
\dims\sqrt{1-\epsilon} & {\dims<x<\sqrt{1+\epsilon}}\\
\ec\sqrt{1-\epsilon}-1 & {\ec<x-1<\sqrt{1+\epsilon}-1}.
\end{align*}



\noindent Try this in the SAGE applet with a few values of $\ec\epsilon$,
and verify that $\ec\delta=\sqrt{1+\epsilon}-1$ keeps the blue function
out of the pink regions.

\end{onlyenv}%{}
\end{overlayarea}

\lyxframeend{}\lyxframe{{What about $w(x)$?}}

Now consider $\ec w(x)=\sin(1/x)$. To help see why this has no limit
at $\ec x=0$, make the following changes to the SAGE applet: 
\begin{itemize}
\item $\ec f\rightarrow sin(1/x)$ 
\item $\ec a\rightarrow0$ 
\item $\ec L\rightarrow0$ (we'll start with a guess that the limit is zero) 
\item $\ec\delta\rightarrow0.1$ 
\item $\ec\epsilon\rightarrow0.1$ 
\item $\ec x_{\mathrm{m}in}\rightarrow-1$ 
\item $\ec x_{\mathrm{m}ax}\rightarrow1$ 
\end{itemize}

\lyxframeend{}\lyxframe{\noindent {What about $w(x)$?}}

\noindent Your initial graph should look like this:

\begin{center}
\includegraphics[scale=0.3]{figures/wiggle_bad1} 
\par\end{center}

Notice the intense {}``wiggling'' as $\ec x\rightarrow0$. The blue
curve passes through the pink regions many, many times, so this value
of $\ec\delta$ is too large for $\ec\epsilon=.1$; let's try a smaller
value of $\ec\delta$, say $\ec\delta=.01$. Be sure to zoom in the
$x$ values as well to $\ec[-.05,.05]$.


\lyxframeend{}\lyxframe{What about $w(x)$?}

\noindent Now you should see this (or something similar):

\begin{center}
\includegraphics[scale=0.3]{figures/wiggle_bad2} 
\par\end{center}

The wiggling has not ceased to take us into the pink zone, so $\ec\delta$
is still too large for this value of $\ec\epsilon$. Let's try one
more smaller value of $\ec\delta$.


\lyxframeend{}\lyxframe{What about $w(x)$?}

\noindent Now you should see this (or something similar):

\begin{center}
\includegraphics[scale=0.3]{figures/wiggle_bad3} 
\par\end{center}

No wonder mathematicians call this the \emph{Infinite Wiggle}.


\lyxframeend{}\lyxframe{{What is going on?}}

\noindent No matter how small we made $\ec\delta$, the graph of $\ec w(x)$
only wiggled all the more intensely. We need to convince ourselves
of this.


\pause{}

\begin{center}
\includegraphics[scale=0.3]{figures/wiggle_bad3} 
\par\end{center}

Notice that the curve touches $\ec y=1$ many, many times. What $x$
values give $\ec\sin(x)=1$?


\pause{}

You should know that $\ec x=\frac{\pi}{2},-\frac{\pi}{2},\frac{5\pi}{2},-\frac{5\pi}{2},\ldots$
produce $\ec\sin(x)=1$.


\pause{}

We are dealing with the function $\ec\sin(1/x)$, so look at the reciprocal
of these numbers: $\ec x=\frac{2}{\pi},-\frac{2}{\pi},\frac{2}{5\pi},-\frac{2}{5\pi},\ldots$
produce $\ec\sin(1/x)=1$.


\pause{}

These values approach zero: $\ec\frac{2}{\pi},\frac{2}{5\pi},\frac{2}{9\pi},\ldots$.
The pattern goes on forever, \emph{all} their $y$ values are 1, and
the limit of these numbers is 0.


\lyxframeend{}\lyxframe{What is going on?}

\noindent No matter how small we made $\delta$, the graph of $w(x)$
only wiggled all the more intensely. We need to convince ourselves
of this.

\begin{center}
\includegraphics[scale=0.3]{figures/wiggle_bad3} 
\par\end{center}

The upshot? 
\begin{itemize}
\item Regardless of the value of $\ec\delta$ 
\item we can find $\ec x$ 
\item such that $\ec|x-0|<\delta$ 
\item but $\ec|f(x)-0|=1>0.1=\epsilon!$ 
\end{itemize}

\lyxframeend{}\lyxframe{{Thus...}}

\noindent We conclude that 
\[
\ec\lim_{x\rightarrow0}\sin\left(\frac{1}{x}\right)
\]
 \textbf{does not exist}.


\lyxframeend{}\lyxframe{{Conclusion}}
\begin{itemize}
\item You have seen {\hilite the precise definition of a limit}:\setlength{\shadeboxwidth}{4in}

\begin{definitions}%{}
$\ec\lim_{x\rightarrow a}f(x)=L$ if 
\begin{itemize}
\item for all $\ec\epsilon>0$, 
\item there exists $\ec\delta>0$ 
\item such that for all $\ec x$ satisfying $\ec|x-a|<\delta$ (except maybe
$\ec x=a$) 
\item $\ec|f(x)-L|<\epsilon$.
\end{itemize}
\end{definitions}%{}
\item You have had an introduction to finding $\ec\delta$ algebraically.
It takes a lot of practice to grow accustomed to it. 
\item Why does this give us the precise definition of the limit? 

\begin{itemize}
\item No matter how close ($\ec\epsilon$) we check near $\ec y=L$, 
\item we can find a neighborhood ($\ec\delta$) of $\ec x=a$ 
\item such that the distance between $\ec L$ and $\ec f(x)$ is less than
$\ec\epsilon$ ($\ec|f(x)-L|<\epsilon$). 
\item Since $\ec\epsilon$ is \emph{any} measurable distance, the limit
of $\ec f(x)$ is $\ec L$. 
\end{itemize}
\item You can use the SAGElet {}``Limits: $\epsilon$-$\delta$'' to illustrate
this, both when the limit exists and when it does not. 
\end{itemize}

\lyxframeend{}
\end{document}
