\frac{e^{x \cdot \log \left(\frac{x}{x + y}\right)}}{x}\begin{array}{l}
\mathbf{if}\;x \le -13.81174464235228427355650637764483690262 \lor \neg \left(x \le 0.1204014281115151213663594376157561782748\right):\\
\;\;\;\;\frac{e^{-y}}{x}\\
\mathbf{else}:\\
\;\;\;\;{\left(\frac{1}{\sqrt[3]{x + y} \cdot \sqrt[3]{x + y}}\right)}^{x} \cdot \frac{{\left(\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{\sqrt[3]{x + y} \cdot \sqrt[3]{x + y}}}\right)}^{x} \cdot {\left(\frac{\sqrt[3]{x}}{\sqrt[3]{\sqrt[3]{x + y}}}\right)}^{x}}{x}\\
\end{array}double f(double x, double y) {
double r246993 = x;
double r246994 = y;
double r246995 = r246993 + r246994;
double r246996 = r246993 / r246995;
double r246997 = log(r246996);
double r246998 = r246993 * r246997;
double r246999 = exp(r246998);
double r247000 = r246999 / r246993;
return r247000;
}
double f(double x, double y) {
double r247001 = x;
double r247002 = -13.811744642352284;
bool r247003 = r247001 <= r247002;
double r247004 = 0.12040142811151512;
bool r247005 = r247001 <= r247004;
double r247006 = !r247005;
bool r247007 = r247003 || r247006;
double r247008 = y;
double r247009 = -r247008;
double r247010 = exp(r247009);
double r247011 = r247010 / r247001;
double r247012 = 1.0;
double r247013 = r247001 + r247008;
double r247014 = cbrt(r247013);
double r247015 = r247014 * r247014;
double r247016 = r247012 / r247015;
double r247017 = pow(r247016, r247001);
double r247018 = cbrt(r247001);
double r247019 = r247018 * r247018;
double r247020 = cbrt(r247015);
double r247021 = r247019 / r247020;
double r247022 = pow(r247021, r247001);
double r247023 = cbrt(r247014);
double r247024 = r247018 / r247023;
double r247025 = pow(r247024, r247001);
double r247026 = r247022 * r247025;
double r247027 = r247026 / r247001;
double r247028 = r247017 * r247027;
double r247029 = r247007 ? r247011 : r247028;
return r247029;
}




Bits error versus x




Bits error versus y
Results
| Original | 11.2 |
|---|---|
| Target | 8.2 |
| Herbie | 0.1 |
if x < -13.811744642352284 or 0.12040142811151512 < x Initial program 10.9
Simplified10.9
Taylor expanded around inf 0.1
if -13.811744642352284 < x < 0.12040142811151512Initial program 11.6
Simplified11.6
rmApplied *-un-lft-identity11.6
Applied add-cube-cbrt11.6
Applied *-un-lft-identity11.6
Applied times-frac11.6
Applied unpow-prod-down3.3
Applied times-frac3.3
Simplified3.3
rmApplied add-cube-cbrt3.3
Applied cbrt-prod3.3
Applied add-cube-cbrt3.3
Applied times-frac3.3
Applied unpow-prod-down0.0
Final simplification0.1
herbie shell --seed 2019323
(FPCore (x y)
:name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, F"
:precision binary64
:herbie-target
(if (< y -3.7311844206647956e+94) (/ (exp (/ -1 y)) x) (if (< y 2.817959242728288e+37) (/ (pow (/ x (+ y x)) x) x) (if (< y 2.347387415166998e+178) (log (exp (/ (pow (/ x (+ y x)) x) x))) (/ (exp (/ -1 y)) x))))
(/ (exp (* x (log (/ x (+ x y))))) x))