Y
Hacker News
new
|
ask
|
show
|
jobs
by
Sharlin
848 days ago
It’s not (or shouldn’t be), it’s simply a result of math, as the article explains in length.
1 comments
lifthrasiir
848 days ago
Many libm implementations don't have an accurate `log` or `exp` routine, so there does exist a risk. (Of course, it's also true that many of them also special-case `log(x) ~= x - 1` and `exp(x) ~= x + 1` for small enough `x`.)
link
planede
848 days ago
The math hinges on that there is the same error for exp(x) at both places. So as long as exp(x) is deterministic then this should be alright.
link
adgjlsfhk1
848 days ago
I don't know of any libm that have log or exp sufficiently inaccurate for this to break. Do you?
link
lifthrasiir
848 days ago
Indeed, any well-known enough libm wouldn't do that. But I can imagine some less-known libms with wild error bounds.
link