From e503945c666dc28f1a806ba1a2deaa587a836200 Mon Sep 17 00:00:00 2001 From: Alberto Ruiz Date: Thu, 30 Dec 2010 18:07:39 +0000 Subject: cond --- lib/Numeric/LinearAlgebra/Tests.hs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'lib/Numeric/LinearAlgebra/Tests.hs') diff --git a/lib/Numeric/LinearAlgebra/Tests.hs b/lib/Numeric/LinearAlgebra/Tests.hs index 181cfbf..76eaaae 100644 --- a/lib/Numeric/LinearAlgebra/Tests.hs +++ b/lib/Numeric/LinearAlgebra/Tests.hs @@ -369,7 +369,14 @@ findAssocTest = utest "findAssoc" ok where ok = m1 == m2 m1 = assoc (6,6) 7 $ zip (find (>0) (ident 5 :: Matrix Float)) [10 ..] :: Matrix Double - m2 = diagRect 7 (fromList[10..14]) 6 6 :: Matrix Double + m2 = diagRect 7 (fromList[10..14]) 6 6 + +--------------------------------------------------------------------- + +condTest = utest "cond" ok + where + ok = step v * v == cond v 0 0 0 v + v = fromList [-7 .. 7 ] :: Vector Float --------------------------------------------------------------------- @@ -542,6 +549,7 @@ runTests n = do , chainTest , succTest , findAssocTest + , condTest ] return () -- cgit v1.2.3