packages feed

GaussQuadIntegration-0.1: GaussQuadIntegration.cabal

Name:                GaussQuadIntegration
Version:             0.1
Stability:           Experimental

Author:              Grigory Sarnitsky <sargrigory@ya.ru>
Maintainer:          Grigory Sarnitsky <sargrigory@ya.ru>
License:             BSD3
License-file:        LICENSE

Build-type:          Simple
Cabal-version:       >=1.2

Category:            Math
Synopsis:            Non-adaptive Gaussian quadrature for numeric integraton
Description:
  This package provides means for numeric integration with a Gaussian quadrature. Precisely, it incorporates non-adaptive approximation for definite integrals using 128-, 256-, 512- and 1024-point Gaussian quadrature rule.

  For example, to find the approximation of an integral with a 256-point rule:
  .
  > ╭ a
  > │   f(x) dx = nIntegrate256 f a b
  > ╯ b
  .
  > > nIntegrate256 (\x -> x^999) 0 1
  > 9.999999999999887e-4
  .
  The type of a function here is not confined only by Double -> Double, indeed one can use any instance of Fractional:
  .
  > > nIntegrate256 (\x -> x^999 :: Fixed Prec50) 0 1
  > 0.00100000000000000000000000000000000000000000000009
  .
  128 and 256 rules are given with the accuracy of 50 digits, 512 --- with 35 digits (roughly quad), all of them were computed by myself. 1024-point rule was taken from the Gauss-Legendre Quadrature C\/C++ library by Pavel Holoborodko (<http://www.holoborodko.com/pavel/numerical-methods/numerical-integration/>) and goes with the accuracy of 25 decimal digits (fixed point).


Library
  hs-source-dirs:      src
  Exposed-modules:     Math.GaussianQuadratureIntegration
  other-modules:       Math.GaussianQuadratureRules
  build-depends:       base >= 3 && < 6