\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\begin{array}{l}
\mathbf{if}\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} = -\infty:\\
\;\;\;\;x\\
\mathbf{elif}\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \le -3.48512744200682378 \cdot 10^{-250}:\\
\;\;\;\;1 \cdot \frac{\mathsf{fma}\left(x, y, \left(\sqrt[3]{z} \cdot \sqrt[3]{z}\right) \cdot \left(\sqrt[3]{z} \cdot \left(t - a\right)\right)\right)}{\mathsf{fma}\left(b - y, z, y\right)}\\
\mathbf{elif}\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \le -0.0:\\
\;\;\;\;\frac{t}{b} - \frac{a}{b}\\
\mathbf{elif}\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \le 5.16890509567698123 \cdot 10^{307}:\\
\;\;\;\;\frac{1}{\left(y + z \cdot \left(b - y\right)\right) \cdot \frac{1}{x \cdot y + z \cdot \left(t - a\right)}}\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{b} - \frac{a}{b}\\
\end{array}double f(double x, double y, double z, double t, double a, double b) {
double r805391 = x;
double r805392 = y;
double r805393 = r805391 * r805392;
double r805394 = z;
double r805395 = t;
double r805396 = a;
double r805397 = r805395 - r805396;
double r805398 = r805394 * r805397;
double r805399 = r805393 + r805398;
double r805400 = b;
double r805401 = r805400 - r805392;
double r805402 = r805394 * r805401;
double r805403 = r805392 + r805402;
double r805404 = r805399 / r805403;
return r805404;
}
double f(double x, double y, double z, double t, double a, double b) {
double r805405 = x;
double r805406 = y;
double r805407 = r805405 * r805406;
double r805408 = z;
double r805409 = t;
double r805410 = a;
double r805411 = r805409 - r805410;
double r805412 = r805408 * r805411;
double r805413 = r805407 + r805412;
double r805414 = b;
double r805415 = r805414 - r805406;
double r805416 = r805408 * r805415;
double r805417 = r805406 + r805416;
double r805418 = r805413 / r805417;
double r805419 = -inf.0;
bool r805420 = r805418 <= r805419;
double r805421 = -3.485127442006824e-250;
bool r805422 = r805418 <= r805421;
double r805423 = 1.0;
double r805424 = cbrt(r805408);
double r805425 = r805424 * r805424;
double r805426 = r805424 * r805411;
double r805427 = r805425 * r805426;
double r805428 = fma(r805405, r805406, r805427);
double r805429 = fma(r805415, r805408, r805406);
double r805430 = r805428 / r805429;
double r805431 = r805423 * r805430;
double r805432 = -0.0;
bool r805433 = r805418 <= r805432;
double r805434 = r805409 / r805414;
double r805435 = r805410 / r805414;
double r805436 = r805434 - r805435;
double r805437 = 5.168905095676981e+307;
bool r805438 = r805418 <= r805437;
double r805439 = r805423 / r805413;
double r805440 = r805417 * r805439;
double r805441 = r805423 / r805440;
double r805442 = r805438 ? r805441 : r805436;
double r805443 = r805433 ? r805436 : r805442;
double r805444 = r805422 ? r805431 : r805443;
double r805445 = r805420 ? r805405 : r805444;
return r805445;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t




Bits error versus a




Bits error versus b
| Original | 23.5 |
|---|---|
| Target | 18.2 |
| Herbie | 15.5 |
if (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))) < -inf.0Initial program 64.0
rmApplied clear-num64.0
rmApplied div-inv64.0
Applied add-cube-cbrt64.0
Applied times-frac64.0
Simplified64.0
Simplified64.0
Taylor expanded around 0 35.9
if -inf.0 < (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))) < -3.485127442006824e-250Initial program 0.3
rmApplied clear-num0.4
rmApplied *-un-lft-identity0.4
Applied *-un-lft-identity0.4
Applied times-frac0.4
Applied add-cube-cbrt0.4
Applied times-frac0.4
Simplified0.4
Simplified0.3
rmApplied add-cube-cbrt1.0
Applied associate-*l*1.0
if -3.485127442006824e-250 < (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))) < -0.0 or 5.168905095676981e+307 < (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))) Initial program 57.2
rmApplied clear-num57.2
rmApplied div-inv57.2
Applied add-cube-cbrt57.2
Applied times-frac57.2
Simplified57.2
Simplified57.2
Taylor expanded around inf 38.1
if -0.0 < (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))) < 5.168905095676981e+307Initial program 0.3
rmApplied clear-num0.5
rmApplied div-inv0.7
Final simplification15.5
herbie shell --seed 2020065 +o rules:numerics
(FPCore (x y z t a b)
:name "Development.Shake.Progress:decay from shake-0.15.5"
:precision binary64
:herbie-target
(- (/ (+ (* z t) (* y x)) (+ y (* z (- b y)))) (/ a (+ (- b y) (/ y z))))
(/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))))