x \cdot \frac{\frac{y}{z} \cdot t}{t}\begin{array}{l}
\mathbf{if}\;\frac{y}{z} \le -1.35613759911877656476275151503320492094 \cdot 10^{280}:\\
\;\;\;\;y \cdot \frac{x}{z}\\
\mathbf{elif}\;\frac{y}{z} \le -8.828782166850766038005620975563547450989 \cdot 10^{-175}:\\
\;\;\;\;\frac{y}{z} \cdot x\\
\mathbf{elif}\;\frac{y}{z} \le 6.939139322974091469623957424428358865557 \cdot 10^{-194}:\\
\;\;\;\;\frac{y \cdot x}{z}\\
\mathbf{elif}\;\frac{y}{z} \le 2.459953299034684076090573649758520228965 \cdot 10^{86}:\\
\;\;\;\;\frac{y}{z} \cdot x\\
\mathbf{else}:\\
\;\;\;\;y \cdot \frac{x}{z}\\
\end{array}double f(double x, double y, double z, double t) {
double r416518 = x;
double r416519 = y;
double r416520 = z;
double r416521 = r416519 / r416520;
double r416522 = t;
double r416523 = r416521 * r416522;
double r416524 = r416523 / r416522;
double r416525 = r416518 * r416524;
return r416525;
}
double f(double x, double y, double z, double __attribute__((unused)) t) {
double r416526 = y;
double r416527 = z;
double r416528 = r416526 / r416527;
double r416529 = -1.3561375991187766e+280;
bool r416530 = r416528 <= r416529;
double r416531 = x;
double r416532 = r416531 / r416527;
double r416533 = r416526 * r416532;
double r416534 = -8.828782166850766e-175;
bool r416535 = r416528 <= r416534;
double r416536 = r416528 * r416531;
double r416537 = 6.939139322974091e-194;
bool r416538 = r416528 <= r416537;
double r416539 = r416526 * r416531;
double r416540 = r416539 / r416527;
double r416541 = 2.459953299034684e+86;
bool r416542 = r416528 <= r416541;
double r416543 = r416542 ? r416536 : r416533;
double r416544 = r416538 ? r416540 : r416543;
double r416545 = r416535 ? r416536 : r416544;
double r416546 = r416530 ? r416533 : r416545;
return r416546;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 15.2 |
|---|---|
| Target | 1.5 |
| Herbie | 1.0 |
if (/ y z) < -1.3561375991187766e+280 or 2.459953299034684e+86 < (/ y z) Initial program 34.5
Simplified20.9
rmApplied div-inv21.0
Applied associate-*l*3.9
Simplified3.8
if -1.3561375991187766e+280 < (/ y z) < -8.828782166850766e-175 or 6.939139322974091e-194 < (/ y z) < 2.459953299034684e+86Initial program 8.3
Simplified0.2
if -8.828782166850766e-175 < (/ y z) < 6.939139322974091e-194Initial program 17.1
Simplified9.7
rmApplied add-cube-cbrt10.0
Applied *-un-lft-identity10.0
Applied times-frac10.0
Applied associate-*l*2.7
rmApplied associate-*l/1.3
Applied frac-times1.3
Simplified1.3
Simplified0.8
Final simplification1.0
herbie shell --seed 2019326
(FPCore (x y z t)
:name "Graphics.Rendering.Chart.Backend.Diagrams:calcFontMetrics from Chart-diagrams-1.5.1, B"
:precision binary64
:herbie-target
(if (< (/ (* (/ y z) t) t) -1.20672205123045e+245) (/ y (/ z x)) (if (< (/ (* (/ y z) t) t) -5.907522236933906e-275) (* x (/ y z)) (if (< (/ (* (/ y z) t) t) 5.658954423153415e-65) (/ y (/ z x)) (if (< (/ (* (/ y z) t) t) 2.0087180502407133e+217) (* x (/ y z)) (/ (* y x) z)))))
(* x (/ (* (/ y z) t) t)))