X-Git-Url: http://gitweb.michael.orlitzky.com/?a=blobdiff_plain;f=src%2FComparisons.hs;h=b5d76d5b11d6da85ca386021be918041d83abd53;hb=ea92f7319ba4350715e2397928def15f574d9d8c;hp=506ebab8217b8c46cda4bf2b8ee7fe636c619cf2;hpb=28710758dac0a1241911c6ba296b0685b877b5e3;p=spline3.git diff --git a/src/Comparisons.hs b/src/Comparisons.hs index 506ebab..b5d76d5 100644 --- a/src/Comparisons.hs +++ b/src/Comparisons.hs @@ -1,9 +1,10 @@ +-- | Functions for comparing 'Double' values. module Comparisons where -- | epsilon is the value that will be used in all tests that require --- some measure of "closeness." Increasing it will make those tests --- more tolerant. +-- some measure of \"closeness.\" Increasing it will make those +-- tests more tolerant. epsilon :: Double epsilon = 0.0001 @@ -22,7 +23,7 @@ very_positive :: Double -> Bool very_positive x = x - epsilon > 0 --- | Takes a list of Doubles and returns the ones which are not very +-- | Takes a list of 'Double' and returns the ones which are not very -- positive. non_very_positive_entries :: [Double] -> [Double] non_very_positive_entries = filter (not . very_positive)