\left(x + y\right) - \frac{\left(z - t\right) \cdot y}{a - t}\begin{array}{l}
\mathbf{if}\;a \le -9.4689010464121415508002148715762489261 \cdot 10^{-153}:\\
\;\;\;\;\mathsf{fma}\left(\left(t - z\right) \cdot \frac{1}{a - t}, y, x + y\right)\\
\mathbf{elif}\;a \le 1.019767468767238742050870882472042955611 \cdot 10^{-151}:\\
\;\;\;\;\mathsf{fma}\left(\frac{z}{t}, y, x\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{y}{\sqrt[3]{a - t} \cdot \sqrt[3]{a - t}} \cdot \frac{t - z}{\sqrt[3]{a - t}} + \left(x + y\right)\\
\end{array}double f(double x, double y, double z, double t, double a) {
double r372253 = x;
double r372254 = y;
double r372255 = r372253 + r372254;
double r372256 = z;
double r372257 = t;
double r372258 = r372256 - r372257;
double r372259 = r372258 * r372254;
double r372260 = a;
double r372261 = r372260 - r372257;
double r372262 = r372259 / r372261;
double r372263 = r372255 - r372262;
return r372263;
}
double f(double x, double y, double z, double t, double a) {
double r372264 = a;
double r372265 = -9.468901046412142e-153;
bool r372266 = r372264 <= r372265;
double r372267 = t;
double r372268 = z;
double r372269 = r372267 - r372268;
double r372270 = 1.0;
double r372271 = r372264 - r372267;
double r372272 = r372270 / r372271;
double r372273 = r372269 * r372272;
double r372274 = y;
double r372275 = x;
double r372276 = r372275 + r372274;
double r372277 = fma(r372273, r372274, r372276);
double r372278 = 1.0197674687672387e-151;
bool r372279 = r372264 <= r372278;
double r372280 = r372268 / r372267;
double r372281 = fma(r372280, r372274, r372275);
double r372282 = cbrt(r372271);
double r372283 = r372282 * r372282;
double r372284 = r372274 / r372283;
double r372285 = r372269 / r372282;
double r372286 = r372284 * r372285;
double r372287 = r372286 + r372276;
double r372288 = r372279 ? r372281 : r372287;
double r372289 = r372266 ? r372277 : r372288;
return r372289;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t




Bits error versus a
| Original | 16.9 |
|---|---|
| Target | 8.5 |
| Herbie | 9.1 |
if a < -9.468901046412142e-153Initial program 15.4
Simplified8.5
rmApplied div-inv8.5
if -9.468901046412142e-153 < a < 1.0197674687672387e-151Initial program 21.6
Simplified21.1
Taylor expanded around inf 9.2
Simplified9.1
if 1.0197674687672387e-151 < a Initial program 15.6
Simplified9.2
rmApplied div-inv9.2
rmApplied add-cube-cbrt9.3
Applied add-cube-cbrt9.3
Applied times-frac9.3
Simplified9.3
Simplified9.3
rmApplied fma-udef9.3
Simplified9.2
rmApplied add-cube-cbrt9.3
Applied *-un-lft-identity9.3
Applied times-frac9.3
Applied associate-*r*9.7
Simplified9.7
Final simplification9.1
herbie shell --seed 2019322 +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))))