This is the mail archive of the gsl-discuss@sourceware.org mailing list for the GSL project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

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


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
gsl_integration_glfixed*

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,
Rhys

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.

Attachment: 0001-Added-gsl_integration_glfixed-routines.patch.gz
Description: GNU Zip compressed data


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]