∫Yoboa Math
Home / Integral of 1/x
Integral Reference

Integral of 1/x

Step-by-step derivation, definite integral examples, and common variants.

The power rule \(\int x^n\,dx = rac{x^{n+1}}{n+1} + C\) fails at n = −1 because dividing by zero is undefined. The integral of 1/x fills that gap with a logarithm.

Result

\[ \int \frac{1}{x}\,dx = \ln|x| + C \]

Derivation

Since \(\dfrac{d}{dx}[\ln|x|] = \dfrac{1}{x}\) for all \(x \neq 0\), the antiderivative is:

\[ \int \frac{1}{x}\,dx = \ln|x| + C \]

The absolute value is essential: \(\ln(x)\) is only defined for \(x > 0\), but \(1/x\) is defined (and integrable) for \(x < 0\) too. On \(x < 0\), \(\dfrac{d}{dx}[\ln(-x)] = \dfrac{1}{x}\), which is captured by \(\ln|x|\).

Definite integral examples

\(\int_1^e \frac{1}{x}\,dx\)

\[ \Big[\ln|x|\Big]_1^e = \ln(e) - \ln(1) = 1 - 0 = 1 \]

\(\int_1^{10} \frac{1}{x}\,dx\)

\[ \Big[\ln(x)\Big]_1^{10} = \ln(10) \approx 2.303 \]

Common variants

IntegralAntiderivativeNotes
\(\int \frac{1}{ax + b}\,dx\)\(\dfrac{\ln|ax+b|}{a} + C\)u-substitution: \(u = ax + b\).
\(\int \frac{f\'(x)}{f(x)}\,dx\)\(\ln|f(x)| + C\)General logarithmic integration: numerator is the derivative of the denominator.

Try it in the calculator

Paste any variant below into the step-by-step integral calculator for a full worked solution and graph.

Open in calculator →

Related guides