\frac{e^{x \cdot \log \left(\frac{x}{x + y}\right)}}{x}\begin{array}{l}
\mathbf{if}\;x \le -10.11942408653544234198307094629853963852 \lor \neg \left(x \le 0.1204014281115151213663594376157561782748\right):\\
\;\;\;\;\frac{e^{-y}}{x}\\
\mathbf{else}:\\
\;\;\;\;\frac{{\left(\frac{1}{\sqrt[3]{x + y} \cdot \sqrt[3]{x + y}}\right)}^{x} \cdot \left({\left(\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{\sqrt[3]{x + y}} \cdot \sqrt[3]{\sqrt[3]{x + y}}}\right)}^{x} \cdot {\left(\frac{\sqrt[3]{x}}{\sqrt[3]{\sqrt[3]{x + y}}}\right)}^{x}\right)}{x}\\
\end{array}double f(double x, double y) {
double r292140 = x;
double r292141 = y;
double r292142 = r292140 + r292141;
double r292143 = r292140 / r292142;
double r292144 = log(r292143);
double r292145 = r292140 * r292144;
double r292146 = exp(r292145);
double r292147 = r292146 / r292140;
return r292147;
}
double f(double x, double y) {
double r292148 = x;
double r292149 = -10.119424086535442;
bool r292150 = r292148 <= r292149;
double r292151 = 0.12040142811151512;
bool r292152 = r292148 <= r292151;
double r292153 = !r292152;
bool r292154 = r292150 || r292153;
double r292155 = y;
double r292156 = -r292155;
double r292157 = exp(r292156);
double r292158 = r292157 / r292148;
double r292159 = 1.0;
double r292160 = r292148 + r292155;
double r292161 = cbrt(r292160);
double r292162 = r292161 * r292161;
double r292163 = r292159 / r292162;
double r292164 = pow(r292163, r292148);
double r292165 = cbrt(r292148);
double r292166 = r292165 * r292165;
double r292167 = cbrt(r292161);
double r292168 = r292167 * r292167;
double r292169 = r292166 / r292168;
double r292170 = pow(r292169, r292148);
double r292171 = r292165 / r292167;
double r292172 = pow(r292171, r292148);
double r292173 = r292170 * r292172;
double r292174 = r292164 * r292173;
double r292175 = r292174 / r292148;
double r292176 = r292154 ? r292158 : r292175;
return r292176;
}




Bits error versus x




Bits error versus y
Results
| Original | 11.2 |
|---|---|
| Target | 8.2 |
| Herbie | 0.0 |
if x < -10.119424086535442 or 0.12040142811151512 < x Initial program 10.9
Simplified10.9
Taylor expanded around inf 0.1
if -10.119424086535442 < x < 0.12040142811151512Initial program 11.6
Simplified11.6
rmApplied add-cube-cbrt11.6
Applied *-un-lft-identity11.6
Applied times-frac11.6
Applied unpow-prod-down3.3
rmApplied add-cube-cbrt3.3
Applied add-cube-cbrt3.3
Applied times-frac3.3
Applied unpow-prod-down0.0
Final simplification0.0
herbie shell --seed 2019323 +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))