probability-0.2.5: Probabilistic Functional Programming

Safe HaskellSafe-Inferred
LanguageHaskell98

Numeric.Probability.Example.TreeGrowth

Contents

Synopsis

Documentation

data Tree Source

Constructors

Alive Height 
Hit Height 
Fallen 

Instances

seed :: Tree Source

tree growth simulation: start with seed and run for n generations

exact results

tree :: Int -> Tree -> Dist Tree Source

tree n : tree distribution after n generations

hist :: Int -> Expand Tree Source

hist n : history of tree distributions for n generations

simulation results

simTree :: Int -> Int -> RTrans Tree Source

Since '(*.)' is overloaded for Trans and RChange, we can run the simulation ~. directly to n *. live.

sh2 :: IO () Source

st2 :: IO () Source