x \cdot \log \left(\frac{x}{y}\right) - z\left(x \cdot \left(2 \cdot \log \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right) + x \cdot \log \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right) - zdouble f(double x, double y, double z) {
double r560029 = x;
double r560030 = y;
double r560031 = r560029 / r560030;
double r560032 = log(r560031);
double r560033 = r560029 * r560032;
double r560034 = z;
double r560035 = r560033 - r560034;
return r560035;
}
double f(double x, double y, double z) {
double r560036 = x;
double r560037 = 2.0;
double r560038 = cbrt(r560036);
double r560039 = y;
double r560040 = cbrt(r560039);
double r560041 = r560038 / r560040;
double r560042 = log(r560041);
double r560043 = r560037 * r560042;
double r560044 = r560036 * r560043;
double r560045 = r560036 * r560042;
double r560046 = r560044 + r560045;
double r560047 = z;
double r560048 = r560046 - r560047;
return r560048;
}




Bits error versus x




Bits error versus y




Bits error versus z
Results
| Original | 16.0 |
|---|---|
| Target | 8.0 |
| Herbie | 0.2 |
Initial program 16.0
rmApplied add-cube-cbrt16.0
Applied add-cube-cbrt16.0
Applied times-frac16.0
Applied log-prod3.8
Applied distribute-lft-in3.8
Simplified0.2
Final simplification0.2
herbie shell --seed 2020001
(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))