Core Pure · Series · Year 2

Maclaurin Series

Every derivative at x=0 hands you one more coefficient of a power-series expansion — giving a systematic way to build infinite series for almost any function.

10 min read 1 worked example

Maclaurin series

Theorem 2.2 — the Maclaurin series expansion

Provided $f(0),f'(0),f''(0),\ldots$ all exist and are finite, a function can be expanded as an infinite series in ascending powers of $x$:

$$f(x)=f(0)+f'(0)x+\frac{f''(0)}{2!}x^2+\frac{f'''(0)}{3!}x^3+\cdots+\frac{f^{(r)}(0)}{r!}x^r+\cdots$$

DerivationWhy the coefficients take this form
1
Suppose $f(x)=a_0+a_1x+a_2x^2+a_3x^3+\cdots$ for constants $a_0,a_1,a_2,\ldots$
Assume the function has a power-series expansion of this general form.
2
Setting $x=0$: $f(0)=a_0$.
Every term with a positive power of $x$ vanishes.
3
Differentiate once: $f'(x)=a_1+2a_2x+3a_3x^2+\cdots$. Setting $x=0$: $f'(0)=a_1$.
Each differentiation strips one power of $x$ off the leading surviving term.
4
Differentiate again: $f''(x)=2a_2+3\times2\,a_3x+\cdots$. Setting $x=0$: $f''(0)=2!\,a_2$, so $a_2=\dfrac{f''(0)}{2!}$.
The constant term picks up a factor of $2!$ from the two rounds of differentiation.
5
Continuing this pattern, differentiating $r$ times and setting $x=0$ gives $f^{(r)}(0)=r!\,a_r$, so $a_r=\dfrac{f^{(r)}(0)}{r!}$ for every $r$.
This is exactly the coefficient pattern in the theorem above.
∎
Three series worth memorising

$$e^x=1+x+\frac{x^2}{2!}+\frac{x^3}{3!}+\cdots, \; x\in\mathbb{R}$$

$$\frac1{1-x}=1+x+x^2+x^3+\cdots, \; |x|<1$$

$$\sqrt{1+x}=1+\frac x2-\frac{x^2}8+\frac{x^3}{16}-\cdots, \; |x|<1$$

The restriction $|x|<1$ (or similar) on the second and third series reflects that the underlying function has a singularity or isn't real-valued outside that range; $e^x$, by contrast, is well-behaved for every real $x$, so its series converges everywhere.

Example 1 · Deriving a Maclaurin series from scratch
Find the Maclaurin series for $f(x)=\ln(1+x)$ up to and including the term in $x^4$.

$f(x)=\ln(1+x)$, so $f(0)=\ln1=0$.

$f'(x)=(1+x)^{-1}$, so $f'(0)=1$.

$f''(x)=-(1+x)^{-2}$, so $f''(0)=-1$.

$f'''(x)=2(1+x)^{-3}$, so $f'''(0)=2$.

$f^{(4)}(x)=-6(1+x)^{-4}$, so $f^{(4)}(0)=-6$.

Substituting into the Maclaurin formula: $\ln(1+x)=0+1\cdot x+\dfrac{-1}{2!}x^2+\dfrac{2}{3!}x^3+\dfrac{-6}{4!}x^4+\cdots=x-\dfrac{x^2}2+\dfrac{x^3}3-\dfrac{x^4}4+\cdots$

Watch out — functions with no valid Maclaurin series

Not every function has a Maclaurin series: it requires $f(0),f'(0),f''(0),\ldots$ to all exist and be finite. For example $f(x)=\ln x$ fails immediately, since $f(0)=\ln0$ is undefined — there is no Maclaurin expansion of $\ln x$ itself (though $\ln(1+x)$, expanded around $x=0$, works fine, as above).

Exam-style questions

Question 1 7 marks

Find the Maclaurin series for $f(x)=e^{2x}\sin x$ up to and including the term in $x^3$.

$f(0)=1\times0=0$. $f'(x)=2e^{2x}\sin x+e^{2x}\cos x$, so $f'(0)=0+1=1$. (M1, A1)

$f''(x)=4e^{2x}\sin x+2e^{2x}\cos x+2e^{2x}\cos x-e^{2x}\sin x=3e^{2x}\sin x+4e^{2x}\cos x$, so $f''(0)=0+4=4$. (M1, A1)

$f'''(x)=6e^{2x}\sin x+3e^{2x}\cos x+8e^{2x}\cos x-4e^{2x}\sin x=2e^{2x}\sin x+11e^{2x}\cos x$, so $f'''(0)=0+11=11$. (M1)

$f(x)=0+1\cdot x+\dfrac4{2!}x^2+\dfrac{11}{3!}x^3+\cdots=x+2x^2+\dfrac{11}6x^3+\cdots$ (A1)

Question 2 7 marks

Find the Maclaurin series for $f(x)=\ln(1-2x)$ up to and including the term in $x^3$.

$f(0)=\ln1=0$ (B1)

$f'(x)=\dfrac{-2}{1-2x}$, so $f'(0)=-2$ (M1, A1)

$f''(x)=\dfrac{-4}{(1-2x)^2}$, so $f''(0)=-4$ (M1, A1)

$f'''(x)=\dfrac{-16}{(1-2x)^3}$, so $f'''(0)=-16$ (A1)

$f(x)=0+(-2)x+\dfrac{-4}{2!}x^2+\dfrac{-16}{3!}x^3+\cdots=-2x-2x^2-\dfrac83x^3+\cdots$ (A1)