\documentclass[11pt]{article}
\usepackage{latexsym,amsmath,amssymb}
\setlength{\textwidth}{6.5in}
\setlength{\oddsidemargin}{0in}
\setlength{\textheight}{8.0in}
\begin{document}
\centerline{Mathematics 241 -- Multivariable Calculus}
\centerline{Solutions for Midterm Exam 1}
\centerline{September 28, 2007}
\vskip 10pt
\noindent
I.  
\vskip 10pt
\noindent
A)   A direction vector for the line is $Q - P = (1,2,-4) - (0,0,1) = (1,2,-5)$.
Parametric equations come from $P + t(Q - P) = (0,0,1) + t(1,2,-5)$, so 
\begin{eqnarray*}
x &=& t\\
y &=& 2t\\
z &=& 1 - 5t.
\end{eqnarray*}
The interval of $t$-values giving the line segment from $P$ to $Q$ for these
parametric equations is $0 \le t \le 1$ (note that $t = 0$ gives $(x,y,z) = (0,0,1)$
which is $P$, and $t = 1$ gives $(1,2,-4)$, which is $Q$).  The point equidistant
from $P$ and $Q$ along the line is the midpoint of the line segment, which is
the point with $t = \frac{1}{2}$.  This can be seen in several different ways.
The easiest is just to notice that the parametric equations correspond to motion
with constant speed along the line segment, so $t = \frac{1}{2}$ will take
us exactly half the distance from $P$ to $Q$.
\vskip 10pt
\noindent
B.  Let $v = Q - P = (1,2,-5)$ as above.  Also let $w = R - P = (1,-1,0) - (0,0,1) = (1,-1,-1)$.
Then a normal vector for the desired plane is 
\[
{\bf N} = (1,2,-5) \times (1,-1,-1) = (-2 - 5, -(-1 + 5), -1 - 2) = (-7, -4, -3).
\]
The Cartesian equation of the plane is 
\[
0 = {\bf N}\cdot (x - 0, y - 0, z - 1) = (-7,-4,-3)\cdot (x, y ,z - 1) = -7x - 4y - 3z + 3,
\]
or $7x + 4y + 3z = 3$.
\vskip 10pt
\noindent
C.  The desired angle is 
\begin{eqnarray*}
\theta &=& \cos^{-1}\left(\frac{v\cdot w}{\|v\|\|w\|}\right)\\
       &=& \cos^{-1}\left(\frac{4}{\sqrt{30}\sqrt{3}}\right)\\
       &\doteq& 1.13 \text{ radians, or}\\
       &\doteq& 65.1^\circ.
\end{eqnarray*}
\vskip 10pt
\noindent
II.  Note that $(x,y,z)\cdot (0,0,1) = z$, and $\|(x,y,z)\| = \sqrt{x^2 + y^2 + z^2}$.
Hence the equation given can be rewritten as 
\[
\frac{z}{\sqrt{x^2 + y^2 + z^2}} = \frac{1}{\sqrt{2}}.
\]
Changing to spherical coordinates, we know $z = \rho \cos(\varphi)$, and 
$\rho^2 = x^2 + y^2 + z^2$.  Hence the equation can be rewritten
as 
\[
\frac{1}{\sqrt{2}} = \frac{\rho\cos(\varphi)}{\rho} = \cos(\varphi).
\]
For $0 \le \varphi \le \pi$, this has just one solution, $\varphi = \frac{\pi}{4}$.
The set of all points satisfying this equation (equivalent to the original one)
is a {\it cone} with axis along the $z$-axis.
\vskip 10pt
\noindent
{\it Comment:}  A common error on this problem was to take the equation
$\displaystyle{\frac{z}{\sqrt{x^2 + y^2 + z^2}} = \frac{1}{\sqrt{2}}}$ and equate
numerators and denominators to obtain $z = 1$ and $\sqrt{x^2 + y^2 + z^2} = 2$.
{\it This is NOT a valid algebraic maneuver.}  Knowing $\frac{a}{b} = \frac{c}{d}$
does not imply that $a = c$ and $b = d$; it just implies that $ad = bc$.
\vskip 10pt
\noindent
III. 
\vskip 10pt
\noindent
A.
Letting $(x,y)$ go to $(0,0)$ along the line $y = mx$,
\begin{eqnarray*}
\lim_{x\to 0} f(x,mx) &=& \lim_{x \to 0} \frac{x\cdot mx - (mx)^2}{x^2 + 4(mx)^2}\\
&=& \lim_{x \to 0} \frac{x^2(m - m^2)}{x^2(1 + 4m^2)}\\
&=& \lim_{x \to 0} \frac{m - m^2}{1 + 4m^2} \text{ (cancel the $x^2$'s)}\\
&=& \frac{m - m^2}{1 + 4m^2}
\end{eqnarray*}
\noindent
B.  From the computations in part A, we see that $f(x,mx)$ is approaching
different values as $x \to 0$, depending on the value of $m$.  For example,
we get a limiting value of $0$ if $m = 1$, but a limiting value of $-\frac{2}{5}$
if $m = -1$.  This implies that $\lim_{(x,y)\to (0,0)} f(x,y)$ {\it does not 
exist}.  Hence $f$ cannot be continuous at $(0,0)$, since the definition of
continuity is that $\lim_{(x,y)\to (0,0)} f(x,y)$ must exist and equal
$f(0,0)$.
\vskip 10pt
\noindent
IV.  
\vskip 10pt
\noindent
A.  The Cartesian equation of the graph is $z = \cos(\sqrt{x^2 + y^2})$.
In cylindrical coordinates, $r^2 = x^2 + y^2$ and $z$ is the Cartesian
$z$-coordinate, so the cylindrical equation is just $z = \cos(r)$.  
\vskip 10pt
\noindent
B.  The equation of the level curve is $\cos(r) = 1$.  This implies
$r = 2n\pi$ some integer $n \ge 0$.  If $n = 0$, we get a single point
at the origin.  If $n \ge 1$, then the polar equation $r = 2n\pi$ defines
a circle of radius $2n\pi$ in the polar coordinate plane.  Thus, the 
level curve consists of an isolated point at the origin together with
an infinite collection of circles centered at the origin, with radii
$2n\pi$ for $n = 1,2,3, \ldots$.   
\vskip 10pt
\noindent
{\it Comment:}  Of course you can get the same conclusion by going
back to the Cartesian coordinate equation of the graph.
The set of points in the plane with $\sqrt{x^2 + y^2} = 2n\pi$ is
the circle described above when $n \ge 1$.
\vskip 10pt
\noindent
C.  By the chain rule for 1-variable derivatives:
\[
\frac{\partial f}{\partial x} = 
\frac{\partial}{\partial x}\left(\cos(\sqrt{x^2 + y^2})\right) = 
-\sin(\sqrt{x^2 + y^2})\cdot \frac{1}{2}(x^2 + y^2)^{-1/2}\cdot 2x.
\]
This can be simplified to give
\[
\frac{\partial f}{\partial x} = \frac{-x\sin(\sqrt{x^2 + y^2})}{\sqrt{x^2 + y^2}}.
\]
Substituting $x = \frac{\pi}{2}$, we obtain
\[
\frac{\partial f}{\partial x}\left(\frac{\pi}{2},0\right) 
 = \frac{-\frac{\pi}{2}\sin(\frac{\pi}{2})}{\frac{\pi}{2}} = -1.
\]
\end{document} 
