x \cdot \frac{\frac{y}{z} \cdot t}{t}\frac{\frac{\sqrt[3]{y} \cdot \sqrt[3]{y}}{\sqrt[3]{z} \cdot \sqrt[3]{z}}}{\frac{1}{x}} \cdot \frac{\sqrt[3]{y}}{\sqrt[3]{z}}(FPCore (x y z t) :precision binary64 (* x (/ (* (/ y z) t) t)))
(FPCore (x y z t) :precision binary64 (* (/ (/ (* (cbrt y) (cbrt y)) (* (cbrt z) (cbrt z))) (/ 1.0 x)) (/ (cbrt y) (cbrt z))))
double code(double x, double y, double z, double t) {
return x * (((y / z) * t) / t);
}
double code(double x, double y, double z, double t) {
return (((cbrt(y) * cbrt(y)) / (cbrt(z) * cbrt(z))) / (1.0 / x)) * (cbrt(y) / cbrt(z));
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 14.7 |
|---|---|
| Target | 1.5 |
| Herbie | 2.0 |
Initial program 14.7
Simplified6.3
rmApplied add-cube-cbrt_binary64_117077.1
Applied add-cube-cbrt_binary64_117077.3
Applied times-frac_binary64_116787.3
Applied associate-*r*_binary64_116122.0
Simplified4.5
rmApplied div-inv_binary64_116694.5
Applied associate-/r*_binary64_116162.0
Final simplification2.0
herbie shell --seed 2021176
(FPCore (x y z t)
:name "Graphics.Rendering.Chart.Backend.Diagrams:calcFontMetrics from Chart-diagrams-1.5.1, B"
:precision binary64
:herbie-target
(if (< (/ (* (/ y z) t) t) -1.20672205123045e+245) (/ y (/ z x)) (if (< (/ (* (/ y z) t) t) -5.907522236933906e-275) (* x (/ y z)) (if (< (/ (* (/ y z) t) t) 5.658954423153415e-65) (/ y (/ z x)) (if (< (/ (* (/ y z) t) t) 2.0087180502407133e+217) (* x (/ y z)) (/ (* y x) z)))))
(* x (/ (* (/ y z) t) t)))