HSGEP-0.1.5: Gene Expression Programming evolutionary algorithm in Haskell

Safe HaskellNone

GEP.Rmonad

Description

Monad based on state for passing random number state around for GEP. The choice of Mersenne.Pure64 was for performance, and the pure version will play nicely with threading.

Author: mjsottile@computer.org

Synopsis

Documentation

type GEPMonad a = Rand aSource

nextFSource

Arguments

:: Double

Upper bound.

-> Rand Double 

Generate a random number as a Double between 0.0 and the given upper bound.

nextRSource

Arguments

:: Int

Upper bound.

-> Rand Int 

Generate a random integer between 1 and the upper bound (inclusive).

nextRDifferentSource

Arguments

:: Int

Upper bound.

-> Int

Integer to avoid.

-> Rand Int 

Generate a random integer in the specified range that is NOT equal to the integer provided.

nextRListSource

Arguments

:: Int

Number of integers to generate

-> Int

Upper bound for each integer.

-> Rand [Int] 

Generate a list of random integers.

nextRListUnique :: Int -> [Int] -> Int -> Rand [Int]Source

Generate a list of n random integers such that each entry occurs at most once. Each number in the list must be unique.

generatePairs :: Int -> Rand [(Int, Int)]Source

Document me!