diff options
Diffstat (limited to 'packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs')
-rw-r--r-- | packages/tests/src/Numeric/LinearAlgebra/Tests/Properties.hs | 5 |
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 | ||
16 | module Numeric.LinearAlgebra.Tests.Properties ( | 16 | module 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 ( | |||
45 | import Numeric.LinearAlgebra.HMatrix hiding (Testable,unitary) | 45 | import Numeric.LinearAlgebra.HMatrix hiding (Testable,unitary) |
46 | import Test.QuickCheck | 46 | import Test.QuickCheck |
47 | 47 | ||
48 | (~=) :: Double -> Double -> Bool | ||
49 | a ~= b = abs (a - b) < 1e-10 | ||
50 | |||
48 | trivial :: Testable a => Bool -> a -> Property | 51 | trivial :: Testable a => Bool -> a -> Property |
49 | trivial = (`classify` "trivial") | 52 | trivial = (`classify` "trivial") |
50 | 53 | ||