Week 1 Discussion Notes

Table of Contents

Direct Integration

This "technique" is used when the integrand is the derivative of a function that you already know. Basically, if you remember the common derivatives, then you already know a lot of integrals.

Power Rule

The derivative of xnx^n is nxn1nx^{n-1}, so you immediately get

nxn1dx=xn+C    xn1dx=xnn+C.\int nx^{n-1} \,\diff{x} = x^n + C \implies \int x^{n-1} \,\diff{x} = \frac{x^n}{n} + C.

(I absorbed the nn into the CC, since nn is just a constant.)

Trig Functions

Recall the derivatives of the trig functions:

ddxsinx=cosxddxcosx=sinxddxtanx=sec2xddxcotx=csc2xddxsecx=secxtanxddxcscx=cscxcotx\begin{aligned} \deriv{}{x} \sin{x} &= \phantom{-}\cos{x} \\ \deriv{}{x} \cos{x} &= -\sin{x} \\ \deriv{}{x} \tan{x} &= \phantom{-}\sec^2{x} \\ \deriv{}{x} \cot{x} &= -\csc^2{x} \\ \deriv{}{x} \sec{x} &= \phantom{-}\sec{x}\tan{x} \\ \deriv{}{x} \csc{x} &= -\csc{x}\cot{x} \end{aligned}

This becomes a list of integrals:

cosxdx=sinx+Csinxdx=cosx+Csec2xdx=tanx+Ccsc2xdx=cotx+Csecxtanxdx=secx+Ccscxcotxdx=cscx+C\begin{aligned} \int \cos{x} \,\diff{x} &= \phantom{-}\sin{x} + C \\ \int \sin{x} \,\diff{x} &= -\cos{x} + C \\ \int \sec^2{x} \,\diff{x} &= \phantom{-}\tan{x} + C \\ \int \csc^2{x} \,\diff{x} &= -\cot{x} + C \\ \int \sec{x}\tan{x} \,\diff{x} &= \phantom{-}\sec{x} + C \\ \int \csc{x}\cot{x} \,\diff{x} &= -\csc{x} + C \end{aligned}

Beyond these, there are a few weirder ones that don't really fit under direct integration, but are still good to know off the top of your head:

tanxdx=lnsecx+Csecxdx=lnsecx+tanx+Ccotxdx=lncscx+Ccscxdx=lncscx+cotx+C\begin{aligned} \int \tan{x} \,\diff{x} &= \phantom{-}\ln{\abs{\sec{x}}} + C \\ \int \sec{x} \,\diff{x} &= \phantom{-}\ln{\abs{\sec{x} + \tan{x}}} + C \\ \int \cot{x} \,\diff{x} &= -\ln{\abs{\csc{x}}} + C \\ \int \csc{x} \,\diff{x} &= -\ln{\abs{\csc{x} + \cot{x}}} + C \end{aligned}

You can derive the ones for tanx\tan{x} and cotx\cot{x} using uu-substitution. The ones for secx\sec{x} and cscx\csc{x} use a trick, though.

Exponentials and Logarithms

Like before, here are the common derivatives:

ddxbx=bxlnbddxlogbx=1xlnb\begin{aligned} \deriv{}{x} b^x &= b^x \ln{b} \\[2ex] \deriv{}{x} \log_b{x} &= \frac{1}{x\ln{b}} \end{aligned}

The first one gives you the integral

bxdx=bxlnb+C.\int b^x \,\diff{x} = \frac{b^x}{\ln{b}} + C.

When b=eb = e, the second one gives you

1xdx=lnx+C.\int \frac{1}{x} \,\diff{x} = \ln{\abs{x}} + C.

The reason for the absolute value is because if x<0x < 0, then

ddxln(x)=1x1=1x\deriv{}{x} \ln\p{-x} = \frac{1}{-x} \cdot -1 = \frac{1}{x}

by the chain rule. So both lnx\ln{x} and ln(x)\ln\p{-x} are antiderivatives for 1x\frac{1}{x} depending on the sign of xx.

Inverse Trig Functions

Here are the derivatives:

ddxarcsinx=11x2ddxarctanx=11+x2ddxarcsecx=1xx21ddxarccosx=11x2ddxarccotx=11+x2ddxarccscx=1xx21\begin{aligned} \deriv{}{x} \arcsin{x} &= \phantom{-}\frac{1}{\sqrt{1 - x^2}} \\ \deriv{}{x} \arctan{x} &= \phantom{-}\frac{1}{1 + x^2} \\ \deriv{}{x} \arcsec{x} &= \phantom{-}\frac{1}{\abs{x}\sqrt{x^2 - 1}} \\ \deriv{}{x} \arccos{x} &= -\frac{1}{\sqrt{1 - x^2}} \\ \deriv{}{x} \arccot{x} &= -\frac{1}{1 + x^2} \\ \deriv{}{x} \arccsc{x} &= -\frac{1}{\abs{x}\sqrt{x^2 - 1}} \\ \end{aligned}

So you have these integrals:

11x2dx=arcsinx+C11+x2dx=arctanx+C1xx21dx=arcsecx+C\begin{aligned} \int \frac{1}{\sqrt{1 - x^2}} \,\diff{x} &= \arcsin{x} + C \\ \int \frac{1}{1 + x^2} \,\diff{x} &= \arctan{x} + C \\ \int \frac{1}{\abs{x}\sqrt{x^2 - 1}} \,\diff{x} &= \arcsec{x} + C \end{aligned}

Symmetry

Sometimes, you need to calculate a definite integral, but you "can't" integrate something (i.e., you can't express the antiderivative in terms of trig functions, exponentials, polynomials, etc.). In some cases, you can still write down the answer:

Example 1.

Calculate 22sin(x3)dx\displaystyle \int_{-2}^2 \sin\p{x^3} \,\diff{x}.

Solution.

You won't be able to integrate f(x)=sin(x3)f\p{x} = \sin\p{x^3} no matter how hard you try. However, this function has a special property-it's an odd function:

f(x)=sin((x)3)=sin(x3)=sin(x3)=f(x).f\p{-x} = \sin\p{\p{-x}^3} = \sin\p{-x^3} = -\sin\p{x^3} = -f\p{x}.

Moreover, the definite integral we're trying to calculate has symmetric bounds, so the integral of ff on [2,0]\br{-2, 0} will cancel out with the integral on [0,2]\br{0, 2}. In other words,

22sin(x3)dx=0.\int_{-2}^2 \sin\p{x^3} \,\diff{x} = \boxed{0}.

uu-substitution

uu-substitution is the "reverse chain rule." This means you'll want to try it when you see a function and its derivative (maybe times a constant).

Example 2.

Calculate xsin(x2)dx\displaystyle \int x\sin\p{x^2} \,\diff{x}.

Solution.

Here, you can see x2x^2 and basically its derivative 2x2x, except we're missing a 22. This means we'll want to try u=x2u = x^2, which gives du=2xdx\diff{u} = 2x \,\diff{x}, so the integral becomes

xsin(x2)dx=sinudu2=12cosu+C=12cos(x2)+C.\begin{aligned} \int x\sin\p{x^2} \,\diff{x} &= \int \sin{u} \,\frac{\diff{u}}{2} \\ &= -\frac{1}{2} \cos{u} + C \\ &= \boxed{-\frac{1}{2} \cos\p{x^2} + C}. \end{aligned}
Example 3.

Calculate dxxlnx\displaystyle \int \frac{\diff{x}}{x\ln{x}}.

Solution.

We can write the integral as

1x1lnxdx,\int \frac{1}{x} \cdot \frac{1}{\ln{x}} \,\diff{x},

and from here, it's more clear that we see lnx\ln{x} and its derivative, so we can set u=lnxu = \ln{x} to get

dxxlnx=duu=lnu+C=lnlnx+C.\begin{aligned} \int \frac{\diff{x}}{x\ln{x}} &= \int \frac{\diff{u}}{u} \\ &= \ln\abs{u} + C \\ &= \boxed{\ln\abs{\ln{x}} + C}. \end{aligned}

Here's a fun problem that's similar:

Exercise 1.

Calculate dxx(lnx)ln(lnx)\displaystyle \int \frac{\diff{x}}{x\p{\ln{x}}\ln\p{\ln{x}}}.

Integration by Parts

Similar to uu-substitution, integration by parts is a "reverse product rule."

Theorem (integration by parts)
udv=uvvdu\int u \,\diff{v} = uv - \int v \,\diff{u}

Equivalently, you can write this as

f(x)g(x)dx=f(x)g(x)f(x)g(x)dx.\int f\p{x} g'\p{x} \,\diff{x} = f\p{x}g\p{x} - \int f'\p{x}g\p{x} \,\diff{x}.

In other words, integration by parts lets you replace f(x)f\p{x} with its derivative f(x)f'\p{x}, which can sometimes simplify the integral. For example, if f(x)=lnxf\p{x} = \ln{x}, then f(x)=1xf'\p{x} = \frac{1}{x}, which is generally easier to work with when integrating.

There are two main scenarios where you want to use integration by parts:

  1. When you want to integrate a product of two "random" functions.
  2. When you want to integrate a "weird" function by itself.
Example 4.

Calculate xcosxdx\displaystyle \int x\cos{x} \,\diff{x}.

Solution.

Here, we're in scenario 1 above. For this problem, you will want to use the parts u=xu = x and dv=cosxdv\diff{v} = \cos{x} \,\diff{v}, which give

du=dxandv=sinx.\diff{u} = \diff{x} \quad\text{and}\quad v = \sin{x}.

Then

xcosxdx=udv=uvvdu=xsinxsinxdx=xsinx+cosx+C.\begin{aligned} \int x\cos{x} \,\diff{x} &= \int u \,\diff{v} \\ &= uv - \int v \,\diff{u} \\ &= x\sin{x} - \int \sin{x} \,\diff{x} \\ &= \boxed{x\sin{x} + \cos{x} + C}. \end{aligned}
Example 5.

Calculate arcsinxdx\displaystyle \int \arcsin{x} \,\diff{x}.

Solution.

This time, we're in scenario 2. When this happens, we can just let u=arcsinxu = \arcsin{x} and dv=dx\diff{v} = \diff{x}, so

du=dx1x2andv=x.\diff{u} = \frac{\diff{x}}{\sqrt{1 - x^2}} \quad\text{and}\quad v = x.

Plugging everything in,

arcsinxdx=udv=uvvdu=xarcsinxx1x2dx.\begin{aligned} \int \arcsin{x} \,\diff{x} &= \int u \,\diff{v} \\ &= uv - \int v \,\diff{u} \\ &= x\arcsin{x} - \int \frac{x}{\sqrt{1 - x^2}} \,\diff{x}. \end{aligned}

So, we just need to calculate this new integral, which can be done using the substitution w=1x2w = 1 - x^2. This gives us dw=2xdx\diff{w} = -2x \,\diff{x}, so

x1x2dx=12dww=w+C=1x2+C.\begin{aligned} \int \frac{x}{\sqrt{1 - x^2}} \,\diff{x} &= -\frac{1}{2} \int \frac{\diff{w}}{\sqrt{w}} \\ &= -\sqrt{w} + C \\ &= -\sqrt{1 - x^2} + C. \end{aligned}

Thus,

arcsinxdx=xarcsinx+1x2+C.\int \arcsin{x} \,\diff{x} = \boxed{x\arcsin{x} + \sqrt{1 - x^2} + C}.

Trig Substitution

You usually want to try this technique when you see something similar to 1+x21 + x^2 or 1x21 - x^2 and a uu-substitution doesn't work. When this happens, you'll want to choose your substitution as follows:

1x2x=sinθ1+x2x=tanθ\begin{aligned} 1 - x^2 &\rightsquigarrow x = \sin{\theta} \\ 1 + x^2 &\rightsquigarrow x = \tan{\theta} \end{aligned}
Example 6.

Calculate dx1+x2\displaystyle \int \frac{\diff{x}}{\sqrt{1 + x^2}}.

Solution.

Any uu-substitution you try won't work here since there's no xx in the numerator, so we'll have to try a trig substitution. We're in the 1+x21 + x^2 case, so we can set x=tanθx = \tan{\theta}, which means dx=sec2θdθ\diff{x} = \sec^2{\theta} \,\diff{\theta}. Then

dx1+x2=sec2θ1+tan2θdθ=sec2θsecθdθ=secθdθ=lnsecθ+tanθ+C.\begin{aligned} \int \frac{\diff{x}}{\sqrt{1 + x^2}} &= \int \frac{\sec^2{\theta}}{\sqrt{1 + \tan^2{\theta}}} \,\diff{\theta} \\ &= \int \frac{\sec^2{\theta}}{\sec{\theta}} \,\diff{\theta} \\ &= \int \sec{\theta} \,\diff{\theta} \\ &= \ln\abs{\sec{\theta} + \tan{\theta}} + C. \end{aligned}

To finish the problem, we need to undo the substitution. We already know that tanθ=x\tan{\theta} = x (this was the substitution we started with), and for secθ\sec{\theta}, we can use our trig identities:

sec2θ=1+tan2θ=1+x2    secθ=1+x2.\sec^2{\theta} = 1 + \tan^2{\theta} = 1 + x^2 \implies \sec{\theta} = \sqrt{1 + x^2}.

Substituting everything back in, we get

dx1+x2=ln1+x2+x+C.\int \frac{\diff{x}}{\sqrt{1 + x^2}} = \boxed{\ln\abs{\sqrt{1 + x^2} + x} + C}.
Example 7.

Calculate 14x2dx\displaystyle \int \sqrt{1 - 4x^2} \,\diff{x}.

Solution.

If you don't remember your trig identities (like the double-angle identities), then it may be helpful to take a look at this review sheet I made for my 31B students last quarter (you can ignore everything starting at Series).

For this problem, we're essentially in the 1x21 - x^2 case, though it's not exactly in that form yet. We can write

14x2=1(2x)2,\sqrt{1 - 4x^2} = \sqrt{1 - \p{2x}^2},

so replacing xx with 2x2x, we get the substitution 2x=sinθ2x = \sin{\theta}. Then 2dx=cosθdθ2 \,\diff{x} = \cos{\theta} \,\diff{\theta}, and we get

14x2dx=121sin2θcosθdθ=12cos2θdθ=121+cos2θ2dθ(double-angle identity)=141+cos2θdθ=14(θ+12sin2θ)+C=14θ+18sin2θ+C.\begin{aligned} \int \sqrt{1 - 4x^2} \,\diff{x} &= \frac{1}{2} \int \sqrt{1 - \sin^2{\theta}} \cos{\theta} \,\diff{\theta} \\ &= \frac{1}{2} \int \cos^2{\theta} \,\diff{\theta} \\ &= \frac{1}{2} \int \frac{1 + \cos{2\theta}}{2} \,\diff{\theta} && \p{\text{double-angle identity}} \\ &= \frac{1}{4} \int 1 + \cos{2\theta} \,\diff{\theta} \\ &= \frac{1}{4} \p{\theta + \frac{1}{2} \sin{2\theta}} + C \\ &= \frac{1}{4} \theta + \frac{1}{8} \sin{2\theta} + C. \end{aligned}

Solving for θ\theta from 2x=sinθ2x = \sin{\theta}, we get θ=arcsin2x\theta = \arcsin{2x}. To undo the substitution for the other term, we'll need another identity:

sin2θ=2sinθcosθ\sin{2\theta} = 2\sin{\theta}\cos{\theta}

We already know sinθ=2x\sin{\theta} = 2x, and to get cosθ\cos{\theta},

cosθ=1sin2θ=14x2,\cos{\theta} = \sqrt{1 - \sin^2{\theta}} = \sqrt{1 - 4x^2},

which means

sin2θ=22x14x2=4x14x2.\sin{2\theta} = 2 \cdot 2x \cdot \sqrt{1 - 4x^2} = 4x\sqrt{1 - 4x^2}.

Putting everything together, we end up with

14x2dx=14arcsin2x+12x14x2+C.\int \sqrt{1 - 4x^2} \,\diff{x} = \boxed{\frac{1}{4} \arcsin{2x} + \frac{1}{2} x\sqrt{1 - 4x^2} + C}.