\documentclass[11pt]{article}


\usepackage{amsfonts}

\renewcommand{\labelenumi}{\underline{\underline{\bf\theenumi.}}\ }

\setlength{\hoffset}{-1in}
\setlength{\textwidth}{160mm}
\setlength{\parindent}{0pt}
\setlength{\voffset}{-1in}
\setlength{\textheight}{235mm}
\setlength{\parindent}{0pt}
\setlength{\parskip}{1ex}

\def\R{\mathbb{R}}
\def\abs#1{\mathopen|#1\mathclose|}

\let\Dst=\displaystyle
\let\Tst=\textstyle

\def\artanh{\mathop{\rm artanh}}
\def\arcosh{\mathop{\rm arcosh}}
\def\arsinh{\mathop{\rm arsinh}}


\begin{document}

\centerline{\bf Sample Solutions to Homework }
\centerline{\bf
UTK -- M148 -- Honors Calculus II -- Spring 2015}
\centerline{\bf
Jochen Denzler}

\underline{\underline{\bf 1.}} 
Find antiderivatives of the following functions:
$$
\begin{array}{l@{\quad}l@{\qquad\qquad}l}
(a) &\Dst
f(x) = \cos (2x+4) &\Dst
F(x) = \frac12 \sin(2x+4) + C
\\[2ex]
(b) &\Dst
g(x) = 3e^x + e^{3x} + x^{3e} &\Dst
G(x) = 3e^x + \frac13 e^{3x} + \frac{1}{3e+1} x^{3e+1} + C
\\[2ex]
(c) &\Dst
h(x) = \frac1{5x} \mbox{ for } x>0 &\Dst
H(x) = \frac15 \ln x + C
\\[2ex]
(d) &\Dst k(x) = 1/x^5 &\Dst
K(x) = -\frac14 x^{-4} + C
\end{array}
$$

{\bf Note: }I would consider it ok here if you were to omit the $C$
(or choose one particular number for it), simply because ``Find
antiderivatives for [these]'' could be reasonably understood as ``Find
some / at least one antiderivative for each of these''. Had I
specifically demanded to find {\em the\/} or {\em all\/}
antiderivatives, then the $C$ would be mandatory.  

{\bf Note: } In part (c), $H(x) = \frac 15 \ln(5x) + C$ is also
correct since $\ln (5x)=\ln x + \ln 5$. An absolute value sign as in
$\ln\abs{x} + C$ is permissible, but redundant, since I specified
$x>0$ beforehand. 

\bigskip
\begin{quote}
\underline{\underline{\bf 2.}} \small
Find the area below the curve $y=x^2$, above the $x$-axis, between $x=0$ 
and $x=b$ as a limit of a sum of rectangle areas (as done for $y=ax$ in 
class). To this end, divide the interval $[0,b]$ into $n$ pieces each of 
equal length $\Delta x=\frac bn$. Do two calculations, one by evaluating 
the function at the left endpoint, one at the right endpoint. 

Draw a picture. 

{\bf Hints: }
You may need the following formula (which is likely new to you, and you 
may just take my word for its validity): 
$1^2 + 2^2 + 3^2 + \ldots + n^2 = \frac{n(n+1)(2n+1)}{6}$.
You may also need a similar formula ending with $(n-1)^2$, which 
you can obtain from the one I gave you by simple algebra. 
\end{quote}

{\bf Solution: }

Let me first use the hint. From 
$$
1^2 + 2^2 + 3^2 + \ldots + n^2 = \frac{n(n+1)(2n+1)}{6}
$$
(which is true for each positive integer $n$) we conclude, by
replacing $n$ with $n-1$, that
$$
1^2 + 2^2 + 3^2 + \ldots + (n-1)^2 = \frac{(n-1)(n-1+1)(2(n-1)n+1)}{6}
= \frac{n(n-1)(2n-1)}{6}
$$

\newpage

\begin{picture}(250,250)(-10,-10)
\put(0,0){\special{psfile=hwk2fig.eps}}
\put(-3,-12){0}
\put(235,-12){$n\frac bn=n$}
\put(25,-12){$\frac bn$}
\put(55,-12){$2\frac bn$}
\put(85,-12){$3\frac bn$}
\end{picture}

The Riemann sum with tags at the left end of each interval is
$$
A_l(n)= \frac bn 0^2 + \frac bn \Big(\frac bn\Big)^2 + \frac bn \Big(2\frac
bn\Big)^2 + \ldots 
+ \frac bn \Big((n-1)\frac bn\Big)^2
=
\frac{b^3}{n^3} \Big( 0^1 + 1^2 + 2^2 + \ldots  + (n-1)^2 \Big)
$$
Using the above summation formula, 
we obtain the area of the rectangles to be  
$A_l(n) = b^3 \frac{(n-1)(2n-1)}{6n^2}$, and $\lim_{n\to\infty} A_l(n)
= b^3\frac{2}{6} = b^3/3$.

\bigskip

\begin{picture}(250,250)(-10,-10)
\put(0,0){\special{psfile=hwk2fig2.eps}}
\put(-3,-12){0}
\put(235,-12){$n\frac bn=n$}
\put(25,-12){$\frac bn$}
\put(55,-12){$2\frac bn$}
\put(85,-12){$3\frac bn$}
\end{picture}

The Riemann sum with tags at the right end of each interval is
$$
A_r(n)= \frac bn 1^2 + \frac bn \Big(\frac bn\Big)^2 + \frac bn \Big(2\frac
bn\Big)^2 + \ldots 
+ \frac bn \Big(n\frac bn\Big)^2
=
\frac{b^3}{n^3} \Big(  1^2 + 2^2 + \ldots  + n^2 \Big)
$$
Using the above summation formula, 
we obtain the area of the rectangles to be  
$A_r(n) = b^3 \frac{(n+1)(2n+1)}{6n^2}$, and $\lim_{n\to\infty} A_r(n)
= b^3\frac{2}{6} = b^3/3$.


\bigskip
\begin{quote}
\underline{\underline{\bf 3.}} \small
(a) Evaluate $\sum_{j=0}^6 j(6-j)$. 
\\
(b) Simplify the expression $\sum_{j=1}^n f(j) - \sum_{k=2}^{n-1}
f(k)$ (where you may assume that $n$ is an integer $\ge3$).   
\\
(c) Evaluate $\sum_{j=1}^n \frac{1}{j(j+1)}$ for $n=1,2,\ldots,7$
respectively and conjecture a formula for general $n$. Then write
$\frac{1}{j(j+1)}$ as a difference of two terms, based on the
conjectured formula, and use this to prove the formula as a
telescoping sum. 
\end{quote}

{\bf Solution: }
$$\kern0pt
(a) \qquad 
\sum_{j=0}^6 j(6-j) = 0\cdot6 + 1\cdot 5 + 2\cdot 4 + 3\cdot 3 +
4\cdot 2 + 5\cdot 1 + 6 \cdot 0 = 35
\kern10cm\hss
$$
$$\kern0pt
(b) \qquad
\sum_{j=1}^n f(j) - \sum_{k=2}^{n-1} f(k) = 
f(1) + f(2) + \ldots + f(n) - \Bigl(
f(2) + \ldots + f(n-1) \Bigr) = f(1) + f(n)
\kern10cm\hss
$$
(Note that there {\em is\/} an $f(n-1)$ in the first sum, even though
it's hiding amongst the `\ldots', right before the $f(n)$.)

\bigskip 
(c) First the numerical evaluation: 
$$
\begin{array}{ll}
\sum_{j=1}^1 \frac{1}{j(j+1)} = \frac{1}{1\cdot 2} 
&\mbox{}
= \frac12
\\[1ex]
\sum_{j=1}^2 \frac{1}{j(j+1)} = \frac{1}{1\cdot 2} 
+ \frac{1}{2\cdot 3} 
&\mbox{}
= \frac12+\frac16 = \frac23
\\[1ex]
\sum_{j=1}^3 \frac{1}{j(j+1)} = \frac{1}{1\cdot 2} 
+ \frac{1}{2\cdot 3} + \frac{1}{3\cdot 4} 
&\mbox{}
= \frac23 + \frac1{12} = \frac34
\\[1ex]
\sum_{j=1}^4 \frac{1}{j(j+1)} = \frac{1}{1\cdot 2} 
+ \frac{1}{2\cdot 3} + \frac{1}{3\cdot 4} + \frac{1}{4\cdot 5} 
&\mbox{}
= \frac34 + \frac1{20} = \frac45
\\[1ex]
\sum_{j=1}^5 \frac{1}{j(j+1)} = \frac{1}{1\cdot 2} 
+ \frac{1}{2\cdot 3} + \frac{1}{3\cdot 4} + \frac{1}{4\cdot 5} +
\frac{1}{5\cdot 6}  
&\mbox{}
= \frac45 + \frac1{30} = \frac56
\\[1ex]
\sum_{j=1}^6 \frac{1}{j(j+1)} = \frac{1}{1\cdot 2} 
+ \frac{1}{2\cdot 3} + \frac{1}{3\cdot 4} + \frac{1}{4\cdot 5} +
\frac{1}{5\cdot 6}  + \frac{1}{6\cdot 7}  
&\mbox{}
= \frac56 + \frac1{42} = \frac67
\\[1ex]
\sum_{j=1}^7 \frac{1}{j(j+1)} = \frac{1}{1\cdot 2} 
+ \frac{1}{2\cdot 3} + \frac{1}{3\cdot 4} + \frac{1}{4\cdot 5} +
\frac{1}{5\cdot 6}  + \frac{1}{6\cdot 7}  + \frac{1}{7\cdot 8}  
&\mbox{}
= \frac67 + \frac1{56} = \frac78
\end{array}
$$
So we observe a pattern and conjecture that 
$\sum_{j=1}^n \frac{1}{j(j+1)} = \frac{n}{n+1}$. 

As for writing $\frac{1}{j(j+1)}$ as a difference, you could use a
formula that I mentioned in class in different context (and quite
inconspicuously so), namely $\frac{1}{j(j+1)} = \frac1j -
\frac1{j+1}$. That would be correct, but you could find a different
way by relying on the hint `based on the conjectured formula', namely: 

If indeed $\sum_{j=1}^n\frac{1}{j(j+1)}= \frac{n}{n+1}$ (as we
conjecture to be true for all $n$ and have verified up to $n=7$ at
least), then the sameformula for $n-1$ would read 
$\sum_{j=1}^{n-1}\frac{1}{j(j+1)}= \frac{n-1}{n-1+1}= \frac{n-1}{n}$. 
These two sums just differ by the last term, namely the
$\frac1{j(j+1)}$ with $j=n$. So if the conjectured formula is indeed
true, then $\frac1{n(n+1)} = \frac{n}{n+1}-\frac{n-1}{n}$. 

But we do not need to rely on the conjectured formula to believe this
last statement; rather we can verify it by direct algebra: 
$$\textstyle
 \frac{n}{n+1}-\frac{n-1}{n} = \frac{n^2 - (n-1)(n+1)}{n(n+1)} =
 \frac{1}{n(n+1)} 
$$
indeed. Having verified this formula, we can now work backwards to
obtain the conjectured formula with the certainty that doesn't rely on
guesswork: 
$$
\sum_{j=1}^n \frac{1}{j(j+1)} 
= \sum_{j=1}^n \Bigl(\frac{j}{j+1}-\frac{j-1}{j}\Bigr)
=
\Bigl(\frac12 - \frac01\Bigr) + \Bigl(\frac23-\frac12\Bigr) + 
\Bigl(\frac34 - \frac23\Bigr) + \Bigl(\frac45-\frac34\Bigr) + 
\ldots + \Bigl(\frac n{n+1}-\frac{n-1}{n}\Bigr)
$$
We see that intermediate terms cancel: the negative term in each
parenthesis cancels out the positive term in the preceding
parenthesis. All that remains is $-\frac01 + \frac{n}{n+1}$. 
This confirms that the conjectured formula indeed holds for all $n$. 

{\small\sf Note: in future classes you will prove this kind of formula by
  a method called induction. The calculational part will be more or
  less the same as what we did here, but the writeup will be more
  formal and organized.}

Your calculation may look a bit different if you wrote $\frac1{j(j+1)}
= \frac1j-\frac1{j+1}$. Namely you'd get:
$$
\sum_{j=1}^n \frac{1}{j(j+1)} 
= \sum_{j=1}^n \Bigl(\frac1{j}-\frac1{j+1}\Bigr)
=
\Bigl(\frac11-\frac12 \Bigr) + \Bigl(\frac12-\frac13\Bigr) + 
\Bigl(\frac13-\frac14 \Bigr) + \Bigl(\frac14-\frac15\Bigr) + 
\ldots + \Bigl(\frac1n-\frac1{n+1}\Bigr)
$$
Adjacent terms from adjacent pairs cancel, and all that remains is
$\frac11-\frac1{n+1}=\frac n{n+1}$. 


\bigskip

\begin{quote}
\underline{\underline{\bf 4.}} \small
  Estimate $\int_0^5 \frac{dx}{1+x^2}$ from above and below by a
  Riemann sum each; make the Riemann sums consist of 10 terms (using
  an equidistant partition). 
\end{quote}
{\bf Solution: }
Since $1/(1+x^2)$ is {\em decreasing\/} on $[0,5]$, we get an estimate
from {\em above\/} by using the {\em left\/} endpoints as tags,
whereas we get an estimate from {\em below\/} by using the {\em
  right\/} endpoints as tags. 

The equidistant partition of $[0,5]$ into 10 pieces is
$$
0=x_0 < \frac12=x_1 < 1 = x_2 < \frac32 = x_3 <\ldots < \frac92=x_9 < 5
= x_{10}
$$
So $x_j = \frac j2$ and each $\Delta x_j=\frac12$. 
For the left endpoints as tags, we have $t_j=x_{j-1}=\frac{j-1}{2}$.
We conclude
$$
\int_0^5\frac{dx}{1+x^2} < \sum_{j=1}^{10}
\frac{1}{1+(\frac{j-1}{2})^2}\times \frac12
\approx 1.61349
$$

Similarly, for the left endpoints as tags, we have $t_j=x_j=\frac
j{2}$. We conclude 
$$
\int_0^5\frac{dx}{1+x^2} < \sum_{j=1}^{10}
\frac{1}{1+(\frac{j-1}{2})^2}\times \frac12
\approx 1.13272
$$

{\small \sf Note: We will shortly see that the exact value of the
  integral is $\arctan 5\approx1.37340$. Clearly, for good numerical
  evaluation, a better estimate than Riemann sums is desirable. 
  The trapezoidal rule would yield the average of the two Riemann
  sums above, namely $\approx 1.37310$. The midpoint rule would be a
  separate calculation
  $\frac12\sum_{j=1}^{10}1/(1+(\frac{j-0.5}{2})^2) \approx
  1.37354$.}


\bigskip\newpage

\begin{quote}
\underline{\underline{\bf 5.}} \small
We'll get a 4-digit precise result for $\int_0^3\frac{dx}{x^2+3}$ here. 
You will like a programmable calculator for this, but the main work is still 
analytic work on the paper. Here is the philosophy of this problem: While
Riemann sums are good for theoretical purposes, a practical calculation will
give more precise results by using trapezoids rather than rectangles. 

(a) Calling $f(x):= 1/(x^2+3)$,  find out on which subinterval of $[0,3]$  we
have $f''(x)>0$ and $f''(x)<0$ respectively. 
Answer should be in the form ``$f''(x)<0$'' if $x<??$ and $f''(x)>0$
if $x>??$''. 

(b) Instead of nesting a small slice of area beneath the graph of $f$, from
$x_j$ to $x_{j+1}$, between rectangles, nest it between trapezoids: 
One trapezoid will have the oblique line connecting $(x_j,f(x_j))$ and 
$(x_{j+1},f(x_{j+1}))$, the other trapezoid will have the oblique line being a
tangent to the graph of $f$ at $x=\frac{1}{2}(x_j+x_{j+1})$. Which trapezoid
gives a lower bound for the area, which gives an upper bound, and how does the
answer depend on issues discussed previously?

(c) Write out a formula for the areas of the individual trapezoids involved in
the calculation, then sum up the appropriate areas to get an upper and a lower
bound for $\int_0^3\frac{dx}{x^2+3}$: choose 150 subintervals of
equal length in $[0,3]$.
Make sure that you select the midpoint rule for some intervals and the
trapezoidal for others, as discussed in (a) to get either an upper or
a lower bound for the integral. Now you may want to use technology and
get actual numerical values. 
\end{quote}

{\bf Solution: }

(a) First, $f'(x) = \frac{-2x}{(x^2+3)^2}$ and 
$f''(x) = \frac{-2(x^2+3)^2+4x(x^2+3)\,2x}{(x^2+3)^2} = 
\frac{6x^2-6}{(x^2+3)^3}$. 
So we have $f''(x)<0$ for $0\le x<1$ and $f''(x)>0$ for $x>1$. 

(b) When $f''(x)<0$, the trapezoid connecting $(x_j,f(x_j))$ and 
$(x_{j+1},f(x_{j+1}))$ underestimates the Riemann integral; the
trapezoid touching the graph of $f$ at the midpoint $(x_j+x_{j+1})/2$
overestimates the Riemann integral. (cf left picture)

\begin{picture}(60,155)(-15,-15)
\put(0,0){\special{psfile=hwk5fig.eps}}
\put(7,-12){$x_j$}
\put(46,-12){$x_{j+1}$}
\put(107,-12){$x_j$}
\put(146,-12){$x_{j+1}$}

\end{picture}

On the other hand (cf.\ right picture), when $f''(x)>0$, 
the trapezoid connecting $(x_j,f(x_j))$ and 
$(x_{j+1},f(x_{j+1}))$ overestimates the Riemann integral; the
trapezoid touching the graph of $f$ at the midpoint $(x_j+x_{j+1})/2$
underestimates the Riemann integral. 

(c) Dividing up the interval into 150 pieces, each will have width
$\frac1{50}$. According to part (a), in the interval $[0,1]$, we get
estimate $\int_0^1 \frac{dx}{x^2+3}$ from below by the trapezoid
method: 
$$
\int_0^1\frac{dx}{x^2+3} 
> \sum_{j=1}^{50} \frac1{50} \frac{f((j-1)/50)+f(j/50)}{2} =:
A_{1,tra}
\approx 0.302296
$$
and from above by the midpoint method: 
$$
\int_0^1\frac{dx}{x^2+3} 
< \sum_{j=1}^{50} \frac1{50} f\Bigl(\frac{j-1/2}{50}\Bigr) =:
A_{1,mid}
\approx 0.302302
$$
In the interval $[1,3]$, we get the estimate from above by the
trapezoid method 
$$
\int_1^3\frac{dx}{x^2+3} 
< \sum_{j=51}^{150} \frac1{50} \frac{f((j-1)/50)+f(j/50)}{2} =: A_{2,tra}
\approx 0.302303
$$
and from below by the midpoint method: 
$$
\int_1^3\frac{dx}{x^2+3} 
> \sum_{j=51}^{150} \frac1{50} f\Bigl(\frac{j-1/2}{50}\Bigr) =:
A_{2,mid}
\approx 0.302299
$$
So we find
$$
A_{1,tra}+A_{2,mid} \approx 0.604594
< \int_0^3\frac{dx}{x^2+3} < A_{1,mid}+ A_{2,tra} \approx 0.604605
$$

{\small\sf Note: It transpires, using the fundamental theorem of
  calculus, that 
$$
\int_0^1\frac{dx}{x^2+3} = 
\left[\frac1{\sqrt{3}} \arctan\frac{x}{\sqrt{3}}\right]_0^1
= \frac{\pi}{6\sqrt{3}}
$$
and 
$$
\int_1^3\frac{dx}{x^2+3} = 
\left[\frac1{\sqrt{3}} \arctan\frac{x}{\sqrt{3}}\right]_1^3
= \frac{\pi}{6\sqrt{3}}
$$ 
as well. So it is a coincidence of this particular problem that the
two parts of the integral are numerically so close to each other. 
}

\bigskip
\begin{quote}
\underline{\underline{\bf 6:}}
\small
Evaluate the following integrals (among the expected answers, there may be: 
``cannot do it with tools available'', or, ``integral may not exist
since integrand isn't piecewise continuous''):  
$$
\begin{array}{l@{\kern3cm}l} 
   \Dst(a) \quad        \int \cos x\,dx
& \Dst(b) \quad         \int \left(3x^3 -4\sin(2x)\right)\,dx
\\[2ex] \Dst(c) \quad   \int_2^7 \frac{1}{x^2}\,dx
& \Dst(d) \quad         \int_1^5 \frac{\sin x}{x} \,dx
\\[2ex] \Dst(e) \quad   \int_{-2}^2 \frac{1}{x^2}\,dx
& \Dst(f) \quad         \lim_{x\to\infty} \int_1^x t^{-3/2}\,dt
\\[2ex] \Dst(g) \quad   \int_0^1 x^2\, dx
& \Dst(h) \quad         \int_0^1 t^2\, dx
\end{array} 
$$
\end{quote}

{\bf Solution: }
$$
\begin{array}{l}\Dst
(a) \quad        \int \cos x\,dx = \sin x + C
\\[2ex]\Dst
(b) \quad         \int \left(3x^3 -4\sin(2x)\right)\,dx
= \frac{3}{4}x^4 + 2\cos(2x) + C
\\[2ex]\Dst
(c) \quad       \int_2^7 \frac{1}{x^2}\,dx = \left[-\frac1x\right]_2^7 = 
-\frac17+\frac12 = \frac5{14}
\\[2ex]\Dst
(d)\quad        \int_1^5 \frac{\sin x}{x} \,dx \qquad
 \mbox{ you're not expected to be able to do this} 
\\[2ex]\Dst
(e)\quad       \int_{-2}^2 \frac{1}{x^2}\,dx  \qquad
\mbox{ may not exist b/c integrand is not piecwise continuous on the
  interval }[-2,2] 
\end{array}
$$
{\sf 
Note that in (e) all you can say is `{\em may\/} not exist\ldots', i.e., raise
doubt. We had discussed in class that ``when $f$ is piecewise
continuous on an interval $[a,b]$, then $\int_a^b f(x)\,dx$ is
defined''. This guarantee does not apply for (e), because $1/x^2$ is
not piecewise continuous on $[-2,2]$. The above statement does not
rule out the possibility of other functions also having an integral,
and indeed there are examples of functions that have an integral
without being piecewise continuous. FYI, the present example is not of
this kind and indeed the integral {\em does\/} not exist. 
}

The next problem consists of two steps: first you are to calculate an
integral, then a limit of this integral. 
$$
\begin{array}{l}\Dst
\int_1^x t^{-3/2}\,dt = \left[-2t^{-1/2}\right]_1^x = -2 x^{-1/2} + 2
\\[2ex]\Dst
\mbox{Therefore} 
\lim_{x\to\infty} \int_1^x t^{-3/2}\,dt = 
\lim_{x\to\infty} (-2 x^{-1/2} + 2) = 2
\end{array}
$$
{\sf In textbooks, you find this type of problems under a special
  section `Improper integrals'. We will study them in more detail
  later. However, short of the name tag `improper integral', all we
  are having here is simply a combination of two known concepts. }
$$
(g) \quad   \int_0^1 x^2\, dx = \left[\frac13x^3\right]_0^1= \frac13
$$
(That was too easy.) --- In contrast, in the next problem, $t$ is {\em
  not\/} the integration variable. It is (short of any context
indicating otherwise) a constant. 
$$
(h) \quad   \int_0^1 t^2\, dx = \left[t^2x\right]_{x=0}^1=
t^2\cdot1 - t^2\cdot0 = t^2
$$
{\sf Note that I have enhanced the notation of the right bracket to
  avoid ambiguity: I have written $[\ldots]_{x=0}^1$ instead of merely
  $[\ldots]_0^1$, because two symbolic variables are present. }

\bigskip

\begin{quote}
\underline{\underline{\bf 7: }}\small 
Let 
$$
f(x):= \left\{ 
\begin{array}{ll} 
x^2 &\mbox{ if }|x|<1
\\
2|x|-1 &\mbox{ if } |x|\ge1
\end{array} 
\right.
$$
Find $\int_{-1}^3 f(x)\,dx$
\end{quote}
{\bf Solution: }
We need to split the integral depending on which formula applies: 
Between $-1$ and $1$, we have $f(x)=x^2$, and above 1, we have $f(x) =
2\abs{x}-1 = 2x-1$. So
$$
\begin{array}{l}\Dst
\int_{-1}^3 f(x) \,dx = \int_{-1}^1 f(x)\,dx + \int_1^3 f(x)\,dx = 
\int_{-1}^1 x^2\,dx + \int_1^3 (2x-1) dx = 
\left[\frac13x^3\right]_{-1}^1  + \left[x^2-x\right]_1^3 =\mbox{}
\\[2ex]\Dst\qquad\mbox{} = 
\frac13-\Bigl(-\frac13\Bigr) + 9-3 -(1-1) = \frac{20}{3}
\end{array}
$$
{\sf Note: Since in the case of piecewise continuous functions, 
  the integral does not depend on the value of the function in a
  single point, there is no need to worry about the fact that at the
  lower limit of integration $x=-1$, a different formula applies. ---
  In this particular example, there is no issue in any case, since
  both formulas $2\abs{x}-1$ and $x^2$ give the same value at the
  `seam' points $x=\pm1$, so I could have written ``$x^2$ for
  $\abs{x}\le 1$'' without changing the function. }

\bigskip

\begin{quote} \underline{\underline{\bf 8:}} \small
Take the same function $f$ as before.
Calculate 
$F(x) := \int_0^x f(t)\,dt$. The answer should be a formula that also involves
if's. 
Graph both $f$ and $F$ on the interval $[-2,2]$ in the same coordinate system.
(In this graphing job, a halfway decent handmade figure,  like what
I'd draw on the blackboard, is preferable to a print-quality
technology-generated figure.)
\end{quote}

{\bf Solution: }
If $\abs{x}<1$, then the whole interval of integration between 0
and~$x$ contains only such points~$t$ for which $\abs{t}<1$, and
therefore the formula $f(t)=t^2$ applies. (By the note in the previous
problem, the same conclusion applies for $\abs{x}\le1$.) 

So we calculate
$$
F(x):= \int _0^x t^2\,dt = \left[\frac{t^3}{3}\right]_0^x =
\frac{x^3}{3}
\qquad \mbox{ for }\quad \abs{x}\le1
$$

Now assume $\abs{x}>1$. Specifically, we consider $x>1$ first. Then we
have to split the integral at 1, as we did in the preceding problem,
and we calculate
$$
F(x):= \int_0^x f(t)\,dt = 
\int_0^1 t^2\,dt + \int_1^x (\underbrace{2\abs{t}-1}_{=2t-1})\,dt 
=\frac13 +\left[t^2-t\right]_1^x = x^2-x+\frac13
\qquad \mbox{ for }\quad x>1
$$
Likewise, we calculate for $x<-1$:
$$
F(x):= \int_0^x f(t)\,dt = 
\int_0^{-1} \! t^2\,dt + \int_{-1}^x \!(\underbrace{2\abs{t}-1}_{=-2t-1})\,dt 
=-\frac13 +\left[-t^2-t\right]_{-1}^x = -x^2-x-\frac13
\quad \mbox{ for}\quad x<-1
$$
{\sf Note: You could have used $\int_0^x = - \int_{x}^0$ to get the
  limits of integration into their natural order, but doing so is not
  necessary, even though it may be preferred for the `feelgood effect'.}

The figures are: 

\begin{minipage}{230bp}
{\unitlength 1bp
\begin{picture}(220,310)
\put(0,0){\special{psfile=hwk8fig.eps}}
\put(173,250){$f$}
\put(170,170){$F$}
\put(158,139){$1$}
\put(54,153){$-1$}
\put(113,197){$1$}
\end{picture}
}
\end{minipage}
\begin{minipage}{5cm}
$$\kern1em
F(x):= \left\{
\begin{array}{ll}
-x^2-x-\frac13 & \mbox{ for } x< -1 \\
\frac13 x^3    &  \mbox{ for } -1 \le x \le 1 \\
x^2-x+\frac13  & \mbox{ for } x>1
\end{array}
\right.
$$
\end{minipage}


\newpage

\begin{quote} \underline{\underline{\bf 9:}} \small
Find the following derivatives without attempting to evaluate the integrals
first. 
$$
\begin{array}{l@{\kern3cm}l} 
   \Dst(a) \quad       \frac{d}{dx} \int_0^x \sin^2 t\,dt
&  \Dst(b) \quad       \frac{d}{dx} \int_x^{50} (\sin^2 t)/t\,dt
\\[2ex] \Dst(c) \quad  \frac{d}{dx} \int_x^{2x} \frac{dt}{1+t^4}
& \Dst(d) \quad        \frac{d}{dx} \int_x^{2x} \frac{dt}{t}
\\[2ex] \Dst(e) \quad  \frac{d}{dx} \int_0^{\sin x} \frac{\sin t}{t^2+1}\,dt
& \Dst(f) \quad        \frac{d}{dx} \int_0^{x^2} g((t+1)^2)\,dt
\end{array} 
$$
\end{quote}
{\bf Solution: }
$$
\begin{array}{l}\Dst
\frac{d}{dx} \int_0^x \sin^2 t\,dt = \sin^2 x
\\[2ex] \Dst
\frac{d}{dx} \int_x^{50} (\sin^2 t)/t\,dt = - \frac{\sin^2x}{x}
\\[2ex]\Dst
\int_x^{2x} \frac{dt}{1+t^4} = \frac{2}{1+(2x)^4} - \frac{1}{1+x^4}
\\[2ex]\Dst
\int_x^{2x} \frac{dt}{t} = \frac{2}{2x} - \frac{1}{x} = 0
\\[2ex]\Dst
\frac{d}{dx} \int_0^{\sin x} \frac{\sin t}{t^2+1}\,dt = \frac{\cos x\,
  \sin(\sin x)}{\sin^2x+1} 
\\[2ex]\Dst
\frac{d}{dx} \int_0^{x^2} g((t+1)^2)\,dt = 
2x\,g((x^2+1)^2)
\end{array}
$$

\bigskip
\begin{quote} \underline{\underline{\bf 10:}} \small
Of the following three integrals, two are prohibitively difficult, one
is easy. Select the  easy one and calculate it:
$$
(a) \quad \int \sqrt{2+\sin x}\,dx\,,  \qquad
(b) \quad \int \cos x \sqrt{2+\sin x}\, dx\,, \qquad
(c) \quad \int \sin x \sqrt{2+\sin x}\, dx
$$
\end{quote}
{\bf Solution: } The manageable one is (b). The substitution $u=
2+\sin x$ (or just as well the similar substitution $v=\sin x$) gives
$$
\int \cos x \sqrt{2+\sin x}\, dx =  \int \sqrt{u}\,du = \frac23
u^{3/2} + C = \frac23 (2+\sin x)^{3/2}+C
$$


\def\rmk#1{_{\makebox[0pt][l]{%
      \raisebox{-2.5ex}{\kern-0.6em$\uparrow$}%
      \raisebox{-5.5ex}{\makebox[0pt]{\footnotesize$#1$}}%
}}}

\bigskip
\underline{\underline{\bf 11:}} 
$$
\int_1^2 \frac{e^{\sqrt{x}}}{\sqrt{x}}\,dx =\rmk{u=\sqrt{x}, \; du =
  \frac12 dx/\sqrt{x}} 
2\int_1^{\sqrt{2}} e^u\,du = 2(e^{\sqrt{2}}-e)
$$
{\sf Note: Numerical value by calculator is $2.78994$. ---
  Plausibility check in head: 1-term Riemann sum at midpoint is
  $e^{\sqrt{1.5}}/\sqrt{1.5} \approx e^{1.2}/1.2 \approx^*  e(1+0.2)/1.2
  \approx 2.8$. --- ($^*$) I used $e^{small}\approx 1+{small}$, approximating the
  graph with its tangent line near $x=0$.}

\underline{\underline{\bf 12:}} 
$$
\begin{array}{l}\Dst
\int_1^2\frac{\ln x}{x}\,dx = \rmk{u=\ln x,\; du = dx/x}
\int_0^{\ln 2} u\,du = \left[u^2/2\right]_0^{\ln 2} = \frac12 (\ln 2)^2
\\[7ex] \Dst
\int_2^4\frac{1}{x\,\ln x}\,dx= \rmk{u=\ln x,\; du = dx/x} 
\int_{\ln 2}^{\ln 4} \frac{du}{u} = \left[\ln u\right]_{\ln 2}^{\ln
  4}= \ln(\ln 4) - \ln (\ln 2)
= \ln \frac{\ln 4}{\ln 2} = \rmk{ \ln 4 = \ln(2^2) = 2\ln 2 }
\ln 2
\end{array}
$$
{\sf Note: Numerical value by calculator for the first integral is
  0.240227, for the second integral 0.693147. }

\underline{\underline{\bf 13:}} 
$$
\begin{array}{l}\Dst
\int_0^8 \sqrt{1+\sqrt{1+x}}\,dx = 
        \rmk{u=\sqrt{1+x},\; x= u^2-1,\; dx=2u\,du \kern6em} 
\int_1^3 2u \sqrt{1+u}\, du
= \rmk{ \kern6em v=\sqrt{1+u},\; du = 2v\,dv}
\int_{\sqrt{2}}^2 2(v^2-1)\,v\,2v\,dv
= \left[
\frac45 v^5 - \frac43 v^3 \right]_{\sqrt{2}}^2 = \mbox{}
\\[7ex]\Dst
\kern5em
\mbox{}= 
\frac{128}{5} - \frac{32}{3} - \frac{16}{5}\sqrt{2} + \frac83\sqrt{2}
=
\frac{224-8\sqrt2}{15}
\end{array}
$$
{\sf Note: Plausibility check in head: $\sqrt{2}$ is not quite 1.5, so
  make $8\sqrt{2}$ into approximately 11. Then $213/15 = 71/5 \approx
  14$. (The precise numerical value by calculator is 14.1791.) Looking
  at the integrand, it increases from $\sqrt{2}$ to $\sqrt{4}=2$, so
  the integral must be between $8\sqrt{2}\approx 11$ and $8\times2=16$,
  consistent with our calculation.}


\underline{\underline{\bf 14:}} 
$$
\int\tan x\,dx = 
\int\frac{\sin x}{\cos x}\,dx = \rmk{ u = \cos x} 
\int\frac{-du}{u} = -\ln u +C = -\ln \cos x + C
$$


\underline{\underline{\bf 15:}} 
$$
\int\frac{2dx}{e^x + e^{-x}}\,dx = \rmk{e^x = u,\; x=\ln u,\; dx=du/u} 
\int\frac {2 du}{u(u+u^{-1})} = \int\frac{2\,du}{u^2+1} = 2\arctan u +
C = 2\arctan e^x + C
$$

\underline{\underline{\bf 16:}} 
\begin{quote}\small
(a) Calculate $\int x^3 e^{-x}\,dx$. 
\\
(b) Given any positive integer $n$, express $\int_0^N x^n e^{-x}\,dx$ in 
terms of $\int_0^N x^{n-1} e^{-x}\,dx$. Then express $\lim_{N\to\infty} 
\int_0^N x^n e^{-x}\,dx$ in terms of $\lim_{N\to\infty}\int_0^N x^{n-1} 
e^{-x}\,dx$.
\\  
(c) Evaluate $\lim_{N\to\infty}\int_0^N x^{100} e^{-x}\,dx$. Rather than writing 
the result of a huge integer with over 150 digits, write it as a product of many 
1- and 2-digit numbers without further evaluation. 
\end{quote}
{\bf Solution: }
(a) We do three integrations by parts, deriving the power and
integrating the exponential:
$$
\begin{array}{l}\Dst
\int x^3 e^{-x}\,dx = x^3(-e^{-x}) + \int 3x^2 e^{-x}\,dx =
-x^3 e^{-x} - 3x^2 e^{-x} + \int 6x e^{-x}\,dx =
\mbox{} \\ \Dst \kern3em \mbox{}
= -x^3 e^{-x} - 3x^2 e^{-x} - 6x e^{-x} +  \int 6 e^{-x}\,dx =
-( x^3 + 3x^2 + 6x + 6 ) e^{-x} + C
\end{array}
$$
(b) A single integration by parts, just as before, gives
$$
\int_0^N x^n e^{-x}\,dx 
= \left[-x^n e^{-x}\right]_0^N + n\int_0^N x^{n-1} e^{-x}\,dx 
= -N^n e^{-N} + n\int_0^N x^{n-1} e^{-x}\,dx 
$$
when $n>0$. Taking the limit $N\to\infty$ kills the integrated term:
$$
\lim_{N\to\infty} \int_0^N x^n e^{-x}\,dx 
=  n\lim_{N\to\infty}\int_0^N x^{n-1} e^{-x}\,dx 
$$
(c) Let me use the abbreviation $\int_0^\infty$ for
$\lim_{N\to\infty}\int_0^N$. Using the result from (b) repeatedly, we
get
$$
\begin{array}{l}\Dst
\int_0^\infty x^{100} e^{-x}\,dx 
= 100 \times \int_0^\infty x^{99}e^{-x}\,dx 
= 100 \times 99 \times \int_0^\infty x^{98}e^{-x}\,dx = \mbox{}
\\[2ex]\kern3em\Dst \mbox{}
= 100 \times 99 \times 98\times \int_0^\infty x^{97}e^{-x}\,dx 
= \ldots =
100 \times 99 \times 98\times \ldots \times 1 \times \int_0^\infty
e^{-x}\,dx =\mbox{}
\\[2ex]\kern3em\Dst \mbox{}
= 100\times99\times\ldots\times 1 \quad \mbox{(which you may know to
  be abbreviated as }100!\,)
\end{array}
$$

\underline{\underline{\bf 17:}} 
$$
\begin{array}{l@{}l@{}l} \Dst
\int e^{2x}\,\cos 3x\, dx =\mbox{} &
\Dst \frac13 e^{2x}\sin 3x - \frac23\int e^{2x}\sin3x\,dx
&\Dst \mbox{}= 
\frac13 e^{2x}\sin 3x +\frac29 e^{2x}\cos3x - \frac49\int e^{2x}\cos3x\,dx
\\
\kern1.4em \downarrow \kern2.5em \uparrow & 
\kern8em \downarrow \kern2.25em\uparrow
\\[1.5ex]
\kern0.5em 2e^{2x} \kern1em  \frac13\sin3x &
\kern7em 2e^{2x}\kern0.8em {-\frac13}\cos3x
\end{array}
$$ 
After two IBPs we are back to the original integral.
We read this calculation as an equation to be solved for the unknown
integral, i.e., moving the integral to the left, we conclude
$$
\frac{13}{9}\int e^{2x}\,\cos 3x\, dx = 
\frac13 e^{2x}\sin 3x +\frac29 e^{2x}\cos3x 
$$
hence
$$
\int e^{2x}\,\cos 3x\, dx = 
\frac1{13} e^{2x}(3\sin 3x + 2 \cos3x) + C
$$

\underline{\underline{\bf 18:}} (assuming $a>0$)
$$
\begin{array}{l@{}l@{}l}\Dst
\int_a^1 x^2\,(\ln x)^2\,dx = \mbox{} & \Dst
\left[\frac{x^3}{3}(\ln x)^2\right]_a^1 - \frac23\int_a^1 x^2\,\ln x\,dx
= \mbox{} & \Dst
-\frac{a^3}{3}(\ln a)^2 - \left[\frac29x^3\ln x\right]_a^1
+\frac29\int_a^1 x^2\,dx
\\
\kern1.8em\uparrow\kern1.5em\downarrow & 
\kern 9.3em\uparrow \kern1.4em\downarrow
\\[1.4ex]
\kern1em \frac13x^3 \kern1em \frac{2\ln x}{x} &
\kern8.8em \frac13x^3 \kern1.0em \frac1x
\\[6ex]
&\Dst\mbox{}= -\frac{a^3}{3}(\ln a)^2 + \frac 29 a^3\ln a +
\frac2{27}(1-a^3) \kern-10em
\end{array}
$$
Therefore 
$$
\lim_{a\to0+} \int_a^1 x^2(\ln x)^2\,dx
=
\frac2{27}
$$


\underline{\underline{\bf 19:}}
$$
\int_0^4 e^{-\sqrt{x}}\,dx = \rmk{\sqrt{x}=u,\; dx=2u\,du\kern1em} 
\int_0^2 2u e^{-u}\,du
= \rmk{\kern1em\mbox{IBP as in \#16}}
\left[-2u\,e^{-u}\right]_0^2 + \int_0^2 2 e^{-u}\,du
=
\left[-2ue^{-u} - 2e^{-u}\right]_0^2 = 2 - 6 e^{-2}
$$

\underline{\underline{\bf 20:}} IBP applied to $1\times\arcsin x$ with
$1$ being integrated and $\arcsin x$ being differentiated; the
remaining integral can then be handled by substitution:
$$
\int\arcsin x\,dx = x\arcsin x - \int\frac{x}{\sqrt{1-x^2}}\,dx = 
\rmk{1-x^2=u,\;x\,dx=-\frac12\,du} x\arcsin x + \frac12\int
u^{-1/2}\,du
= x\arcsin x + \sqrt{1-x^2} + C
$$

\underline{\underline{\bf 21:}}
$$
\int\frac{\ln(\ln x)\, \ln x}{x}\, dx = \rmk{\ln x = u,\; du =
  \frac{dx}{x}} 
\int u\ln u\,du = \rmk{\mbox{IBP}}
\frac{u^2}{2}\ln u - \int\frac u2\,du
= \frac{u^2}{2}\ln u - \frac {u^2}{4} + C
= \frac{(\ln x)^2\,\ln(\ln x)}{2} -\frac{(\ln x)^2}{4} + C
$$

\underline{\underline{\bf 22:}}
$$
\begin{array}{l}\Dst
\int_1^4\sqrt{x}\,\ln x\,dx = \rmk{\sqrt{x}=u,\;x=u^2,\;dx=2u\,du}
\int_1^2 2u^2\,\ln(u^2)\,du = 4\int_1^2 u^2\ln u\,du =
\rmk{\mbox{IBP}}
\left[4\frac{u^3}{3}\ln u\right]_1^2
-4\int_1^2\frac{u^3}{3}\,\frac1u\,du
=\mbox{}\\[6ex]\Dst\kern4em \mbox{}
=\frac{32}3\ln 2 - 4\left[\frac{u^3}{9}\right]_1^2 
=\frac{32}3\ln 2 - \frac{28}9 
\end{array}
$$

\underline{\underline{\bf 23:}} (quote of problem abridged here:)
\begin{quote}\small
{\sf M.I.~Shap  had forgotten the antiderivative of
$\frac1{x^2+1}$.  So he attempted integration by parts, using $u'=1$
and $v=\frac{1}{x^2+1}$.}

{\bf Task 1: } Carry out M.I.~Shap's calculation and see what integral
he obtained. 

{\bf Task 2: }(too easy)
$$\int \frac{dx}{x^2+1} = ???$$

Using this simple piece of algebra:
$$
\frac{x^2}{(x^2+1)^2} = \frac{x^2+1}{(x^2+1)^2} - \frac{1}{(x^2+1)^2} 
$$
and using the trick of going around in circles
(and be known as a big wheel for it), do the next task:

{\bf Task 3: }Evaluate $\Dst\int\frac{dx}{(x^2+1)^2}$.

{\bf Task 4: }Now evaluate $\Dst\int\frac{dx}{(x^2+a^2)^2}$. 

  ``I have done it once, I can do it again''

{\bf Task 5: }Evaluate $\Dst\int\frac{dx}{(x^2+1)^3}$
\end{quote}

{\bf Solution: }\\
{\bf Task 1:} Integration by parts on $\int\frac1{x^2+1}\,dx$:
$$
\int 1\times \frac{1}{x^2+1} \, dx = \frac{x}{x^2+1} - \int
x\,\frac{-2x}{(x^2+1)^2}\, dx = 
\frac{x}{x^2+1} + 2 \int \frac{x^2}{(x^2+1)^2}\,dx
$$
{\bf Task 2: }
$$
\int \frac{1}{x^2+1} \, dx = \arctan x + C
$$
{\bf Task 3: } Using the hint $
\frac{x^2}{(x^2+1)^2} = \frac{x^2+1}{(x^2+1)^2} - \frac{1}{(x^2+1)^2} 
$, salvage the work from the previous task to evaluate the new
integral $\int dx/(x^2+1)^2$: 

$$
\int\frac1{x^2+1}\,dx = \rmk{\mbox{ from Task 1}} 
\frac{x}{x^2+1} +2 \int\frac{x^2}{(x^2+1)^2}\,dx = 
\rmk{\mbox{from hint}}
\frac{x}{x^2+1} +2 \int\frac{1}{x^2+1}\,dx -2 \int\frac{1}{(x^2+1)^2}\,dx
$$
Substituting the {\em known\/} integral $\int\frac1{x^2+1}\,dx =
\arctan x+C$ (as in Task 2) and solving for the unknown 
$\int\frac1{(x^2+1)^2}\,dx$, we get
$$
\int\frac1{(x^2+1)^2}\,dx =
\frac12\left(\frac{x}{x^2+1}+\int\frac{1}{x^2+1}\,dx\right) =
 \frac12  \left(\frac{x}{x^2+1}+\arctan x\right) +C
$$
{\bf Task 4: }To evaluate $\Dst\int\frac{dx}{(x^2+a^2)^2}$, we could
either redo the previous steps, starting with $\int dx/(x^2+a^2)$
instead of $\int dx/(x^2+1)$ (correct, but unnecessarily complicated);
or else we reduce it to the case $a=1$ with a simple substitution:
$$
\begin{array}{l}\Dst
\int\frac{dx}{(x^2+a^2)^2} = \rmk{x=at,\;dx = a\,dt} 
\int \frac{a\,dt}{(a^2 t^2 + a^2)^2} = 
a^{-3} \int\frac{dt}{(t^2+1)^2} = 
\frac12 a^{-3} \left(\frac{t}{t^2+1} + \arctan t\right) +C
= \mbox{}
\\[6.5ex]\kern4em\Dst\mbox{} = 
\frac12 a^{-3} \left(\frac{x/a}{(x/a)^2+1} + \arctan \frac xa\right)
+C
=
\frac12 a^{-2} \left(\frac{x}{x^2+a^2} + \frac1a\arctan \frac
xa\right) +C
\end{array}
$$

{\bf Task 5: } This time, we use the integration by parts --Task 1
style-- on the (now known) $\int dx/(x^2+1)^2$, obtaining (with
similar algebra as in Task 3) the new integral $\int dx/(x^2+1)^3$:
$$
\int 1\times \frac{1}{(x^2+1)^2} \, dx = \frac{x}{(x^2+1)^2} - \int
x\,\frac{-2\cdot 2x}{(x^2+1)^3}\, dx = 
\frac{x}{(x^2+1)^2} + 4 \int \frac{x^2}{(x^2+1)^3}\,dx
$$
Using $\frac{x^2}{(x^2+1)^3} = \frac{x^2+1}{(x^2+1)^3} -
\frac{1}{(x^2+1)^3}$, and solving for the new unknown integral, we get
$$
4\int\frac{dx}{(x^2+1)^3} = \frac{x}{(x^2+1)^2} + 3\int \frac{dx}{(x^2+1)^2}
$$
and therefore
$$
\int\frac{dx}{(x^2+1)^3} = \frac14\left( 
\frac{x}{(x^2+1)^2} + \frac32\,\frac{x}{x^2+1} + \frac32 \arctan x 
\right) + C
$$


\bigskip
\begin{quote}
\underline{\underline{\bf 24:}} 
Sometimes, definite integrals can be determined without finding an antiderivative: 
(a) Find $\int_{-7}^7 \frac{\sin x\,dx}{x^4+1}$ without attempting to obtain 
an antiderivative. Give a quick sketch of the graph of  the function
under the integral sign to illustrate your reasoning.
--- (b) Use the substitution $y=-x$ on the integral to confirm your
conclusion algebraically. 
\end{quote}
{\bf Solution: } (a)
The function $f$ given by $f(x) = \frac{\sin x}{x^4+1}$ is 
{\em odd\/}, i.e., $f(-x) = -f(x)$.  So whatever area is above the
$x$-axis for $x>0$ is matched with a corresponding area below the
$x$-axis for $x<0$ (and vice versa: what is below the $x$-axis for
$x>0$ is matched by a corresponding area above the $x$-axis for
$x<0$.) Since we are integrating over a symmetric interval $[-7,7]$,
the contributions cancel out, and the integral is~$0$. 
Here is a graph of $f$:

\begin{picture}(420,180)
\put(0,0){\special{psfile=hwk24fig.eps}}
\put(250,70){Between $\pi$ and $2\pi$, the function is negative,}
\put(250,57){but of such a small absolute value that the }
\put(250,44){figure does not resolve it.}
\end{picture}

(b) Letting $I:= \int_{-7}^7\frac{\sin x}{x^4+1}\,dx$, and substituting
$x=-y$ gives
$$
I = \int_{+7}^{-7} \frac{\sin(-y)}{(-y)^4+1}\, (-1) dy
= 
\int_{-7}^7 \frac{-\sin y}{y^4+1}\,dy = -I
$$
Since $I=-I$, we conclude that $I$ must be 0. 


\bigskip
\begin{quote}
\underline{\underline{\bf 25:}} 
(a) Describe the graph $y=\sqrt{25-x^2}$ in geometric terms. Based on this
deliberation, what should $\int_{-5}^5\sqrt{5-x^2}\,dx$ be? 
---
(b) Use an appropriate trig substitution to verify your conclusion
calculationally.
\end{quote}
{\bf Solution: }
(a) The graph is a semi-circle with radius~5. The area underneath this
graph should therefore be $\frac12\,\pi\,5^2$. 
\\
(b) Using the substitution $x=5\sin u$, with $u$ between $-\frac\pi2$
and $\frac\pi2$, we calculate
$\int_{-5}^5\sqrt{25-x^2}\,dx= \int_{-\pi/2}^{\pi/2} 
25\cos^2u\,du = \left[\frac{25}{2} (u+\sin u\,\cos
  u)\right]_{-\pi/2}^{\pi/2} = \frac{25}{2}\pi$. 

\bigskip
\begin{quote}
\underline{\underline{\bf 26:}} 
You sure know that $\cos x\le 1$ for all $x$, and probably also that
$\sin x \le x$ for $x>0$. But you may not know yet that $\cos x \ge
1-\frac12x^2$ for all $x$, and that $\sin x\ge x-\frac16 x^3$ for
$x>0$. 
In this homework, you'll see why this is the case (and a bit more). 

Recall: If $f(x)\le g(x)$ for $x\in[a,b]$, then $\int_a^b f(x)\,dx \le
\int_a^b g(x)\,dx$. 

(a) Integrate the inequality $\cos t\le 1$ for all $t$ over the
interval $[0,x]$, with $x>0$. What inequality do you obtain?

(b) Next integrate the inequality so obtained (renaming the variable
into $t$) over the interval $[0,x]$ again and solve for the trig
function. What inequality do you now obtain?

(c) Repeat the procedure three more times, obtaining new inequalities
for $\sin x$ or $\cos x$ in each step. 

(d) Use the best of these inequalities to nest the values of
$\cos\frac12$ and $\sin\frac12$ between values easily calculated by
hand; i.e., find rational numbers for the `?' to make 
$?_1 \le \cos \frac12 \le {?_2}$  and $?_3 \le \sin \frac12 \le {?_4}$  
true. None of your calc's will require a pocket calculator (except possibly 
for converting fractions to decimals in the very end). 
\end{quote}
{\bf Solution: }
(a) We obtain $\int_0^x\cos t\,dt \le \int_0^x 1\,dt$, which
simplifies to $\sin x \le x$.

(b) Integrating $\sin t \le t$ over the interval $[0,x]$, we obtain 
$\int_0^x\sin t\,dt \le \int_0^x t\,dt$. This is $1-\cos x \le
\frac12x^2$. Solving for the trig, we obtain  $\cos x \ge 1-\frac12
x^2$. 

(c) Integrating $\cos t \ge 1-\frac12t^2$ over $[0,x]$, we obtain 
$ \int_0^x \cos t\,dt \ge \int_0^x (1-\frac12t^2)\,dt$, which
evaluates to 
$\sin x \ge x-\frac16x^3$. 

Next, we integrate $\sin t \ge t-\frac16t^3$ over $[0,x]$ and obtain
$ 1-\cos x \ge \frac12x^2 - \frac1{24} x^4$ and therefore
$\cos x \le 1-  \frac12x^2 + \frac1{24} x^4$.

Now integrating this again, we obtain 
$\int_0^x \cos t\,dx  \le \int_0^x (1-  \frac12t^2 + \frac1{24}
t^4)\,dt$, in other words,
$\sin x \le x-\frac16 x^3 + \frac{1}{120} x^5$. 

(d) We find $1-\frac12(\frac12)^2 \le \cos \frac12 \le
1-\frac12(\frac12)^2 + \frac1{24}(\frac12)^4$, which is
$\frac78\le\cos\frac12\le \frac78+\frac1{384}$. 
In decimals (with 6 digits accuracy), this is 
$0.875000 \le\cos\frac12 \le 0.877605$

Likewise for $\sin\frac12$, we conclude 
$\frac12-\frac16(\frac12)^3 \le \sin\frac12 \le
\frac12-\frac16(\frac12)^3 + \frac1{120}(\frac12)^5$, 
which in decimals amounts to:
$0.479166 \le \sin\frac12 \le 0.479428$.

[When converting to decimals, I have chosen always to round {\em up\/}
  the upper bounds and to round {\em down\/} the lower bounds, such as
  to have {\em certain\/} estimates.]

\bigskip

$$
\int \frac{dx}{(4-x^2)^{3/2}} = \rmk{x=2\sin u \quad (^*)} \int \frac{2\cos
  u\,du}{8\cos^3 u} = \frac14 \tan u + C = \frac{x/8}{\sqrt{1-(x/2)^2}} + C =
\frac{x/4}{\sqrt{4-x^2}} +C
\leqno{\underline{\underline{\bf 27a:}}} 
$$
$(^*)$ Clearly $\abs{x}<2$, else the original integral wouldn't make
sense. We may (and do) choose $u$ between $-\frac\pi2$ and
$\frac\pi2$, hence $\cos u>0$. This is why no absolute value arises in
$(4\cos^2 u)^{3/2} = 8 \cos^3 u$. 

$$
\int (4-x^2)^{3/2}\,dx = \rmk{x=2\sin u} \int (4\cos^2 u)^{3/2}\,
2\cos u\,du = 16\int \cos^4 u\,du
\leqno{\underline{\underline{\bf 27b:}}} 
$$
We finish this up with integration by parts:
$$
\begin{array}{l@{}l@{}l}\Dst
\int \cos^4 u\,du = \mbox{} & \Dst \int \cos^3 u\,\cos u\,du = 
\mbox{} & \Dst  \cos^3 u \sin u + 3\int \cos^2u \underbrace{\sin^2
  u_{\rule{0pt}{0pt}}}_{1-\cos^2 u}\,du 
% = \cos^3 u \sin u + 3\int \cos^2u \,du - 3\int \cos^4 u\,du
\\ & \Dst
\kern2em \downarrow \kern2.8em \uparrow
\\[1ex] & \Dst
\kern-2.5em -3\cos^2 u\,\sin u \kern 1em \sin u
\end{array}
$$
Therefore 
$$
4\int \cos^4 u\,du \,=\, \cos^3 u \sin u + 3 \int \cos^2 u\,du \,=\, 
\cos^3 u \sin u + \frac32\left( u+ \cos u\,\sin u\right) +C
$$
Inserting and undoing the substitution, in particular $\cos^2 u =
1-(\frac x2)^2$, we get
$$
\begin{array}{l@{}l}\Dst
\int (4-x^2)^{3/2}\,dx & \Dst   \mbox{} = 
4\left(1-({\Tst\frac{x}{2}})^2\right)^{3/2} (x/2) + 6
\left( \arcsin\frac x2 + \frac x2\sqrt{1-(x/2)^2}
\right)+C
\\[2ex]&\Dst =
\frac x4 (4-x^2)^{3/2} + 6\arcsin\frac x2 + \frac32 x\sqrt{4-x^2} + C
\end{array}
$$

$$
\int \frac{x^2}{\sqrt{x^2+1}}\,dx = 
       \rmk{x=\tan u\,,\; dx= du/\cos^2 u\,,\; 1+x^2 =
         1/\cos^2u } 
\int \frac{\tan^2u\,\cos u}{\cos^2u}\,du
= \int \frac{\sin^2 u}{\cos^3 u}\, du
%= \rmk{ \sin u = y} \int \frac{y^2}{(1-y^2)^2}\,dy
\leqno{\underline{\underline{\bf 27c^*:}}} 
$$
Again we may and do choose $\abs u < \frac\pi2$ so that $\cos u>0$ and
no absolute value is needed when taking the square root of $\cos^2
u$. {\sf (The same remark will apply in the following problems without being
repeated each time.)}

$$
\int \sqrt{x^2+x+1}\,dx = \int\sqrt{\Tst (x+\frac12)^2 + \frac34}\,dx
= \rmk{x+\frac12 = (\sqrt3/2)\tan u}
\int\sqrt{\frac{3/4}{\cos^2u}} \frac{\sqrt{3}}{2}\,\frac{du}{\cos^2 u}
=\frac34\int\frac{du}{\cos^3u} 
\leqno{\underline{\underline{\bf 27d^*:}}} 
$$

$$
\int \sqrt{(x-1)(x-3)}\,dx = 
\int \sqrt{(x-2)^2 -1}\,dx = 
\rmk{x-2 = 1/\cos u\,,\;dx= \sin u\,du/\cos^2 u}
\int\tan u\,\frac{\sin u\, du}{\cos^2 u}
=
\int\frac{\sin^2 u\, du}{\cos^3 u}
\leqno{\underline{\underline{\bf 27e^*:}}} 
$$
We have assumed $x>3$ here. (Clearly the root is real only when $x>3$
or $x<1$.) This makes $x-2>1$ and therefore $\cos u>0$. We may assume
$u$ to be between 0 and $\frac\pi2$, hence $\tan u>0$. In contrast, if
we had $x<1$,
we'd have $\cos u<0$, and we would need to assume $u$ between
$\frac\pi2$ and $\pi$. Then $\tan u$ would be negative and
$\sqrt{\frac{1}{\cos^2 u}-1}$ would be $-\tan u$ rather than $\tan u$.  

$$
\int_1^4 \frac{x}{1+\sqrt{x^4+1}}\,dx = \rmk{x^2 = y}
\frac12\int_1^{16} \frac{dy}{1+\sqrt{y^2+1}} 
= \rmk{ y= \tan u} 
\frac12\int_{\arctan 1}^{\arctan 16} \frac{du}{\cos^2 u\,(1+ 1/\cos u)}
\leqno{\underline{\underline{\bf 27f^*:}}} 
$$


$$
\begin{array}{l@{}l}\Dst
\int\frac{\arcsin x}{x^2} \,dx
& \Dst \mbox{} = \int\arcsin x \cdot \frac{1}{x^2}\, dx = 
-\frac{\arcsin x}{x} +\int \frac{dx}{x\sqrt{1-x^2}}
\\
&\Dst \kern4em\downarrow\kern2.5em\uparrow
\\[1ex] &\Tst
\kern3em \frac{1}{\sqrt{1-x^2}} \kern1em \frac{-1}{x}
\end{array}
\leqno{\underline{\underline{\bf 27g:}}} 
$$
Now we can treat the remaining integral with a trig substitution:
$$
\begin{array}{l}\Dst
\int \frac{dx}{x\sqrt{1-x^2}}
= \rmk{x=\sin u}
 \int \frac{du}{\sin u}
=\int\frac{\sin u\,du }{1-\cos^2 u} = 
\rmk{\cos u = y} \int\frac{-dy}{1-y^2} = 
-\frac12\int\left(\frac1{1-y} + \frac1{1+y}\right)\,dy =\mbox{}
\\[7ex]\Dst \kern5em \mbox{} = 
\frac12\Bigl(\ln(1-y)-\ln(1+y)\Bigr)+C
=\frac12\ln\frac{1-\cos u}{1+\cos u}+C
=
\frac12\ln\frac{1-\sqrt{1-x^2}}{1+\sqrt{1-x^2}}+C
\end{array}
$$
Here $y$ is between 0 and 1, so $1-y$ and $1+y$ are positive and no
absolute value is needed in under the logarithm. 

Note that a variety of versions are possible in the final result. For
instance, expanding the fraction with $1-\sqrt{1-x^2}$ to get the root
out of the denominator yields $\ln \frac{1-\sqrt{1-x^2}}{x} + C$, at
least if $x>0$; for $x<0$, you'd have to write 
$\ln \frac{1-\sqrt{1-x^2}}{\abs{x}} + C$ instead.

$$
\int_0^1\sqrt{\frac{1-x}{1+x}}\,dx
=
\int_0^1\frac{1-x}{\sqrt{1-x^2}}\,dx = \rmk{x=\sin u}
\int_0^{\pi/2}\frac{1-\sin u}{\cos u}\,\cos u\,du
=
\left[ u+\cos u\right]_{0}^{\pi/2} = \frac{\pi}2
-1
\leqno{\underline{\underline{\bf 27h:}}} 
$$
{\sf Here we have a convenient plausibility check: The integral is
  clearly $<\int_0^1 1\,dx=1$ and $>\int_0^1(1-x)\,dx=\frac12$. The
  calculated result is numerically $\approx0.571$, consistent with the
  plausibility check. Also the midpoint rule with just one interval
  yields $1\cdot \sqrt{\frac{1/2}{3/2}} = \frac13\sqrt{3}\approx
  0.577$. }

\newpage

\begin{quote}
\underline{\underline{\bf 28:}} 
In one of the examples of the previous problem, the trig substitution could be avoided, and
a simple power substitution would work instead. Find which of them it
is and also carry out the power substitution for comparison. 
\end{quote}
{\bf Solution: }
If, for the quadratic under the square root, we have its derivative
explicitly available to combine with $dx$, then we can substitute the
quadratic, rather than using a trigonometric substitution. This
happens in \#27g:
$$
\int \frac{dx}{x\sqrt{1-x^2}} = \int\frac{x\,dx}{x^2\sqrt{1-x^2}} =
\rmk{1-x^2 = v\,,\;-2x\,dx=dv\kern2em} 
-\frac12 \int\frac{dv}{(1-v)\sqrt{v}} 
=\rmk{\kern2em\sqrt{v}=y\,,\;dy=dv/2\sqrt{v}} -\int\frac{dy}{1-y^2}
$$
But now we are back to the same integral as in 27g, and the finish-up
is the same as before. 


\begin{quote}
\underline{\underline{\bf 29:}}
Redo  all problems of the previous list (\#27 a--h), using a hyperbolic
substitution instead of the trig substitution. Subsequently get rid of
the hyperbolics by expressing them as exponentials and substituting
$e^t = y$ (assuming $t$ is what you named the new variable in the hyp substitution.)
If you end up with a rational expression in $y$ that is {\em not\/}
routine to integrate, you may stop here; we'll return to this task
later. Otherwise, finish them up. If possible, draw a resume whether
you feel the hyperbolic or the trigonometric substitution was easier.
\end{quote}

{\bf Solution: }
$$
\int \frac{dx}{(4-x^2)^{3/2}} = \rmk{x=2\tanh t}
\int \frac{2dt/\cosh^2 t}{(4/\cosh^2t)^{3/2}} 
=
\frac14\int \cosh t\, dt = \frac14 \sinh t + C
\leqno{\underline{\underline{\bf 29a:}}} 
$$
Undoing the substitution to get $\frac14\sinh(\artanh\frac x2)+C$ is
straightforward, but hyperbolics of inverse hyperbolics should be
simplified, and I wouldn't expect you to have much knowledge about
inverse hyperbolics available anyways. So here we go `the pedestrian
way':
If $\frac x2 = \tanh t = \frac{e^t - e^{-t}}{e^t+e^{-t}} =
\frac{e^{2t}-1}{e^{2t}+1}$, then solving for $e^{2t}$ is easy: 
$e^{2t} = (1+\frac x2)/(1-\frac x2)$. So $e^t =
\sqrt{\frac{2+x}{2-x}}$. This means $\sinh t = \frac12(e^t-e^{-t}) = 
\frac12 (\sqrt{\frac{2+x}{2-x}} - \sqrt{\frac{2-x}{2+x}})$. 
Conclusion:
$$
\int \frac{dx}{(4-x^2)^{3/2}} = \frac18\left(
\sqrt{\frac{2+x}{2-x}} - \sqrt{\frac{2-x}{2+x}}
\right) + C
=\rmk{\mbox{common denominator $\sqrt{4-x^2}$}}
\frac18\frac{(2+x)-(2-x)}{\sqrt{4-x^2}} + C = \frac{x}{4\sqrt{4-x^2}}+C
$$
{\sf Here the hyperbolic subsitution gave an easy integral, but
  returning to the orginal variables was lengthy. So this time the
  trig sub seems easier.}

$$
\int (4-x^2)^{3/2}\,dx = \rmk{x=2\tanh t}
\int \Bigl(\frac{4}{\cosh^2t}\Bigr)^{3/2} \frac{2dt}{\cosh^2 t} =
\int\frac{16\,dt}{\cosh^5 t} =
\int\frac{16\cdot32 dt}{(e^t+e^{-t})^5} = \int\frac{2^9 e^{5t}\,dt}{(e^{2t}+1)^5}
\leqno{\underline{\underline{\bf 29b:}}} 
$$
The standard sub is  $e^t = y$, $e^t\,dt = dy$; so we can continue
$$
\ldots = 2^9 \int \frac{y^4 \,dy}{(y^2+1)^5}
$$
You may stop here until we learn the algebra to integrate rational
functions, but there is one sneaky thing you could do first to
simplify matters: borrow
one factor $y$ to go with the denominator for an integration by parts:
$$
\begin{array}{l@{}l@{}l} \Dst
\int y^3 \,\frac{y}{(y^2+1)^5}\, dy & \Dst \mbox{} =
-\frac{y^3}{8(y^4+1)^4} + \frac38\int y\, \frac{y}{(y^2+1)^4}\,dy
& \Tst \mbox{} =
-\frac{y^3}{8(y^4+1)^4} -\frac{y}{16(y^2+1)^3} + \frac1{16}\int \frac{dy}{(y^2+1)^3}
\\
\kern1.3em\downarrow\kern2.2em\uparrow
&\kern10em \downarrow\kern2.2em\uparrow
\\[1ex]
\Dst \kern0.5em 3y^2 \kern1em \Tst\frac{-1/8}{(y^2+1)^4}
&\Dst\kern10em 1 \kern1em \Tst\frac{-1/6}{(y^2+1)^3}
\end{array}
$$
Hey, we're lucky; Miss Happy's hwk \#23 will take care of the rest:
$$
2^9\int\frac{y^4\,dy}{(y^2+1)^5} = \frac{-2^6 y^3}{(y^2+1)^4} -
\frac{2^5 y}{(y^2+1)^3} + 
\frac{8y}{(y^2+1)^2} + \frac{12y}{y^2+1} + 12 \arctan y 
 + C
$$
As before, we argue that, if $\frac x2=\tanh t$, then
$y=e^t=\sqrt{\frac{2+x}{2-x}}$; and therefore $y^2+1 = \frac{4}{2-x}$.
So we
get
$$
\begin{array}{l}\Dst 
\int(4-x^2)^{3/2}\,dx = -
\frac{(2-x)^4}{4}\,\frac{(2+x)^{3/2}}{(2-x)^{3/2}} -
\frac{(2-x)^3}{2}\,\frac{(2+x)^{1/2}}{(2-x)^{1/2}} +
\frac{(2-x)^2}{2}\,\frac{(2+x)^{1/2}}{(2-x)^{1/2}} +\mbox{}
\\[2ex] \kern9em \Dst\mbox{} +
3(2-x)\,\frac{(2+x)^{1/2}}{(2-x)^{1/2}} + 
12\arctan\sqrt{\frac{2+x}{2-x}} + C
\\[2ex]\Dst \kern3em \mbox{}
=\frac14\sqrt{4-x^2}\Bigl( -(2-x)^2(2+x) - 2(2-x)^2 +2(2-x) +12
\Bigr) + 12\arctan\sqrt{\frac{2+x}{2-x}} + C
\\[2ex]\Dst \kern3em \mbox{}
=\frac{10x-4x^3}{4}\sqrt{4-x^2} + 12\arctan\sqrt{\frac{2+x}{2-x}} + C
\end{array}
$$
{\sf Both trig and hyp subs were a bit lengthy, but still it looks
  like trig has an edge here. --- Note also that the results do not
  {\em look\/} like they are the same; but that doesn't mean they
  aren't. We'd have to do some algebra to convert the arctan into an
  arcsin to see this. }

$$
\int \frac{x^2}{\sqrt{x^2+1}}\,dx = \rmk{x = \sinh t}
\int\frac{\sinh^2 t\,\cosh t\,dt}{\cosh t} = 
\frac14 \int (e^{2t}-2+e^{-2t})\,dt = \frac18\Bigl( e^{2t} - e^{-2t} -
4t \Bigr) + C
\leqno{\underline{\underline{\bf 29c:}}} 
$$
To undo the substitution, we need to solve for $t$: Yes, that's
$t=\arsinh x$ (if you are familiar with inverse hyperbolics), but we
can express this with logarithms (since hyperbolics can be expressed
in terms of exponentials), and we sure want  to simplify $e^t$, which
should  feature the undoing of a logarithm by the exponential. 
So here we go:
$2x = e^t - e^{-t}$, hence $(e^t)^2 -2x (e^t) - 1 = 0$. Therefore 
$e^t = x \pm \sqrt{x^2+1}$ (and we can discard the $-$ sign since
$e^t>0$). In conclusion we get
$$
\begin{array}{l}\Dst
\int \frac{x^2}{\sqrt{x^2+1}}\,dx = \frac18\Bigl(
(x+\sqrt{x^2+1})^2 - (x-\sqrt{x^2+1})^2 - 4 \ln(x+\sqrt{x^2+1})
\Bigr)+C
\\[2ex]\Dst
\kern6.2em \mbox{}
=
\frac12\Bigl(x\sqrt{x^2+1} - \ln (x+\sqrt{x^2+1}) \Bigr) + C
\end{array}
$$
{\sf That looks easier than the trig sub; in particular since we are
  done already with the hyperbolic, whereas there is still unfinished
  work to do on the trig sub. }

$$
\int \sqrt{x^2+x+1}\,dx = \int\sqrt{\Tst (x+\frac12)^2 + \frac34}\,dx 
= \rmk{x+\frac12 = (\sqrt{3}/2) \sinh t} 
\frac34\int \cosh^2 t\,dt = \frac3{16}\int\Bigl( e^{2t}+e^{-2t}+2 \Bigr)\,dt
\leqno{\underline{\underline{\bf 29d:}}} 
$$
which is $\frac3{32}(e^{2t}-e^{-2t}+4t)+C$. 
The further evaluation is as in \#29c, with only a minor change;
namely 
$$
e^{\pm t} = \pm \frac{x+1/2}{\sqrt{3}/2} +
\sqrt{\Bigl(\frac{x+1/2}{\sqrt{3}/2}\Bigr)^2+1}
= \frac{\pm(2x+1)+2\sqrt{x^2+x+1}}{\sqrt{3}}
$$
So
$$
\begin{array}{l}\Dst
\int \sqrt{x^2+x+1}\,dx  =  \frac3{32}\Bigl( 
\frac{(2x+1+2\sqrt{x^2+x+1})^2}{3}-\frac{(-(2x+1)+2\sqrt{x^2+x+1})^2}{3}  +4t \Bigr) +C 
\\[2ex] \Dst \kern3em\mbox{} = 
\frac{2x+1}4 \sqrt{x^2+x+1} + \frac38\ln\Bigl(2x+1+2\sqrt{x^2+x+1}\Bigr) +
\tilde C
\end{array}
$$
(where in the last step, the $\ln\sqrt{3}$ was absorbed in the
arbitrary constant $C$). 

{\sf Again the hyp sub seems more expedient, given that we still have
  to deal with the return to the original variables in the case of the
  trig sub.}

$$
\int \sqrt{(x-1)(x-3)}\,dx = \int \sqrt{(x-2)^2 -1}\,dx = 
\rmk{x-2=\cosh t\,,\;dx=\sinh t\,dt}
\int\sinh^2 t\,dt = \frac18\Bigl( e^{2t}-e^{-2t}-4t\Bigr) + C
\leqno{\underline{\underline{\bf 29e:}}} 
$$
We have used $x>3$ again and may take $t>0$. In contrast, if we had
had $x<1$, we would have needed the sub $x-2=-\cosh t$ instead (and
could still have $t>0$). 

To undo the substitution, we have $e^t + e^{-t} = 2(x-2)$, i.e., 
$(e^t)^2 -2(x-2) e^t + 1 =0$, hence $e^t = (x-2) \pm
\sqrt{(x-2)^2-1}$ and $e^{-t}= (x-2) \mp \sqrt{(x-2)^2-1}$. Since we
took $t>0$, we know $e^t>e^{-t}$ and therefore the upper sign is applicable. 
We conclude
$$
\begin{array}{l}\Dst
\int \sqrt{(x-1)(x-3)}\,dx = \frac18\left(
\Bigl((x-2)+\sqrt{(x-2)^2-1}\Bigr)^2 -
\Bigl((x-2)-\sqrt{(x-2)^2-1}\Bigr)^2 -4t
\right) + C
\\[2ex]\Dst\kern3em\mbox{}
=
\frac{x-2}{2} \sqrt{(x-1)(x-3)}  - \frac12\ln \left(
x-2 + \sqrt{(x-1)(x-3)}
\right) +C 
\end{array}
$$
{\sf Again, it looks the hyperbolic is the easier one, unless we find
  a really swift way of finishing up the trig integral in \#27e. }
$$
\int_1^4 \frac{x}{1+\sqrt{x^4+1}}\,dx = 
\frac12\int_1^{16} \frac{dy}{1+\sqrt{y^2+1}} 
= \rmk{ y= \sinh t} 
\frac12\int_{y=1}^{y=16} \frac{\cosh t\,dt}{1+\cosh t}
=
\frac12\int_{y=1}^{y=16} \frac{(e^{2t}+1)\,dt}{2e^t+e^{2t}+1}
\leqno{\underline{\underline{\bf 29f:}}} 
$$
We have postponed the tranformation of the limits of integration for a
moment. As before (in \#29c), if $y=\sinh t$, then $e^t=
y+\sqrt{y^2+1}$. 
We substitute $e^t = z$, $dt=dz/z$,  and get
$$
\int_1^4 \frac{x}{1+\sqrt{x^4+1}}\,dx = \frac12
\int_{1+\sqrt{2}}^{16+\sqrt{257}} \frac{(z^2+1)dz}{z(z^2+2z+1)}
$$
At this moment, we await the skill to integrate rational functions
before finishing up. 

{\sf The decision whether trig or hyp is faster has to wait yet.}

$$
\int\frac{\arcsin x}{x^2}\,dx = -\frac{\arcsin x}{x} +\int
\frac{dx}{x\sqrt{1-x^2}}
\leqno{\underline{\underline{\bf 29g:}}} 
$$
where 
$$ 
\int \frac{dx}{x\sqrt{1-x^2}}= \rmk{x=\tanh t\,,\; dx=dt/\cosh^2t}
\int \frac{dt/\cosh^2 t}{\tanh t/\cosh t}
=\int\frac{dt}{\sinh t} = \int\frac{2 e^t\,dt}{e^{2t}-1} = 
\rmk{e^t=z} 
\int \frac{2\,dz}{z^2-1}
$$
With a similar hint as in \#27g, we can write the last integrand as
$\frac{1}{z-1}-\frac{1}{z+1}$ and then integrate:
If $x>0$, then $t>0$ and $z>1$, so we have the integral $\ln (z-1) -
\ln (z+1) + C$. If $x<0$, then $t<0$ and $z<1$, and we have the
integral $\ln(1-z) - \ln (z+1) + C$. 

We have yet to express $e^t$ in terms of $x$. As in \#29a,b, we get
$e^{t} = \sqrt{\frac{1+x}{1-x}}$. Therefore
$$
\int \frac{dx}{x\sqrt{1-x^2}} = \ln\frac{\abs{z-1}}{z+1} +C 
= \ln \frac{\abs{\sqrt{1+x}-\sqrt{1-x}}}{\sqrt{1+x}+\sqrt{1-x}} +C
$$
It would take a bit more algebra to show that this is indeed the same
as what we got in \#27g, despite the different appearance. 

$$
\int_0^1\sqrt{\frac{1-x}{1+x}}\,dx = 
\int_0^1\frac{1-x}{\sqrt{1-x^2}}\,dx = \rmk{x=\tanh t} 
\int_0^\infty \frac{(1-\tanh t)\,dt}{\cosh^2 t/\cosh t}
=
\int_0^\infty \frac{4e^{-t}\,dt}{e^{2t}+e^{-2t}+2} = \rmk{e^t=y}
\int_1^\infty \frac{4\,dy}{y^4+2y^2 + 1}
\leqno{\underline{\underline{\bf 29h:}}} 
$$
We may rely on \#23c for the last integral: It is
$$
\left[2\Bigl(\frac{y}{y^2+1} + \arctan y\Bigr)\right]_1^\infty
\pi-1-\frac\pi2 = \frac\pi2-1\;.
$$ 
{\sf Both methods were reasonably straightforward, but it seems the
  trig has an edge over the hyp here.}


\bigskip
\begin{quote}
\underline{\underline{\bf 30:}} 
  (a) Reduce the integral $\int\frac{\sin^2 u}{\cos^3 u}\,du$ to the
  integral of a rational function in two ways:  Either using the
  substitution $\sin u=y$ (taking advantage of the fact that one 
  $\cos u$ can go with the differential, leaving only even powers of
  $\sin u$ and of $\cos u$). Or use $\tan\frac u2 = t$, which is a
  universal tool working for all rational expressions of $\sin u$ and
  $\cos u$. Which of the two methods leads to the `easier' rational
  integral (where `easyness' is judged by the degree of the
  denominator)? 

  (b) Convert the integrals obtained in 27c-e into integrals of
  rational expressions. 

  (c) Next you will use the hint that 
  $\frac{1}{1-y^2}=  \frac12(\frac1{1-y}+\frac1{1+y})$ and 
  $\frac{y}{1-y^2}=  \frac12(\frac1{1-y}-\frac1{1+y})$,
  which is a piece of algebra that  you will be able to invent
  yourself in a few weeks; and also a similar piece of algebra that you can obtain by
  squaring the given hints, like 
  $\frac{1}{(1-y^2)^2}=  \frac14(\frac1{(1-y)^2}+\frac1{(1+y)^2}+
  \frac{2}{1-y^2})$ (then re-use the first hint for the last term!)

  With these hints you should be able to finish up the integrals
  obtained in 27c,d,e. (Don't forget to undo the substitutions in the
  end to get answers in terms of~$x$.)
\end{quote}

{\bf Solution: }
$$
\int\frac{\sin^2 u}{\cos^3 u}\, du = 
\int\frac{\sin^2 u\, \cos u}{(1-\sin^2 u)^2}\,du
= \rmk{ \sin u = y} \int \frac{y^2}{(1-y^2)^2}\,dy
\leqno(a)-\mbox{With $\sin u=y$} 
$$
For the substitution $t=\tan\frac u2$, we need to express $\sin u$ and
$\cos u$ in terms   
of $t=\tan \frac u2$, which is, by trig identities used in class, 
$$
\cos u = \frac{1-t^2}{1+t^2}\,,\qquad
\sin u = \frac{2t}{1+t^2}\,,\qquad
du = \frac{2\,dt}{1+t^2}
$$
Then we get
$$
\int\frac{\sin^2 u}{\cos^3 u}\, du = 
\int\frac{(2t)^2/(1+t^2)^2}{(1-t^2)^3/(1+t^2)^3}\, \frac{2\,dt}{1+t^2}
=
\int\frac{8t^2}{(1-t^2)^3}\,dt
\leqno(a)-\mbox{With $\tan\frac u2=t$}
$$
The former variant is simpler, and we will use it in part (b).

{\bf Part b:} The reduction of 27c\&e has just been done in part
(a). As for \#27d, we calculate
$$
\frac34\int\frac{du}{\cos^3u} = \frac34\int\frac{\cos u\,
  du}{(1-\sin^2 u)^2} = 
\rmk{\sin u =y} \frac34\int\frac{dy}{(1-y^2)^2}
\leqno
$$

{\bf Part c:} From the hint we have the algebraic $\int$implification
(which you by now know to be called `partial fraction decomposition')
$$
\frac{y^2}{(1-y^2)^2} = 
\frac14\left(\frac1{(1-y)^2}+\frac1{(1+y)^2} - \frac{2}{1-y^2}\right)
= 
\frac{1/4}{(1-y)^2}+\frac{1/4}{(1+y)^2} - \frac{1/4}{1-y}
-\frac{1/4}{1+y}
$$
Therefore 
$$
\int\frac{y^2}{(1-y^2)^2}\,dy = 
\frac{1/4}{1-y} - \frac{1/4}{1+y} + \frac14\ln(1-y) - \frac14\ln(1+y)
+C
=
\frac{y/2}{1-y^2} + \frac14\ln\frac{1-y}{1+y}+C
$$
Now let's undo the substitutions in {\bf \#27c} (I am suppressing the
arbitrary constant $C$)
$$
\begin{array}{l}\Dst
\int\frac{x^2\,dx}{\sqrt{x^2+1}} = \rmk{27c\,,\;30ab} 
\frac{y/2}{1-y^2} + \frac14\ln\frac{1-y}{1+y}
= \rmk{y=\sin u}
\frac{\sin u}{2\cos^2u} 
+ \frac14\ln\underbrace{\frac{1-\sin u}{1+\sin u}}_%
{\kern-1em(1-\sin u)^2/\cos^2 u\kern-1em} 
= \frac{\tan u}{2\cos u} + \frac12\ln\Bigl(\frac1{\cos u} - \tan
u\Bigr)
\\[7ex] \Dst \kern6em\mbox{}
=
\rmk{\tan u = x\,,\; \cos u= (1+x^2)^{-1/2}}
\frac{x}{2}\sqrt{1+x^2} + \frac12\ln\Bigl(\sqrt{1+x^2}-x\Bigr)
\end{array}
$$
(Using $\ln T = - \ln (1/T)$, we see that this is the same as what we
got in 29c, albeit a bit differently written.)

Next, we undo the substitutions in {\bf \#27e} (again I drop the $C$): 
$$
\begin{array}{l}\Dst
\int \sqrt{(x-1)(x-3)}\,dx = \rmk{27c\,,\;30ab}
\frac{y/2}{1-y^2} + \frac14\ln\frac{1-y}{1+y}
= \rmk{y=\sin u \mbox{ as before }}
\frac{\tan u}{2\cos u} + \frac12\ln\Bigl(\frac1{\cos u} - \tan
u\Bigr)
= \rmk{1/\cos u = x-2} \mbox{}
\\[7ex]\Dst \kern6em \mbox{} = 
\frac{(x-2)\sqrt{(x-2)^2-1}}{2} + \frac12 \ln\Bigl( x-2 -
  \sqrt{(x-2)^2-1}\Bigr) 
=
\\[2ex]\Dst \kern6em \mbox{} = 
\frac{(x-2)\sqrt{(x-1)(x-3)}}{2} + \frac12 \ln\Bigl( x-2 -
  \sqrt{(x-1)(x-3)}\Bigr) 
\end{array}
$$
Again, when comparing this to 29e, this {\em is\/} the same result,
despite the difference in two signs. Use $\ln T=-\ln(1/T)$. 
The two expressions $(x-2)\pm\sqrt{(x-2)^2-1}$ are each other's
reciprocals. 

For {\bf\#27d}, we need to do the partial fraction decomposition yet:
$$
\frac{1}{(1-y^2)^2} = 
\frac{1/4}{(1-y)^2}+\frac{1/4}{(1+y)^2} + \frac{1/4}{1-y}
+\frac{1/4}{1+y}
$$
Therefore (just changing a sign compared to the previous calculation)
$$
\int\frac{dy}{(1-y^2)^2} = 
\frac{y/2}{1-y^2}-\frac14\ln\frac{1-y}{1+y} +C
=\rmk{y=\sin u}
\frac{\tan u}{2\cos u} - \frac12\ln\Bigl(\frac1{\cos u} - \tan u
\Bigr) + C
$$
Undoing the substituion (and not forgetting the factor $\frac34$ in
front of the $y$-integral), we get
$$\begin{array}{l}\Dst
\int \sqrt{x^2+x+1}\,dx =\rmk{27e\,,\;30b} 
\frac{3\tan u}{8\cos u} - \frac38\ln\Bigl(\frac1{\cos u} - \tan u
\Bigr) +C
= \rmk{\tan u = (2x+1)/\sqrt{3}} \mbox{}
\\[7ex]\Dst\kern6em\mbox{}=
\frac{\sqrt{3}(2x+1)}{8}\sqrt{1+\frac{(2x+1)^2}{3}} 
- \frac38\ln\Bigl(\sqrt{1+\frac{(2x+1)^2}{3}} -
\frac{2x+1}{\sqrt{3}}\Bigr) +C
\\[2ex]\Dst\kern6em\mbox{}=
\frac{2x+1}{4}\sqrt{x^2+x+1} 
- \frac38\ln\Bigl(\sqrt{x^2+x+1} - (x+\Tst\frac12)\Bigr) + C'
\end{array}
$$
In the last step I have combined $C-\frac38\ln\frac2{\sqrt{3}}$ into
the new constant $C'$. 

\bigskip


\begin{quote}
\underline{\underline{\bf 31:}}
  Finish up \#27f, using the universally helpful substitution for
  rational expressions in $\sin u$, $\cos u$ mentioned in the previous
  problem. (And I am not aware of a simpler procedure by means of a
  more specialized substitution). Make sure to get an exact
  expression first,  in which all occurrences of trig(arctrig(number))
  are simplified; then you may use technology to get a numeric result
  and check it for plausibility in view of the original integral. 
\end{quote}
%
\newpage
{\bf Solution: }
$$
I:= 
\int_1^4 \frac{x}{1+\sqrt{x^4+1}}\,dx = \rmk{x^2 = y\,,\;\mbox{then
  }y=\tan u}
\frac12\int_{\arctan 1}^{\arctan 16} \frac{du}{\cos^2 u + \cos u}
= \rmk{t=\tan\frac{u}{2}}
\frac12 \int_?^? \frac{1}{\frac{(1-t^2)^2}{(1+t^2)^2}+\frac{1-t^2}{1+t^2}}\frac{2dt}{1+t^2}
$$
First we need to express the limits in terms of $t$: 
Lower limit of integration: Note that $\tan u = \frac{\sin u}{\cos u}
= \frac{2t}{1-t^2}$. So when $u= \arctan 1$, i.e., $\tan u =1$, then
$t$ must satisfy $\frac{2t}{1-t^2}=1$, i.e., $t^2+2t-1=0$, or
$t=-1\pm\sqrt{2}$. The positive sign applies since $t>0$ when $u$ is
between 0 and $\pi/2$. Likewise, when $\frac{2t}{1-t^2}=16$, we find
$t= (-1+\sqrt{257})/16$. 

So we simplify
$$
I= \int_{\sqrt{2}-1}^{(\sqrt{257}-1)/16}
\frac{1+t^2}{(1-t^2)^2+(1-t^2)(1+t^2)}\,dt
=   \int_{\sqrt{2}-1}^{(\sqrt{257}-1)/16} \frac{1+t^2}{2(1-t^2)}\,dt
$$
and
$$
\int\frac{1+t^2}{2(1-t^2)}\,dt 
= \int \left(
-\frac12+\frac{1/2}{1-t} +\frac{1/2}{1+t}
\right)\,dt
=\frac12\left(-t + \ln\frac{1+t}{1-t}\right) + C
$$
Therefore 
$$
\begin{array}{l}\Dst
I = \frac12\left( -\frac{\sqrt{257}-1}{16} + \sqrt{2}-1  + 
\ln \frac{(\sqrt{257}+15)/16}{(17-\sqrt{257})/16} -
\ln\frac{\sqrt2}{2-\sqrt2}
\right)
\\[2.5ex]\Dst \phantom{I}\mbox{}
=\frac12\left(
\sqrt2 - \frac{\sqrt{257}+15}{16} + \ln(16+\sqrt{257}) -\ln(1+\sqrt2)
\right)
\end{array}
$$
The numerical value is $I\approx 1.03005$. 

{\sf A quick plausibility check could go like this: drop the 1 under
  the square root, obtaining
$$
I= \int_1^4\frac{x\,dx}{1+\sqrt{x^4+1}} < 
\int_1^4\frac{x\,dx}{1+x^2} =\frac12\left[\ln(1+x^2)\right]_1^4 =
\frac12\ln\frac{17}{2} \approx 1.07003
$$
}

{\sl The next part was not required, but let me do it for comparison
  anyways: We can also finish up the same integral coming through the
  hyperbolic substitution, from \#29f: }

$$
I= \frac12\int_{1+\sqrt2}^{16+\sqrt{257}} \frac{(z^2+1)\,dz}{z(z+1)^2}
$$
The partial fraction decomposition has a repeated factor this time,
but is bottom heavy. We have
$$
\frac{z^2+1}{z(z+1)^2} = 
\frac{1}{z} + \frac{-2}{(z+1)^2} + \frac{0}{z+1}
$$
So
$$
I= \left[ \frac12 \ln z +
  \frac1{z+1}\right]_{1+\sqrt2}^{16+\sqrt{257}} 
=\frac12\Bigl( \ln(16+\sqrt{257}) - \ln(1+\sqrt2) \Bigr) 
+ \frac{1}{17+\sqrt{257}} - \frac1{2+\sqrt2}
$$

Well, you judge which one is easier\ldots

\bigskip

\begin{quote}
\underline{\underline{\bf 32:}}
  Find the PFD of $\Dst\frac{5x^2+4x-13}{x^3+2x^2-5x-6}$ 
  and calculate $\Dst\int_0^1 \frac{5x^2+4x-13}{x^3+2x^2-5x-6}\,dx$. 
\end{quote}
{\bf Solution: }
First we need to factor the denominator. Good guesses for a zero are $\pm1$, 
$\pm2$, $\pm3$ and $\pm6$. {\sf The rational root test says that the only rational 
numbers that could be zeros of a polynomial with integer coefficients
are among those that have a numerator dividing the constant term of
the polynomial (here: $-6$) and a denominator dividing the highest
order coefficient (here: 1). Hence, if none of the above-mentioned
good guesses works, the polynomial will not have a rational zero and
our factorization becomes impossible, short of the `cubic formula'
(which you are not expected to know and which is complicated enough to
be a pain in the butt to use). }

$-1$ is a zero. So is $2$. So is $-3$. [Alternatively, We could stop
  guessing after the first success  and
  factor $x^3+2x^2-5x-6 = (x+1)(x^2+x-6)$ and then use the quadratic
  formula on $x^2+x-6$.]

The rational is bottom--heavy. We have the {\em form\/} of the PFD as
$$
\frac{5x^2+4x-13}{x^3+2x^2-5x-6} = 
\frac{5x^2+4x-13}{(x+1)(x-2)(x+3)} = 
\frac{A}{x+1} + \frac{B}{x-2} + \frac{C}{x+3} 
$$
Cover-up yields:\\
At $x\to-1$: \ $A= \frac{5-4-13}{(-3)\cdot2} = 2$, \\
At $x\to2$:  \ $B= \frac{20+8-13}{3\cdot5} = 1$,\\
At $x\to-3$: \ $C= \frac{45-12-13}{(-2)(-5)} = 2$.

Possible consistency checks to detect miscalc's: \\
Multiply with $x$ and take $\lim_{x\to\infty}$: yields $5=A+B+C$,
\\
Plugging in $x=1$ yields $-4/(-8)= \frac A2-B + \frac C4$. 

Now we can integrate:
$$
\begin{array}{l}\Dst
\int_0^1 \frac{5x^2+4x-13}{x^3+2x^2-5x-6} \,dx = 
\int_0^1 \left(\frac{2}{x+1} + \frac{1}{x-2} + \frac{2}{x+3}
\right)\,dx =\mbox{}
\\[2ex]\Dst \kern3em\mbox{} 
=
\Bigl[2\ln (x+1) + \ln(2-x) + 2\ln(x+3)\Bigr]_0^1
=\mbox{}
\\[2ex]\Dst \kern3em\mbox{} 
=
2\ln 2 -\ln 2 + 2\ln 4-2\ln 3 = 5\ln 2 - 2\ln 3 = \ln\frac{32}{9}
\end{array}
$$



\begin{quote}
\underline{\underline{\bf 33:}}
  (a) Find the PFD of $\Dst\frac{(x+2)(x^2-2)}{(x+1)^2(x^2+1)}$ ---
  Part (b) see next item.
\end{quote}
{\bf Solution: } (a) The form of the PFD is (we are in the
bottom--heavy case again)
$$
\frac{(x+2)(x^2-2)}{(x+1)^2(x^2+1)} = \frac{A}{(x+1)^2} + \frac{B}{x+1} + \frac{Cx+D}{x^2+1}
$$
Cover-up at $x\to-1$ yields $A= \frac{1(-1)}{2} = -\frac12$.
\\
Cover-up (complex) at $x\to i$ yields $Ci+D =
\frac{(i+2)(i^2-2)}{(i+1)^2} = \frac{-3(i+2)}{2i} = -\frac32 +3i$. 
\\
So we get $C=3$ and $D=-\frac32$. 
\\
Multiplying by $x$ and letting $x\to\infty$ yields the equation 
$1 = B+C$, hence (with $C=3$ known already) $B=-2$. 
We have thus found the PFD
$$
\frac{(x+2)(x^2-2)}{(x+1)^2(x^2+1)} = \frac{-1/2}{(x+1)^2} + 
\frac{-2}{x+1} + \frac{3x-3/2}{x^2+1}
$$
A consistency check against miscalc's could use $x=0$: \\
$-4 \stackrel{?}{=} -\frac12-2-\frac32$. 

{\sl Here is a different approach: }

Obtaining $A=-\frac12$ as before, we subtract that term from both
sides:
$$
  \frac{B}{x+1} + \frac{Cx+D}{x^2+1}
=
\frac{(x+2)(x^2-2)}{(x+1)^2(x^2+1)} + \frac{1}{2(x+1)^2}
=
\frac{2(x+2)(x^2-2) + (x^2+1)}{2(x+1)^2(x^2+1)}
=
\frac{2x^3+5x^2-4x-7}{2(x+1)^2(x^2+1)}
$$
That numerator must have $-1$ as a zero, allowing us to factor off
$(x+1)$. Namely $2x^3+5x^2-4x-7 = (x+1)(2x^2+3x-7)$. 
This leaves us with the new, simpler, PFD task:
$$
  \frac{B}{x+1} + \frac{Cx+D}{x^2+1}
=
\frac{2x^2+3x-7}{2(x+1)(x^2+1)}
$$
Cover--up at $x\to-1$ yields $B=\frac{2-3-7}{2\cdot2}=-2$.
Moving the newly found term over again, gives
$$
\frac{Cx+D}{x^2+1}
=
\frac{2x^2+3x-7}{2(x+1)(x^2+1)} +  \frac{2}{x+1} 
=
\frac{2x^2+3x-7 + 4(x^2+1)}{2(x+1)(x^2+1)} 
= 
\frac{6x^2+3x-3}{2(x+1)(x^2+1)} 
= 
\frac{(x+1)(6x-3)}{2(x+1)(x^2+1)} 
$$
and after cancellation we read off $C,D$ immediately.
In this calculation, each reduction step is its own consistency check
since the factorization and cancellation would fail if the preceding
coefficient were not calculated correctly. 


\begin{quote}
\underline{\underline{\bf 33:}}
  (b) Find the PFD of $\Dst\frac{x^6+76}{(x+2)^3(x-3)^2}$
\end{quote}
{\bf Solution: } (b) This one is {\em not\/} bottom-heavy. The
denominator has degree 5, whereas the numerator has degree
6. Polynomial division will give us a first degree polynomial before
we get a bottom--heavy remainder. 

The form of the PFD is therefore 
$$
\frac{x^6+76}{(x+2)^3(x-3)^2} = ax + b + 
\frac{A}{(x+2)^3} + \frac{B}{(x+2)^2} + \frac{C}{x+2} + \frac{D}{(x-3)^2} + \frac{E}{x-3} 
$$
We have the choice to obtain $A$ and $D$ by cover--up immediately or
after the polynomial division. 

I'll do it right away, and then again after the polynomial division,
for you to compare, and also as a consistency check that would likely
discover miscalc's in the polynomial division. 

We get $A= \frac{(-2)^6 + 76}{(-5)^2}= \frac{140}{25}=\frac{28}{5}$.\\
We also get $D=
\frac{3^6+76}{5^3}=\frac{729+76}{125}=\frac{161}{25}$. 

Let's do the long division of polynomials; this requires us to expand
the denominator:\\ 
$(x+2)^3(x-3)^2 = (x^3+6x^2+12x+8)(x^2-6x+9) =
x^5+0x^4-15x^3-10x^2+60x+72$. 
$$
x^6 + 76 = (x^5+0x^4-15x^3-10x^2+60x+72) ( x + 0 ) + ( 15x^4+10x^3
-60x^2 - 72 x +76 )
$$
So we have
$$
\frac{x^6+76}{(x+2)^3(x-3)^2} = x + 
\frac{15x^4 + 10x^3 - 60x^2 - 72 x + 76}{(x+2)^3(x-3)^2} 
$$
and 
$$
\frac{15x^4 + 10x^3 - 60x^2 - 72 x + 76}{(x+2)^3(x-3)^2} 
=
\frac{A}{(x+2)^3} + \frac{B}{(x+2)^2} + \frac{C}{x+2} + \frac{D}{(x-3)^2} + \frac{E}{x-3} 
$$
We can obtain $A,D$ by cover-up from here as well:
\\
$A= \frac{15\cdot16 -80 -240 +144 + 76}{(-5)^2}= \frac{140}{25}=\frac{28}{5}$
and
$D= \frac{15\cdot81+270-540-72\cdot3+76}{5^3}=\frac{1215-270-140}{125}=\frac{161}{25}$. 

From here, we have to determine three coefficients yet. Either we have
to move the calculated terms on the other side and cancel factors, or
we have to plug in numbers haphazardly \marginpar{($*$)}
and solve a system of equations. 
I choose to move the calculated terms over:
$$
\frac{25(15x^4 + 10x^3 - 60x^2 - 72 x + 76)-140(x-3)^2-161(x+2)^3}%
     {25(x+2)^3(x-3)^2} 
=
\frac{B}{(x+2)^2} + \frac{C}{x+2} +  \frac{E}{x-3} 
$$
The numerator gets simplified and we know beforehand that we will be
able to factor off $(x+2)(x-3)=x^2-x-6$.
$$
\begin{array}{l}\Dst
25(15x^4 + 10x^3 - 60x^2 - 72 x +
76)-140\underbrace{(x-3)^2}_{=x^2-6x+9}
-161\underbrace{(x+2)^3}_{\kern-2em =x^3+6x^2+12x+8\kern-2em}
=375 x^4 + (250-161) x^3 + \mbox{}
\\[4ex]\Dst\kern3em
\mbox{}+
(-1500-140-966)x^2 + (-1800+840-1932) x + (1900-1260-1288)
\\[2ex]\Dst\kern4em\mbox{} = 
375 x^4 + 89 x^3 - 2606 x^2 - 2892 x - 648
= (x^2-x-6)( 375 x^2  + 464 x +108)
\end{array}
$$
This leaves us with the (simpler) PFD task
$$
\frac{375 x^2  + 464 x +108}%
     {25(x+2)^2(x-3)} 
=
\frac{B}{(x+2)^2} + \frac{C}{x+2} +  \frac{E}{x-3} 
$$
By cover-up, we get\\
$B= \frac{375\cdot4 -464\cdot2+108}{25(-5)}= \frac{680}{25(-5)}=-\frac{136}{25}$
and\\[1ex]
$E= \frac{375\cdot9+464\cdot3+108}{25\cdot25}= \frac{4875}{25\cdot25}=
\frac{975}{125}=\frac{195}{25}=\frac{39}{5}$.

Now we use the trick ``multiply by $x$ and let $x\to\infty$'' t get
$C$ from $E$: Namely $C+E=\frac{375}{25}= 15$, hence $C=\frac{36}{5}$.

{\bf Conclusion: }
$$
\frac{x^6+76}{(x+2)^3(x-3)^2} = x +
\frac{28}{5(x+2)^3} - \frac{136}{25(x+2)^2} + \frac{36}{5(x+2)} +
\frac{161}{25(x-3)^2} + \frac{39}{5(x-3)} 
$$
A quick consistency check can be done at $x=0$ (in a first step, I'll
combine those terms that have similar denominators): 
$$
\frac{76}{8\cdot9} \stackrel{?}{=} 
\frac{28}{5\cdot8} - \frac{136}{100} +\frac{18}{5} + \frac{161}{25\cdot9} -\frac{13}5
\quad
\iff
\quad
\frac{19\cdot25-322}{50\cdot9} \stackrel{?}{=} 
\frac{70}{100} - \frac{136}{100} + 1
$$
The left simplifies to $\frac{17}{50}$. The right to
$\frac{-33}{50}+1$. Yeah!!!

{\bf Variant: }Returning to the paragraph marked (*), we could trade
the reduction algorithm (moving terms over, simplifying, cancelling) 
for solving a system of linear equations by plugging in some
reasonably nice numbers. Let me do this here: 

Using $x\to\infty$ (after multiplying with $x$), we obtain $15=C+E$.
Using $x=0$, we obtain $\frac{76}{8\cdot9} = \frac{28}{5\cdot 8}
+\frac{B}{4} + \frac{C}{2} + \frac{161}{25\cdot9} -\frac E3$. 
Using $x=-1$, we obtain $\frac{15-10-60+72+76}{16}= \frac{28}{5} +B +C
+ \frac{161}{25\cdot16} -\frac E4$. 
So the system of linear equations we have is
$$
\left.
\begin{array}{l}
C+E=15\\[1ex]
B+C-\frac14E = \frac{25\cdot 93-28\cdot80-161}{400} =
\frac{-76}{400}=-\frac{19}{100} 
\\[1ex]
\frac14B+\frac12C-\frac13E = \frac{950-14\cdot45-644}{900} =
\frac{-324}{900} = - \frac{36}{100}
\end{array}
\right\}
\Longrightarrow
\left\{
\begin{array}{l}
B+\frac54 C = \frac{356}{100} = \frac{89}{25}
\\[1ex]
\frac14B + \frac{5}{6}C = \frac{464}{100}=\frac{116}{25}
\end{array}
\right.
\quad
\mbox{etc}
$$







\begin{quote}
\underline{\underline{\bf 34:}}
  Find the PFD of $\Dst\frac{25}{(x-1)^2(x^2+4x+5)}$ in two ways: one using 
  complex numbers to deal with the quadratic, one without use of complex numbers. 
\end{quote}
{\bf Solution: }
The {\em form\/} of the PFD is
$$
\frac{25}{(x-1)^2(x^2+4x+5)} = \frac{A}{(x-1)^2}+\frac{B}{x-1} + \frac{Cx+E}{(x+2)^2+1}
$$
Alternatively, we can write it as
$$
\frac{25}{(x-1)^2(x^2+4x+5)} = \frac{A}{(x-1)^2}+\frac{B}{x-1} + \frac{C(x+2)+D}{(x+2)^2+1}
$$
where $D+2C=E$. The second variant is slightly more convenient, both
for calculation with complex numbers and for subsequent use in
integration (or, later in Math231, for use in inverse Laplace transforms).
The punchline in the 2nd variant is that the $(x+2)$ multiplying the
unknown coefficient $D$ aligns with the $x+2$ in the completed-square
form of the denominator. 

We get $A$ by cover--up at $x\to1$ as $A= \frac{25}{10}=\frac52$. 
Using complex cover-up at $x\to-2+i$, we get
$\frac{25}{(-3+i)^2} = Ci+D$ (or $=C(-2+i)+E$).
But $\frac{25}{(-3+i)^2}=\frac{25(3+i)^2}{(-10)^2}= \frac{8+6i}{4}$.
So we see $C=\frac32$ and $D=2$. 

From multiplying with $x$ and letting $x\to\infty$, we get $0=B+C$,
hence $B=-\frac32$.  

Consistency check at $x=0$ yields $5=A-B + \frac{2C+D}{5}$, which is
true for the numbers $A,B,C,D$ found.

Without use of complex numbers, we'd probably be best off using the
reduction method after finding $A$:

$$
\begin{array}{l}\Dst
\frac{B}{x-1} + \frac{Cx+E}{(x+2)^2+1} = \frac{25}{(x-1)^2(x^2+4x+5)}
- \frac{5}{2(x-1)^2}  
=
\frac{50-5(x^2+4x+5)}{2(x-1)^2(x^2+4x+5)} 
\\[2ex]\Dst\kern3em\mbox{}
= \frac{-5x^2-20x+25}{2(x-1)^2(x^2+4x+5)} =
\frac{(x-1)(-5x-25)}{2(x-1)^2(x^2+4x+5)} =
\frac{-5(x+5)}{2(x-1)(x^2+4x+5)} 
\end{array}
$$
Cover-up at $x\to1$ gives now $B= \frac{-15}{10}=-\frac32$.

We could now get $C=-B$ from $x\to\infty$ as before, and $D$ or $E$ by
plugging in $x=0$. Or we do another reduction step:
$$
\begin{array}{l}\Dst
 \frac{Cx+E}{(x+2)^2+1} = 
\frac{-5(x+5)}{2(x-1)(x^2+4x+5)} + \frac{3}{2(x-1)} 
=
\frac{-5x-25+3(x^2+4x+5)}{2(x-1)(x^2+4x+5)}
=\mbox{}
\\[2ex]\Dst\kern3em\mbox{}=
\frac{3x^2+7x-10}{2(x-1)(x^2+4x+5)}
=\frac{(x-1)(3x+10)}{2(x-1)(x^2+4x+5)}
\end{array}
$$
So we read off $C=\frac32$ and $E=5$. 

{\bf Conclusion: }
$$
\frac{25}{(x-1)^2(x^2+4x+5)} = \frac{5/2}{(x-1)^2}-\frac{3/2}{x-1} 
+ \frac{3(x+2)/2+2}{(x+2)^2+1}
$$

\begin{quote}
\underline{\underline{\bf 35:}}
  Use PFD to evaluate $\Dst I(a,b;x):= 
  \int_0^x \frac{dt}{(t^2+a^2)(t^2+b^2)}$, assuming $a,b>0$ and 
  $b\neq a$. Finally, calculate the limit $\lim_{b\to a} I(a,b;x)$ (which may 
  require l'Hopital). --- {\sf The purpose of this problem is to obtain $I(a,a;x) =
  \int_0^x dt/(t^2+a^2)^2$ by a different method; we trust that 
  $I(a,a;x) = \lim_{b\to a} I(a,b;x)$, i.e., that the integral depends continuously 
  on $b$.} --- Compare your result with Hwk \#23 (Task 4).
\end{quote}
{\bf Solution: }
$$
\frac{1}{(t^2+a^2)(t^2+b^2)} = \frac{1}{b^2-a^2} 
\left(\frac{1}{t^2+a^2} - \frac{1}{t^2+b^2}\right)
$$
Therefore
$$
\int_0^x \frac{dt}{(t^2+a^2)(t^2+b^2)} = 
\frac{1}{b^2-a^2}\left[\frac1a\arctan\frac ta - \frac 1b \arctan\frac tb\right]_0^x
=
\frac{b\arctan\frac xa-a\arctan\frac xb}{ab(b^2-a^2)}
$$
To calculate the limit as $b\to a$ in this expression we use
l'Hopital.
The derivative of the numerator (wrt~$b$~!) is
$
\arctan\frac xa - a(1+(\frac xb)^2)^{-1}(-\frac x{b^2})
= 
\arctan\frac xa + \frac{ax}{x^2+b^2}$.
The derivative of the denominator wrt~$b$ is 
$
a(b^2-a^2)+ab(2b)$. 
So 
$$
\lim_{b\to a} I(a,b;x) = \lim_{b\to a}
\frac{\arctan\frac xa + \frac{ax}{x^2+b^2}}%
     {a(b^2-a^2)+ab(2b)} = 
\frac{\arctan\frac xa + \frac{ax}{x^2+a^2}}{2a^3}
$$
Same as in~\#23 as it should be.


\begin{quote}
\underline{\underline{\bf 36:}}
  Use the trig substitution $x=a \tan u$ on the integral $\int dx/(x^2+a^2)^2$ and 
  evaluate it this way. 
\end{quote}
{\bf Solution: } 
$$
\int \frac{dx}{(x^2+a^2)^2} = \rmk{x=a\tan u}
a^{-3}\int\cos^2u\,du = \frac12 a^{-3}\Bigl(u + \underbrace{\sin u
  \cos u}_{=\tan u\cos^2 u}\Bigr)
+C 
= \frac{1}{2a^3} \arctan\frac xa + \frac1{2a^3}
\,\frac{x/a}{1+(x/a)^2} +C
$$

\end{document}

