-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Fast functions on integers. -- -- Fast functions for number theory and combinatorics with a high level -- of safety guaranteed by ATS. @package fast-arithmetic @version 0.6.4.0 -- | This provides facilities for working with common combinatorial -- functions. module Numeric.Combinatorics -- | <math> choose :: Int -> Int -> Integer -- | <math> doubleFactorial :: Int -> Integer -- | The nth Catalan number, with indexing beginning at -- 0. -- --
-- λ:> catalan <$> [0..9] -- [1,1,2,5,14,42,132,429,1430,4862] --catalan :: Int -> Integer factorial :: Int -> Integer -- | \( !n \) -- --
-- λ:> derangement <$> [0..10] -- [1,0,1,2,9,44,265,1854,14833,133496,1334961] --derangement :: Int -> Integer permutations :: Int -> Int -> Integer -- | Compute the maximal number of regions obtained by joining \( n \) -- points about a circle by straight lines. See here. maxRegions :: Int -> Integer -- | Stirling numbers of the second kind. stirling2 :: Int -> Int -> Integer -- | This module provides fast number theoretic functions. module Numeric.NumberTheory -- | Euler totient function. totient :: Int -> Int -- | Number of distinct divisors. tau :: Int -> Int -- | Number of distinct prime factors littleOmega :: Int -> Int -- | See here isPerfect :: Int -> Bool -- | Sum of proper divisors. May overflow. sumDivisors :: Int -> Int -- | <math> isPrime :: Int -> Bool -- | Radical of an integer radical :: Int -> Int