IB Maths AI HL Integration Paper 1 & 2 ~7 min read

Numerical Integration using the Trapezoidal Rule

Some areas under a curve are awkward to integrate exactly — so we approximate. The trapezoidal rule slices the region into vertical strips, treats each as a trapezoid, and adds up their areas. It’s a quick numerical estimate of ab y dx, and the formula is handed to you in the booklet.

📘 What you need to know

The formula and the strips

The region is cut into n equal-width strips. Each strip is a trapezoid whose parallel sides are two neighbouring y-values; adding their areas gives the estimate.

Trapezoidal rule ab y dx12h[(y0 + yn) + 2(y1 + y2 + … + yn−1)],  h = ban ✓ given in the formula booklet

🧠 “Ends once, middles twice”

The two outer heights (y0 and yn) are counted once; every height in between is doubled. Multiply the whole bracket by 12h.

⚠ Strips vs data points

Working through it

🧭 Recipe — trapezoidal rule

  1. Find the strip width h = ban.
  2. List the x-values x0 = a, x1 = a+h, … up to xn = b.
  3. Build a table of y-values y0, y1, … yn from y = f(x).
  4. Substitute all the y-values, h and n into the formula.

🤔 Why trapezoids and not rectangles?

A rectangle uses a flat top, so it either cuts the corner off the curve or overshoots it. A trapezoid slants its top to join the two end heights of the strip, hugging the curve far more closely. More strips means thinner trapezoids and an even better fit — which is why a larger n gives a more accurate estimate.

Percentage error: once you have both an estimate and the exact value, compare them with estimate − exactexact × 100. Take the size (ignore any minus sign) — or do exact − estimate to keep it positive.

Worked examples

All parts approximate 04 6x2x3 + 2 dx with n = 4.

WE 1

Find the strip width h and the x-values

Use h = ban with a = 0, b = 4, n = 4.

h = 4 − 04 = 1 x-values: 0, 1, 2, 3, 4 (five values)
WE 2

Build the table of y-values

Substitute each x into y = 6x2x3 + 2.

y₀ = f(0) = 0 y₁ = f(1) = 63 = 2 y₂ = f(2) = 2410 = 2.4 y₃ = f(3) = 5429 = 1.862… y₄ = f(4) = 9666 = 1.454…
WE 3

Apply the formula (answer to 3 d.p.)

Ends once, middles twice, all × 12h.

12(1)[(0 + 1.454…) + 2(2 + 2.4 + 1.862…)] = 12(1.454… + 12.524…) = 12(13.978…) = 6.9893… ≈ 6.989 (3 d.p.)
WE 4

The exact area is 6.993. Find the percentage error

Use estimate − exactexact × 100.

6.989 − 6.9936.993 × 100 = −0.0572…% (ignore the minus) ≈ 0.06% (2 d.p.)
WE 5

Spot the count: how many strips and how many y-values when n = 6 on [1, 4]?

Strips = n; y-values = n+1; width = ban.

strips n = 6 y-values = 6 + 1 = 7 (y₀ … y₆) h = 4 − 16 = 0.5

💡 Top tips

⚠ Common mistakes

Next up — Introduction to Integration. The trapezoidal rule estimates an area numerically; the rest of this unit finds areas (and antiderivatives) exactly. The next topic flips differentiation on its head: integration is antidifferentiation, the process of recovering a function from its gradient — and it introduces the all-important constant of integration, “+ c“.

Need help with Integration?

Get 1-on-1 help from an IB examiner who knows exactly what Paper 1 & 2 are looking for.

Book Free Session →