haskell / math-functions

Special mathematical functions
http://hackage.haskell.org/package/math-functions
BSD 2-Clause "Simplified" License
41 stars 28 forks source link

Check precision of incomplete gamma #41

Closed Shimuuar closed 8 years ago

Shimuuar commented 8 years ago

Following comment in incomplete gamma implementation does sound very reassuring

    -- For very large `p' normal approximation gives <1e-10 error
    | p >= 2e5           = norm (3 * sqrt p * ((x/p) ** (1/3) + 1/(9*p) - 1))
Shimuuar commented 8 years ago

Implementation of incomplete gamma provides about 10 signiticant digits. Sometimes worse

Shimuuar commented 8 years ago

Mostly fixed in dd10135d14a0da2a8b66da275de569490bb32442

There's still room for improvements but these will be filed as separate issues.