aivika-0.7: A multi-paradigm simulation library

Stabilityexperimental
MaintainerDavid Sorokin <david.sorokin@gmail.com>
Safe HaskellSafe-Inferred

Simulation.Aivika.Parameter

Description

Tested with: GHC 7.6.3

This module defines the parameters of simulation experiments.

Synopsis

Documentation

newParameter :: IO a -> IO (Simulation a)Source

Create a thread-safe parameter that returns always the same value within the simulation run, where the value is recalculated for each new run.

newTableParameter :: Array Int a -> IO (Simulation a)Source

Create a thread-safe parameter that returns always the same value within the simulation run, where the value is taken consequently from the specified table based on the number of the current run starting from zero. After all values from the table are used, it takes the first value of the table, then the second one and so on.

newIndexedParameter :: (Int -> IO a) -> IO (Simulation a)Source

Create a thread-safe parameter that returns always the same value within the simulation run, where the value depends on the number of this run starting from zero.