# Derivative of ln x

How to solve the derivative of ln x problems: formulas (ln x, ln |x|), proofs, examples, and their solutions.

## Formula: [ln x]'

The derivative of ln x is 1/x.

## Formula: [ln |x|]'

The derivative of ln |x| is also 1/x.

## Proofs

Let's prove [ln x]' = 1/x.

Use the definition of a derivative function.

Move the denominator h to the front part.

Split the base into two fractions
and simplify x/x.

Move 1/h into the base's exponent.

Logarithms of powers

The base is 1 + h/x.

So, change the exponent 1/h into x/h.
(the reciprocal of h/x)

And, to undo the x,
multiply 1/x to the exponent.

Take the exponent 1/x out.

Logarithms of powers

As h → 0,
the gray part goes to e.

Definition of e (Mathematical constant)

So (right side) = (1/x) ln e.

So [ln x]' = 1/x.

Case 1: x > 0

|x| = x

So [ln |x|]' = [ln x]'.
= 1/x.

So [ln |x|]' = 1/x
when x > 0.

Case 2: x < 0

|x| = -x

So [ln |x|]' = [ln (-x)]'.

And [ln (-x)]' = [1/(-x)]⋅(-1).

(Multiplied -1 is the derivative of -x.)

Chain rule in differentiation

So [ln |x|]' = 1/x
when x < 0.

So [ln |x|]' = 1/x.

## Example 1

y = ln (2x + 7)

So y' is equal to,
the derivative of the outer part, 1/(2x + 7)
times, the derivative of the inner part, 2.

Chain rule in differentiation

Derivative of polynomials

## Example 2

y = ln |x3 - 2x|

So y' is equal to,
the derivative of the outer part, 1/(x3 - 2x)
times, the derivative of the inner part, (3x2 - 2).

Chain rule in differentiation

Derivative of polynomials

## Example 3

Take the exponent 4 out.

Logarithms of powers

y = 4 ln |x|

So y' = 4⋅(1/x).

## Example 3: Different Solution

Let's solve this example differently.

Think y = ln x4 as a composite function:
y = ln (x4).

Then y' is equal to,
the derivative of the outer part, 1/x4
times, the derivative of the inner part, 4x3.

Chain rule in differentiation

Power rule in differentiation (Part 1)

(1/x4)⋅4x3 = 4/x

As you can see,
you can get the same answer: 4/x.

## Example 4

y = (x3)(ln x)

So y' is equal to,
the derivative of x3, 3x2
times ln x
plus x3,
times, the derivative of ln x, 1/x.

Product rule in differentiation

Derivative of polynomials

## Example 5

ln both sides,
covering the bases with the absolute value signs.

(The absolute value signs are added
becasue both sides can be (-).)

Natural logarithms

Differentiate both sides.

Implicit differentiation

Product rule in differentiation

Multiply y on both sides.

Change y into xx.

Then y' = xx(ln |x| + 1).