Every engineer, physicist, and data scientist eventually needs to compute an integral they cannot solve by hand. The obvious approach is to sample the function at many evenly spaced points and add up the pieces — the trapezoidal rule, or its smoother cousin Simpson's rule. Double the number of samples and you roughly halve the error. Eventually you converge, but slowly.
Carl Friedrich Gauss asked a sharper question in 1814: if I am free to choose where I sample a function, not just how many times, where should I look? The answer he found was remarkable. For polynomials, you can integrate exactly — zero error — using far fewer evaluations than you might think, simply by placing the sample points at the roots of a special family of polynomials called the Legendre polynomials.
The technique he discovered, now called Gaussian quadrature, is one of the great efficiency wins in all of numerical analysis. An -point Gaussian rule integrates every polynomial of degree up to exactly. Three points suffice for any degree-5 polynomial. Five points handle degree 9. The number of free parameters — points plus weights, totalling — is used to the last degree of freedom.
This is not a story about approximation getting lucky. It is about an optimal allocation of effort, and the mathematics behind it connects to polynomial approximation and the deep structure of orthogonal polynomials.
Comments
Loading comments...