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 r521627 = x;
double r521628 = y;
double r521629 = r521627 / r521628;
double r521630 = log(r521629);
double r521631 = r521627 * r521630;
double r521632 = z;
double r521633 = r521631 - r521632;
return r521633;
}
double f(double x, double y, double z) {
double r521634 = x;
double r521635 = 2.0;
double r521636 = cbrt(r521634);
double r521637 = y;
double r521638 = cbrt(r521637);
double r521639 = r521636 / r521638;
double r521640 = log(r521639);
double r521641 = r521635 * r521640;
double r521642 = r521634 * r521641;
double r521643 = r521634 * r521640;
double r521644 = r521642 + r521643;
double r521645 = z;
double r521646 = r521644 - r521645;
return r521646;
}




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))