\documentclass[12pt]{article}

\usepackage{latexsym,amsmath,epsfig,graphicx}
\setlength{\textwidth}{6.5in} \setlength{\textheight}{9in} \oddsidemargin = -.1 cm
\evensidemargin = -.1 cm 
\topmargin=-2cm
\begin{document}

\centerline{Mathematics 134 -- Calculus 2 With Fundamentals}
\centerline{Exam 4 -- Solutions for Review Sheet Sample Problems}
\centerline{April 26, 2018}
\vskip 10pt
\noindent
{\it Sample problems}
\vskip 10pt
\noindent
{\it Note:  The actual exam will be considerably shorter than the following
list of questions and it might not contain questions of all of these types.  
The purpose here is just to give an idea of the range
of different topics that will be covered and how questions might be posed.}
\vskip 10pt
\noindent
I.  For each of the following integrals, say why the integral is improper,
determine if the integral converges, and if so, find its value.
\vskip 10pt
\begin{enumerate}
\item[A)]  $\displaystyle \int_1^\infty \frac{1}{{\root 5 \of x}}\ dx$
\item[] {\it Solution:}  This is improper because of the infinite interval.
$$\lim_{b\to\infty} \int_1^b x^{-1/5}\ dx =
\lim_{b\to\infty} \left. \frac{5}{4} x^{4/5}\right|_1^b =\lim_{b\to\infty}\frac{5}{4}\left(b^{4/5} - 1\right).$$
This is not finite, so the integral \emph{diverges -- it does not converge}.  
\item[B)]  $\displaystyle \int_0^2 \frac{dx}{x^2 - 7x + 6}$
\item[] {\it Solution:}  This one is improper because the denominator
$x^2 - 7x + 6 = (x-1)(x-6)$
is zero at $x = 1$, which is in the interior of the interval.  In order
for the integral to converge, \emph{both}
$$\lim_{b\to 1^-} \int_0^b \frac{dx}{x^2 - 7x + 6}$$
and 
$$\lim_{a\to 1^+} \int_{a}^2 \frac{dx}{x^2 - 7x + 6}$$
must exist.  However neither integral does exist.  We integrate the first by partial 
fractions and find 
\begin{eqnarray*}
\lim_{b\to 1^-} \int_0^b \frac{dx}{x^2 - 7x + 6} &=& 
\lim_{b\to 1^-}\left(\left. -\frac{1}{5}\ln|x-1| + \frac{1}{5}\ln|x - 6|\right|_0^b\right)\\
&=&\lim_{b\to 1^-}\left(-\frac{1}{5}\ln|b-1| + \frac{1}{5}(\ln|b - 6| - \ln(6))\right).
\end{eqnarray*}
But the first term here does not have a finite limit as $b\to 1^-$.
Therefore this integral also {\it diverges}.
\item[C)]  $\int_0^\infty x e^{-3x}\ dx$
\item[] {\it Solution:}  We integrate by parts with $u = x$, $dv = e^{-3x}\ dx$ and find
\begin{eqnarray*}
&=&\lim_{b\to\infty} \left. -\frac{x e^{-3x}}{3} - \frac{e^{-3x}}{9}\right|_0^b\\
&=&\lim_{b\to\infty} -\frac{b}{3e^{3b}} - \frac{1}{9e^{3b}} + \frac{1}{9}\\
&=& \frac{1}{9}
\end{eqnarray*} 
using L'Hopital's Rule on the first term (the limit of each of the first
two terms is zero).  This integral {\it converges}
\item[D)]  For which values of $a$ is $\int_0^\infty e^{ax}\sin(x)\ dx$
convergent?  Evaluate the integral for those $a$. 
\item[] {\it Solution:}  The only chance here is if $a < 0$ so the 
exponential is decaying as $x \to +\infty$.  If this is true then we integrate
by parts twice to get 
$$\int e^{ax} \sin(x)\ dx = \frac{e^{ax}}{1 + a^2}(a\sin(x) - \cos(x))$$
since $a < 0$, the exponential goes to zero as $x \to \infty$ and the 
value of the integral is just the negative of the value at $x = 0$:
$$\int_0^\infty e^{ax}\sin(x)\ dx = \frac{1}{1 + a^2}.$$
\end{enumerate}
\vskip 10pt
\noindent
II.  The time $t$ (in minutes) between two 
successive incoming calls at a phone center is a random variable
with a pdf of the form $f(t) = c e^{-t/r}$ if $t \ge 0$ and 
$0$ otherwise.   
\begin{enumerate}
\item[(A)]   What must the value of $c$ be to make this a valid pdf? Express
$c$ in terms of the constant $r$.
\item[] {\it Solution:}  We want 
$$\int_0^\infty c e^{-t/r}\ dt = 1,$$
so 
$$1 = \lim_{b\to\infty} \int_0^b e^{-t/r}\ dt = c \lim_{b\to\infty}\left. -re^{-t/r}\right|_0^b
=c \lim_{b\to\infty} r$$
Hence $c = \frac{1}{r}$.    
\item[(B)] Suppose that the probability that two successive calls are more 
than one minute apart is $.3$.  What is the value of $r$?
\item[] {\it Solution:}  We have 
$$.3 = \int_1^\infty \frac{1}{r}e^{-t/r}\ dt = e^{-1/r}$$
So then $-1/r = \ln(.3)$, and $r = -1/\ln(.3) \doteq .8306$.  
\item[(C)] Using the value of $r$ you determined in part A, find the 
probability that the two successive calls are at least 5 minutes apart.
\item[] {\it Solution:}  This probability is 
$$P(T > 5) \doteq \int_5^\infty \frac{1}{.8306} e^{-t/.8306}\ dt \doteq .0024$$
(that is about a $.2\%$ chance of this happening).  
\end{enumerate}
\vskip 10pt
\noindent
III. (Normal probabilities) Use the normal curve area table:
\begin{enumerate}
\item[(A)] The probability that a standard normal random variable $Z$ satisfies
$-1.30 < Z < 0.83$
\item[]  {\it Solution:} This is equal to $P(0 < Z < 1.30) + P(0 < Z < 0.83) = .4032 + .2967 = .7999$.
\item[(B)] Cans of tomato soup have a stated volume of $16$ fluid ounces, but
the actual volume of the contents is normally distributed with mean $16.3$ fluid
oz. and SD $.22$ fluid oz.  What is the probability that a randomly selected
can contains less than 16 fluid oz. of tomato soup?  
\item[] {\it Solution:} By the standardization formula, this is equal to 
$$P\left(Z < \frac{16 - 16.3}{.22}\right) = P(Z < -1.36) = .5000 - P(0 < Z < 1.36) = .5000 - .4131 = .0869$$
(It would happen about 9\% of the time.)  
\end{enumerate}
\vskip 10pt
\noindent
IV.  {\it Differential Equations}.
\begin{enumerate}
\item[(A)]  Verify that for any constant $C$, the function $y = \sqrt{C + x^2}$
is a solution of the differential equation $\displaystyle \frac{dy}{dx} =\frac{x}{y}$.  Which 
of these solutions also satisfies the initial condition $y(0) = 5$?
\item[] {\it Solution:}  Computing the derivative with the Chain Rule:
$$y\frac{dy}{dx} = \sqrt{C + x^2}\cdot \frac{2x}{2\sqrt{C+x^2}} = x$$
Therefore $y = \sqrt{C + x^2}$ is a solution.
\item[(B)]  For which real $a$ is $y = e^{ax}$ a solution of the differential equation 
$\frac{dy}{dx} - 16y = 0$?
\item[] {\it Solution:}  if $y = e^{ax}$, then $\frac{dy}{dx} = a e^{ax}$.
So $\frac{dy}{dx} - 16y = 0$ if and only if $a = 16$.  
\item[(C)]   Find the general solution of 
$$\frac{dy}{dx} = xe^{x+y}$$
\item[] {\it Solution:}  This is a separable equation because the right side can be
written as 
$$\frac{dy}{dx} = xe^x \cdot e^y$$
Hence 
$$\int e^{-y}\ dy = \int x e^x\ dx$$
Integrating by parts on the right side, 
$$-e^{-y} = x e^x - e^x + C$$
for some arbitrary constant.  Hence
$$e^{-y} = -xe^x + e^x - C$$
and 
$$y = - \ln(-xe^x + e^x - C).$$
\item[(D)]  Find the general solution of 
$$\sqrt{1 - x^2}\frac{dy}{dx} = y^2 + 2y$$
\item[] {\it Solution:}  This is a separable equation:
$$\frac{dy}{y(y + 2)} = \frac{1}{\sqrt{1 - x^2}}\ dx$$
Integrate with partial fractions on the left:
$$\frac{1}{y(y+2)} = \frac{A}{y} + \frac{B}{y+2}$$
when $A = \frac{1}{2}$ and $B = -\frac{1}{2}$.  So
\begin{eqnarray*}
\int \frac{1/2}{y} - \frac{1/2}{y+2}\ dy &=& \int \frac{1}{\sqrt{1 - x^2}}\ dx\\
\frac{1}{2}\ln|y| - \frac{1}{2}\ln|y+2| &=& \sin^{-1}(x) + C\\
\ln\left|\frac{y}{y+2}\right| &=& 2\sin^{-1}(x) + C'\qquad (C' = 2C)\\
y &=& \frac{2 a e^{2 \sin^{-1}(x)}}{1 - a e^{2 \sin^{-1}(x)}}.
\end{eqnarray*}
where $a = \pm e^{C'}$.
\item[(E)]  Find the general solution of 
$$\frac{dy}{dx} = xe^{x+y}$$
\item[] {\it Solution:}  This is also separable:
$$\int e^{-y}\ dy = \int x e^x\ dx.$$
On the right integrate by parts with $u = x$ $dv = e^x\ dx$.  So 
$$-e^{-y} = x e^x - e^x + C$$
Then 
$$y = -\ln(-xe^x + e^x + C)$$
(I have written the arbitrary constant as $C$ again; in the final version,
the constant is the negative of the one in the line before.)
\item[(F)]  A baked potato is taken out of the oven at a temperature of $140^\circ$ C
and left to cool on a counter in a room maintained at $20^\circ$ C.  
After 2 minutes the temperature of the 
potato has decreased to $100^\circ$ C.  How long will it take for the temperature
to reach $80^\circ$ C?
\item[] {\it Solution:}  The relevant differential equation is the one from 
Newton's Law of Cooling.  The initial condition
comes from thinking of the time when the potato comes out of the oven
as $t = 0$.  Letting $T$ be the temperature of the potato in 
degrees C, $t$ be time in minutes:
\begin{eqnarray*}
\frac{dT}{dt} &=& k(T - 20)\\
T(0) &=& 140
\end{eqnarray*}
The solution is 
$$T(t) = 20 + 120 e^{kt}$$
(with $k < 0$).  We are given $T(2) = 100$. So 
$$100 = 20 + 120 e^{2k}$$
and $k = \frac{1}{2}\ln(2/3) \doteq -.20273$.  Then we want to solve
for $t$ in the equation from the time when $T = 80$: 
$$80 = 20 + 120e^{(-.20273)t}$$
which shows 
$$t = \frac{\ln(1/2)}{-.20273} \doteq 3.42$$
It will take a total of $3.42$ minutes (equivalently, another $1.42$ minutes
after the time when $T = 100$).  
\item[(G)]  Sunset Lake is stocked with 2000 rainbow trout.  After 2 years
the trout population has grown to 4500.  Assuming logistic growth with
a carrying capacity of 10000 trout, find the growth constant $k$ and determine
when the population will reach 5000.
\item[] {\it Solution:} Let $y$ be the trout population as a function of 
time $t$ in years.  We are given that the growth is logistic, which means
that 
$$\frac{dy}{dt} = ky\left(1 - \frac{y}{10000}\right)$$
for some $k$.  We also know the general solution will look like this:
$$y = \frac{10000}{1 + a e^{-kt}}$$
Take $t = 0$ to be the time when the lake is stocked, so $y(0) = 2000$.  (We need
to assume there were no trout there before.)  Then 
$$2000 = \frac{10000}{1 + a} \Rightarrow a = 4.$$
Next at $t = 2$ we have
\begin{eqnarray*}
4500 &=& \frac{10000}{1 + 4e^{-2k}}\\  
1 + 4e^{-2k} &=& \frac{10000}{4500} \doteq 2.222\\
k  &\doteq& -\frac{1}{2}\ln(1.222/4) \doteq .5929
\end{eqnarray*}
The population will reach $5000$ when
$$5000 = \frac{10000}{1 + 4 e^{-(.5929)t}}.$$
Solving for $t$:
$$t = \frac{\ln(1/4)}{-.5929} \doteq 2.3$$
years.  That is, in another $0.3$ years after $t = 2$.  
\end{enumerate}
\vskip 10pt
\noindent
V.  Time value of money (and geometric series).
\begin{enumerate}
\item[(A)] Juan deposits $\$500$ in a savings account earning
$3\%$ interest compounded monthly.  What will the balance in the account be
after $4$ years?  What if the interest is compounded continuously.
\item[] {\it Solution:}  We want the future value of a single sum of $\$500$ after $4$
years with a $3\%$ annual interest rate, compounded monthly.  This is: 
$$FV = \$500 \cdot \left(1 + \frac{.03}{12}\right)^{12\cdot 4} \doteq  \$563.66$$
With continuous compounding the balance will be 
$$\$500 \cdot e^{(.03)(4)} \doteq \$ 563.75$$
or $9$ cents more(!)
\item[(B)]  What is the sum of the finite geometric series
$$6 + \frac{6}{4} + \frac{6}{16} + \cdots + \frac{6}{4^9}?$$
What happens when you keep adding terms of this form indefinitely:
$$6 + \frac{6}{4} + \frac{6}{16} + \cdots + \frac{6}{4^{N-1}}$$
and take a limit as $N \to \infty$?
\item[] {\it Solution:}  The given sum is 
$$\frac{6\left(1 - \left(\frac{1}{4}\right)^{10}\right)}{1 - \frac{1}{4}} = \frac{1048575}{131072}$$
(Needless to say the expression to the left of the equals sign is more informative!)
For the second part of the question, note that $\lim_{N\to\infty} \frac{1}{4^N} = 0$.  
So 
$$\lim_{N\to\infty} \frac{6\left(1 - \left(\frac{1}{4}\right)^{N}\right)}{1 - \frac{1}{4}} = \frac{6}{1 - \frac{1}{4}} = 8.$$
In fact, the decimal equivalent of $\frac{1048575}{131072}$ is $7.999992371$(!) so we're already
extremely close to $8$ just with the first 10 terms in the geometric series.  
\item[(C)] Some banks began offering
``Christmas clubs'' around the time of the Great Depression in the 1930's.   
Customers would make contributions from their
weekly pay checks to the ``club'' in order to have a given amount on hand to buy
presents come Christmas time.  Suppose you decide to make 48 weekly payments
into a Christmas club earning an annual interest rate of $1\%$, compounded
weekly.  What should the payment be in order to have $\$800$ on hand to spend on gifts
at the end of the 48 weeks?    
\item[] {\it Solution:}  If the weekly payment is $P$, the future value of the stream of 48 
payments is
$$P\cdot \frac{\left(1 + \frac{.01}{52}\right)^{48} - 1}{\frac{.01}{52}} \doteq P\cdot 48.21763960$$
We want this to equal $\$ 800$ for the Christmas gifts, so 
$$P = \frac{800}{48.21763960} \doteq \$ 16.59$$
(Note:  The bank could make money on the deal by offering a lower interest rate on the Christmas club
than they could get by reinvesting the money held for the customers in other ways -- e.g. by 
writing other loans.  And the interest-bearing ``club'' is only a slight improvement over
stashing money under the mattress -- the total of the ``club'' payments is 
$$48\cdot \$ 16.59 = \$ 796.32$$
The point of these arrangements was to give the customers an easy way to set aside
money for a bigger-ticket item that was predictable every year.  It was an encouragement
to save.) 
\item[(D)] What would be the monthly payment on a 15-year mortgage for $\$ 300,000$ at
an annual interest rate of $3.6\%$?
\item[] {\it Solution:}  As we discussed in class, these loans are structured so 
that the future value of the stream of monthly payments is equal to the future value
of the loan amount given to the customer at the start of the loan.  The monthly payment 
amount is 
$$q = \frac{P\cdot \frac{r}{12}}{1 - \left(1 + \frac{r}{12}\right)^{-12\cdot y} }$$
if the loan is written for a term of $y$ years.  With the given information 
$$q = \frac{\$ 300000\cdot (.036/12)}{1 - (1 + .036/12)^{-180}}\doteq \$ 2159.41$$ 
\end{enumerate} 
\end{document}
