The kf'(x)/f(x) Form

Recognising and integrating $\dfrac{k\,f'(x)}{f(x)}$, including $\displaystyle\int \tan x\, \text{d}x$ — the logarithmic integral pattern
9709 Paper 3 · §3.5 Integration · Week 6 Lesson 5
💡 Lead In: The Hidden Connection

Quick Recall

Quick check — pick the correct statement before we meet today's wall.

Recall 1 — What is $\displaystyle\int \frac{1}{ax+b}\, \text{d}x$?
$\dfrac{1}{a}\ln|ax+b| + C$
$a\ln|ax+b| + C$
$\ln|ax+b| + C$
$\dfrac{1}{ax+b}\ln|a| + C$

$\displaystyle\int \frac{1}{ax+b}\, \text{d}x = \frac{1}{a}\ln|ax+b| + C$, because $\dfrac{\text{d}}{\text{d}x}\big(\ln|ax+b|\big) = \dfrac{a}{ax+b}$ and the extra factor $a$ must be cancelled.

Recall 2 — Why does the factor $\dfrac{1}{a}$ appear in the answer?
Because the integral of a fraction always has a constant factor
Because $a$ is the integration constant
The chain rule multiplies the derivative of $\ln|ax+b|$ by $a$, so the reverse process divides by $a$
Because $\ln|ax+b|$ differentiates to $a$ times itself

$\dfrac{\text{d}}{\text{d}x}\big(\ln|ax+b|\big) = \dfrac{a}{ax+b}$ — the inner function $ax+b$ differentiates to $a$. Reversing this to integrate $\dfrac{1}{ax+b}$ therefore needs a compensating $\dfrac{1}{a}$. Today's lesson generalises this same "reverse the chain rule" idea.

The Wall

But now consider this integral:

$$\int \frac{x}{x^2+1}\, \text{d}x = \;?$$

The denominator is $x^2+1$, not a simple $ax+b$. The formula from L1 does not directly apply. A student tries “maybe $\ln|x^2+1| + C$?” — but differentiating $\ln|x^2+1|$ gives $\dfrac{2x}{x^2+1}$ (chain rule!), which is twice the integrand. The guess is too big by a factor of 2.

The Need

The key insight: the derivative of the denominator is $2x$, and the numerator $x$ is exactly half of $2x$. So we can write:

$$\frac{x}{x^2+1} = \frac{1}{2} \cdot \frac{2x}{x^2+1} = \frac{1}{2} \cdot \frac{f'(x)}{f(x)}$$

where $f(x) = x^2+1$ and $f'(x) = 2x$.

Today we learn the general rule: if the numerator is a constant multiple of the derivative of the denominator, the integral is a logarithm.

💡 The Bridge (click to reveal)

The chain rule for logarithms says: $\dfrac{\text{d}}{\text{d}x}\!\left[\ln|f(x)|\right] = \dfrac{f'(x)}{f(x)}$.

Reversing this gives the master formula:

$$\int \frac{f'(x)}{f(x)}\, \text{d}x = \ln|f(x)| + C$$

More generally, if the numerator is $k$ times the derivative of the denominator:

$$\int \frac{k\,f'(x)}{f(x)}\, \text{d}x = k\ln|f(x)| + C$$

For our problem: $\displaystyle\int \frac{x}{x^2+1}\, \text{d}x = \frac{1}{2}\ln|x^2+1| + C$. Verify: $\dfrac{\text{d}}{\text{d}x}\!\left(\frac{1}{2}\ln|x^2+1|\right) = \frac{1}{2} \cdot \frac{2x}{x^2+1} = \frac{x}{x^2+1}$. It checks!

📖 Key Concepts: The kf'(x)/f(x) Pattern

Last lesson we used partial fractions to integrate rational functions. Today we learn to recognise a special pattern: when the numerator is a constant multiple of the derivative of the denominator, the integral is a logarithm.

Key relation 1 — The master pattern:

From the chain rule, $\dfrac{\text{d}}{\text{d}x}\!\left[\ln|f(x)|\right] = \dfrac{f'(x)}{f(x)}$. Reversing gives:

$$\boxed{\;\int \frac{k\,f'(x)}{f(x)}\, \text{d}x = k\ln|f(x)| + C\;}\qquad(f(x) \neq 0)$$

The key test: is the numerator a constant multiple of the derivative of the denominator? If yes, identify $f(x)$, $f'(x)$, and the constant $k$, then apply the formula.

Key relation 2 — Special case: $\int \dfrac{1}{ax+b}\, \text{d}x$:

This is a special case of the master pattern with $f(x) = ax+b$, $f'(x) = a$. Here $\dfrac{1}{ax+b} = \dfrac{1}{a} \cdot \dfrac{a}{ax+b} = \dfrac{1}{a} \cdot \dfrac{f'(x)}{f(x)}$, so $k = \dfrac{1}{a}$:

$$\boxed{\;\int \frac{1}{ax+b}\, \text{d}x = \frac{1}{a}\ln|ax+b| + C\;}\qquad(a \neq 0)$$

This connects back to Lesson 1 — the formula we already knew is just the $kf'(x)/f(x)$ pattern with $f(x) = ax+b$.

Key relation 3 — $\int \tan x\, \text{d}x$:

Since $\tan x = \dfrac{\sin x}{\cos x}$, let $f(x) = \cos x$. Then $f'(x) = -\sin x$, so $\sin x = -f'(x)$.

Therefore $\tan x = \dfrac{\sin x}{\cos x} = \dfrac{-f'(x)}{f(x)} = -\dfrac{f'(x)}{f(x)}$, meaning $k = -1$.

Applying the master pattern:

$$\boxed{\;\int \tan x\, \text{d}x = -\ln|\cos x| + C\;}\qquad(\cos x \neq 0)$$

This is one of the most important results in the integration toolkit. Verify: $\dfrac{\text{d}}{\text{d}x}\!\left(-\ln|\cos x|\right) = -\dfrac{-\sin x}{\cos x} = \tan x$. It checks!

Group Activity 1: Approve the Pattern — Reveal Every Line

In groups of three you must approve each line before it is shown. At every stage, pick the line you believe comes next in the evaluation of $\displaystyle\int \dfrac{4x+6}{x^{2}+3x+5}\,\text{d}x$. A correct pick reveals the line and unlocks the next stage; a wrong pick turns red and explains the trap. Four or fewer wrong picks in the whole run earns the top band.

Stage approved: 0 / 5 Wrong picks: 0 Goal: 0 wrong picks

Group rule: nobody clicks until all three members agree on the line. If you disagree, say why — that disagreement is where the learning happens.

Individual Activity 2: Pattern Detective — Name the Shared Rule

On your own. Each level shows three integrals. Your job is to name the rule they share, not to evaluate them. Level 2 only opens when level 1 is cleared, and only a perfect first attempt at every level earns all three stars.

Level: 1 / 3 First-attempt clear: 0 / 3
Group · Guided Worked Example 1: Identify the Constant Multiple Exercise 8C Q1(ii)

Find $\displaystyle\int \frac{2x+3}{3x^{2}+9x-1} \, \text{d}x$.

👁 Reveal Solution
Step 1: Identify $f(x)$, $f'(x)$ and $k$

The denominator plays the part of $f(x)$, so take $f(x) = 3x^{2}+9x-1$.

Differentiate it: $f'(x) = 6x+9 = 3(2x+3)$.

Now test the numerator. Is $2x+3$ a constant multiple of $f'(x)$? Yes:

$2x+3 = \dfrac{1}{3}\cdot 3(2x+3) = \dfrac{1}{3}f'(x)$, so $k = \dfrac{1}{3}$, which is a constant.

Since the numerator is a constant multiple of the derivative of the denominator, the master pattern applies. (If the multiplier depended on $x$ it would not be a constant, and the pattern would fail.)

Step 2: Apply the master pattern

Using $\displaystyle\int \frac{k\,f'(x)}{f(x)}\, \text{d}x = k\ln|f(x)| + C$ with $k = \dfrac{1}{3}$:

$\displaystyle\int \frac{2x+3}{3x^{2}+9x-1}\, \text{d}x = \frac{1}{3}\ln|3x^{2}+9x-1| + C$

$\boxed{\displaystyle\int \frac{2x+3}{3x^{2}+9x-1}\, \text{d}x = \frac{1}{3}\ln|3x^{2}+9x-1| + C}$

Step 3: Check by differentiating

$\dfrac{\text{d}}{\text{d}x}\!\left[\frac{1}{3}\ln|3x^{2}+9x-1|\right] = \frac{1}{3}\cdot\dfrac{6x+9}{3x^{2}+9x-1} = \dfrac{2x+3}{3x^{2}+9x-1}$. It checks!

The integral is valid wherever $3x^{2}+9x-1 \neq 0$.

Individual · Guided Worked Example 2: A Definite Integral Exercise 8C Q2(ii)

Find $\displaystyle\int_{4}^{6} \frac{x-3}{x^{2}-6x+9} \, \text{d}x$, giving your answer to 3 significant figures where appropriate.

👁 Reveal Solution
Step 1: Recognise the pattern

Write the denominator as a perfect square: $x^{2}-6x+9 = (x-3)^{2}$, so take $f(x) = (x-3)^{2}$.

Then $f'(x) = 2(x-3) = 2x-6$, and the numerator is $x-3 = \dfrac{1}{2}f'(x)$. So $k = \dfrac{1}{2}$.

Step 2: Find the antiderivative

$\displaystyle\int \frac{x-3}{x^{2}-6x+9}\, \text{d}x = \frac{1}{2}\ln\left|(x-3)^{2}\right| + C$

Using $\ln|a^{2}| = 2\ln|a|$, this is $\dfrac{1}{2}\cdot 2\ln|x-3| = \ln|x-3| + C$.

Step 3: Evaluate the definite integral

$\displaystyle\int_{4}^{6} \frac{x-3}{x^{2}-6x+9}\, \text{d}x = \left[\frac{1}{2}\ln\left|(x-3)^{2}\right|\right]_{4}^{6}$

$= \frac{1}{2}\left(\ln\left|(6-3)^{2}\right| - \ln\left|(4-3)^{2}\right|\right) = \frac{1}{2}\left(\ln 9 - \ln 1\right)$

$= \frac{1}{2}\ln 9 = \frac{1}{2} \cdot 2\ln 3 = \ln 3 \approx 1.10$ (3 s.f.)

$\boxed{\displaystyle\int_{4}^{6} \frac{x-3}{x^{2}-6x+9}\, \text{d}x = \ln 3 \approx 1.10}$

Comment

On $4 \leqslant x \leqslant 6$ we have $x-3 > 0$, so the modulus signs are not needed in the final answer.

The denominator is zero only at $x = 3$, which lies outside the interval of integration, so the definite integral is well defined.

✏️ Concept Quiz
Score: 0 / 4
1. Which of the following integrals is of the form $\displaystyle\int \frac{k\,f'(x)}{f(x)}\, \text{d}x$ (with constant $k$)?
$\displaystyle\int \frac{x^2}{x^2+1}\, \text{d}x$
$\displaystyle\int \frac{6x}{x^2+4}\, \text{d}x$
$\displaystyle\int \frac{x+1}{x^2+1}\, \text{d}x$
$\displaystyle\int \frac{\sin x}{x}\, \text{d}x$
For $\int \frac{6x}{x^2+4}\, \text{d}x$: $f(x) = x^2+4$, $f'(x) = 2x$, and $\frac{6x}{x^2+4} = 3 \cdot \frac{2x}{x^2+4} = 3 \cdot \frac{f'(x)}{f(x)}$, so $k = 3$ (constant). This is the only option where the numerator is a constant multiple of $f'(x)$. For $\frac{x^2}{x^2+1}$: $f(x) = x^2+1$, $f'(x) = 2x$, and $x^2$ is not a constant multiple of $2x$ (it would require $k = x/2$, which is not constant). For $\frac{x+1}{x^2+1}$: $x+1$ is not a constant multiple of $2x$. For $\frac{\sin x}{x}$: $f(x) = x$, $f'(x) = 1$, and $\sin x$ is not a constant multiple of $1$.
2. The integral $\displaystyle\int \frac{4x}{x^2+7}\, \text{d}x$ equals:
$\dfrac{1}{2}\ln|x^2+7| + C$
$2\ln|x^2+7| + C$
$4\ln|x^2+7| + C$
$\ln|x^2+7| + C$
Here $f(x) = x^2+7$, $f'(x) = 2x$. Write $\frac{4x}{x^2+7} = 2 \cdot \frac{2x}{x^2+7} = 2 \cdot \frac{f'(x)}{f(x)}$, so $k = 2$. The integral is $2\ln|x^2+7| + C$. Verify: $\frac{\text{d}}{\text{d}x}[2\ln|x^2+7|] = 2 \cdot \frac{2x}{x^2+7} = \frac{4x}{x^2+7}$. The trap $4\ln|x^2+7|$ uses the numerator 4 directly as $k$ without comparing to $f'(x) = 2x$. The trap $\frac{1}{2}\ln|x^2+7|$ inverts the ratio (using $f'(x)/\text{numerator}$ instead of $\text{numerator}/f'(x)$).
3. The integral $\displaystyle\int \tan x\, \text{d}x$ equals:
$\ln|\cos x| + C$
$-\ln|\cos x| + C$
$-\ln|\sin x| + C$
$-\ln|\tan x| + C$
Since $\tan x = \frac{\sin x}{\cos x}$, let $f(x) = \cos x$, $f'(x) = -\sin x$. Then $\tan x = \frac{\sin x}{\cos x} = \frac{-f'(x)}{f(x)} = -\frac{f'(x)}{f(x)}$, so $k = -1$. The integral is $-\ln|\cos x| + C$. Verify: $\frac{\text{d}}{\text{d}x}[-\ln|\cos x|] = -\frac{-\sin x}{\cos x} = \tan x$. The trap $\ln|\cos x|$ (without the minus) forgets that $f'(x) = -\sin x$, not $+\sin x$.
4. The value of $\displaystyle\int_{0}^{1} \frac{2x}{x^2+1}\, \text{d}x$ is:
$0$
$\ln 2$
$\dfrac{1}{2}\ln 2$
$2\ln 2$
Here $f(x) = x^2+1$, $f'(x) = 2x$. Since the numerator IS $f'(x)$, we have $k = 1$. So $\int \frac{2x}{x^2+1}\, \text{d}x = \ln|x^2+1| + C$. Evaluate: $[\ln|x^2+1|]_0^1 = \ln 2 - \ln 1 = \ln 2 - 0 = \ln 2$. The trap $\frac{1}{2}\ln 2$ incorrectly divides by 2 (confusing this with the case where the numerator is $x$, not $2x$). The trap $0$ comes from evaluating only at the lower limit ($\ln 1 = 0$) and forgetting the upper limit.
🎉
You scored 0 / 4
📝 More Practice

Attempt each question on paper first, then click Reveal Solution to check your work. Questions are ordered from easiest to hardest.

Exercise 8C Q6(iii) Standard

Find the value of $\displaystyle\int_{1}^{\mathrm{e}} \frac{2t}{t^{2}+1} \, \text{d}t$.

💡 Hint

Take $f(t) = t^{2}+1$, so $f'(t) = 2t$. The numerator is exactly $f'(t)$, so $k = 1$.

The antiderivative is $\ln|t^{2}+1|$. Evaluate at $t = 1$ and $t = \mathrm{e}$, then simplify with log laws.

👁 Reveal Solution
Step 1: Find the antiderivative

With $f(t) = t^{2}+1$ we have $f'(t) = 2t$, so $\dfrac{2t}{t^{2}+1} = \dfrac{f'(t)}{f(t)}$ and $k = 1$.

$\displaystyle\int \frac{2t}{t^{2}+1}\, \text{d}t = \ln|t^{2}+1| + C$

Step 2: Evaluate the definite integral

$\displaystyle\int_{1}^{\mathrm{e}} \frac{2t}{t^{2}+1}\, \text{d}t = \left[\ln(t^{2}+1)\right]_{1}^{\mathrm{e}}$

$= \ln(\mathrm{e}^{2}+1) - \ln(1^{2}+1) = \ln(\mathrm{e}^{2}+1) - \ln 2$

$= \ln\!\left(\dfrac{\mathrm{e}^{2}+1}{2}\right) \approx 1.43$

$\boxed{\displaystyle\int_{1}^{\mathrm{e}} \frac{2t}{t^{2}+1}\, \text{d}t = \ln\!\left(\frac{\mathrm{e}^{2}+1}{2}\right) \approx 1.43}$

Exercise 8C Q6(ii) Medium

The curve $y = \dfrac{\mathrm{e}^{x}}{\mathrm{e}^{x}+1}$ lies above the $x$-axis for all $x$.

Find the area of the region enclosed by this curve, the axes and the line $x = 2$.

💡 Hint

The region is bounded on the left by the $y$-axis ($x = 0$) and on the right by $x = 2$, so the area is $\displaystyle\int_{0}^{2} \frac{\mathrm{e}^{x}}{\mathrm{e}^{x}+1}\, \text{d}x$.

Take $f(x) = \mathrm{e}^{x}+1$. Then $f'(x) = \mathrm{e}^{x}$, which is exactly the numerator, so $k = 1$ and the antiderivative is $\ln(\mathrm{e}^{x}+1)$.

👁 Reveal Solution
Step 1: Set up the integral

The region is bounded by the curve, the $x$-axis, the $y$-axis and the line $x = 2$, so

$\text{Area} = \displaystyle\int_{0}^{2} \frac{\mathrm{e}^{x}}{\mathrm{e}^{x}+1}\, \text{d}x$

Step 2: Integrate using the pattern

Take $f(x) = \mathrm{e}^{x}+1$, so $f'(x) = \mathrm{e}^{x}$. The numerator is $f'(x)$ itself, so $k = 1$:

$\displaystyle\int \frac{\mathrm{e}^{x}}{\mathrm{e}^{x}+1}\, \text{d}x = \ln|\mathrm{e}^{x}+1| + C = \ln(\mathrm{e}^{x}+1) + C$

Here $\mathrm{e}^{x}+1 > 0$ for all $x$, so the modulus signs may be dropped.

Step 3: Evaluate the definite integral

$\displaystyle\int_{0}^{2} \frac{\mathrm{e}^{x}}{\mathrm{e}^{x}+1}\, \text{d}x = \left[\ln(\mathrm{e}^{x}+1)\right]_{0}^{2}$

$= \ln(\mathrm{e}^{2}+1) - \ln(\mathrm{e}^{0}+1) = \ln(\mathrm{e}^{2}+1) - \ln 2$

$= \ln\!\left(\dfrac{\mathrm{e}^{2}+1}{2}\right) \approx 1.43$

$\boxed{\text{Area} = \ln\!\left(\frac{\mathrm{e}^{2}+1}{2}\right) \approx 1.43}$

Exercise 8C Q7 Challenging

(i) The curve $y = \dfrac{x}{x^{2}+1}$ has a maximum point $M$. Find the $x$ coordinate of $M$.

(ii) The region $R$ is bounded by the curve, the $x$-axis and the line $x = p$. Find the area of $R$ in terms of $p$.

(iii) Hence calculate the value of $p$ for which the area of $R$ is 1, giving your answer correct to 3 significant figures.

(9709 Paper 3 Q9 June 2005)

💡 Hint 1

For (i): differentiate $y = \dfrac{x}{x^{2}+1}$ with the quotient rule, then solve $\dfrac{\text{d}y}{\text{d}x} = 0$.

Two values of $x$ satisfy that equation. Decide which one gives the maximum by checking the sign of $\dfrac{\text{d}y}{\text{d}x}$ on either side, or by comparing the two $y$ values.

💡 Hint 2

For (ii): the region runs from $x = 0$ to $x = p$, so $\text{Area} = \displaystyle\int_{0}^{p} \frac{x}{x^{2}+1}\, \text{d}x$. This is the $kf'(x)/f(x)$ pattern with $f(x) = x^{2}+1$ and $f'(x) = 2x$, so $k = \dfrac{1}{2}$.

For (iii): set your expression for the area equal to 1, then use $\mathrm{e}^{\ln a} = a$ to remove the logarithm.

👁 Reveal Solution
Part (i): The $x$ coordinate of $M$

By the quotient rule, with $u = x$ and $v = x^{2}+1$:

$\dfrac{\text{d}y}{\text{d}x} = \dfrac{(1)(x^{2}+1) - x(2x)}{(x^{2}+1)^{2}} = \dfrac{1-x^{2}}{(x^{2}+1)^{2}}$

Setting $\dfrac{\text{d}y}{\text{d}x} = 0$ gives $1-x^{2} = 0$, so $x = 1$ or $x = -1$.

The denominator $(x^{2}+1)^{2}$ is always positive, so the sign of $\dfrac{\text{d}y}{\text{d}x}$ is the sign of $1-x^{2}$: positive for $-1 < x < 1$ and negative for $x > 1$.

The curve therefore rises up to $x = 1$ and falls afterwards, so the maximum point $M$ has $x = 1$. (At $x = -1$ we get $y = -\dfrac{1}{2}$, a minimum.)

$\boxed{x = 1}$

Part (ii): The area of $R$ in terms of $p$

The curve is above the $x$-axis for $x > 0$, so $R$ runs from $x = 0$ to $x = p$ and

$\text{Area} = \displaystyle\int_{0}^{p} \frac{x}{x^{2}+1}\, \text{d}x$

Here $f(x) = x^{2}+1$, $f'(x) = 2x$ and $x = \dfrac{1}{2}f'(x)$, so $k = \dfrac{1}{2}$. Hence

$\text{Area} = \left[\frac{1}{2}\ln(x^{2}+1)\right]_{0}^{p} = \frac{1}{2}\ln(p^{2}+1) - \frac{1}{2}\ln 1 = \frac{1}{2}\ln(1+p^{2})$

$\boxed{\text{Area of }R = \frac{1}{2}\ln(1+p^{2})}$

Part (iii): The value of $p$ for which the area is 1

Set $\dfrac{1}{2}\ln(1+p^{2}) = 1$:

$\ln(1+p^{2}) = 2 \quad\Longrightarrow\quad 1+p^{2} = \mathrm{e}^{2}$

$p^{2} = \mathrm{e}^{2}-1 \quad\Longrightarrow\quad p = \sqrt{\mathrm{e}^{2}-1} = 2.5277\ldots$

Since $p > 0$ we take the positive root, giving $p = 2.53$ (3 s.f.).

$\boxed{p = \sqrt{\mathrm{e}^{2}-1} = 2.53 \text{ (3 s.f.)}}$

🎫

Exit Ticket

Before you leave, tick the objectives you are confident you can achieve. Be honest — this guides next lesson's review.