practicecalculus
Powers, roots and rational functions

Integral of x/(x² + 1): Formula, Steps and Examples

The integral of x/(x² + 1) is ½ ln(x² + 1) + C. See the u-substitution step by step, why no absolute value is needed, and related integrals like 1/(x² + 1).

Powers, roots and rational functions Updated 2 min read

At a glance

\int \frac{x}{x^2 + 1}\,dx = \frac{1}{2}\ln\left(x^2 + 1\right) + C
Antiderivative
\dfrac{1}{2}\ln\left(x^2 + 1\right) + C
Method
u-substitution with u = x^2 + 1
Absolute value
Not needed, since x^2 + 1 > 0
Symmetric interval
\int_{-a}^{a}\dfrac{x}{x^2 + 1}\,dx = 0
Compare
\int \dfrac{1}{x^2 + 1}\,dx = \arctan x + C
On this page
  1. Graph of x/(x² + 1) and its antiderivative
  2. The substitution, step by step
  3. Check by differentiating
  4. Definite integrals
  5. Related integrals
  6. Common mistakes

The integral of \dfrac{x}{x^2 + 1} is \dfrac{1}{2}\ln\left(x^2 + 1\right) + C. It is the textbook example of a u-substitution that turns into a log.

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

Graph of x/(x² + 1) and its antiderivative

Area under y = x/(x² + 1) from 0 to 2, with the antiderivative y = ½ ln(x² + 1)
The shaded area is \frac{1}{2}\ln 5 \approx 0.805. The function is odd, and its antiderivative is even: the dashed curve is symmetric about the y-axis with a minimum at x = 0.

The substitution, step by step

  1. Spot that the derivative of the denominator, 2x, matches the numerator up to a constant.
  2. Let u = x^2 + 1. Then du = 2x\,dx, so x\,dx = \frac{1}{2}du.
  3. Rewrite: \displaystyle\int \frac{x}{x^2 + 1}\,dx = \frac{1}{2}\int\frac{1}{u}\,du.
  4. Integrate with the integral of 1/x: \frac{1}{2}\ln\lvert u\rvert + C.
  5. Substitute back: \frac{1}{2}\ln\lvert x^2 + 1\rvert + C.
  6. Since x^2 + 1 \ge 1 > 0, drop the bars: \frac{1}{2}\ln(x^2 + 1) + C.

The general pattern is \int\frac{f'(x)}{f(x)}\,dx = \ln\lvert f(x)\rvert + C. Here the numerator is \frac{1}{2}f'(x), which gives the factor \frac{1}{2}.

Check by differentiating

\frac{d}{dx}\left[\frac{1}{2}\ln(x^2 + 1)\right] = \frac{1}{2}\cdot\frac{2x}{x^2 + 1} = \frac{x}{x^2 + 1} \checkmark

Definite integrals

Example 1. \int_0^1 \frac{x}{x^2 + 1}\,dx = \frac{1}{2}\ln 2 \approx 0.347.

Example 2. \int_{-3}^{3}\frac{x}{x^2 + 1}\,dx = 0. The integrand is odd, so the area on the left cancels the area on the right.

Example 3: changing the limits. With u = x^2 + 1, the limits x = 0 and x = 2 become u = 1 and u = 5:

\int_0^2 \frac{x}{x^2 + 1}\,dx = \frac{1}{2}\int_1^5\frac{du}{u} = \frac{1}{2}\ln 5

Small changes to the integrand change the method completely:

Integral Method Answer
\int\frac{x}{x^2 + 1}\,dx u = x^2 + 1 \frac{1}{2}\ln(x^2 + 1) + C
\int\frac{1}{x^2 + 1}\,dx known formula \arctan x + C
\int\frac{x}{(x^2 + 1)^2}\,dx u = x^2 + 1 -\frac{1}{2(x^2 + 1)} + C
\int\frac{x}{x^2 + a^2}\,dx u = x^2 + a^2 \frac{1}{2}\ln(x^2 + a^2) + C
\int\frac{x^3}{x^2 + 1}\,dx divide first \frac{x^2}{2} - \frac{1}{2}\ln(x^2 + 1) + C

For the last row, polynomial division gives \frac{x^3}{x^2 + 1} = x - \frac{x}{x^2 + 1}.

Example 4: split the numerator.

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

The second piece uses the integral of 1/(1 + x²).

Common mistakes

  1. Forgetting the \frac{1}{2}. du = 2x\,dx, so x\,dx is only half of du.
  2. Answering \arctan x. That is the integral of \frac{1}{x^2 + 1}, without the x on top.
  3. Writing \ln\lvert x\rvert\cdot\ln\lvert x^2 + 1\rvert or splitting the fraction as \frac{x}{x^2} + \frac{x}{1}. A fraction cannot be split over a sum in the denominator.
  4. Integrating \frac{x}{x^2 - 1} the same way and dropping the bars. That one gives \frac{1}{2}\ln\lvert x^2 - 1\rvert + C, and the absolute value matters.

More practice: u-substitution problems.

Practice it now

U-substitution

Solve real problems on this topic with instant feedback, hints and a step-by-step walkthrough for every answer. Free, no sign-up needed to start.

Practice this lesson

Frequently asked questions

What is the integral of x/(x² + 1)?

It is \frac{1}{2}\ln(x^2 + 1) + C. Use u = x^2 + 1, so x\,dx = \frac{1}{2}du.

What is the integral of 2x/(x² + 1)?

It is \ln(x^2 + 1) + C. The numerator is exactly the derivative of the denominator, so the answer is the log of the denominator.

What is the integral of x/(x² + 1) from 0 to 1?

It is \frac{1}{2}\ln 2 - \frac{1}{2}\ln 1 = \frac{1}{2}\ln 2 \approx 0.347.

Does the integral of x/(x² + 1) from 0 to infinity converge?

No. \frac{1}{2}\ln(b^2 + 1) \to \infty as b \to \infty, so the integral diverges. For large x the integrand behaves like \frac{1}{x}.

Written by the PracticeCalculus team

We build interactive calculus lessons and write every page to be clear and correct. Spotted something off? Tell us and we will fix it.