Educerie
Level

This whole subtopic is higher level. Nothing in it is on an SL paper.

Educerie · IB Diploma · Mathematics: analysis and approaches

Topic 5 Calculus · 5.19 Maclaurin series

Level
HL only, the whole subtopic. If you are SL, none of this is on your papers.
Themes (key concepts)
approximation, patterns, generalization. A Maclaurin series replaces a function by a polynomial that copies it near x = 0, trading exactness for simplicity, and the pattern in its coefficients generalizes from a handful of standard series to almost any function you can build from them.
The question this unit answers
how can a polynomial stand in for eˣ, sin x or ln(1 + x), and how do you build the series for a new function from the ones you already know?
Where it is examined
Paper 1 (no calculator): derive a series from the definition (4 to 6 marks), build one by substitution, multiplication, differentiation or integration (3 to 6 marks), use it to find a limit (5.13), or find the series solution of a differential equation (6 to 8 marks). Paper 2: use a series to approximate a value or an integral, and compare with the GDC (4 to 6 marks). Paper 3 often builds a whole problem on a series.

What you must be able to do

You must be able toLevelWhat it looks like in the exam
Find a Maclaurin series from the definition by differentiating repeatedly at x = 0HL only"Find the Maclaurin series for f(x) up to and including the term in x⁴" (5 to 6 marks)
Know and use the series for eˣ, sin x, cos x, arctan x, ln(1 + x) and (1 + x)ᵖ, p ∈ ℚHL only"Write down the first three non-zero terms of …" (1 to 2 marks)
Obtain new series by simple substitutionHL only"Hence write down the series for ex²" (2 marks)
Obtain new series by multiplying two seriesHL only"Find the series for eˣ sin x up to the term in x³" (4 marks)
Obtain new series by differentiating or integrating term by termHL only"By integrating the series for 1/(1 + x²), show that …" (4 to 5 marks)
Use a series to approximate a number, an integral or a limitHL only"Hence find an approximation to ∫₀¹ sin(x²) dx" (3 marks)
Find the Maclaurin series of the solution of a differential equationHL only"Given dy/dx = … and y(0) = …, find the first four terms of the series for y" (6 to 8 marks)

Before you start

You need the derivatives of 5.6 and 5.15, and higher derivatives and the notation f⁽ⁿ⁾(x) from 5.12. You need factorials and the extended binomial theorem from 1.10, which is the series for (1 + x)ᵖ. The formula booklet gives the general Maclaurin formula and the standard series for eˣ, ln(1 + x), sin x, cos x and arctan x; the binomial expansion is in the booklet under 1.10. Implicit differentiation (5.14) is used in section 6.


1The idea in one paragraph

Polynomials are the easiest functions there are: you can evaluate, differentiate and integrate them with nothing but arithmetic. A Maclaurin series writes another function as a polynomial with infinitely many terms, a₀ + a₁x + a₂x² + a₃x³ + …, chosen so that at x = 0 it has the same value as the function, the same gradient, the same second derivative, and so on for ever. Matching the derivatives fixes every coefficient: aₙ = f⁽ⁿ⁾(0) ÷ n!. Cut the series off after a few terms and you have a polynomial that is an excellent approximation near 0, getting worse further away. From five standard series you can build the series of many other functions by substituting, multiplying, differentiating and integrating, and you can even find the series of a function you only know through a differential equation.

2Where the coefficients come from

Suppose f(x) = a₀ + a₁x + a₂x² + a₃x³ + a₄x⁴ + …. Put x = 0 and every term but the first vanishes, so a₀ = f(0). Differentiate once and put x = 0: a₁ = f′(0). Differentiate again: f″(x) = 2a₂ + 3 × 2a₃x + …, so f″(0) = 2a₂. Once more: f‴(0) = 3 × 2 × 1 × a₃ = 3! a₃. The pattern is aₙ = f⁽ⁿ⁾(0)/n!, which gives the formula in the booklet:

Maclaurin series: f(x) = f(0) + x f′(0) + (x²/2!) f″(0) + (x³/3!) f‴(0) + …, with the n-th term (xⁿ/n!) f⁽ⁿ⁾(0).

Example 1: eˣ. Every derivative of eˣ is eˣ, and e⁰ = 1. So every f⁽ⁿ⁾(0) is 1, and

ex = 1 + x + x2/2! + x3/3! + x4/4! + …

Figure 1 shows what the partial sums do. The line 1 + x matches the value and the slope at 0: it is the tangent. Adding x²/2 matches the bending as well, and adding x³/6 matches the rate at which the bending changes. Each term makes the polynomial cling to eˣ over a wider stretch.

Figure 1 · Polynomials that copy eˣ at x = 0 Figure 1 · Polynomials that copy eˣ at x = 0 y = eˣ 1 + x 1 + x + x²/2 (dashed) 1 + x + x²/2 + x³/6 x y −2 −1 1 2 2 4 6 Each new term matches one more derivative at 0: first the value, then the slope, then the bending. Near 0 the cubic is almost indistinguishable from eˣ; further out every polynomial drifts away.
Figure 1 · Polynomials that copy eˣ at x = 0

A quick use: e0.1 ≈ 1 + 0.1 + 0.005 + 0.000167 = 1.105167, and the true value is 1.105171. Four terms give five correct decimal places, because the powers of 0.1 shrink so fast.

Example 2: sin x. The derivatives cycle: sin x, cos x, −sin x, −cos x, sin x, …. At 0 these are 0, 1, 0, −1, 0, 1, …. The even powers vanish and the odd ones alternate in sign.

sin x = x − x3/3! + x5/5! − x7/7! + …

An odd function has only odd powers, which is a good check. Figure 2 shows the polynomials of degree 1, 3, 5 and 7 each staying on the sine curve for longer. The series for cos x follows the same way (derivatives at 0 are 1, 0, −1, 0, …), or faster by differentiating the sine series (section 5).

Figure 2 · More terms, a wider stretch of agreement Figure 2 · More terms, a wider stretch of agreement x degree 3 degree 5 degree 7 y = sin x x y −2π −π π 2π −1 1 Maclaurin polynomials for sin x of degree 1, 3, 5 and 7. Each extra term keeps the polynomial on the curve for longer.
Figure 2 · More terms, a wider stretch of agreement

Example 3: ln(1 + x). Here ln x itself has no Maclaurin series, because ln 0 does not exist; that is why the standard series is for ln(1 + x).

f(x) = ln(1 + x) f(0) = 0
f′(x) = (1 + x)−1 f′(0) = 1
f″(x) = −(1 + x)−2 f″(0) = −1
f‴(x) = 2(1 + x)−3 f‴(0) = 2
f⁗(x) = −6(1 + x)−4 f⁗(0) = −6
ln(1 + x) = 0 + x − x2/2! + 2x3/3! − 6x4/4! + … = x − x2/2 + x3/3 − x4/4 + …

The factorials cancel to leave the tidy pattern ± xⁿ/n. Lay out a derivation like this, a column of derivatives and a column of values at 0, so each mark can be seen.

3The standard series, and where each one works

FunctionSeriesWorks for
eˣ1 + x + x²/2! + x³/3! + …every x
sin xx − x³/3! + x⁵/5! − …every x
cos x1 − x²/2! + x⁴/4! − …every x
ln(1 + x)x − x²/2 + x³/3 − x⁴/4 + …−1 < x ≤ 1
arctan xx − x³/3 + x⁵/5 − x⁷/7 + …−1 ≤ x ≤ 1
(1 + x)ᵖ1 + px + p(p − 1)x²/2! + p(p − 1)(p − 2)x³/3! + …−1 < x < 1 (every x if p is a positive whole number)

The last column matters when you use a series to approximate. The guide does not ask you to prove where a series works, but it helps to know. Figure 3 shows the problem with ln(1 + x): inside −1 < x ≤ 1 the partial sums close in on the curve, but beyond x = 1 each extra term makes things worse, because the powers xⁿ grow faster than the n in the denominator.

Figure 3 · The series for ln(1 + x) only works for −1 < x ≤ 1 Figure 3 · The series for ln(1 + x) only works for −1 < x ≤ 1 series fails y = ln(1 + x) 11 terms 10 terms 5 terms x y −1 1 2 −2 −1 1 2 Partial sums with 5, 10 and 11 terms. Inside −1 < x ≤ 1 they close in on ln(1 + x); beyond x = 1 they swing further away with every term added, so the series is no use there.
Figure 3 · The series for ln(1 + x) only works for −1 < x ≤ 1

The binomial series. For (1 + x)ᵖ with p a fraction or a negative number, the Maclaurin method gives exactly the extended binomial expansion of 1.10: f(0) = 1, f′(0) = p, f″(0) = p(p − 1), and so on. For example, √(1 + x) = (1 + x)1/2 = 1 + x/2 − x²/8 + x³/16 − …. With x = 0.1 this gives √1.1 ≈ 1 + 0.05 − 0.00125 + 0.0000625 = 1.0488125, against the true 1.0488088.

Accuracy against simplicity. More terms mean more accuracy, but the right choice of series can matter more. Five terms of the ln(1 + x) series at x = 1 give ln 2 ≈ 0.783, which is poor, because x = 1 is at the edge of where the series works. Subtracting the series for ln(1 − x) from that for ln(1 + x) gives ln((1 + x)/(1 − x)) = 2(x + x³/3 + x⁵/5 + …), and x = 1/3 makes (1 + x)/(1 − x) = 2. Three terms then give ln 2 ≈ 0.69300, against the true 0.69315. Mathematicians of the Kerala school in India, from Madhava in the fourteenth century onwards, had series for sine, cosine and arctangent and used them for exactly this kind of calculation, centuries before Taylor and Maclaurin.

4New series by substitution and by multiplication

You rarely need to differentiate from scratch. Figure 4 shows the four ways to make a new series from a standard one.

Figure 4 · Five standard series, four ways to build new ones Figure 4 · Five standard series, four ways to build new ones The standard series eˣ sin x, cos x ln(1 + x) arctan x (1 + x)ᵖ Substitute replace x by x², −x, 2x … ex², cos 2x, ln(1 − x) Multiply two series, collect terms eˣ sin x Differentiate term by term d/dx of sin x series → cos x Integrate term by term ∫ 1/(1 + x²) → arctan x You rarely differentiate from scratch. Start from a known series and change it.
Figure 4 · Five standard series, four ways to build new ones

Substitution. Replace x throughout by something else: x², −x, 2x, 3x². The guide's own example is ex²:

eu = 1 + u + u2/2! + u3/3! + …standard series with u in place of x
ex2 = 1 + x2 + x4/2 + x6/6 + …put u = x²: (x²)² = x⁴, (x²)³ = x⁶

The same move gives cos 2x = 1 − (2x)²/2! + (2x)⁴/4! − … = 1 − 2x² + (2/3)x⁴ − …, where the brackets matter: (2x)² is 4x², not 2x². It also gives ln(1 − x) = −x − x²/2 − x³/3 − …, by putting −x for x, and 1/(1 + x²) = 1 − x² + x⁴ − x⁶ + …, from (1 + u)−1 with u = x². A substitution also changes where the series works: ln(1 + 3x) needs −1 < 3x ≤ 1.

Multiplication. Multiply two series as you would two long brackets, but keep only the terms up to the power you are asked for. The guide's example is eˣ sin x, up to x⁴.

ex sin x = (1 + x + x2/2 + x3/6 + …)(x − x3/6 + …)
x1: 1 × x = x
x2: x × x = x2
x3: 1 × (−x3/6) + (x2/2) × x = (−1/6 + 1/2)x3 = x3/3
x4: x × (−x3/6) + (x3/6) × x = 0
ex sin x = x + x2 + x3/3 + 0x4 + …

Collecting by powers, as here, keeps you from multiplying out terms you will throw away. Differentiating eˣ sin x four times would give the same coefficients, much more slowly.

5New series by differentiation and integration

A series can be differentiated or integrated term by term, like any polynomial.

Differentiation. d/dx of the sine series is 1 − 3x²/3! + 5x⁴/5! − …, which simplifies to 1 − x²/2! + x⁴/4! − …: the cosine series, as it should be. From 1/(1 − x) = 1 + x + x² + x³ + …, differentiating gives 1/(1 − x)² = 1 + 2x + 3x² + 4x³ + ….

Integration: where arctan x comes from. The direct method is messy for arctan x, because its derivatives get complicated fast. Integration is quicker. The derivative of arctan x is 1/(1 + x²), whose series you found by substitution:

1/(1 + t2) = 1 − t2 + t4 − t6 + …
arctan x = ∫0x 1/(1 + t2) dt = [ t − t3/3 + t5/5 − t7/7 + … ]0x
arctan x = x − x3/3 + x5/5 − x7/7 + …constant 0, since arctan 0 = 0

When you integrate an indefinite series, work out the constant: here it is 0 because arctan 0 = 0. Forgetting to check it is the usual error.

Integrals no formula can do. The function e−x² has no antiderivative made of standard functions, yet its area matters (it is the shape of the normal distribution in 4.9). Its series integrates easily. Figure 5 shows the area from 0 to 0.5.

e−x2 = 1 − x2 + x4/2 − x6/6 + …substitute u = −x² into eᵘ
∫00.5 e−x2 dx ≈ [ x − x3/3 + x5/10 − x7/42 ]00.5
= 0.5 − 0.041667 + 0.003125 − 0.000186
= 0.46127GDC: 0.46128
Figure 5 · Integrating a series term by term Figure 5 · Integrating a series term by term 0.46128 y = e−x² series: 1 − x² + x⁴/2 − x⁶/6 x y 0.5 1 1.5 0.5 1 This curve has no antiderivative in standard functions, but its series integrates term by term. Four terms give 0.46127 for the shaded area; the true value is 0.46128.
Figure 5 · Integrating a series term by term

Limits. A series also settles limits of the form 0/0 (5.13) without l'Hôpital's rule:

(x − sin x)/x3 = (x − x + x3/6 − x5/120 + …)/x3 = 1/6 − x2/120 + …
limx→0 (x − sin x)/x3 = 1/6

6Series from a differential equation

Sometimes you do not know f(x) at all, only a differential equation it satisfies and one value. The Maclaurin formula needs only the derivatives at 0, and the differential equation supplies them: it gives y′ directly, and differentiating it gives y″, y‴ and so on.

Example 4. The function y satisfies dy/dx = x + y², with y = 1 when x = 0. Find the Maclaurin series for y up to the term in x³.

y′ = x + y2 y′(0) = 0 + 12 = 1
y″ = 1 + 2y y′ y″(0) = 1 + 2(1)(1) = 3differentiate y² implicitly: 2y y′
y‴ = 2(y′)2 + 2y y″ y‴(0) = 2(1) + 2(1)(3) = 8product rule on 2y y′
y = 1 + x + (3/2!)x2 + (8/3!)x3 + …
y = 1 + x + (3/2)x2 + (4/3)x3 + …

None of the exact methods of 5.18 solves this equation: it is not separable, not homogeneous, and not linear, because of the y². The series is what you can get. Figure 6 compares the cubic with the true solution, computed numerically: they agree to 0.003 at x = 0.2, then separate.

Figure 6 · A series solution of dy/dx = x + y², y(0) = 1 Figure 6 · A series solution of dy/dx = x + y², y(0) = 1 (0, 1) series: 1 + x + 1.5x² + (4/3)x³ true solution x y 0.1 0.2 0.3 0.4 0.5 0.6 1 1.5 2 2.5 3 No method on this page solves the equation exactly. The cubic from the series (amber) hugs the true solution (teal, computed numerically) near x = 0 and drifts away as x grows.
Figure 6 · A series solution of dy/dx = x + y², y(0) = 1

Example 5: when you know the function but it is awkward. Find the series for y = esin x up to x⁴. Differentiating esin x four times directly is heavy. Instead, notice that y′ = cos x × esin x = y cos x, a differential equation, and differentiate that.

y = esin x y(0) = 1
y′ = y cos x y′(0) = 1
y″ = y′ cos x − y sin x y″(0) = 1
y‴ = y″ cos x − 2y′ sin x − y cos x y‴(0) = 1 − 0 − 1 = 0
y⁗ = y‴ cos x − 3y″ sin x − 3y′ cos x + y sin x y⁗(0) = 0 − 0 − 3 + 0 = −3
esin x = 1 + x + x2/2 + 0x3 − (3/4!)x4 + … = 1 + x + x2/2 − x4/8 + …

The product rule, applied each time to terms like y′ cos x, produces the next line. Keep y, y′, y″ as symbols until the end and substitute the numbers at 0 only then.

7Where marks are lost

Forgetting the factorials. The coefficient of xⁿ is f⁽ⁿ⁾(0) divided by n!, not f⁽ⁿ⁾(0) alone. In Example 4, y‴(0) = 8 gives (8/6)x³, not 8x³.

Substituting without brackets. For cos 2x the x² term is (2x)²/2! = 2x², not 2x²/2!. Always put the whole substitute in a bracket before raising it to a power.

Multiplying out everything. In a product, collect only the powers you need. Terms beyond the asked power are wasted time and a source of slips.

Dropping terms that should be there. "Up to x⁴" includes a zero coefficient if it is zero: write 0x⁴ or say the term vanishes, so the examiner sees you checked.

Forgetting the constant after integrating. Integrating a series gives a constant; fix it by putting x = 0 into both sides.

Using a series outside where it works. ln(1 + x) at x = 2, or (1 + x)1/2 at x = 3, gives nonsense. Rewrite the number so that the x you use is small, as with ln 2 in section 3.

Differentiating the differential equation wrongly. d/dx(y²) is 2y y′, not 2y. Treat y as a function of x throughout (implicit differentiation, 5.14).

8Work it right

  1. Read what is asked: "up to and including x⁴", or "the first three non-zero terms"; they are different.
  2. From the definition: a column of derivatives, a column of values at 0, then the series with the factorials shown.
  3. Start from a standard series whenever the function is built from one, and name the move (substitute, multiply, differentiate, integrate).
  4. Put substitutes in brackets; in products, collect power by power.
  5. After integrating, find the constant from x = 0.
  6. For a differential equation, keep differentiating the equation itself, and substitute x = 0 values only at the end of each line.
  7. On Paper 2, compare a series approximation with the GDC value and quote the difference if asked for the accuracy.

9Try it

Marks in brackets. Q1 to Q4 are Paper 1 style, no calculator. Q5 is Paper 2 style, with a GDC.

Q1. Using the Maclaurin series for eˣ and ln(1 + x), find the series for eˣ ln(1 + x) up to and including the term in x³. 4 marks

Q2. &nbsp;&nbsp;&nbsp;(a) Write down the Maclaurin series for ln(1 + x²) up to and including the term in x⁶. 2 marks

(b) Hence find the limit of (ln(1 + x²) − x²) ÷ x⁴ as x → 0. 3 marks

Q3. Let f(x) = ln(cos x), for −π/2 < x < π/2. By differentiating, find the Maclaurin series for f(x) up to and including the term in x⁴. 6 marks

Q4. The function y satisfies dy/dx = 1 + xy, with y = 2 when x = 0. Find the Maclaurin series for y up to and including the term in x³. 6 marks

Q5. &nbsp;&nbsp;&nbsp;(a) Using the series for sin x, find the first three non-zero terms of the Maclaurin series for sin(x²). 2 marks

(b) Hence find an approximation to ∫₀¹ sin(x²) dx, giving your answer to five decimal places. 3 marks

(c) Use your GDC to find the value of the integral, and find the percentage error in your approximation. 2 marks

10In one breath

A Maclaurin series writes a function as a polynomial that matches it at x = 0 in value and in every derivative: f(x) = f(0) + x f′(0) + x²f″(0)/2! + …, so the coefficient of xⁿ is f⁽ⁿ⁾(0)/n!. The standard series are eˣ, sin x, cos x, ln(1 + x), arctan x and the binomial (1 + x)ᵖ; the first three work for every x, the others only for x near 0, roughly −1 to 1. New series come from old: substitute (ex², cos 2x, in brackets), multiply and collect power by power (eˣ sin x), differentiate term by term, or integrate term by term and fix the constant (arctan x from 1/(1 + x²)). A few terms approximate numbers, integrals such as ∫ e−x² dx, and limits of the form 0/0. For a differential equation, the equation gives y′(0), differentiating it gives y″(0) and y‴(0), and the factorials turn those into the series.


Answers

Q1. (1 + x + x²/2 + …)(x − x²/2 + x³/3 − …). Collect: x¹: x. x²: −x²/2 + x × x = x²/2. x³: x³/3 + x × (−x²/2) + (x²/2) × x = (1/3 − 1/2 + 1/2)x³ = x³/3. So eˣ ln(1 + x) = x + x²/2 + x³/3 + …. M1 for multiplying the two series, A1 for the x term, A1 for x²/2, A1 for x³/3.

Q2. (a) Substitute x² into ln(1 + u) = u − u²/2 + u³/3 − …: ln(1 + x²) = x² − x⁴/2 + x⁶/3 − …. M1 for substituting x², A1 for all three terms. (b) (ln(1 + x²) − x²)/x⁴ = (−x⁴/2 + x⁶/3 − …)/x⁴ = −1/2 + x²/3 − …, so the limit is −1/2. M1 for using the series in the numerator, A1 for −1/2 + x²/3 − …, A1 for −1/2.

Q3. f = ln(cos x), f(0) = 0. f′ = −tan x, f′(0) = 0. f″ = −sec²x, f″(0) = −1. f‴ = −2sec²x tan x, f‴(0) = 0. f⁗ = −4sec²x tan²x − 2sec⁴x, f⁗(0) = −2. So f(x) = −x²/2! − 2x⁴/4! + … = −x²/2 − x⁴/12 + …. A1 for f′ = −tan x, A1 for f″, M1 for a further derivative by the product or chain rule, A1 for f⁗(0) = −2, M1 for using the Maclaurin formula with factorials, A1 for the series.

Q4. y′ = 1 + xy, so y′(0) = 1. Differentiate: y″ = y + xy′, so y″(0) = 2. Again: y‴ = y′ + y′ + xy″ = 2y′ + xy″, so y‴(0) = 2. Then y = 2 + x + (2/2!)x² + (2/3!)x³ + … = 2 + x + x² + x³/3 + …. A1 for y′(0) = 1, M1 for differentiating xy with the product rule, A1 for y″(0) = 2, A1 for y‴(0) = 2, M1 for the Maclaurin formula, A1 for the series.

Q5. (a) sin(x²) = x² − (x²)³/3! + (x²)⁵/5! − … = x² − x⁶/6 + x¹⁰/120 − …. M1 for substituting x² into the sine series, A1 for all three terms. (b) ∫₀¹ (x² − x⁶/6 + x¹⁰/120) dx = [x³/3 − x⁷/42 + x¹¹/1320]₀¹ = 1/3 − 1/42 + 1/1320 = 0.31028 (5 d.p.). M1 for integrating term by term, A1 for the three integrated terms, A1 for 0.31028. (c) GDC: ∫₀¹ sin(x²) dx = 0.310268…. Percentage error = |0.310281 − 0.310268| ÷ 0.310268 × 100 = 0.00422% (3 s.f.). A1 for 0.310268, A1 for 0.00422%. Rounding (b) to 0.31028 first gives 0.00377%, which is also accepted if the rounding is shown.


Educerie · written from the published IB Diploma Programme Mathematics: analysis and approaches guide, first assessment 2021, section AHL 5.19 Maclaurin series. Original text, examples and questions. Diagrams drawn by Educerie. Last reviewed 25 September 2026.

Mocks: in the future, hold tight!