\left(x + y\right) - \frac{\left(z - t\right) \cdot y}{a - t}\begin{array}{l}
\mathbf{if}\;t \le -1.4785650511945879 \cdot 10^{119} \lor \neg \left(t \le 5.62287539718969527 \cdot 10^{93}\right):\\
\;\;\;\;\mathsf{fma}\left(\frac{z}{t}, y, x\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{\sqrt[3]{y} \cdot \sqrt[3]{y}}{\sqrt[3]{a - t}} \cdot \left(\frac{\sqrt[3]{y}}{\sqrt[3]{a - t}} \cdot \frac{t - z}{\sqrt[3]{a - t}}\right) + \left(x + y\right)\\
\end{array}double f(double x, double y, double z, double t, double a) {
double r759866 = x;
double r759867 = y;
double r759868 = r759866 + r759867;
double r759869 = z;
double r759870 = t;
double r759871 = r759869 - r759870;
double r759872 = r759871 * r759867;
double r759873 = a;
double r759874 = r759873 - r759870;
double r759875 = r759872 / r759874;
double r759876 = r759868 - r759875;
return r759876;
}
double f(double x, double y, double z, double t, double a) {
double r759877 = t;
double r759878 = -1.4785650511945879e+119;
bool r759879 = r759877 <= r759878;
double r759880 = 5.622875397189695e+93;
bool r759881 = r759877 <= r759880;
double r759882 = !r759881;
bool r759883 = r759879 || r759882;
double r759884 = z;
double r759885 = r759884 / r759877;
double r759886 = y;
double r759887 = x;
double r759888 = fma(r759885, r759886, r759887);
double r759889 = cbrt(r759886);
double r759890 = r759889 * r759889;
double r759891 = a;
double r759892 = r759891 - r759877;
double r759893 = cbrt(r759892);
double r759894 = r759890 / r759893;
double r759895 = r759889 / r759893;
double r759896 = r759877 - r759884;
double r759897 = r759896 / r759893;
double r759898 = r759895 * r759897;
double r759899 = r759894 * r759898;
double r759900 = r759887 + r759886;
double r759901 = r759899 + r759900;
double r759902 = r759883 ? r759888 : r759901;
return r759902;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t




Bits error versus a
| Original | 16.5 |
|---|---|
| Target | 8.6 |
| Herbie | 8.1 |
if t < -1.4785650511945879e+119 or 5.622875397189695e+93 < t Initial program 30.3
Simplified20.9
Taylor expanded around inf 17.5
Simplified12.3
if -1.4785650511945879e+119 < t < 5.622875397189695e+93Initial program 8.8
Simplified6.7
rmApplied add-cube-cbrt6.8
Applied associate-/l*6.8
rmApplied fma-udef6.8
Simplified6.7
rmApplied add-cube-cbrt6.9
Applied *-un-lft-identity6.9
Applied times-frac6.9
Applied associate-*r*6.7
Simplified6.7
rmApplied add-cube-cbrt6.7
Applied times-frac6.7
Applied associate-*l*5.7
Final simplification8.1
herbie shell --seed 2020042 +o rules:numerics
(FPCore (x y z t a)
:name "Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisTick from plot-0.2.3.4, B"
:precision binary64
:herbie-target
(if (< (- (+ x y) (/ (* (- z t) y) (- a t))) -1.3664970889390727e-07) (- (+ y x) (* (* (- z t) (/ 1 (- a t))) y)) (if (< (- (+ x y) (/ (* (- z t) y) (- a t))) 1.4754293444577233e-239) (/ (- (* y (- a z)) (* x t)) (- a t)) (- (+ y x) (* (* (- z t) (/ 1 (- a t))) y))))
(- (+ x y) (/ (* (- z t) y) (- a t))))