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 r474215 = x;
double r474216 = y;
double r474217 = r474215 / r474216;
double r474218 = log(r474217);
double r474219 = r474215 * r474218;
double r474220 = z;
double r474221 = r474219 - r474220;
return r474221;
}
double f(double x, double y, double z) {
double r474222 = x;
double r474223 = 2.0;
double r474224 = cbrt(r474222);
double r474225 = y;
double r474226 = cbrt(r474225);
double r474227 = r474224 / r474226;
double r474228 = log(r474227);
double r474229 = r474223 * r474228;
double r474230 = r474222 * r474229;
double r474231 = r474222 * r474228;
double r474232 = r474230 + r474231;
double r474233 = z;
double r474234 = r474232 - r474233;
return r474234;
}




Bits error versus x




Bits error versus y




Bits error versus z
Results
| Original | 15.1 |
|---|---|
| Target | 7.7 |
| 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
Applied distribute-lft-in3.6
Simplified0.2
Final simplification0.2
herbie shell --seed 2020060
(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))