Also, when integration by parts can be applied, i.e. \(u(x)\) and \(v(x)\) are differentiable functions, it follows from the fundamental theorem of Calculus that the analogous relation holds for definite integrals,
Let us use integration by parts to work out the indefinite integral \(\int
\ln(x)\ dx\text{.}\) Comparing \(\ln(x)dx\) with \(udv\text{,}\) we can set \(u=\ln(x)\) and \(dv = dx\text{.}\) Clearly, \(v(x)=x\) is a function with \(dv=dx\text{.}\) Now according to Equation (3.1)
\begin{align*}
\int \ln(x) dx & = x\ln(x) - \int x d\ln(x) \\
& = x\ln(x) - \int x \frac{1}{x} dx \\
& = x\ln(x)
- \int dx \\
& = x\ln(x) - x + C.
\end{align*}
Checkpoint3.2.
Find the indefinite integral \(\ds \int x\cos(x) dx\text{.}\)
\begin{align*}
\int x\cos(x)dx & = x\sin(x)-\int \sin(x)dx \\
& =x\sin(x)- (-\cos(x)) + C \\
& =x\sin(x) +\cos(x) + C.
\end{align*}
Checkpoint3.3.
Find the indefinite integral \(\ds \int x^2\sin(x) dx\text{.}\)
Hint.
Set \(u=x^2\) and \(dv = \sin(x)dx\text{.}\) Then apply IBP twice.
Example3.4.
As another example, let us compute \(\int e^x \cos(x) dx\text{.}\) Let \(u = e^x\) and \(dv = \cos(x) dx\text{.}\) Then \(du = e^x dx\) and we take \(v = \sin(x)\text{.}\) So IBP yields,
At the first glance, we are getting nowhere because computing \(\int e^x \sin(x)
dx\) is as hard as the original problem. However, applying IBP one more time, we get
and the original integral, call it \(J\text{,}\) reappears. Thus,
\begin{align*}
J &= e^x \sin x - (-e^x\cos x + J) \\
2J & = e^x (\sin x + \cos x)+ C \\
J & = \frac{e^x(\sin x + \cos x)}{2} + C.
\end{align*}
Checkpoint3.5.
Compute the integral in the example above that is, compute\(\int
e^x\cos(x) dx\) again but this time set \(u=\cos(x)\) and \(dv
= e^x dx\text{.}\) (See also Exercise 3.5.5.)
In some situations, IBP leads to relations called reduction formulas. For instance, using IBP we have
Each application of (3.2) reduces to power of the integrand (in this case, by 2). Eventually, the problem becomes finding either \(I_1=\int \sin(x)dx\) (\(n\) odd) or \(I_0=\int dx\) (\(n\) even) which has already been solved.
Example3.6.
As an example, let us compute the integral \(\int \sin^3(x)
dx\text{.}\) For \(n=3\text{,}\) the reduction (3.2) reads
See Exercise 3.5.3 for reduction formulas for powers of other trigonometric functions.
Example3.7.
Example 3.1 naturally needs to the following reduction formula for the integral of powers of \(\ln(x)\) Write \(I_n =
\ds \int (\ln(x))^n dx\text{.}\) Then
This time let us evaluate the integral \(\ds \int x\arctan(2x)
dx\) using integration by parts. Since the antiderivates of \(\arctan(2x)\) is not readily available, this prompts one to try \(u=\arctan(2x)\) and \(dv = xdx\text{.}\) So, \(du = \dfrac{2
dx}{1+4x^2}\) and one can take \(v=x^2/2\text{.}\) Thus,
From the expression on the right hand side, one recognizes \(\frac{1}{4}\left(x - \frac{1}{2}\arctan(2x)\right)\) is an anit-derivative. Therefore, the original indefinite integral is evaluated to