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 r356380 = x;
double r356381 = y;
double r356382 = r356380 / r356381;
double r356383 = log(r356382);
double r356384 = r356380 * r356383;
double r356385 = z;
double r356386 = r356384 - r356385;
return r356386;
}
double f(double x, double y, double z) {
double r356387 = x;
double r356388 = 2.0;
double r356389 = cbrt(r356387);
double r356390 = y;
double r356391 = cbrt(r356390);
double r356392 = r356389 / r356391;
double r356393 = log(r356392);
double r356394 = r356388 * r356393;
double r356395 = r356394 + r356393;
double r356396 = r356387 * r356395;
double r356397 = z;
double r356398 = r356396 - r356397;
return r356398;
}




Bits error versus x




Bits error versus y




Bits error versus z
Results
| Original | 15.0 |
|---|---|
| Target | 7.6 |
| Herbie | 0.2 |
Initial program 15.0
rmApplied add-cube-cbrt15.0
Applied add-cube-cbrt15.0
Applied times-frac15.0
Applied log-prod3.4
Simplified0.2
Final simplification0.2
herbie shell --seed 2019325
(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))