Re: [Numpy-discussion] commutative allclose

2008-04-10 Thread Charles R Harris
On Thu, Apr 10, 2008 at 1:56 PM, Tom Johnson <[EMAIL PROTECTED]> wrote: > Should allclose() be commutative, so as to prevent the following: > > >>> x = 1.1001 > >>> allclose(x,1), allclose(1,x) > (False, True) > > There is some discussion here which provides two possible solutions: > > > http

[Numpy-discussion] commutative allclose

2008-04-10 Thread Tom Johnson
Should allclose() be commutative, so as to prevent the following: >>> x = 1.1001 >>> allclose(x,1), allclose(1,x) (False, True) There is some discussion here which provides two possible solutions: http://www.boost.org/doc/libs/1_35_0/libs/test/doc/components/test_tools/floating_point_compar