Boost logo

Boost :

From: John Maddock (john_at_[hidden])
Date: 2006-09-26 06:03:01


If you have a couple of minutes, can you explain why you multiply the
absolute error by cosh(x) in the asinh tests:

T y = sinh(x);
T z = asinh(y);
T absolute_error = abs(z-x);
T relative_error = absolute_error*cosh(x); // Why????
T scaled_error = relative_error/epsilon;

Without that and using the usual definition of relative error in this case:


Then I see an error of 0.5eps for the case that fails on Linux/AMD64.

However with the multiplication by cosh(x) in place (which is a largish
value for some of the test inputs) I believe the test will only pass if the
error is zero, which is not the case on Linux AMD64.

BTW, I'm not familiar with the term "scaled error", I don't see anything
useful with a web search either?



Boost list run by bdawes at, gregod at, cpdaniel at, john at