| Copyright | (c) 2009, 2011 Bryan O'Sullivan |
|---|---|
| License | BSD3 |
| Maintainer | bos@serpentine.com |
| Stability | experimental |
| Portability | portable |
| Safe Haskell | None |
| Language | Haskell98 |
Numeric.SpecFunctions.Extra
Description
Less common mathematical functions.
Documentation
chooseExact :: Int -> Int -> Double
Calculate binomial coefficient using exact formula
logChooseFast :: Double -> Double -> Double
Quickly compute the natural logarithm of n k, with
no checking.choose
Less numerically stable:
exp $ lg (n+1) - lg (k+1) - lg (n-k+1) where lg = logGamma . fromIntegral