\input{ThisWeek.tex}
\newcommand{\classday}{\Tuesday}
\input{../TemplateWeek/InClassWork.tex}
\input{Exercises.tex}

%\booltrue{teacher}

%This is some leftovers from previous days as review

%In the first problem part f, should remember to define f(0).  It's not a great problem anyway, because it's an obnoxious limit.
%In exercise 3, it should be "differentiable", not continuous

\section*{Exercise 1}
To warm up, some derivatives:
\begin{enumerate}[label=(\alph*)]
\item Find $\frac{d}{dx}\tan\sin(xe^x)$.
\item Find $\frac{d}{dx}\frac{(\sin x)e^x}{(x^3+1)^2(x-2)}$.
\item $\mathrm{Ci}(x)$ is function with the property that $\mathrm{Ci}'(x)=\frac{\cos x}{x}$.  What is $\frac{d}{dx}\mathrm{Ci}(x^2)$?
\item What is $\frac{d}{dx}\mathrm{Ci}(e^{x^2})$?
\item What is $\frac{d}{dx}\mathrm{Ci}(x\sin x^2)$?
\item What is $\frac{d}{dx}xe^{-1/x^2}|_{x=0}$?
\end{enumerate}

\section*{Exercise 2}
$\tanh$ is a function you may not have encountered yet.  $\tanh x=\frac{e^x-e^{-x}}{e^x+e^{-x}}$.  Find $\frac{d}{dx}\tanh^{-1}x$.

\texttt{
  \begin{enumerate}[label=(\roman*)]
  \item Find $\tanh' x$.
\item Using some algebra, manipulate your definition of $\tanh' x$ so that it is expressed in terms of $\tanh x$.
\item What is $\tanh'\tanh^{-1}x$?  ($\tanh^{-1}$ is the inverse of $\tanh$.  Remember to use the properties of inverses.)
\item Use the derivative rule for inverses to find $\frac{d}{dx}\tanh^{-1}x$?
  \end{enumerate}
}

\section*{Exercise 3}

For each of the following piecewise functions, determine whether it is continuous at $1$, and then draw a picture or plot on a calculator to confirm your answer.

\begin{enumerate}[label=(\alph*)]
\item $f(x)=\left\{\begin{array}{ll}
\sqrt{x}&\text{if }x<1\\
x/2&\text{if }x\geq 1\\
\end{array}\right.$
\item $g(x)=\left\{\begin{array}{ll}
e^x&\text{if }x<1\\
ex&\text{if }x\geq 1\\
\end{array}\right.$
\item $h(x)=\left\{\begin{array}{ll}
x^2&\text{if }x<1\\
x&\text{if }x\geq 1\\
\end{array}\right.$
\end{enumerate}



\section*{Exercise 4}
 Consider this graph of points satisfying $y^2=x^3-x+\sqrt{\frac{4}{27}}$:

\begin{tikzpicture}
  \begin{axis}[width=240, height =200, xmax=2, ymax=2, xmin=-2, ymin=-2, xlabel=$x$, ylabel=$y$, axis x line = middle, axis y line=middle]
\addplot[smooth,samples=1000,domain=-1.1547:1.75] gnuplot{sqrt(x**3-x+2*sqrt(1./27))};
\addplot[smooth,samples=1000,domain=-1.1547:1.75] gnuplot{-sqrt(x**3-x+2*sqrt(1./27))};
  \end{axis}
\end{tikzpicture}

\begin{enumerate}[label=(\alph*)]
\item Before taking the derivative, use the graph to identify where you think the derivative of this curve will be defined.
\item Use implicit differentiation to find the derivative $\frac{dy}{dx}$?  (Your final answer should be $\frac{dy}{dx}=\cdots$ with only $x$ and $y$ on the right.)
\item Compare the points where $\frac{dy}{dx}$ isn't defined to the points on the curve where you didn't expect the derivative to be defined.
\item Use implicit differentiation to find the derivative $\frac{d^2y}{dx^2}$.   (Your final answer should be $\frac{d^2y}{dx^2}=\cdots$ with only $x$ and $y$ on the right.)
\end{enumerate}

\section*{Exercise 5}
In a simple economic model, there is a relationship between the \emph{price} $p$ of widgets and the \emph{quantity} $Q(p)$ of widgets that will be sold at price $Q(p)$.

  \begin{enumerate}[label=(\alph*)]
  \item What are the units of $Q'(p)$?  For most goods, is $Q'(p)$ positive or negative?
\item The \emph{elasticity of demand} is the value $E(p)=\frac{p}{Q(p)}Q'(p)$.  This value measures change relative to the original values.  For example, if $E(p)$ is always equal to $-1$, that means that when the price increases by $1\%$, the quantity will decrease by $1\%$.  What are the units of elasticity?
\item Suppose $Q(p)=3p^{-1/2}$.  Find $(\ln Q(p))'$.
\item Remember that $(\ln Q(p))'=\frac{Q'(p)}{Q(p)}$.  What is $E(p)$?
  \end{enumerate}


\section*{Exercise 6}
If you throw a ball at velocity $v$ at an angle $\theta$, the object will land $\frac{v^2\sin 2\theta}{g}$ meters away (where $g$ is the gravitational constant).  We are aiming at a target $\frac{50^2}{g}$ meters away, so if we throw the ball at the angle $\pi/4$ with $v=50$, we will exactly hit the target.  Which throw will get us closer: if we get the velocity exactly right but the angle wrong by $0.2$ meters or if we get the angle exactly right but the velocity wrong by $0.2$ radians?  (Note that you \emph{don't} need a calculator for this problem.)

\end{document}