x \cdot \left(1 - y \cdot z\right)
\begin{array}{l}
\mathbf{if}\;x \leq -1.5833889410078922 \cdot 10^{-22} \lor \neg \left(x \leq 1.5506037414681654 \cdot 10^{+35}\right):\\
\;\;\;\;x \cdot \left(1 - y \cdot z\right)\\
\mathbf{else}:\\
\;\;\;\;x - y \cdot \left(x \cdot z\right)\\
\end{array}
(FPCore (x y z) :precision binary64 (* x (- 1.0 (* y z))))
(FPCore (x y z) :precision binary64 (if (or (<= x -1.5833889410078922e-22) (not (<= x 1.5506037414681654e+35))) (* x (- 1.0 (* y z))) (- x (* y (* x z)))))
double code(double x, double y, double z) {
return x * (1.0 - (y * z));
}
double code(double x, double y, double z) {
double tmp;
if ((x <= -1.5833889410078922e-22) || !(x <= 1.5506037414681654e+35)) {
tmp = x * (1.0 - (y * z));
} else {
tmp = x - (y * (x * z));
}
return tmp;
}



Bits error versus x



Bits error versus y



Bits error versus z
Results
if x < -1.5833889410078922e-22 or 1.5506037414681654e35 < x Initial program 0.1
if -1.5833889410078922e-22 < x < 1.5506037414681654e35Initial program 4.9
Taylor expanded in y around 0 2.4
Final simplification1.3
herbie shell --seed 2022068
(FPCore (x y z)
:name "Data.Colour.RGBSpace.HSV:hsv from colour-2.3.3, I"
:precision binary64
(* x (- 1.0 (* y z))))