\cosh x \cdot \frac{\sin y}{y}\cosh x \cdot \mathsf{expm1}\left(\mathsf{log1p}\left(\frac{\sin y}{y}\right)\right)double f(double x, double y) {
double r477460 = x;
double r477461 = cosh(r477460);
double r477462 = y;
double r477463 = sin(r477462);
double r477464 = r477463 / r477462;
double r477465 = r477461 * r477464;
return r477465;
}
double f(double x, double y) {
double r477466 = x;
double r477467 = cosh(r477466);
double r477468 = y;
double r477469 = sin(r477468);
double r477470 = r477469 / r477468;
double r477471 = log1p(r477470);
double r477472 = expm1(r477471);
double r477473 = r477467 * r477472;
return r477473;
}




Bits error versus x




Bits error versus y
Results
| Original | 0.1 |
|---|---|
| Target | 0.1 |
| Herbie | 0.1 |
Initial program 0.1
rmApplied expm1-log1p-u0.1
Final simplification0.1
herbie shell --seed 2020057 +o rules:numerics
(FPCore (x y)
:name "Linear.Quaternion:$csinh from linear-1.19.1.3"
:precision binary64
:herbie-target
(/ (* (cosh x) (sin y)) y)
(* (cosh x) (/ (sin y) y)))