summaryrefslogtreecommitdiff
path: root/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs
diff options
context:
space:
mode:
Diffstat (limited to 'packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs')
-rw-r--r--packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs b/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs
index 720b7bd..046644f 100644
--- a/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs
+++ b/packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs
@@ -14,7 +14,7 @@ Testing properties.
14-} 14-}
15 15
16module Numeric.LinearAlgebra.Tests.Properties ( 16module Numeric.LinearAlgebra.Tests.Properties (
17 dist, (|~|), (~~), (~:), Aprox((:~)), 17 dist, (|~|), (~~), (~:), Aprox((:~)), (~=),
18 zeros, ones, 18 zeros, ones,
19 square, 19 square,
20 unitary, 20 unitary,
@@ -45,6 +45,9 @@ module Numeric.LinearAlgebra.Tests.Properties (
45import Numeric.LinearAlgebra.HMatrix hiding (Testable,unitary) 45import Numeric.LinearAlgebra.HMatrix hiding (Testable,unitary)
46import Test.QuickCheck 46import Test.QuickCheck
47 47
48(~=) :: Double -> Double -> Bool
49a ~= b = abs (a - b) < 1e-10
50
48trivial :: Testable a => Bool -> a -> Property 51trivial :: Testable a => Bool -> a -> Property
49trivial = (`classify` "trivial") 52trivial = (`classify` "trivial")
50 53