Tutorials › AP Calculus › Integration by Parts for Logarithmic and Inverse Trigonometric Functions

Numerical and BC Integration Methods · Tutorial 518 of 999

Integration by Parts for Logarithmic and Inverse Trigonometric Functions

Use integration by parts on a logarithmic or inverse trigonometric function by treating it as a factor multiplied by 1.

Advanced 8 min read

What You'll Learn

  • Rewrite a logarithmic or inverse trigonometric integrand as a product with 1.
  • Choose the function to differentiate and the factor to integrate.
  • Find antiderivatives of \(\ln x\), \(\arctan x\), and \(\arcsin x\).
  • Track the domains where each formula and derivative applies.
  • Check each result by differentiating it.
  • Recognize and correct common errors with these integrals.

Why Multiply by 1?

Some functions do not have an obvious antiderivative when they appear alone. A useful strategy is to regard the function as a product with \(1\). For example, \(\ln x\) can be written as \((\ln x)(1)\), and \(\arctan x\) can be written as \((\arctan x)(1)\). That form allows us to use integration by parts.

The choice is effective because differentiating a logarithmic or inverse trigonometric function often produces a simpler expression, while the factor \(1\) has the simple antiderivative \(x\). The resulting integral is then manageable using substitution or a familiar derivative.

Key idea: To integrate a logarithmic or inverse trigonometric function by itself, write it as that function times \(1\). Differentiate the logarithmic or inverse trigonometric factor, and integrate \(1\).

The Rule and the Setup

Integration by parts follows from the product rule. In its indefinite-integral form, if \(u\) and \(v\) are differentiable functions, then

$$ \int u\,dv=uv-\int v\,du. $$

For an integral such as \(\int \ln x\,dx\), the factor choices are \(u=\ln x\) and \(dv=dx\). Thus \(du=\frac{1}{x}\,dx\) and \(v=x\). The key is not just applying the formula: it is choosing factors so the new integral is easier than the original one.

Domain condition: The formula for an antiderivative applies on an interval where the functions and derivatives involved are defined. In particular, \(\ln x\) is defined for \(x>0\); \(\arctan x\) is defined for all real \(x\); and the derivative formula for \(\arcsin x\) applies for \(-1<x<1\).

For these examples, \(dv=dx\), so \(v=x\). The resulting pattern is

$$ \int f(x)\,dx = x f(x)-\int x f'(x)\,dx, $$

provided \(f\) is differentiable on the interval considered. This is the integration-by-parts formula with \(u=f(x)\) and \(dv=dx\). It is not a shortcut that automatically makes every integral easy; the remaining integral still has to be evaluated.

Worked Example: The Natural Logarithm

Worked Example: Integrating \(\ln x\)

Find \(\int \ln x\,dx\) for \(x>0\).

Step 1: Choose the factors. Write the integrand as \((\ln x)(1)\). Let \(u=\ln x\), so \(du=\frac{1}{x}\,dx\), and let \(dv=dx\), so \(v=x\).

Step 2: Apply integration by parts.

$$ \int \ln x\,dx =x\ln x-\int x\left(\frac{1}{x}\right)\,dx. $$

Step 3: Simplify and integrate. Since \(x(1/x)=1\) for \(x>0\),

$$ \int \ln x\,dx =x\ln x-\int 1\,dx =x\ln x-x+C. $$

Check: Differentiate the proposed antiderivative:

$$ \frac{d}{dx}(x\ln x-x) = \ln x+x\left(\frac{1}{x}\right)-1 = \ln x+1-1 = \ln x. $$

The derivative matches the integrand, so \(\int \ln x\,dx=x\ln x-x+C\) on \(x>0\).

The product rule is what makes the method work: differentiating \(x\ln x\) produces both \(\ln x\) and \(1\). Subtracting the antiderivative of the extra \(1\) leaves precisely the desired function.

Worked Example: The Inverse Tangent

Worked Example: Integrating \(\arctan x\)

Find \(\int \arctan x\,dx\). The function is defined for all real \(x\), and its derivative is \(\frac{1}{1+x^2}\).

Step 1: Choose the factors. Let \(u=\arctan x\), so \(du=\frac{1}{1+x^2}\,dx\). Let \(dv=dx\), so \(v=x\).

Step 2: Apply integration by parts.

$$ \int \arctan x\,dx = x\arctan x-\int \frac{x}{1+x^2}\,dx. $$

Step 3: Evaluate the remaining integral. In \(\int \frac{x}{1+x^2}\,dx\), the derivative of \(1+x^2\) is \(2x\). Therefore,

$$ \int \frac{x}{1+x^2}\,dx = \frac{1}{2}\ln(1+x^2)+C, $$

because \(1+x^2>0\) for every real \(x\). Substituting this into the parts calculation gives

$$ \int \arctan x\,dx = x\arctan x-\frac{1}{2}\ln(1+x^2)+C. $$

Check:

$$ \frac{d}{dx}\left(x\arctan x-\frac{1}{2}\ln(1+x^2)\right) = \arctan x+\frac{x}{1+x^2} -\frac{1}{2}\left(\frac{2x}{1+x^2}\right) = \arctan x. $$

The two rational terms cancel, leaving the original integrand.

Worked Example: The Inverse Sine

Worked Example: Integrating \(\arcsin x\)

Find \(\int \arcsin x\,dx\) for \(-1<x<1\). On this interval, \(\frac{d}{dx}(\arcsin x)=\frac{1}{\sqrt{1-x^2}}\).

Step 1: Choose the factors. Let \(u=\arcsin x\), so \(du=\frac{1}{\sqrt{1-x^2}}\,dx\). Let \(dv=dx\), so \(v=x\).

Step 2: Apply integration by parts.

$$ \int \arcsin x\,dx = x\arcsin x-\int \frac{x}{\sqrt{1-x^2}}\,dx. $$

Step 3: Evaluate the remaining integral. Set \(w=1-x^2\). Then \(dw=-2x\,dx\), so \(x\,dx=-\frac{1}{2}\,dw\). Thus

$$ \int \frac{x}{\sqrt{1-x^2}}\,dx = -\frac{1}{2}\int w^{-1/2}\,dw = -\frac{1}{2}(2w^{1/2}) = -\sqrt{w} = -\sqrt{1-x^2}. $$

Step 4: Substitute this result back. The minus sign in the parts formula matters:

$$ \int \arcsin x\,dx = x\arcsin x-\bigl(-\sqrt{1-x^2}\bigr)+C = x\arcsin x+\sqrt{1-x^2}+C. $$

Check: For \(-1<x<1\),

$$ \frac{d}{dx}\left(x\arcsin x+\sqrt{1-x^2}\right) = \arcsin x+\frac{x}{\sqrt{1-x^2}} -\frac{x}{\sqrt{1-x^2}} = \arcsin x. $$

The derivative is the original integrand. The formula holds on the open interval \((-1,1)\), where the derivative calculation is defined.

Why the Method Works

Here is the product-rule justification in full. Suppose \(u\) and \(v\) are differentiable on an interval. The product rule states

$$ \frac{d}{dx}(uv)=u'v+uv'. $$

Rearrange to isolate one product of a function and a derivative:

$$ uv'= \frac{d}{dx}(uv)-u'v. $$

Integrating both sides gives

$$ \int uv'\,dx = uv-\int vu'\,dx+C. $$

In differential notation, this is \(\int u\,dv=uv-\int v\,du\). For a logarithm or inverse trigonometric function by itself, choose that function as \(u\), and choose \(dv=dx\). Then \(v=x\), so the new integral contains \(x\) times the derivative of the original function. In the examples, this new integral is simpler and can be completed directly.

Choosing Factors and Checking Domains

For this particular family of integrals, the useful setup is consistent: set the logarithmic or inverse trigonometric function equal to \(u\), and set \(dv=dx\). Reversing that choice is not useful because it would require integrating the logarithmic or inverse trigonometric function in order to obtain \(v\), which is the original problem.

The function’s domain also determines where the result applies. For example, \(\ln x\) requires \(x>0\). On any interval that does not contain zero, one can also integrate \(\ln|x|\): its derivative is \(1/x\), so the same calculation gives

$$ \int \ln|x|\,dx=x\ln|x|-x+C. $$

This formula applies separately on intervals \(x<0\) and \(x>0\); \(\ln|x|\) is not defined at \(x=0\). For \(\arcsin x\), keep the derivative calculation inside \((-1,1)\). At the endpoints, the derivative formula used in the example is not defined.

Common Pitfall: Confusing a Derivative with an Antiderivative

A frequent error is to use the derivative of a logarithm as though it were its antiderivative. For instance, the calculation

$$ \int \ln x\,dx=\frac{1}{x}+C $$

is incorrect: \(1/x\) is the derivative of \(\ln x\), not an antiderivative of \(\ln x\). Checking by differentiation exposes the problem:

$$ \frac{d}{dx}\left(\frac{1}{x}\right)=-\frac{1}{x^2}\ne \ln x. $$

The correction is to use integration by parts, which gives \(x\ln x-x+C\). Its derivative is \(\ln x\), as verified in the worked example.

A second sign-related risk appears when the remaining integral is itself negative, as in the \(\arcsin x\) example. There, \(\int \frac{x}{\sqrt{1-x^2}}\,dx=-\sqrt{1-x^2}\), and the parts formula subtracts that whole result. Keeping the parentheses makes the sign clear: \(-(-\sqrt{1-x^2})=+\sqrt{1-x^2}\).

Check Your Understanding

For each question, state the domain conditions and use differentiation to check any antiderivative you find.

  1. In \(\int \ln x\,dx\), what choices of \(u\) and \(dv\) make integration by parts useful?
  2. Find \(\int \arctan x\,dx\) and show how the two rational terms cancel when you differentiate your answer.
  3. Why does integrating \(\ln x\) as \(1/x+C\) fail? Verify the failure by differentiating \(1/x\).
  4. Find \(\int \arcsin x\,dx\) for \(-1<x<1\). Where does the plus sign before the square-root term come from?
  5. On which intervals is the formula \(\int \ln|x|\,dx=x\ln|x|-x+C\) valid?

Test yourself: AP Calculus practice exams

Ready to check what you know? Work an AP-style practice exam, then open the full solutions.

Want all 1,114 practice problems?

This tutorial covers one topic. Calc Pass covers all of AP Calculus AB & BC: full review, every practice question, and step-by-step solutions to each one.

QR code to download the Calc Pass app

Get the Calc Pass App

Scan to download and practice on the go, with instant scoring.

Calc Pass Volume 1: 1,114 Practice Questions book cover

Vol. 1: 1,114 Questions

The complete practice question bank, organized by AB & BC topic.

View on Amazon
Calc Pass Volume 2: Solutions Manual book cover

Vol. 2: Solutions Manual

Fully worked solutions to every question in Volume 1.

View on Amazon