\frac{e^{x \cdot \log \left(\frac{x}{x + y}\right)}}{x}\begin{array}{l}
\mathbf{if}\;x \le -12624443392610811608382722060339625590780 \lor \neg \left(x \le 15.93322363967515542526598437689244747162\right):\\
\;\;\;\;\frac{\sqrt{e^{-y}}}{\frac{x}{\sqrt{e^{-y}}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{\left({\left(\frac{\sqrt[3]{x}}{\sqrt[3]{x + y}}\right)}^{x} \cdot {\left(\frac{\sqrt[3]{x}}{\sqrt[3]{x + y}}\right)}^{x}\right) \cdot {\left(\frac{\sqrt[3]{x}}{\sqrt[3]{x + y}}\right)}^{x}}{x}\\
\end{array}double f(double x, double y) {
double r503000 = x;
double r503001 = y;
double r503002 = r503000 + r503001;
double r503003 = r503000 / r503002;
double r503004 = log(r503003);
double r503005 = r503000 * r503004;
double r503006 = exp(r503005);
double r503007 = r503006 / r503000;
return r503007;
}
double f(double x, double y) {
double r503008 = x;
double r503009 = -1.2624443392610812e+40;
bool r503010 = r503008 <= r503009;
double r503011 = 15.933223639675155;
bool r503012 = r503008 <= r503011;
double r503013 = !r503012;
bool r503014 = r503010 || r503013;
double r503015 = y;
double r503016 = -r503015;
double r503017 = exp(r503016);
double r503018 = sqrt(r503017);
double r503019 = r503008 / r503018;
double r503020 = r503018 / r503019;
double r503021 = cbrt(r503008);
double r503022 = r503008 + r503015;
double r503023 = cbrt(r503022);
double r503024 = r503021 / r503023;
double r503025 = pow(r503024, r503008);
double r503026 = r503025 * r503025;
double r503027 = r503026 * r503025;
double r503028 = r503027 / r503008;
double r503029 = r503014 ? r503020 : r503028;
return r503029;
}




Bits error versus x




Bits error versus y
Results
| Original | 11.3 |
|---|---|
| Target | 7.5 |
| Herbie | 0.1 |
if x < -1.2624443392610812e+40 or 15.933223639675155 < x Initial program 11.0
Simplified11.0
Taylor expanded around inf 0.1
rmApplied add-sqr-sqrt0.1
Applied associate-/l*0.1
if -1.2624443392610812e+40 < x < 15.933223639675155Initial program 11.6
Simplified11.6
rmApplied add-cube-cbrt13.4
Applied add-cube-cbrt11.6
Applied times-frac11.6
Applied unpow-prod-down2.3
rmApplied times-frac2.3
Applied unpow-prod-down0.2
Final simplification0.1
herbie shell --seed 2019351 +o rules:numerics
(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))