-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Efficient, purely functional generation of prime numbers -- -- This Haskell library provides an efficient lazy wheel sieve for prime -- generation ispired by Lazy wheel sieves and spirals of primes -- by Colin Runciman and The Genuine Sieve of Eratosthenes by -- Melissa O'Neil. @package primes @version 0.1 -- | This Haskell library provides an efficient lazy wheel sieve for prime -- generation ispired by Lazy wheel sieves and spirals of primes -- [1] by Colin Runciman and The Genuine Sieve of Eratosthenes [2] -- by Melissa O'Neil. -- --
module Data.Numbers.Primes -- | This global constant is an infinite list of prime numbers. It is -- generated by a lazy wheel sieve and shared among different -- applications. If you are concerned about the memory requirements of -- sharing many primes you can call the function wheelSieve -- directly. primes :: [Integer] -- | This function returns an infinite list of prime numbers by sieving -- with a wheel that cancels the multiples of the first n primes -- where n is the argument given to wheelSieve. Don't -- use too large wheels because computing them is more expensive than -- sieving. The number 6 is a good value to pass to this -- function. wheelSieve :: Int -> [Integer]