Skip to main content
\( \definecolor{colordef}{RGB}{249,49,84} \definecolor{colorprop}{RGB}{18,102,241} \)
International Baccalaureate · DP 2: Applications and Interpretation HL

Rules of Differentiation

⌚ ~154 min ▢ 17 blocks ✓ 84 exercises ➣ Prerequisites : Introduction to Differential Calculus, Functions, Exponentials, Logarithms, Trigonometric Functions
I Products, Quotients and Composites
I.1 Product Rule
While the derivative of a sum is the sum of the derivatives, the same is not true for a product. To find the derivative of a function that is the product of two other functions, such as \(f(x) = (x^2+1)\sqrt{x}\), we must use a specific formula called the Product Rule.
Report an error
Proposition — Product Rule
If \(f(x)=u(x)v(x)\) with \(u\) and \(v\) differentiable, then$$ f'(x) = u'(x)v(x) + u(x)v'(x) $$ In Leibniz notation, if \(y=u\cdot v\) :$$ \dfrac{\mathrm{d}y}{\mathrm{d}x}= \dfrac{\mathrm{d}u}{\mathrm{d}x}v + u\dfrac{\mathrm{d}v}{\mathrm{d}x} $$
In words: “The derivative of the first times the second, plus the first times the derivative of the second.”
Report an error
Example
Find the derivative of \(f(x) = (x+1)(x^2+3)\).

  • Using prime notation:
    For \(f(x)=u(x)v(x)\) where \(u(x)=x+1\) and \(v(x)=x^2+3\), the derivatives are \(u'(x)=1\) and \(v'(x)=2x\).$$\begin{aligned}f'(x) &= u'(x)v(x) + u(x)v'(x) \\ &= (1)(x^2+3) + (x+1)(2x) \\ &= x^2+3 + 2x^2+2x \\ &= 3x^2+2x+3\end{aligned}$$
  • Using Leibniz's notation (\(y=f(x)\)):
    For \(y=uv\) where \(u=x+1\) and \(v=x^2+3\), the derivatives are \(\frac{\mathrm{d}u}{\mathrm{d}x}=1\) and \(\frac{\mathrm{d}v}{\mathrm{d}x}=2x\).$$\begin{aligned}\dfrac{\mathrm{d}y}{\mathrm{d}x} &= \dfrac{\mathrm{d}u}{\mathrm{d}x}v + u\dfrac{\mathrm{d}v}{\mathrm{d}x} \\ &= (1)(x^2+3) + (x+1)(2x) \\ &= x^2+3 + 2x^2+2x \\ &= 3x^2+2x+3\end{aligned}$$

Skills to practice
  • Differentiating with the Product Rule
I.2 Quotient Rule
Just as with products, finding the derivative of a quotient of two functions requires a specific formula. The Quotient Rule is used to differentiate functions of the form \(f(x) = \dfrac{u(x)}{v(x)}\), such as \(f(x) = \dfrac{2x+1}{x^2+1}\).
Report an error
Proposition — Quotient Rule
If \(f(x)=\dfrac{u(x)}{v(x)}\) with \(u\) and \(v\) differentiable and \(v(x) \neq 0\), then$$ f'(x) = \dfrac{u'(x)v(x) - u(x)v'(x)}{[v(x)]^2} $$ In Leibniz notation, \(y=\dfrac{u}{v}\), then$$ \frac{\mathrm{d}y}{\mathrm{d}x} = \dfrac{\frac{\mathrm{d}u}{\mathrm{d}x}v - u\frac{\mathrm{d}v}{\mathrm{d}x}}{v^2} $$
Example
Find the derivative of \(f(x) = \frac{x}{x+1}\).

  • Using prime notation:
    For \(f(x)=\frac{u(x)}{v(x)}\) where \(u(x)=x\) and \(v(x)=x+1\), the derivatives are \(u'(x)=1\) and \(v'(x)=1\).$$\begin{aligned}f'(x) &= \frac{u'(x)v(x) - u(x)v'(x)}{[v(x)]^2} \\ &= \frac{(1)(x+1) - (x)(1)}{(x+1)^2} \\ &= \frac{x+1-x}{(x+1)^2} \\ &= \frac{1}{(x+1)^2}\end{aligned}$$
  • Using Leibniz's notation \((y=f(x))\):
    For \(y=\frac{u}{v}\) where \(u=x\) and \(v=x+1\), the derivatives are \(\frac{\mathrm{d}u}{\mathrm{d}x}=1\) and \(\frac{\mathrm{d}v}{\mathrm{d}x}=1\).$$\begin{aligned}\frac{\mathrm{d}y}{\mathrm{d}x} &= \frac{\frac{\mathrm{d}u}{\mathrm{d}x}v - u\frac{\mathrm{d}v}{\mathrm{d}x}}{v^2} \\ &= \frac{(1)(x+1) - (x)(1)}{(x+1)^2} \\ &= \frac{x+1-x}{(x+1)^2} \\ &= \frac{1}{(x+1)^2}\end{aligned}$$

Skills to practice
  • Differentiating with the Quotient Rule
I.3 Derivative of \(x \mapsto g(ax+b)\)
Many functions are obtained by plugging a linear expression \(ax+b\) into a reference function \(g\): \(\sqrt{2x+1}\) (with \(g(X) = \sqrt{X}\)), \((3x-1)^2\) (with \(g(X) = X^2\)), \(\dfrac{1}{4x+2}\) (with \(g(X) = \dfrac{1}{X}\)). Their derivative follows from the derivative of \(g\) by a simple rule.
Report an error
Proposition — Derivative of \(x \mapsto g(ax+b)\)
Let \(g\) be a function differentiable on an interval \(J\), and \(a\), \(b\) two real numbers. The function \(f\) defined by \(f(x) = g(ax+b)\) is differentiable at every \(x\) such that \(ax+b \in J\), and $$ f'(x) = a \times g'(ax+b). $$
Example
Find the derivative of each function.
  1. \(f(x) = (3x-1)^2\) for all real \(x\).
  2. \(f(x) = \sqrt{2x+1}\) for \(x > -\dfrac{1}{2}\).
  3. \(f(x) = \dfrac{1}{4x+2}\) for \(x \neq -\dfrac{1}{2}\).

  1. \(f(x) = g(3x-1)\) with \(g(X) = X^2\), \(g'(X) = 2X\) and \(a = 3\): $$ f'(x) = 3 \times 2(3x-1) = 6(3x-1) = 18x - 6. $$ Check: expanding, \(f(x) = 9x^2 - 6x + 1\), whose derivative is indeed \(18x - 6\).
  2. \(f(x) = g(2x+1)\) with \(g(X) = \sqrt{X}\), \(g'(X) = \dfrac{1}{2\sqrt{X}}\) (for \(X > 0\)) and \(a = 2\): $$ f'(x) = 2 \times \dfrac{1}{2\sqrt{2x+1}} = \dfrac{1}{\sqrt{2x+1}}. $$
  3. \(f(x) = g(4x+2)\) with \(g(X) = \dfrac{1}{X}\), \(g'(X) = -\dfrac{1}{X^2}\) (for \(X \neq 0\)) and \(a = 4\): $$ f'(x) = 4 \times \left(-\dfrac{1}{(4x+2)^2}\right) = -\dfrac{4}{(4x+2)^2}. $$

This rule is a special case of the chain rule, which gives the derivative of \(g(u(x))\) for any differentiable function \(u\), not only a linear one \(ax+b\).
Report an error
Skills to practice
  • Differentiating \(g(ax+b)\) and Its Products
  • Writing Up Derivatives with the Rules
I.4 Chain Rule
Many complex functions are created by composing simpler ones. A composite function has the form \(f(x) = v(u(x))\), where one function (the “inner” function, \(u\)) is the input to another (the “outer” function, \(v\)). For example, in the function \(f(x) = (x^2+1)^3\), the inner function is \(u(x)=x^2+1\) and the outer function is \(v(x)=x^3\).
The Chain Rule provides a powerful method for differentiating such functions by finding the derivatives of the inner and outer functions separately.
Report an error
Proposition — Chain Rule
If \(u\) is differentiable at \(x\) and \(v\) is differentiable at \(u(x)\), then the function \(f\) defined by \(f(x)=v(u(x))\) is differentiable at \(x\) and:$$ f'(x) = v'(u(x)) \cdot u'(x) $$ In Leibniz notation, if \(y=v(u)\) then$$ \dfrac{\mathrm{d}y}{\mathrm{d}x} = \dfrac{\mathrm{d}y}{\mathrm{d}u} \cdot \dfrac{\mathrm{d}u}{\mathrm{d}x} $$
Example
Find the derivative of \(f(x) = (x^2+1)^3\).

  • Using prime notation:
    Let the outer function be \(v(x)=x^3\) and the inner function be \(u(x)=x^2+1\). We have \(f(x)=v(u(x))\). The derivatives are \(v'(x)=3x^2\) and \(u'(x)=2x\).$$\begin{aligned}f'(x) &= v'(u(x)) \cdot u'(x) \\ &= 3(u(x))^2 \cdot (2x) \\ &= 3(x^2+1)^2 \cdot (2x)\\ &= 6x(x^2+1)^2\end{aligned}$$
  • Using Leibniz's notation (\(y=f(x)\)):
    For \(y=u^3\) and \(u=x^2+1\), the derivatives are \(\frac{\mathrm{d}y}{\mathrm{d}u}=3u^2\) and \(\frac{\mathrm{d}u}{\mathrm{d}x}=2x\).$$\begin{aligned}\dfrac{\mathrm{d}y}{\mathrm{d}x} &= \dfrac{\mathrm{d}y}{\mathrm{d}u} \cdot \dfrac{\mathrm{d}u}{\mathrm{d}x} \\ &= (3u^2) \cdot (2x) \\ &= 3(x^2+1)^2 \cdot (2x)\\ & = 6x(x^2+1)^2\end{aligned}$$

Skills to practice
  • Choosing a Differentiation Rule
  • Decomposing Composite Functions
  • Differentiating with the Chain Rule
II Derivatives of Standard Functions
II.1 Exponential Functions
The exponential function, particularly \(f(x)=e^x\), holds a unique and fundamental place in calculus. Its rate of change is directly proportional to its value, which makes it the mathematical language of many natural processes like population growth and compound interest. This function has a remarkably simple derivative.
Report an error
Proposition — Derivative of \(e^x\)
The derivative of the natural exponential function is itself:$$ \dfrac{\mathrm{d}}{\mathrm{d}x}(e^x) = e^x $$
Proposition — Chain Rule for \(e^{u(x)}\)
The derivative of an exponential function with a function in the exponent is given by:$$ \left(e^{u(x)}\right)' = e^{u(x)}u'(x) $$ In Leibniz notation:$$ \dfrac{\mathrm{d}}{\mathrm{d}x}\left(e^{u}\right) = e^{u}\dfrac{\mathrm{d}u}{\mathrm{d}x} $$
Example
Find the derivative of \(f(x)=e^{x^2}\).

Here, the inner function is \(u(x)=x^2\), so \(u'(x)=2x\).$$\begin{aligned}f'(x) &= e^{u(x)}u'(x)\\ &= e^{x^2}2x\end{aligned} $$

Skills to practice
  • Differentiating Composite Exponential Functions
  • Applying the Product and Quotient Rules to the Exponential
II.2 Logarithmic Functions
The natural logarithm function, \(f(x)=\ln(x)\), is the inverse of the exponential function \(e^x\). This inverse relationship is the key to finding its derivative. Just as the exponential function has a remarkably simple derivative, so does the logarithm. This derivative is fundamental in calculus, particularly in integration, as it gives an antiderivative of \(x \mapsto 1/x\) on \((0, +\infty)\).
Report an error
Proposition — Derivative of \(\ln x\)
The derivative of the natural logarithm function for \(x>0\) is:$$ \dfrac{\mathrm{d}}{\mathrm{d}x}(\ln x) = \dfrac{1}{x} $$
Proposition — Chain Rule for \(\ln(u(x))\)
If \(u\) is differentiable and strictly positive on an interval \(I\), then \(\ln(u)\) is differentiable on \(I\) and:$$ \left(\ln(u(x))\right)' = \dfrac{u'(x)}{u(x)} $$ In Leibniz notation:$$ \dfrac{\mathrm{d}}{\mathrm{d}x}\left(\ln(u)\right) = \dfrac{1}{u}\,\dfrac{\mathrm{d}u}{\mathrm{d}x} $$
Example
Find the derivative of \(f(x) = \ln(2x+3)\).

This is of the form \(\ln(u(x))\) where the inner function is \(u(x)=2x+3\).
The derivative of the inner function is \(u'(x)=2\).
Using the chain rule for logarithms:$$ f'(x) = \dfrac{u'(x)}{u(x)} = \dfrac{2}{2x+3} $$

Method — Simplify Before Differentiating
For a complicated logarithmic function, the laws of logarithms are used to expand or simplify the expression before differentiating, on an interval where the arguments of the logarithms are positive. This can turn a difficult problem into a very simple one.
Recall the laws, for \(a>0\) and \(b>0\): \(\ln(ab)=\ln(a)+\ln(b)\), \(\ln(a/b)=\ln(a)-\ln(b)\), and \(\ln(a^n)=n\ln(a)\).
Example
Find the derivative of \(f(x) = \ln\left(\dfrac{x+1}{x}\right)\).

\(f\) is defined where \(\dfrac{x+1}{x} > 0\), that is for \(x < -1\) or \(x > 0\). For \(x > 0\), both \(x+1\) and \(x\) are positive, so the law \(\ln(a/b)=\ln(a)-\ln(b)\) simplifies the expression:$$ f(x) = \ln(x+1) - \ln(x) $$ Now, we can differentiate this much simpler expression term by term:$$\begin{aligned}f'(x) &= \dfrac{\mathrm{d}}{\mathrm{d}x}(\ln(x+1)) - \dfrac{\mathrm{d}}{\mathrm{d}x}(\ln x) \\ &= \dfrac{1}{x+1} - \dfrac{1}{x}\end{aligned}$$ For \(x < -1\), the rule for \(\ln(u)\) with \(u = \dfrac{x+1}{x}\) gives the same expression of \(f'(x)\).

Skills to practice
  • Differentiating Logarithmic Functions
II.3 Trigonometric Functions
Trigonometric functions describe periodic phenomena, which are common in physics and engineering. Their derivatives follow a cyclical pattern that is both elegant and powerful. The derivatives of \(\sin(x)\) and \(\cos(x)\) come from the limit definition of the derivative, with \(x\) measured in radians.
Report an error
Proposition — Derivatives of Sine and Cosine
For \(x\) in radians, the derivatives of the basic trigonometric functions are:$$ \dfrac{\mathrm{d}}{\mathrm{d}x}(\sin x) = \cos x \quad \text{and} \quad \dfrac{\mathrm{d}}{\mathrm{d}x}(\cos x) = -\sin x $$
Proposition — Derivative of Tangent
The derivative of the tangent function is:$$ \dfrac{\mathrm{d}}{\mathrm{d}x}(\tan x) = 1+\tan^2 x $$

We use the quotient rule on \(f(x) = \tan x = \dfrac{\sin x}{\cos x}\).
Let \(u=\sin x\) and \(v=\cos x\). Then \(u'=\cos x\) and \(v'=-\sin x\).$$\begin{aligned}f'(x) &= \dfrac{u'v - uv'}{v^2}\\ &= \dfrac{(\cos x)(\cos x) - (\sin x)(-\sin x)}{(\cos x)^2} \\ &= \dfrac{\cos^2 x + \sin^2 x}{\cos^2 x}\\ &= \dfrac{\cos^2 x}{\cos^2 x} + \dfrac{\sin^2 x}{\cos^2 x} \\ &= 1+ \dfrac{\sin^2 x}{\cos^2 x}\\ &= 1+\tan^2 x \\ \end{aligned}$$

Proposition — Chain Rule for Trigonometric Functions
For a differentiable function \(u\):
  • \((\sin(u(x)))' = u'(x)\cos(u(x))\)
  • \((\cos(u(x)))' = -u'(x)\sin(u(x))\)
  • \((\tan(u(x)))' = u'(x)\bigl(1+\tan^2(u(x))\bigr)\), where \(\cos(u(x)) \neq 0\)
In Leibniz notation:
  • \(\dfrac{\mathrm{d}}{\mathrm{d}x}(\sin(u)) = \cos(u)\dfrac{\mathrm{d}u}{\mathrm{d}x}\)
  • \(\dfrac{\mathrm{d}}{\mathrm{d}x}(\cos(u)) = -\sin(u)\dfrac{\mathrm{d}u}{\mathrm{d}x}\)
  • \(\dfrac{\mathrm{d}}{\mathrm{d}x}(\tan(u)) = \bigl(1+\tan^2(u)\bigr)\dfrac{\mathrm{d}u}{\mathrm{d}x}\)
Example
Find the derivative of \(f(x) = \cos(x^2+3x)\).

This is of the form \(\cos(u(x))\) where the inner function is \(u(x)=x^2+3x\).
The derivative of the inner function is \(u'(x)=2x+3\).
Using the chain rule for cosine:$$\begin{aligned}f'(x) &= -u'(x)\sin(u(x)) \\ &= -(2x+3)\sin(x^2+3x)\end{aligned}$$

Skills to practice
  • Recognising Derivatives of Standard Functions
  • Differentiating Trigonometric Functions
  • Differentiating Composites of Standard Functions
  • Differentiating Composite Tangent Functions
III The Second Derivative
III.1 Second Derivative
Definition — Second Derivative
The second derivative of \(f\), denoted \(f''\), is the derivative of the first derivative, \(f'\).$$ f''(x) = \dfrac{\mathrm{d}}{\mathrm{d}x}(f'(x)) \quad \text{ or in Leibniz notation, } \quad \dfrac{\mathrm{d}^2 y}{\mathrm{d}x^2}= \dfrac{\mathrm{d}}{\mathrm{d}x}\left(\dfrac{\mathrm{d}y}{\mathrm{d}x} \right) $$
Example
Find the second derivative of \(f(x)=x^4 - 5x^2\).

First, we find the first derivative:$$ f'(x) = 4x^3 - 10x $$ Now, we differentiate again to find the second derivative:$$ f''(x) = \dfrac{\mathrm{d}}{\mathrm{d}x}(4x^3 - 10x) = 12x^2 - 10 $$

Skills to practice
  • Calculating First and Second Derivatives
  • Showing That a Function Satisfies a Relation
IV Going further
Skills to practice
  • Solving Problems
  • Quiz