x \cdot \log \left(\frac{x}{y}\right) - z\left(x \cdot \left(\log \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right) + \log \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right) + \log \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right) \cdot x\right) - zdouble f(double x, double y, double z) {
double r14760036 = x;
double r14760037 = y;
double r14760038 = r14760036 / r14760037;
double r14760039 = log(r14760038);
double r14760040 = r14760036 * r14760039;
double r14760041 = z;
double r14760042 = r14760040 - r14760041;
return r14760042;
}
double f(double x, double y, double z) {
double r14760043 = x;
double r14760044 = cbrt(r14760043);
double r14760045 = y;
double r14760046 = cbrt(r14760045);
double r14760047 = r14760044 / r14760046;
double r14760048 = log(r14760047);
double r14760049 = r14760048 + r14760048;
double r14760050 = r14760043 * r14760049;
double r14760051 = r14760048 * r14760043;
double r14760052 = r14760050 + r14760051;
double r14760053 = z;
double r14760054 = r14760052 - r14760053;
return r14760054;
}




Bits error versus x




Bits error versus y




Bits error versus z
Results
| Original | 14.6 |
|---|---|
| Target | 7.3 |
| Herbie | 0.2 |
Initial program 14.6
rmApplied add-cube-cbrt14.6
Applied add-cube-cbrt14.6
Applied times-frac14.6
Applied log-prod3.4
Applied distribute-rgt-in3.4
Simplified0.2
Final simplification0.2
herbie shell --seed 2019162 +o rules:numerics
(FPCore (x y z)
:name "Numeric.SpecFunctions.Extra:bd0 from math-functions-0.1.5.2"
:herbie-target
(if (< y 7.595077799083773e-308) (- (* x (log (/ x y))) z) (- (* x (- (log x) (log y))) z))
(- (* x (log (/ x y))) z))