% LaTex2e
\documentclass[12pt]{article}
\usepackage{amssymb,latexsym}

\def\easy{6}
\def\medium{8}
\def\hard{10}


\oddsidemargin 5pt \evensidemargin 5pt \marginparwidth 68pt
\marginparsep 10pt \topmargin 10pt \headheight 10pt
\headsep 15pt \footskip 35pt
\textheight = 625pt  \textwidth 440pt \columnsep 10pt \columnseprule 5pt

\pagestyle{myheadings}
\def\la{\langle}  \def\ra{\rangle}
\def\header{{\hfill Exam 2 \hfill A. Miller \hfill Spring  99
                                       \hfill Math 272\hfill}}
\markboth\header\header
\newcount\probno
\newcount\total
\newwrite\examTBLFile

\probno=0
\def\prob#1{\advance\probno by 1  \vfill\newpage  % \par
    \noindent\the\probno . (#1 pts)\advance\total by #1
    \immediate\write\examTBLFile{\the\probno
       \string& #1 \string&
       \string\qquad \string\\ \string\hline}}

\def\probx#1{\advance\probno by 1  \vfill  % \par
    \noindent\the\probno . (#1 pts)\advance\total by #1
    \immediate\write\examTBLFile{\the\probno
       \string& #1 \string&
       \string\qquad \string\\ \string\hline}}

\def\finishtbl{
    \immediate\write\examTBLFile{Total \string& \the\total
    \string& \qquad \string\\ \string\hline}
     }

\newwrite\ans
\immediate\openout\ans=answers
\outer\def\answer{\par\medbreak
  \immediate\write\ans{}
  \immediate\write\ans{\string\bigskip \the\probno . }
  \copytoblankline}
\outer\def\putanswer{\par\medbreak
  \immediate\write\ans{}
  \copytoblankline}
\def\copytoblankline{\begingroup\setupcopy\copyans}
\def\setupcopy{\def\do##1{\catcode`##1=12}\dospecials
     \catcode`\|=12\obeylines}
{\obeylines \gdef\copyans#1
  {\def\next{#1}%
  \ifx\next\empty\let\next=\endgroup%
  \else\immediate\write\ans{\next}\let\next=\copyans\fi\next}}
\def\printanswers{\newpage\begin{center} Answers \end{center}
    \immediate\closeout\ans\input answers}

\begin{document}

\bigskip

\begin{center}
{%\Large
No calculators. \\
No notes.\\
Show all work.\\
Circle your answer.\\
Hand in to your TA.\\
}
\end{center}

\par\vskip .25in
\begin{center}
Name\makebox[3in]{\hrulefill} \\
\end{center}

\begin{center}
Circle the time of your TA section: \\
\end{center}
\begin{center}
   8:50-Laghi
   9:55-Laghi
   11:00-Basamakov
   12:05-Basamakov
   1:20-Jenkins
   2:25-Jenkins
\end{center}

% end file with \finishtbl
%\bigskip

\begin{center} \Large
 \begin{tabular}{||c|c|c||} \hline\hline
  Problem & Points & Score \\  \hline\hline
  \input{exam.tbl}
  \hline \hline
 \end{tabular}
\end{center}

\immediate\openout\examTBLFile=exam.tbl

\setcounter{page}{0}


\prob{\easy}
The function degsin$(x)$ is the ordinary sine function using
degrees instead of radians.  Thus, for example,
degsin$(45)={\sqrt{2}\over 2}$.  Find the derivative of
degsin$(x)$ with respect to $x$.
\answer degsin$(x)=\sin(kx)$ where $k={2\pi\over 360}$.
So the derivative of degsin is $k\cos(kx)$.

\prob{\easy}
Find the following:
\par\bigskip (a) $\sin^{-1}(\sin({\pi\over 6}))=$
\par\vfill   (b) $\sin^{-1}(\sin({9\pi\over 8}))=$
\par\vfill   (c) $\sin^{-1}(\sin({3\pi\over 4}))=$
\par\vfill
\answer  The arcsin only takes values between $-{\pi\over 2}$
and  ${\pi\over 2}$.
\par    (a) ${\pi\over 6}$
\par    (b) ${-\pi\over 8}$
\par    (c) ${\pi\over 4}$

\prob{\medium}
Prove Pythagorus's theorem.
\answer \unitlength=1.00mm
\special{em:linewidth 0.4pt}
\linethickness{0.4pt}
\begin{picture}(95.00,45.00)
\put(10.00,10.00){\framebox(35.00,35.00)[cc]{}}
\put(10.00,25.00){\line(3,4){15.00}}
\put(25.00,45.00){\line(4,-3){20.00}}
\put(45.00,30.00){\line(-3,-4){15.00}}
\put(30.00,10.00){\line(-4,3){20.00}}
\put(60.00,10.00){\framebox(35.00,35.00)[cc]{}}
\put(60.00,25.00){\line(1,0){35.00}}
\put(75.00,45.00){\line(0,-1){35.00}}
\put(60.00,25.00){\line(3,4){15.00}}
\put(75.00,10.00){\line(4,3){20.00}}
\put(27.00,27.00){\makebox(0,0)[cc]{$c^2$}}
\put(68.00,18.00){\makebox(0,0)[cc]{$a^2$}}
\put(85.00,35.00){\makebox(0,0)[cc]{$b^2$}}
\end{picture}

\prob{\medium}
Building A is 4 stories tall, Building B is 2 stories tall, and
they are separated by a distance which is equivalent to three stories.
What position ($x$ with $0\leq x\leq 3$)
between the two buildings maximizes the viewing
angle $\theta$ of sky?
\par
\unitlength=1.00mm
\special{em:linewidth 0.4pt}
\linethickness{0.4pt}
\begin{picture}(65.00,40.00)
\put(10.00,10.00){\framebox(17.00,22.00)[cc]{$A$}}
\put(5.00,10.00){\line(1,0){60.00}}
\put(45.00,10.00){\framebox(15.00,10.00)[cc]{$B$}}
\put(35.00,10.00){\vector(1,1){15.00}}
\put(35.00,10.00){\vector(-1,3){10.00}}
\put(6.00,19.00){\makebox(0,0)[cc]{$4$}}
\put(27.00,6.00){\makebox(0,0)[cc]{$0$}}
\put(36.00,6.00){\makebox(0,0)[cc]{$x$}}
\put(45.00,6.00){\makebox(0,0)[cc]{$3$}}
\put(63.00,15.00){\makebox(0,0)[cc]{$2$}}
\put(37.00,19.00){\makebox(0,0)[cc]{$\theta$}}
\end{picture}

\answer $6-{1\over 2}\sqrt{104}$ stories to the right of A.
To maximize $\theta$ minimize the sum of the other two angles
to the left and right of $\theta$.
$$f(x)=\cot^{-1}({x\over 4})+\cot^{-1}({{3-x}\over 2})$$
$$f^\prime(x)=-{4\over{16+x^2}}+{2\over{4+(3-x)^2}}$$
Setting $f^\prime(x)=0$ gives us:
$$x^2-12x+10=0$$
and so $x=6-{1\over 2}\sqrt{104}$ (the other root is outside the
interval $[0,3]$.  Since $f^\prime(0)<0$ and  $f^\prime(3)>0$,
it must that the minimum of $f$ (and hence maximum of $\theta$)
occurs in the interior of $[0,3]$.


\prob{\medium}
Let $f(x)=e^x$.  Approximate the area under this curve, above the
$x$-axis and between the lines $x=0$ and $x=1$ by using the right hand rule
and $\Delta x={1\over n}$.
Find the limit as $n\to \infty$.
\par Hint: You may use the geometric series formula:
$$1+x+x^2+\cdots + x^{n-1}={{1-x^n}\over {1-x}}$$
Check that your answer is correct by using the Fundamental Theorem
of Calculus to find this area.
\answer $$\sum_{k=1}^n f(x_k)\Delta x=\sum_{k=1}^n e^{k\over n}{1\over n}$$
$$\sum_{k=1}^n e^{k\over n}{1\over n}=({1\over n})((e^{1\over n})+
(e^{1\over n})^2+ (e^{1\over n})^3+\cdots + (e^{1\over n})^n)$$
$$=({1\over n})(e^{1\over n})(1 +
(e^{1\over n})^1+ (e^{1\over n})^1+\cdots + (e^{1\over n})^{n-1})$$
using the geometric series formula with $x=(e^{1\over n})$ we get
$$=({1\over n})(e^{1\over n}){{1-e}\over{1-e^{1\over n}}}$$
$$=(e^{1\over n})(1-e){{1\over n}\over{1-e^{1\over n}}}$$
$\lim_{n\to\infty}e^{1\over n}=e^0=1$.   Using L'Hopitol's rule:
$$\lim_{n\to\infty}{({1\over n})\over{1-e^{1\over n}}}=
\lim_{x\to 0^+}{{x}\over{1-e^{x}}}=
\lim_{x\to 0^+}{{1}\over{-e^{x}}}= -1$$
so the answer is $e-1=\int_0^1e^xdx=e^x]^1_0$

\prob{\medium}
Suppose $\int^3_{-2} f(x)\;dx=2$ and $\int^3_2 2f(x)dx=3$.  Find
$$\int^2_{-2} (3-2f(x)) \;dx = $$
\answer 11

\prob{\medium}
Find the minimum and maximum of $f(x)=\sqrt{3+x^4}$ on the
interval $[-1,2]$ and use them to find lower and upper bounds $L,U$ for
the integral:
$$L\leq \int^2_{-1} \sqrt{3+x^4}\;dx\leq U$$
$$L = $$
$$U = $$
\answer $m=\sqrt{3}$, $M=\sqrt{19}$, $L=3\sqrt{3}$, $U=3\sqrt{19}$

\prob{\medium}
The hypothesis of the first part of the Fundamental Theorem
of Calculus states:
\par Suppose that $f(x)$ is a continuous function on the interval
$[a,b]$ and we define
$$I(x)=\int_a^xf(t)dt$$
for all $x$ in $[a,b]$.
\par What is the conclusion of the first part of the Fundamental
Theorem?
\par\vskip 1in
\par The hypothsis of the second part of the Fundamental Theorem
of calculus is
\par Suppose $f(x)$ is a continuous function
on the interval $[a,b]$ and $F(x)$ is a continuous function
on $[a,b]$ such that $F^\prime(x)=f(x)$ for all $x$ in
$(a,b)$.
\par The conclusion is that
$$\int_a^bf(t)dt=F(b)-F(a)$$
Prove it.
\answer The conclusion of the first part is that
\par $I^\prime(x)=f(x)$ for every $x\in [a,b]$.
\par The proof the second part is:
\par By the first part we know that $I^\prime(x)=f(x)=F^\prime(x)$
for every $x\in [a,b]$.  Since two functions with the same derivative
must differ by a constant, we know there exists a constant $C$ such
that $F(x)=I(x)+C$ for all $x \in [a,b]$
Hence
$$F(b)-F(a)=(I(b)+C)-(I(a)+C)=I(b)-I(a)= $$
$$=\int_a^bf(t)dt-\int^a_af(t)dt=\int_a^bf(t)dt-0=\int_a^bf(t)dt$$

\prob{\medium} Find
$${d\over dx}\int^{x^2}_0\sin(t^2)\;dt$$
\answer $2x\sin(x^4)$
$${d\over dx}\int^{x^2}_0\sin(t^2)\;dt={d\over dx}\int^{u}_0\sin(t^2)\;dt=
{d\over dx}I(u)=({d\over du}I(u))({du\over dx})=$$
$$=({d\over du}\int^{u}_0\sin(t^2)\;dt)({du\over dx})=
(\sin(u^2))({2x})=(\sin(x^4))(2x)$$

\prob{\medium} Find
$$\lim_{n\to\infty}\sum_{k=1}^n{1\over n}(1+{k\over n})^5$$
\answer ${{2^6-1}\over 6}$.
This is the same as the integral $$\int^2_1x^5\;\;dx$$

\prob{\medium} Find
$$\int^1_0{{x\;dx}\over{1+x^4}}$$
\answer ${\pi\over 8}$. Substitute $u=x^2$ and then integrate using the
arctan.


\prob{\medium} Find
$$\int^1_{-1}xe^{x^4}\;dx$$
\answer $0$.  This is because $f(-x)=-f(x)$ implies
that $\int_{-a}^a f(x)dx=0$.  This problem can also be worked
by substituting $u=x^2$ and getting an integral
$\int^1_1$ which is zero.

\prob{\medium} Find the constant $c$ so that the area between the
curves $y=c$ and $y=4-x^2$ is exactly 1.
\answer $c=4-(3/4)^{2/3}$
Let $(a,c)$ be on both curves.  Hence $4-a^2=c$.  Then the
area is given by
$$\int_{-a}^a ((4-x^2)-c)\;dx=\int_{-a}^a ((4-x^2)-(4-a^2))\;dx=
\int_{-a}^a (a^2-x^2)\;dx$$
Since this integrand is even ($f(-x)=f(x)$) we have
that
$$\int_{-a}^a (a^2-x^2)\;dx= 2\int_{0}^a (a^2-x^2)\;dx=
\left.2(a^2x-{x^3\over 3})\right]^a_0=2(a^3-{a^3\over 3})={4\over 3}a^3$$
We want this integral to equal 1 so we must have
$${4\over 3}a^3=1$$
and so
$$a=({3\over 4})^{1\over 3}$$
and
$$c=4-a^2=4-(3/4)^{2/3}$$


\finishtbl
\printanswers

\end{document}

