Lines Matching defs:x1
173 // equalWithAbsError (x1, x2, e)
175 // Returns true if x1 is the same as x2 with an absolute error of
178 // abs (x1 - x2) <= e
180 // equalWithRelError (x1, x2, e)
182 // Returns true if x1 is the same as x2 with an relative error of
185 // abs (x1 - x2) <= e * x1
191 equalWithAbsError (T x1, T x2, T e)
193 return ((x1 > x2)? x1 - x2: x2 - x1) <= e;
199 equalWithRelError (T x1, T x2, T e)
201 return ((x1 > x2)? x1 - x2: x2 - x1) <= e * ((x1 > 0)? x1: -x1);