x + \left(y - z\right) \cdot \frac{t - x}{a - z}\begin{array}{l}
\mathbf{if}\;x + \left(y - z\right) \cdot \frac{t - x}{a - z} \leq -4.950225063189642 \cdot 10^{-287}:\\
\;\;\;\;x + \left(\left(y - z\right) \cdot \frac{\sqrt[3]{t - x} \cdot \sqrt[3]{t - x}}{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}\right) \cdot \frac{\sqrt[3]{t - x}}{\sqrt[3]{a - z}}\\
\mathbf{elif}\;x + \left(y - z\right) \cdot \frac{t - x}{a - z} \leq 1.595159633781633 \cdot 10^{-230}:\\
\;\;\;\;t + y \cdot \left(\frac{x}{z} - \frac{t}{z}\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(\left(y - z\right) \cdot \frac{\sqrt[3]{t - x} \cdot \sqrt[3]{t - x}}{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}\right) \cdot \frac{\sqrt[3]{t - x}}{\sqrt[3]{a - z}}\\
\end{array}(FPCore (x y z t a) :precision binary64 (+ x (* (- y z) (/ (- t x) (- a z)))))
(FPCore (x y z t a)
:precision binary64
(if (<= (+ x (* (- y z) (/ (- t x) (- a z)))) -4.950225063189642e-287)
(+
x
(*
(*
(- y z)
(/ (* (cbrt (- t x)) (cbrt (- t x))) (* (cbrt (- a z)) (cbrt (- a z)))))
(/ (cbrt (- t x)) (cbrt (- a z)))))
(if (<= (+ x (* (- y z) (/ (- t x) (- a z)))) 1.595159633781633e-230)
(+ t (* y (- (/ x z) (/ t z))))
(+
x
(*
(*
(- y z)
(/
(* (cbrt (- t x)) (cbrt (- t x)))
(* (cbrt (- a z)) (cbrt (- a z)))))
(/ (cbrt (- t x)) (cbrt (- a z))))))))double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((x + ((y - z) * ((t - x) / (a - z)))) <= -4.950225063189642e-287) {
tmp = x + (((y - z) * ((cbrt(t - x) * cbrt(t - x)) / (cbrt(a - z) * cbrt(a - z)))) * (cbrt(t - x) / cbrt(a - z)));
} else if ((x + ((y - z) * ((t - x) / (a - z)))) <= 1.595159633781633e-230) {
tmp = t + (y * ((x / z) - (t / z)));
} else {
tmp = x + (((y - z) * ((cbrt(t - x) * cbrt(t - x)) / (cbrt(a - z) * cbrt(a - z)))) * (cbrt(t - x) / cbrt(a - z)));
}
return tmp;
}



Bits error versus x



Bits error versus y



Bits error versus z



Bits error versus t



Bits error versus a
Results
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -4.95022506318964218e-287 or 1.595159633781633e-230 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 6.9
rmApplied add-cube-cbrt_binary647.6
Applied add-cube-cbrt_binary647.7
Applied times-frac_binary647.7
Applied associate-*r*_binary644.5
if -4.95022506318964218e-287 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 1.595159633781633e-230Initial program 57.9
Taylor expanded around inf 26.6
Simplified21.9
Final simplification7.3
herbie shell --seed 2020273
(FPCore (x y z t a)
:name "Numeric.Signal:interpolate from hsignal-0.2.7.1"
:precision binary64
(+ x (* (- y z) (/ (- t x) (- a z)))))