Fiveable

๐ŸงฎComputational Mathematics Unit 4 Review

QR code for Computational Mathematics practice questions

4.4 Quadrature rules

๐ŸงฎComputational Mathematics
Unit 4 Review

4.4 Quadrature rules

Written by the Fiveable Content Team โ€ข Last updated September 2025
Written by the Fiveable Content Team โ€ข Last updated September 2025
๐ŸงฎComputational Mathematics
Unit & Topic Study Guides

Quadrature rules are numerical methods for approximating definite integrals. They replace complex integrands with simpler functions, usually polynomials, and express the result as a weighted sum of function values at specific points.

These rules are crucial when analytical solutions are challenging or impossible. They're classified as open or closed formulas and have varying degrees of precision. Choosing the right rule depends on accuracy needs, computational efficiency, and the nature of the integrand.

Quadrature rules for integration

Numerical approximation of definite integrals

  • Quadrature rules approximate definite integrals when analytical solutions prove challenging or impossible
  • Replace the integrand with a simpler function (typically a polynomial) for easier integration
  • Express as a weighted sum of function values at specific points within the integration interval
  • Classify as open or closed formulas based on inclusion of integration interval endpoints in evaluation points
  • Degree of precision indicates the highest degree polynomial for which the rule gives an exact result
  • Error analysis examines the remainder term (difference between true integral and approximation)
  • Select quadrature rule based on desired accuracy, computational efficiency, and integrand nature
    • Example: Gaussian quadrature for highly oscillatory functions
    • Example: Trapezoidal rule for periodic functions

Classification and error analysis

  • Open formulas exclude endpoints of integration interval from evaluation points
    • Example: Midpoint rule evaluates function at interval center
  • Closed formulas include endpoints in evaluation points
    • Example: Trapezoidal rule uses function values at interval endpoints
  • Degree of precision determines accuracy for polynomial integrands
    • Example: Simpson's rule has degree of precision 3, exact for cubic polynomials
  • Remainder term represents approximation error
    • Typically expressed in terms of higher derivatives of the integrand
    • Example: Trapezoidal rule error proportional to second derivative of integrand
  • Error bounds help estimate approximation accuracy
    • Often involve maximum values of higher derivatives over integration interval

Newton-Cotes formulas for integration

Trapezoidal and Simpson's rules

  • Newton-Cotes formulas approximate integrals using equally spaced points and polynomial interpolation
  • Trapezoidal rule fits a linear function between two points
    • Averages function values at endpoints
    • Formula: โˆซabf(x)dxโ‰ˆbโˆ’a2[f(a)+f(b)]\int_a^b f(x) dx \approx \frac{b-a}{2}[f(a) + f(b)]
  • Simpson's rule uses quadratic interpolation over three points
    • More accurate for many functions compared to trapezoidal rule
    • Formula: โˆซabf(x)dxโ‰ˆbโˆ’a6[f(a)+4f(a+b2)+f(b)]\int_a^b f(x) dx \approx \frac{b-a}{6}[f(a) + 4f(\frac{a+b}{2}) + f(b)]
  • Composite versions divide integration interval into subintervals
    • Apply basic rule to each subinterval and sum results
    • Improve accuracy for non-polynomial integrands
  • Error terms proportional to power of step size and higher derivative of integrand
    • Trapezoidal rule error: O(h2)O(h^2), where h is step size
    • Simpson's rule error: O(h4)O(h^4)

Higher-order formulas and implementation

  • Higher-order Newton-Cotes formulas provide increased accuracy for smooth functions
    • Simpson's 3/8 rule uses four points for cubic interpolation
    • Boole's rule employs five points for quartic interpolation
  • Stability concerns arise for certain functions with higher-order formulas
    • Runge phenomenon can occur with high-degree polynomial interpolation
  • Implement Newton-Cotes formulas using loop structures or vectorized operations
    • Example (Python):
      def trapezoidal(f, a, b, n):
          h = (b - a) / n
          x = np.linspace(a, b, n+1)
          y = f(x)
          return h * (0.5*y[0] + np.sum(y[1:-1]) + 0.5y[-1])
      
  • Adaptive implementations adjust subinterval sizes based on local error estimates
    • Concentrate evaluation points in regions of high integrand variation

Accuracy and efficiency of quadrature rules

Assessing accuracy and convergence

  • Compare approximations to known analytical solutions or higher-precision numerical results
  • Error estimates involve bounds on higher derivatives of integrand over integration interval
  • Order of convergence indicates error decrease rate as function evaluations increase
    • Example: Trapezoidal rule has second-order convergence
    • Example: Simpson's rule exhibits fourth-order convergence
  • Efficiency measured by accuracy achieved for given number of function evaluations or computational time
  • Adaptive quadrature methods adjust evaluation point distribution based on integrand behavior
    • Improve accuracy and efficiency for functions with localized features
    • Example: Gauss-Kronrod quadrature adapts to integrand complexity

Advanced techniques and trade-offs

  • Richardson extrapolation increases accuracy order by combining approximations with different step sizes
    • Example: Romberg integration applies Richardson extrapolation to trapezoidal rule
  • Trade-offs between accuracy, computational cost, and integrand smoothness influence quadrature rule selection
    • High-order methods (Simpson's rule) provide better accuracy for smooth functions
    • Lower-order methods (trapezoidal rule) offer stability for less smooth or oscillatory functions
  • Specialized quadrature rules target specific integrand types
    • Clenshaw-Curtis quadrature for periodic functions
    • Gauss-Laguerre quadrature for integrals over semi-infinite intervals
  • Error control strategies ensure desired accuracy
    • Adaptive step size selection based on local error estimates
    • Example: Integrate until difference between successive approximations falls below tolerance