Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- getRandomS :: (MonadRandom m, Random a) => Behaviour m time a
- getRandomRS :: (MonadRandom m, Random a) => BehaviourF m time (a, a) a
- getRandomRS_ :: (MonadRandom m, Random a) => (a, a) -> Behaviour m time a
- runRandS :: (RandomGen g, Monad m) => ClSF (RandT g m) cl a b -> g -> ClSF m cl a (g, b)
- evalRandS :: (RandomGen g, Monad m) => ClSF (RandT g m) cl a b -> g -> ClSF m cl a b
- execRandS :: (RandomGen g, Monad m) => ClSF (RandT g m) cl a b -> g -> ClSF m cl a g
- evalRandIOS :: Monad m => ClSF (RandT StdGen m) cl a b -> IO (ClSF m cl a b)
- evalRandIOS' :: MonadIO m => ClSF (RandT StdGen m) cl a b -> ClSF m cl a b
- getRandomsS :: forall (m :: Type -> Type) b a. (MonadRandom m, Random b) => Automaton m a [b]
- getRandomsRS :: forall (m :: Type -> Type) b a. (MonadRandom m, Random b) => (b, b) -> Automaton m a [b]
- getRandomsRS_ :: forall (m :: Type -> Type) b. (MonadRandom m, Random b) => Automaton m (b, b) [b]
Documentation
getRandomS :: (MonadRandom m, Random a) => Behaviour m time a Source #
Produce a random value at every tick.
getRandomRS :: (MonadRandom m, Random a) => BehaviourF m time (a, a) a Source #
Produce a random value at every tick, within a range given per tick.
getRandomRS_ :: (MonadRandom m, Random a) => (a, a) -> Behaviour m time a Source #
Produce a random value at every tick, within a range given once.
:: (RandomGen g, Monad m) | |
=> ClSF (RandT g m) cl a b | |
-> g | The initial random seed |
-> ClSF m cl a (g, b) |
Generates random values, updating the generator on every step.
evalRandS :: (RandomGen g, Monad m) => ClSF (RandT g m) cl a b -> g -> ClSF m cl a b Source #
Updates the generator every step but discards the generator.
execRandS :: (RandomGen g, Monad m) => ClSF (RandT g m) cl a b -> g -> ClSF m cl a g Source #
Updates the generator every step but discards the value, only outputting the generator.
evalRandIOS :: Monad m => ClSF (RandT StdGen m) cl a b -> IO (ClSF m cl a b) Source #
Evaluates the random computation by using the global random generator.
evalRandIOS' :: MonadIO m => ClSF (RandT StdGen m) cl a b -> ClSF m cl a b Source #
Evaluates the random computation by using the global random generator on the first tick.
getRandomsS :: forall (m :: Type -> Type) b a. (MonadRandom m, Random b) => Automaton m a [b] #
Create a stream of lists of random values.
getRandomsRS :: forall (m :: Type -> Type) b a. (MonadRandom m, Random b) => (b, b) -> Automaton m a [b] #
Create a stream of lists of random values in a given fixed range.
getRandomsRS_ :: forall (m :: Type -> Type) b. (MonadRandom m, Random b) => Automaton m (b, b) [b] #
Create a stream of lists of random values in a given range, where the range is specified on every tick.