Raymond Hettinger <raymond.hettin...@gmail.com> added the comment: I would have thought this would be a straight pass-through to the underlying hardware FPU tan() instruction so that it would give the same answer for the same hardware regardless of O/S.
Perhaps we're seeing a software-only implementation (using CORDIC or somesuch). If so, inputs close to a singularity are the place where the implementation is likely to fall apart (the relative error in this example is 1.000004001955473). * https://www.gnu.org/software/libc/manual/html_node/Errors-in-Math-Functions.html * https://stackoverflow.com/questions/16880376/sin-cos-tan-not-accurate * http://code.activestate.com/recipes/576792-polar-to-rectangular-conversions-using-cordic/ ---------- nosy: +rhettinger, tim.peters _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue31630> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com