Navigation: Wiki Home > Skills > Integrals Yielding Natural Logarithm
Remember the power rule for integration?
$$\int x^n \, dx = \frac{x^{n+1}}{n+1} + C \quad \text{(when } n \neq -1\text{)}$$
What happens when $n = -1$? The formula would give $\frac{x^0}{0}$, which is undefined.
This is where the natural logarithm saves us:
$$\boxed{\int \frac{1}{x}\,dx = \ln\vert x\vert + C}$$
The integral of $\frac{1}{x}$ is not a power function—it's a logarithm. This formula fills the one gap in the power rule and connects differentiation of logs back to integration.
Test: What is $\frac{d}{dx}[\ln(x^2 + 1)]$?
Answer: $\frac{2x}{x^2 + 1}$
If this is unfamiliar, review Derivative of Natural Log first.
| Integral | Result | Valid Domain |
|---|---|---|
| $\displaystyle\int \frac{1}{x}\,dx$ | $\ln\|x\| + C$ | $x \neq 0$ |
| $\displaystyle\int \frac{f'(x)}{f(x)}\,dx$ | $\ln\|f(x)\| + C$ | $f(x) \neq 0$ |
| $\displaystyle\int \frac{1}{ax + b}\,dx$ | $\frac{1}{a}\ln\|ax + b\| + C$ | $ax + b \neq 0$ |
Verification: You can always check by differentiating your answer.
$$\boxed{\int \frac{1}{x}\,dx = \ln\vert x\vert + C}$$
Why the absolute value? The function $\frac{1}{x}$ is defined for all $x \neq 0$, including negative $x$. But $\ln x$ only accepts positive inputs. The absolute value extends our antiderivative to negative values:
This is the most important formula for recognizing ln integrals:
$$\boxed{\int \frac{f'(x)}{f(x)}\,dx = \ln\vert f(x)\vert + C}$$
In words: If the numerator is the derivative of the denominator, the integral is ln of the denominator.
How to spot it:
For $\int \frac{1}{ax + b}\,dx$:
Let $u = ax + b$, so $du = a\,dx$, meaning $dx = \frac{1}{a}du$.
$$\int \frac{1}{ax + b}\,dx = \frac{1}{a}\int \frac{1}{u}\,du = \frac{1}{a}\ln\vert u\vert + C = \frac{1}{a}\ln\vert ax + b\vert + C$$
Shortcut formula: $$\boxed{\int \frac{1}{ax + b}\,dx = \frac{1}{a}\ln\vert ax + b\vert + C}$$
Evaluate $\displaystyle\int_1^e \frac{1}{x}\,dx$.
Evaluate $\displaystyle\int \frac{1}{3x + 5}\,dx$.
Evaluate $\displaystyle\int \frac{2x}{x^2 + 4}\,dx$.
Evaluate $\displaystyle\int \frac{x}{x^2 + 1}\,dx$.
Evaluate $\displaystyle\int \tan x\,dx$.
Evaluate $\displaystyle\int_1^e \frac{\ln x}{x}\,dx$.
Find the area of the region under $y = \frac{1}{x}$ from $x = 1$ to $x = 2$.
Why do we write $\int \frac{1}{x}dx = \ln\vert x\vert + C$ instead of $\ln x + C$?
Verify that $\frac{d}{dx}(\ln\vert x\vert ) = \frac{1}{x}$ for both positive and negative $x$.
When you see an integral, ask these questions:
| Mistake | Why It's Wrong | Correct Approach |
|---|---|---|
| $\int \frac{1}{x}dx = \ln x + C$ | Missing absolute value | $\ln\|x\| + C$ |
| $\int \frac{1}{2x}dx = \ln\|2x\| + C$ | Forgot the coefficient adjustment | $\frac{1}{2}\ln\|2x\| + C$ or equivalently $\frac{1}{2}\ln\|x\| + C$ |
| $\int \frac{x}{x^2}dx = \ln\|x^2\| + C$ | The numerator is not the derivative of denominator | $\int \frac{1}{x}dx = \ln\|x\| + C$ |
| Writing $\ln(x^2 + 4)$ without checking sign | Could need absolute value | Here $x^2 + 4 > 0$ always, so no absolute value needed |
"Derivative on top, function on bottom = ln of the bottom"
When you see a fraction where:
Then the integral is $\ln\vert f(x)\vert + C$.
Visual check: Cover the numerator. Take its derivative mentally. Does it match (or nearly match) the numerator you see? If yes, use ln.
Looking back:
Looking ahead:
Real-world applications:
| Previous | Up | Next |
|---|---|---|
| Derivative of General Logs | Section 6.4 | e as a Limit |
Last updated: 2026-01-23