x + \frac{e^{y \cdot \log \left(\frac{y}{z + y}\right)}}{y}x + \frac{{\left(e^{\sqrt[3]{y} \cdot \sqrt[3]{y}}\right)}^{\left(\sqrt[3]{y} \cdot \log \left(\frac{y}{z + y}\right)\right)}}{y}double f(double x, double y, double z) {
double r579304 = x;
double r579305 = y;
double r579306 = z;
double r579307 = r579306 + r579305;
double r579308 = r579305 / r579307;
double r579309 = log(r579308);
double r579310 = r579305 * r579309;
double r579311 = exp(r579310);
double r579312 = r579311 / r579305;
double r579313 = r579304 + r579312;
return r579313;
}
double f(double x, double y, double z) {
double r579314 = x;
double r579315 = y;
double r579316 = cbrt(r579315);
double r579317 = r579316 * r579316;
double r579318 = exp(r579317);
double r579319 = z;
double r579320 = r579319 + r579315;
double r579321 = r579315 / r579320;
double r579322 = log(r579321);
double r579323 = r579316 * r579322;
double r579324 = pow(r579318, r579323);
double r579325 = r579324 / r579315;
double r579326 = r579314 + r579325;
return r579326;
}




Bits error versus x




Bits error versus y




Bits error versus z
Results
| Original | 6.3 |
|---|---|
| Target | 1.2 |
| Herbie | 1.2 |
Initial program 6.3
rmApplied add-log-exp35.1
Applied exp-to-pow1.2
rmApplied add-cube-cbrt1.2
Applied exp-prod1.2
Applied pow-pow1.2
Final simplification1.2
herbie shell --seed 2020035
(FPCore (x y z)
:name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, G"
:precision binary64
:herbie-target
(if (< (/ y (+ z y)) 7.1154157597908e-315) (+ x (/ (exp (/ -1 z)) y)) (+ x (/ (exp (log (pow (/ y (+ y z)) y))) y)))
(+ x (/ (exp (* y (log (/ y (+ z y))))) y)))