Updated with rigor, per Haskell community feedback.
This commit is contained in:
parent
48b20c54ce
commit
0f9f50c732
13 changed files with 120 additions and 223 deletions
|
@ -1,15 +1,14 @@
|
|||
module Main where
|
||||
|
||||
import Control.Monad.State
|
||||
import System.Random
|
||||
import RWD
|
||||
import qualified Types
|
||||
import qualified RWD
|
||||
|
||||
main :: IO ()
|
||||
main = do
|
||||
g <- newStdGen
|
||||
let i = take 10 $ randoms g
|
||||
(iDot, phase) = dynamics i 0.0
|
||||
fieldprint <- evalStateT (fieldprint i) (i, 0.0)
|
||||
let intellectons = replicate 10 (Types.Intellecton 1.0 1.0)
|
||||
(iDots, phase) = RWD.dynamics intellectons 0.0
|
||||
fieldprint <- evalStateT (RWD.fieldprint intellectons) (Types.WitnessState intellectons 0.0)
|
||||
if fieldprint > 0
|
||||
then putStrLn $ "RWD test passed: Fieldprint = " ++ show fieldprint
|
||||
else putStrLn "RWD test failed" >> error "Test failed"
|
Loading…
Add table
Add a link
Reference in a new issue