x \cdot \log \left(\frac{x}{y}\right) - zx \cdot \left(2 \cdot \log \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right) + \log \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right) - zdouble f(double x, double y, double z) {
double r617233 = x;
double r617234 = y;
double r617235 = r617233 / r617234;
double r617236 = log(r617235);
double r617237 = r617233 * r617236;
double r617238 = z;
double r617239 = r617237 - r617238;
return r617239;
}
double f(double x, double y, double z) {
double r617240 = x;
double r617241 = 2.0;
double r617242 = cbrt(r617240);
double r617243 = y;
double r617244 = cbrt(r617243);
double r617245 = r617242 / r617244;
double r617246 = log(r617245);
double r617247 = r617241 * r617246;
double r617248 = r617247 + r617246;
double r617249 = r617240 * r617248;
double r617250 = z;
double r617251 = r617249 - r617250;
return r617251;
}




Bits error versus x




Bits error versus y




Bits error versus z
Results
| Original | 15.1 |
|---|---|
| Target | 7.9 |
| Herbie | 0.2 |
Initial program 15.1
rmApplied add-cube-cbrt15.1
Applied add-cube-cbrt15.1
Applied times-frac15.1
Applied log-prod3.6
Simplified0.2
Final simplification0.2
herbie shell --seed 2019362
(FPCore (x y z)
:name "Numeric.SpecFunctions.Extra:bd0 from math-functions-0.1.5.2"
:precision binary64
:herbie-target
(if (< y 7.595077799083773e-308) (- (* x (log (/ x y))) z) (- (* x (- (log x) (log y))) z))
(- (* x (log (/ x y))) z))