\frac{e^{x \cdot \log \left(\frac{x}{x + y}\right)}}{x}\begin{array}{l}
\mathbf{if}\;x \le \frac{-2490835364172071}{1048576} \lor \neg \left(x \le \frac{7990709749320737}{2251799813685248}\right):\\
\;\;\;\;\frac{1}{e^{y} \cdot x}\\
\mathbf{else}:\\
\;\;\;\;\frac{e^{\left(2 \cdot \log \left(\frac{\sqrt[3]{x}}{\sqrt[3]{x + y}}\right)\right) \cdot x} \cdot {\left(\frac{\sqrt[3]{x}}{\sqrt[3]{x + y}}\right)}^{x}}{x}\\
\end{array}double f(double x, double y) {
double r419314 = x;
double r419315 = y;
double r419316 = r419314 + r419315;
double r419317 = r419314 / r419316;
double r419318 = log(r419317);
double r419319 = r419314 * r419318;
double r419320 = exp(r419319);
double r419321 = r419320 / r419314;
return r419321;
}
double f(double x, double y) {
double r419322 = x;
double r419323 = -2490835364172071.0;
double r419324 = 1048576.0;
double r419325 = r419323 / r419324;
bool r419326 = r419322 <= r419325;
double r419327 = 7990709749320737.0;
double r419328 = 2251799813685248.0;
double r419329 = r419327 / r419328;
bool r419330 = r419322 <= r419329;
double r419331 = !r419330;
bool r419332 = r419326 || r419331;
double r419333 = 1.0;
double r419334 = y;
double r419335 = exp(r419334);
double r419336 = r419335 * r419322;
double r419337 = r419333 / r419336;
double r419338 = 2.0;
double r419339 = cbrt(r419322);
double r419340 = r419322 + r419334;
double r419341 = cbrt(r419340);
double r419342 = r419339 / r419341;
double r419343 = log(r419342);
double r419344 = r419338 * r419343;
double r419345 = r419344 * r419322;
double r419346 = exp(r419345);
double r419347 = pow(r419342, r419322);
double r419348 = r419346 * r419347;
double r419349 = r419348 / r419322;
double r419350 = r419332 ? r419337 : r419349;
return r419350;
}




Bits error versus x




Bits error versus y
Results
| Original | 11.0 |
|---|---|
| Target | 8.0 |
| Herbie | 0.0 |
if x < -2375445713.2073126 or 3.548587978717038 < x Initial program 10.6
Simplified10.6
Taylor expanded around inf 0.0
Simplified0.0
rmApplied clear-num0.0
Simplified0.0
if -2375445713.2073126 < x < 3.548587978717038Initial program 11.5
Simplified11.5
rmApplied add-cube-cbrt11.6
Applied add-cube-cbrt11.5
Applied times-frac11.5
Applied unpow-prod-down2.6
rmApplied add-exp-log33.7
Applied add-exp-log33.7
Applied prod-exp33.7
Applied add-exp-log33.7
Applied add-exp-log33.7
Applied prod-exp33.7
Applied div-exp33.7
Applied pow-exp32.6
Simplified0.0
Final simplification0.0
herbie shell --seed 2019304
(FPCore (x y)
:name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, F"
:precision binary64
:herbie-target
(if (< y -3.73118442066479561e94) (/ (exp (/ -1 y)) x) (if (< y 2.81795924272828789e37) (/ (pow (/ x (+ y x)) x) x) (if (< y 2.347387415166998e178) (log (exp (/ (pow (/ x (+ y x)) x) x))) (/ (exp (/ -1 y)) x))))
(/ (exp (* x (log (/ x (+ x y))))) x))