Skip to content
Calculus I / Techniques of Integration

Approximate Integration: Trapezoid, Midpoint, and Simpson's Rules

There are two situations where the Fundamental Theorem of Calculus cannot be used directly: when no elementary antiderivative exists (e.g. ∫01e−x2 dx\int_0^1 e^{-x^2}\,dx, the Gaussian integral that drives the Black-Scholes normal CDF), and when the function is given only at discrete data points (a time-series of asset returns, a table of observed option prices). In both cases, numerical quadrature — approximating the integral by a weighted sum of function values — gives a computable answer with a controllable error. The Trapezoid Rule, Midpoint Rule, and Simpson's Rule are the three workhorses, each improving accuracy at the cost of slightly more bookkeeping. Knowing the error bounds tells you how many points you need to hit a target accuracy.
Learning objectives. By the end of this note you should be able to:
  • write down the Trapezoid, Midpoint, and Simpson's Rule formulas for a given nn;
  • apply each rule to compute a definite integral numerically;
  • state the error bounds for TnT_n, MnM_n, and SnS_n and use them to determine nn;
  • choose the right rule given a tolerance constraint.

In this lesson

  1. Setup and notation
  2. The Trapezoid Rule
  3. The Midpoint Rule
  4. Simpson's Rule
  5. Error bounds
  6. Finance application: the Gaussian integral

Before you start

The full lesson, with worked examples and exercise solutions, is for members.

Read the full lesson

New to SelfMadeQuant.com? See membership options or explore the curriculum.