Midterm 2 Solutions
Midterm 2 Solutions
(2 points) 1. Carefully read the instructions on the front page of this exam.
(10 points) 2. Compute the antiderivative (Hint: if you use complex exponentials, make sure you end
up with real functions in your final answer)
Z
sin2 (x) cos(πx)dx
meaning
Z Z
1
2
sin (x) cos(πx)dx = − e(2+π)ix + e−(2+π)ix + e(π−2)ix + e−(π−2)ix − 2(eπix + e−πix )dx
8
Z
1
=− cos((2 + π)x) + cos((π − 2)x) − 2 cos(πx)dx
4
1 sin((2 + π)x) sin((π − 2)x) 2
=− [ + − sin(πx)] + C.
4 2+π π−2 π
To find this second integral, we have to integrate by parts twice (or use the angle addition
formulas, but that is essentially method 1). First let
1
u = sin(2x), dv = sin(πx) ⇒ du = 2 cos(2x)dx, v = − cos(πx).
π
Then
Z Z
1 2
sin(2x) sin(πx)dx = − sin(2x) cos(πx) + cos(2x) cos(πx)dx.
π π
Finally, we set
1
u = cos(2x), dv = cos(πx)dx ⇒ du = −2 sin(2x), v = sin(πx),
π
resulting in
Z Z
1 2
cos(2x) cos(πx)dx = sin(πx) cos(2x) + sin(2x) sin(πx).
π π
Plugging this into our earlier calculation
Z Z
1 1 2 1 2
sin(2x) sin(πx)dx = − sin(2x) cos(πx)+ [ sin(πx) cos(2x)+ sin(2x) sin(πx)dx],
π π π π π
hence
Z
4 1 2
(1 − ( 2 ) sin(2x) sin(πx)dx = ( sin(πx) cos(2x) − sin(2x) cos(πx)),
π π π
which implies
Z
4 1 2
sin(2x) sin(πx)dx = (1 − 2 )−1 ( sin(πx) cos(2x) − sin(2x) cos(πx))
π π π
2
π − 4 −1 1 2
=( ) ( sin(πx) cos(2x) − sin(2x) cos(πx))
π2 π π
π2 1 2
= 2 ( sin(πx) cos(2x) − sin(2x) cos(πx))
π −4π π
π 2
= 2 ( sin(πx) cos(2x) − sin(2x) cos(πx))
π −4 π
Finally, we can plug this back into our original integration by parts equation to get that
Z Z
2 1 2 1
sin (x) cos(πx)dx = sin (x) sin(πx) − sin(2x) sin(πx)dx
π π
1 1 2
= sin2 (x) sin(πx) − 2 ( sin(πx) cos(2x) − sin(2x) cos(πx))
π π −4 π
Name and PID: Version B
1 1 1 2 1
= · (1 − cos(2x)) sin(πx) − 2 · sin(πx) cos(2x) + 2 sin(2x) cos(πx)
π 2 π −4 π π −4
1 1 1 2 1
= sin(πx) − ( + 2 · ) sin(πx) cos(2x) + 2 sin(2x) cos(πx).
2π 2π π − 4 π π −4
To make this look more like the answer from the first method, we recall that
1 1 1 1
= ( − )
π2 −4 4 π−2 π+2
, and that finding a common denominator shows that
1 1 2 π
+ 2 · =
2π π − 4 π 2(π 2 − 4)
1 1 1
= ( + ).
4 π−2 π−2
Thus we can rewrite
1 1 2 1
−( + 2 · ) sin(πx) cos(2x) + 2 sin(2x) cos(πx)
2π π − 4 π π −4
as
1 1 1
[ (sin(2x) cos(πx) − cos(2x) sin(πx)) − (sin(2x) cos(πx) + cos(2x) sin(πx))]
4 π−2 π+2
1 sin((2 − π)x) sin((π + 2)x)
= ( − )
4 π−2 π+2
1 sin((π − 2)x) sin((π + 2)x)
=− ( − )
4 π−2 π+2
where the second line comes from the angle addition formulas. Finally, we get that
Solution: Call the integrand f (x). Then f (x) is proper, since its numerator has degree
2 and its denominator has degree 3. Also, x2 − 2x + 12 is irreducible (we can see this
by completing the square or using the quadratic formula to check that its roots are not
real), so we know its partial fraction decomposition has the form
A Bx + C
f (x) = + 2 .
x + 7 x − 2x + 12
Finding a common denominator, this means that
so
300 = 75A;
ie,
A = 4.
Next, we can plug in x = 0 to find
34 = 4 · 12 + 7C
⇒ −14 = 7C
⇒ −2 = C.
44 = 44 + (B − 2) · 8
⇒ 0 = (B − 2) · 8
⇒ B = 2.
6x2 + 4x + 34 2x − 2
Z Z
4
2
dx = + 2 dx
(x + 7)(x − 2x + 12) x + 7 x − 2x + 12
= 4 log |x + 7| + log |x2 − 2x + 12| + C,
(2 points) 4. (a) Find the general form of the partial fraction decomposition for the rational function
x3
(x + 11)4 (x2 + 29)2
√
x2 + 1
x
θ
1
Z∞ ZR
2 2
dx = lim dx
(x + 1)2
2 R→∞ (x2 + 1)2
0 0
R
x
= lim arctan(x) + 2
R→∞ x +1 0
R
= lim arctan(R) + 2 − arctan(0)
R→∞ R +1
R
= lim arctan(R) + 2
R→∞ R +1
π
= +0
2
π
= .
2
Name and PID: Version B
meaning
1 1
p < √ .
x log(x)x2 − 81 x x2 − 81
Thus, by comparison to the integral from part a, which we just showed converges,
Z∞
1
p dx
x log(x)x2 − 81
9
converges as well.
Name and PID: Version B
Scratch paper