Message274350
Opening this for the record; I intend to close as "wont fix". The tan function has poor accuracy for inputs near pi/2 on OS X 10.4. This is a direct consequence of a poor libm implementation, so there's little we can do about it short of re-implenting tan ourselves. 10.4 is ancient enough by now that it's difficult to care too much. Example failures: ====================================================================== FAIL: test_testfile (test.test_math.MathTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/db3l/buildarea/3.x.bolen-tiger/build/Lib/test/test_math.py", line 1190, in test_testfile '\n '.join(failures)) AssertionError: Failures in test_testfile: tan0064: tan(1.5707963267948961): expected 1978937966095219.0, got 1978945885716843.0 (error = 7.92e+09 (31678486496 ulps); permitted error = 0 or 5 ulps) and a corresponding failure in cmath: ====================================================================== FAIL: test_specific_values (test.test_cmath.CMathTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/db3l/buildarea/3.x.bolen-tiger/build/Lib/test/test_cmath.py", line 398, in test_specific_values msg=error_message) File "/Users/db3l/buildarea/3.x.bolen-tiger/build/Lib/test/test_cmath.py", line 147, in rAssertAlmostEqual '{!r} and {!r} are not sufficiently close'.format(a, b)) AssertionError: tan0064: tan(complex(1.5707963267948961, 0.0)) Expected: complex(1978937966095219.0, 0.0) Received: complex(1978945885716843.0, 0.0) Received value insufficiently close to expected value. | |
| Date | User | Action | Args | | 2016-09-04 08:35:39 | mark.dickinson | set | recipients: + mark.dickinson, ronaldoussoren, ned.deily | | 2016-09-04 08:35:39 | mark.dickinson | set | messageid: <1472978139.6.0.979363390278.issue27953@psf.upfronthosting.co.za> | | 2016-09-04 08:35:39 | mark.dickinson | link | issue27953 messages | | 2016-09-04 08:35:39 | mark.dickinson | create | | |