[PATCH] Adding fixed-order Gauss-Legendre integration routines

Rhys Ulerich rhys.ulerich@gmail.com
Sun Jun 21 20:31:00 GMT 2009

Hi all,

Attached is a gzipped patch that adds fixed-order Gauss-Legendre quadrature
to the numerical integration routines.  This is work by Pavel Holoborodko
(http://www.holoborodko.com/pavel/?page_id=679) which I have modified
to fit GSL conventions.  The routines include precomputed full double
precision points and weights for n =
2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,
32, 64, 96, 100, 128, 256, 512, and 1024 Gauss points.  If the user
selects any other number, the necessary points and weights are
computed on the fly and remain quite good.  Documentation and unit
tests are provided.  Functions/structs live under the name

One might justly ask why include this code when gsl_integration_qng
already provides non-adaptive Gauss-Kronrod rules.  For integrands
with known polynomial order, it is possible to cut down the number of
evaluations required when using these routines.

Would love to hear feedback,

P.S. Sorry about the patch size.  It's a bit hefty from coefficients
and trailing whitespace elimination in the documentation and
integration unit tests files.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Added-gsl_integration_glfixed-routines.patch.gz
Type: application/x-gzip
Size: 57402 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/gsl-discuss/attachments/20090621/89423352/attachment.bin>

More information about the Gsl-discuss mailing list