\frac{x \cdot \frac{\sin y}{y}}{z}\frac{x}{\frac{z}{\frac{\sin y}{y}}}double f(double x, double y, double z) {
double r395685 = x;
double r395686 = y;
double r395687 = sin(r395686);
double r395688 = r395687 / r395686;
double r395689 = r395685 * r395688;
double r395690 = z;
double r395691 = r395689 / r395690;
return r395691;
}
double f(double x, double y, double z) {
double r395692 = x;
double r395693 = z;
double r395694 = y;
double r395695 = sin(r395694);
double r395696 = r395695 / r395694;
double r395697 = r395693 / r395696;
double r395698 = r395692 / r395697;
return r395698;
}




Bits error versus x




Bits error versus y




Bits error versus z
Results
| Original | 2.6 |
|---|---|
| Target | 0.3 |
| Herbie | 3.1 |
if z < -4.5702531938853563e-132 or 7.563073643537452e-27 < z Initial program 0.6
rmApplied clear-num0.6
rmApplied *-un-lft-identity0.6
Applied *-un-lft-identity0.6
Applied times-frac0.6
Applied add-cube-cbrt0.6
Applied times-frac0.6
Applied associate-*r*0.6
Simplified0.6
rmApplied associate-*r/0.6
Simplified0.6
if -4.5702531938853563e-132 < z < 7.563073643537452e-27Initial program 6.7
rmApplied associate-/l*0.2
Final simplification3.1
herbie shell --seed 2019303
(FPCore (x y z)
:name "Linear.Quaternion:$ctanh from linear-1.19.1.3"
:precision binary64
:herbie-target
(if (< z -4.21737202034271466e-29) (/ (* x (/ 1 (/ y (sin y)))) z) (if (< z 4.44670236911381103e64) (/ x (* z (/ y (sin y)))) (/ (* x (/ 1 (/ y (sin y)))) z)))
(/ (* x (/ (sin y) y)) z))