\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y}\left(x - \frac{y}{z \cdot 3}\right) + \frac{\frac{\sqrt[3]{t} \cdot \sqrt[3]{t}}{z}}{\sqrt[3]{y} \cdot \sqrt[3]{y}} \cdot \frac{\frac{\sqrt[3]{t}}{3}}{\sqrt[3]{y}}(FPCore (x y z t) :precision binary64 (+ (- x (/ y (* z 3.0))) (/ t (* (* z 3.0) y))))
(FPCore (x y z t) :precision binary64 (+ (- x (/ y (* z 3.0))) (* (/ (/ (* (cbrt t) (cbrt t)) z) (* (cbrt y) (cbrt y))) (/ (/ (cbrt t) 3.0) (cbrt y)))))
double code(double x, double y, double z, double t) {
return (x - (y / (z * 3.0))) + (t / ((z * 3.0) * y));
}
double code(double x, double y, double z, double t) {
return (x - (y / (z * 3.0))) + ((((cbrt(t) * cbrt(t)) / z) / (cbrt(y) * cbrt(y))) * ((cbrt(t) / 3.0) / cbrt(y)));
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 3.7 |
|---|---|
| Target | 1.7 |
| Herbie | 0.9 |
Initial program 3.7
rmApplied associate-/r*_binary64_177541.7
rmApplied add-cube-cbrt_binary64_178452.0
Applied add-cube-cbrt_binary64_178452.0
Applied times-frac_binary64_178162.0
Applied times-frac_binary64_178160.9
Final simplification0.9
herbie shell --seed 2021019
(FPCore (x y z t)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, H"
:precision binary64
:herbie-target
(+ (- x (/ y (* z 3.0))) (/ (/ t (* z 3.0)) y))
(+ (- x (/ y (* z 3.0))) (/ t (* (* z 3.0) y))))