3.6 Numerical Integration

3 min readjune 24, 2024

techniques offer practical ways to approximate definite integrals. These methods, like the midpoint and trapezoidal rules, divide the area under a curve into smaller shapes, summing them up to estimate the total area.

Error calculations and bounds help assess the accuracy of these approximations. , a more advanced technique, uses parabolic arcs for improved precision. Understanding when methods over- or underestimate integrals is crucial for selecting the right approach.

Numerical Integration

Midpoint and trapezoidal rule applications

Top images from around the web for Midpoint and trapezoidal rule applications
Top images from around the web for Midpoint and trapezoidal rule applications
  • divides the interval into equal subintervals and uses the midpoint of each subinterval to calculate the height of rectangles approximating the area under the curve (01exdx\int_0^1 e^x dx)
    • Formula abf(x)dxΔxi=1nf(xi)\int_a^b f(x) dx \approx \Delta x \sum_{i=1}^n f(x_i^*) where Δx=ban\Delta x = \frac{b-a}{n} is the width of each subinterval and xi=xi1+xi2x_i^* = \frac{x_{i-1} + x_i}{2} is the midpoint of each subinterval
  • divides the interval into equal subintervals and uses trapezoids formed by connecting the function values at the endpoints of each subinterval to approximate the area under the curve (0πsinxdx\int_0^{\pi} \sin x dx)
    • Formula abf(x)dxΔx2[f(x0)+2f(x1)+2f(x2)++2f(xn1)+f(xn)]\int_a^b f(x) dx \approx \frac{\Delta x}{2} [f(x_0) + 2f(x_1) + 2f(x_2) + \cdots + 2f(x_{n-1}) + f(x_n)] where Δx=ban\Delta x = \frac{b-a}{n} is the width of each subinterval
  • Both methods are examples of approximations, which partition the interval and sum the areas of simpler shapes

Error calculations in numerical integration

  • measures the difference between the exact value of the integral and the approximation obtained through numerical integration methods (01x2dx\int_0^1 x^2 dx)
    • Formula Ea=exact valueapproximationE_a = |\text{exact value} - \text{approximation}| provides the magnitude of the error
  • expresses the as a fraction of the exact value of the integral (121xdx\int_1^2 \frac{1}{x} dx)
    • Formula Er=exact valueapproximationexact valueE_r = \frac{|\text{exact value} - \text{approximation}|}{|\text{exact value}|} gives the error as a proportion of the true value

Error-bound formulas for integration

  • EMK(ba)324n2|E_M| \leq \frac{K(b-a)^3}{24n^2} where KK is the maximum value of f(x)|f''(x)| on the interval [a,b][a,b] limits the maximum possible error for the midpoint rule approximation (01cosxdx\int_0^1 \cos x dx)
  • Trapezoidal rule error bound ETK(ba)312n2|E_T| \leq \frac{K(b-a)^3}{12n^2} where KK is the maximum value of f(x)|f''(x)| on the interval [a,b][a,b] provides an upper limit for the error in the trapezoidal rule approximation (011x2dx\int_0^1 \sqrt{1-x^2} dx)
  • These error bounds help determine the of the as the number of subintervals increases

Over- vs underestimation in integration

  • Midpoint rule overestimates the integral when the function is (f(x)>0f''(x) > 0) on the interval (01exdx\int_0^1 e^x dx) and underestimates when (f(x)<0f''(x) < 0) (01lnxdx\int_0^1 \ln x dx)
  • Trapezoidal rule underestimates the integral when the function is concave up (f(x)>0f''(x) > 0) on the interval (0π/2sinxdx\int_0^{\pi/2} \sin x dx) and overestimates when concave down (f(x)<0f''(x) < 0) (121x2dx\int_1^2 \frac{1}{x^2} dx)

Simpson's rule for definite integrals

  • Simpson's rule approximates the area under a curve by dividing the interval into an even number of subintervals and using parabolas to estimate the area (01x3dx\int_0^1 x^3 dx)
    • Formula abf(x)dxΔx3[f(x0)+4f(x1)+2f(x2)+4f(x3)++2f(xn2)+4f(xn1)+f(xn)]\int_a^b f(x) dx \approx \frac{\Delta x}{3} [f(x_0) + 4f(x_1) + 2f(x_2) + 4f(x_3) + \cdots + 2f(x_{n-2}) + 4f(x_{n-1}) + f(x_n)] where Δx=ban\Delta x = \frac{b-a}{n} and nn is even
  • Error bound for Simpson's rule ESK(ba)5180n4|E_S| \leq \frac{K(b-a)^5}{180n^4} where KK is the maximum value of f(4)(x)|f^{(4)}(x)| on the interval [a,b][a,b] limits the maximum error (0πcosxdx\int_0^{\pi} \cos x dx)
  • Achieving specified accuracy requires increasing the number of subintervals nn until the error bound is less than the desired accuracy (011+x2dx\int_0^1 \sqrt{1+x^2} dx with error <104< 10^{-4})

Advanced numerical integration techniques

  • apply basic integration methods (like midpoint, trapezoidal, or Simpson's) to smaller subintervals and sum the results for improved accuracy
  • Gaussian methods use specially chosen points and weights to achieve higher accuracy with fewer function evaluations
  • Adaptive quadrature algorithms adjust the subinterval sizes based on the function's behavior to optimize the balance between accuracy and computational efficiency

Key Terms to Review (26)

Absolute error: Absolute error is the difference between the exact value of an integral and its numerical approximation. It quantifies the magnitude of error without considering its direction.
Absolute Error: Absolute error refers to the magnitude of the difference between the true or exact value of a quantity and the measured or approximate value of that quantity. It quantifies the accuracy of a measurement or calculation by providing the actual difference between the real and observed values.
Antiderivative: An antiderivative, also known as a primitive function or indefinite integral, is a function whose derivative is the original function. It represents the accumulation or the reverse process of differentiation, allowing us to find the function that was differentiated to obtain a given derivative.
Composite Rules: Composite rules, in the context of numerical integration, refer to the process of combining multiple basic integration techniques, such as the Trapezoidal Rule and Simpson's Rule, to approximate the integral of a function over a given interval. These rules allow for more accurate integration of complex functions by leveraging the strengths of different numerical integration methods.
Concave Down: Concave down refers to a function or curve that is curved downward, with the curve's vertex pointing downward. This shape indicates that the function is decreasing at an increasing rate, meaning the rate of change of the function is decreasing as the independent variable increases.
Concave Up: Concave up is a term used to describe the shape of a curve on a graph. When a curve is concave up, it means the curve is bending upwards, forming a bowl-like shape. This curvature indicates that the rate of change of the function is increasing at that point.
Convergence Rate: Convergence rate refers to the speed at which a numerical method, such as a series or iterative process, approaches the true solution or limit of a function. It quantifies how quickly the approximations generated by the method get closer to the exact value as more iterations or steps are performed.
Definite integral: The definite integral of a function between two points provides the net area under the curve from one point to the other. It is represented by the integral symbol with upper and lower limits.
Definite Integral: The definite integral represents the area under a curve on a graph over a specific interval. It is a fundamental concept in calculus that allows for the quantification of the accumulation of a quantity over a given range.
Error Bound: An error bound is a mathematical concept that quantifies the maximum possible difference between the true value of a quantity and its estimated or approximated value. It provides a way to measure the accuracy and reliability of numerical computations, approximations, and solutions in various areas of mathematics and science.
Midpoint rule: The midpoint rule is a numerical integration technique used to approximate the definite integral of a function. It estimates the integral by taking the value of the function at the midpoint of each subinterval and multiplying it by the width of the subintervals.
Midpoint Rule: The midpoint rule is a numerical integration method used to approximate the definite integral of a function over a given interval. It involves evaluating the function at the midpoint of the interval and multiplying the result by the width of the interval.
Newton-Cotes Formulas: Newton-Cotes Formulas are a class of numerical integration methods used to approximate the definite integral of a function over a given interval. These formulas are named after Isaac Newton and Roger Cotes, who developed them as a way to numerically evaluate integrals when an analytical solution is not readily available.
Numerical Approximation: Numerical approximation is the process of using mathematical techniques to estimate or approximate the value of a function or quantity when an exact solution is not readily available or computationally feasible. It is a fundamental concept in the field of numerical analysis and is particularly important in the context of numerical integration, where it is used to estimate the value of integrals that cannot be solved analytically.
Numerical integration: Numerical integration involves approximating the value of definite integrals using discrete data points. It is useful when an integral cannot be solved analytically.
Quadrature: Quadrature is the process of approximating the area under a curve using numerical integration techniques. It involves dividing the region into smaller segments and applying mathematical formulas to estimate the total area.
Relative error: Relative error measures the accuracy of an approximation by comparing the absolute error to the exact value. It is often expressed as a percentage.
Relative Error: Relative error is a measure of the accuracy of a numerical approximation or measurement compared to the true value. It quantifies the magnitude of the error relative to the actual value, providing a way to assess the reliability and precision of a calculation or observation.
Riemann sum: A Riemann sum is a method for approximating the total area under a curve on a graph, otherwise known as an integral. It sums up the areas of multiple rectangles to estimate the value of an integral.
Riemann Sum: A Riemann sum is a method used to approximate the value of a definite integral by dividing the interval of integration into smaller subintervals and then summing the areas of the rectangles formed by the function values at the subinterval endpoints. It provides a way to numerically estimate the integral when an analytical solution is not readily available.
Riemann sums: Riemann sums approximate the integral of a function using finite sums. They involve partitioning the interval and summing the product of function values and subinterval widths.
Simpson’s rule: Simpson's rule is a method for numerical integration that approximates the value of a definite integral by using quadratic polynomials. It is particularly useful for functions that are difficult to integrate analytically.
Simpson's Rule: Simpson's rule is a numerical integration method used to approximate the definite integral of a function over an interval. It is a more accurate alternative to the Riemann sum method, particularly for functions that can be well approximated by quadratic polynomials.
The Integral Symbol (∫): The integral symbol (∫) represents the mathematical operation of integration, which is the inverse of differentiation. It is used to calculate the accumulated change of a function over an interval, finding the area under a curve, or determining the total effect of a varying quantity.
Trapezoidal Rule: The trapezoidal rule is a numerical integration method used to approximate the definite integral of a function over a given interval. It is a simple and widely-used technique for estimating the area under a curve by dividing the interval into trapezoids and summing their areas.
Truncation Error: Truncation error is the difference between the actual value of a function and its approximation obtained by truncating an infinite series or limiting the number of terms in a numerical method. It is a type of discretization error that arises when continuous mathematical problems are approximated by discrete numerical methods.
© 2024 Fiveable Inc. All rights reserved.
AP® and SAT® are trademarks registered by the College Board, which is not affiliated with, and does not endorse this website.
Glossary
Glossary