Mark Dickinson <dicki...@gmail.com> added the comment:
> however, for x < 0.0 it is always worse That's quite surprising. Which platform? And can you give some example inputs and outputs? With a good math library, I'd expect `log1p(x)` to almost always be at least as accurate as `log(1 + x)`, and substantially _more_ accurate for small x (say abs(x) < 1e-5). If that's not happening, we may want to substitute our own implementation for the system implementation on some platforms (in the same was as we did for lgamma, erf, and friends). ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue37454> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com