Message303556
If someone opens a bug report with OpenBSD, or just for us to get more info, it could be useful to have a larger universe of troublesome tan inputs to stare at. So the attached tanny.py supplies them, testing all inputs within 100 ulps of math.pi/2 (or change N=100 to whatever you like).
There are no failures on my 64-bit Win10 3.6.1.
The "correct" answers are computed by using mpmath.tan() set to 200 mantissa bits, then rounding back to 53 bits. These all match the results from my dirt-dumb decimal tan() rounded back, but it's better to trust a widely-used package.
Of course mpmath needs to be installed ("pip install mpmath" works fine):
http://mpmath.org/
Nothing else is needed (while mpmath will exploit gmpy if it's installed, by default it sticks to pure Python code). |
|
Date |
User |
Action |
Args |
2017-10-02 18:39:23 | tim.peters | set | recipients:
+ tim.peters, rhettinger, mark.dickinson, skrah, serhiy.storchaka, davin |
2017-10-02 18:39:23 | tim.peters | set | messageid: <1506969563.08.0.213398074469.issue31630@psf.upfronthosting.co.za> |
2017-10-02 18:39:23 | tim.peters | link | issue31630 messages |
2017-10-02 18:39:22 | tim.peters | create | |
|