
(FPCore (x y z t a) :precision binary64 (+ x (* (- y z) (/ (- t x) (- a z)))))
double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + ((y - z) * ((t - x) / (a - z)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
def code(x, y, z, t, a): return x + ((y - z) * ((t - x) / (a - z)))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) end
function tmp = code(x, y, z, t, a) tmp = x + ((y - z) * ((t - x) / (a - z))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - z\right) \cdot \frac{t - x}{a - z}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 23 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (+ x (* (- y z) (/ (- t x) (- a z)))))
double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + ((y - z) * ((t - x) / (a - z)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + ((y - z) * ((t - x) / (a - z)));
}
def code(x, y, z, t, a): return x + ((y - z) * ((t - x) / (a - z)))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) end
function tmp = code(x, y, z, t, a) tmp = x + ((y - z) * ((t - x) / (a - z))); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(y - z\right) \cdot \frac{t - x}{a - z}
\end{array}
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (fma (/ (- z y) (- z a)) (- t x) x))
(t_2 (- x (* (- z y) (/ (- x t) (- z a))))))
(if (<= t_2 -2e-294)
t_1
(if (<= t_2 0.0) (- t (* (- y a) (/ (- x) z))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = fma(((z - y) / (z - a)), (t - x), x);
double t_2 = x - ((z - y) * ((x - t) / (z - a)));
double tmp;
if (t_2 <= -2e-294) {
tmp = t_1;
} else if (t_2 <= 0.0) {
tmp = t - ((y - a) * (-x / z));
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = fma(Float64(Float64(z - y) / Float64(z - a)), Float64(t - x), x) t_2 = Float64(x - Float64(Float64(z - y) * Float64(Float64(x - t) / Float64(z - a)))) tmp = 0.0 if (t_2 <= -2e-294) tmp = t_1; elseif (t_2 <= 0.0) tmp = Float64(t - Float64(Float64(y - a) * Float64(Float64(-x) / z))); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(z - y), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, Block[{t$95$2 = N[(x - N[(N[(z - y), $MachinePrecision] * N[(N[(x - t), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e-294], t$95$1, If[LessEqual[t$95$2, 0.0], N[(t - N[(N[(y - a), $MachinePrecision] * N[((-x) / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(\frac{z - y}{z - a}, t - x, x\right)\\
t_2 := x - \left(z - y\right) \cdot \frac{x - t}{z - a}\\
\mathbf{if}\;t\_2 \leq -2 \cdot 10^{-294}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_2 \leq 0:\\
\;\;\;\;t - \left(y - a\right) \cdot \frac{-x}{z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -2.00000000000000003e-294 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 92.3%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6495.6
Applied rewrites95.6%
if -2.00000000000000003e-294 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0Initial program 4.0%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6499.7
Applied rewrites99.7%
Taylor expanded in x around inf
Applied rewrites99.7%
Final simplification96.1%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (/ (- x t) (- z a)))
(t_2 (fma t_1 (- y z) x))
(t_3 (- x (* (- z y) t_1))))
(if (<= t_3 -2e-294)
t_2
(if (<= t_3 5e-129) (- t (* (/ (- t x) z) (- y a))) t_2))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (x - t) / (z - a);
double t_2 = fma(t_1, (y - z), x);
double t_3 = x - ((z - y) * t_1);
double tmp;
if (t_3 <= -2e-294) {
tmp = t_2;
} else if (t_3 <= 5e-129) {
tmp = t - (((t - x) / z) * (y - a));
} else {
tmp = t_2;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(Float64(x - t) / Float64(z - a)) t_2 = fma(t_1, Float64(y - z), x) t_3 = Float64(x - Float64(Float64(z - y) * t_1)) tmp = 0.0 if (t_3 <= -2e-294) tmp = t_2; elseif (t_3 <= 5e-129) tmp = Float64(t - Float64(Float64(Float64(t - x) / z) * Float64(y - a))); else tmp = t_2; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(x - t), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 * N[(y - z), $MachinePrecision] + x), $MachinePrecision]}, Block[{t$95$3 = N[(x - N[(N[(z - y), $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$3, -2e-294], t$95$2, If[LessEqual[t$95$3, 5e-129], N[(t - N[(N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x - t}{z - a}\\
t_2 := \mathsf{fma}\left(t\_1, y - z, x\right)\\
t_3 := x - \left(z - y\right) \cdot t\_1\\
\mathbf{if}\;t\_3 \leq -2 \cdot 10^{-294}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_3 \leq 5 \cdot 10^{-129}:\\
\;\;\;\;t - \frac{t - x}{z} \cdot \left(y - a\right)\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -2.00000000000000003e-294 or 5.00000000000000027e-129 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) Initial program 93.6%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
*-commutativeN/A
lower-fma.f6493.6
lift-/.f64N/A
frac-2negN/A
lower-/.f64N/A
neg-sub0N/A
lift--.f64N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
lower--.f64N/A
neg-sub0N/A
lift--.f64N/A
sub-negN/A
+-commutativeN/A
associate--r+N/A
neg-sub0N/A
remove-double-negN/A
lower--.f6493.6
Applied rewrites93.6%
if -2.00000000000000003e-294 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 5.00000000000000027e-129Initial program 16.5%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6492.3
Applied rewrites92.3%
Final simplification93.4%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.9e+203)
(* (/ z (- z a)) t)
(if (<= z -2.7e+76)
(* (/ y (- z a)) (- x t))
(if (<= z 8e+53)
(fma (- y z) (/ (- t x) a) x)
(if (<= z 4.45e+164)
(* (/ t (- z a)) (- z y))
(fma a (/ (- t x) z) t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.9e+203) {
tmp = (z / (z - a)) * t;
} else if (z <= -2.7e+76) {
tmp = (y / (z - a)) * (x - t);
} else if (z <= 8e+53) {
tmp = fma((y - z), ((t - x) / a), x);
} else if (z <= 4.45e+164) {
tmp = (t / (z - a)) * (z - y);
} else {
tmp = fma(a, ((t - x) / z), t);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.9e+203) tmp = Float64(Float64(z / Float64(z - a)) * t); elseif (z <= -2.7e+76) tmp = Float64(Float64(y / Float64(z - a)) * Float64(x - t)); elseif (z <= 8e+53) tmp = fma(Float64(y - z), Float64(Float64(t - x) / a), x); elseif (z <= 4.45e+164) tmp = Float64(Float64(t / Float64(z - a)) * Float64(z - y)); else tmp = fma(a, Float64(Float64(t - x) / z), t); end return tmp end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.9e+203], N[(N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, -2.7e+76], N[(N[(y / N[(z - a), $MachinePrecision]), $MachinePrecision] * N[(x - t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8e+53], N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 4.45e+164], N[(N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision] * N[(z - y), $MachinePrecision]), $MachinePrecision], N[(a * N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{+203}:\\
\;\;\;\;\frac{z}{z - a} \cdot t\\
\mathbf{elif}\;z \leq -2.7 \cdot 10^{+76}:\\
\;\;\;\;\frac{y}{z - a} \cdot \left(x - t\right)\\
\mathbf{elif}\;z \leq 8 \cdot 10^{+53}:\\
\;\;\;\;\mathsf{fma}\left(y - z, \frac{t - x}{a}, x\right)\\
\mathbf{elif}\;z \leq 4.45 \cdot 10^{+164}:\\
\;\;\;\;\frac{t}{z - a} \cdot \left(z - y\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{t - x}{z}, t\right)\\
\end{array}
\end{array}
if z < -1.90000000000000012e203Initial program 60.7%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6470.3
Applied rewrites70.3%
Taylor expanded in y around 0
Applied rewrites91.3%
if -1.90000000000000012e203 < z < -2.6999999999999999e76Initial program 67.9%
Taylor expanded in y around inf
div-subN/A
associate-/l*N/A
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6451.9
Applied rewrites51.9%
if -2.6999999999999999e76 < z < 7.9999999999999999e53Initial program 93.5%
Taylor expanded in a around inf
+-commutativeN/A
*-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6473.2
Applied rewrites73.2%
if 7.9999999999999999e53 < z < 4.4499999999999999e164Initial program 76.4%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6470.9
Applied rewrites70.9%
if 4.4499999999999999e164 < z Initial program 48.7%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6495.1
Applied rewrites95.1%
Taylor expanded in y around 0
Applied rewrites80.3%
Final simplification73.4%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.9e+203)
(* (/ z (- z a)) t)
(if (<= z -1.7e+81)
(* (/ y (- z a)) (- x t))
(if (<= z 9e-80)
(fma (/ y a) (- t x) x)
(if (<= z 4.45e+164)
(* (/ t (- z a)) (- z y))
(fma a (/ (- t x) z) t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.9e+203) {
tmp = (z / (z - a)) * t;
} else if (z <= -1.7e+81) {
tmp = (y / (z - a)) * (x - t);
} else if (z <= 9e-80) {
tmp = fma((y / a), (t - x), x);
} else if (z <= 4.45e+164) {
tmp = (t / (z - a)) * (z - y);
} else {
tmp = fma(a, ((t - x) / z), t);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.9e+203) tmp = Float64(Float64(z / Float64(z - a)) * t); elseif (z <= -1.7e+81) tmp = Float64(Float64(y / Float64(z - a)) * Float64(x - t)); elseif (z <= 9e-80) tmp = fma(Float64(y / a), Float64(t - x), x); elseif (z <= 4.45e+164) tmp = Float64(Float64(t / Float64(z - a)) * Float64(z - y)); else tmp = fma(a, Float64(Float64(t - x) / z), t); end return tmp end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.9e+203], N[(N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, -1.7e+81], N[(N[(y / N[(z - a), $MachinePrecision]), $MachinePrecision] * N[(x - t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e-80], N[(N[(y / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 4.45e+164], N[(N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision] * N[(z - y), $MachinePrecision]), $MachinePrecision], N[(a * N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{+203}:\\
\;\;\;\;\frac{z}{z - a} \cdot t\\
\mathbf{elif}\;z \leq -1.7 \cdot 10^{+81}:\\
\;\;\;\;\frac{y}{z - a} \cdot \left(x - t\right)\\
\mathbf{elif}\;z \leq 9 \cdot 10^{-80}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\
\mathbf{elif}\;z \leq 4.45 \cdot 10^{+164}:\\
\;\;\;\;\frac{t}{z - a} \cdot \left(z - y\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{t - x}{z}, t\right)\\
\end{array}
\end{array}
if z < -1.90000000000000012e203Initial program 60.7%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6470.3
Applied rewrites70.3%
Taylor expanded in y around 0
Applied rewrites91.3%
if -1.90000000000000012e203 < z < -1.70000000000000001e81Initial program 66.5%
Taylor expanded in y around inf
div-subN/A
associate-/l*N/A
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6454.0
Applied rewrites54.0%
if -1.70000000000000001e81 < z < 9.0000000000000006e-80Initial program 95.4%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6496.1
Applied rewrites96.1%
Taylor expanded in z around 0
lower-/.f6474.7
Applied rewrites74.7%
if 9.0000000000000006e-80 < z < 4.4499999999999999e164Initial program 79.8%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6460.3
Applied rewrites60.3%
if 4.4499999999999999e164 < z Initial program 48.7%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6495.1
Applied rewrites95.1%
Taylor expanded in y around 0
Applied rewrites80.3%
Final simplification72.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (/ (* (- x t) y) z)) (t_2 (fma (/ a z) t t)))
(if (<= z -1.16e+198)
t_2
(if (<= z -1.52e-114)
t_1
(if (<= z 2.8e-187) (* (/ y (- a z)) t) (if (<= z 9.2e+64) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = ((x - t) * y) / z;
double t_2 = fma((a / z), t, t);
double tmp;
if (z <= -1.16e+198) {
tmp = t_2;
} else if (z <= -1.52e-114) {
tmp = t_1;
} else if (z <= 2.8e-187) {
tmp = (y / (a - z)) * t;
} else if (z <= 9.2e+64) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(Float64(Float64(x - t) * y) / z) t_2 = fma(Float64(a / z), t, t) tmp = 0.0 if (z <= -1.16e+198) tmp = t_2; elseif (z <= -1.52e-114) tmp = t_1; elseif (z <= 2.8e-187) tmp = Float64(Float64(y / Float64(a - z)) * t); elseif (z <= 9.2e+64) tmp = t_1; else tmp = t_2; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(x - t), $MachinePrecision] * y), $MachinePrecision] / z), $MachinePrecision]}, Block[{t$95$2 = N[(N[(a / z), $MachinePrecision] * t + t), $MachinePrecision]}, If[LessEqual[z, -1.16e+198], t$95$2, If[LessEqual[z, -1.52e-114], t$95$1, If[LessEqual[z, 2.8e-187], N[(N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, 9.2e+64], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\left(x - t\right) \cdot y}{z}\\
t_2 := \mathsf{fma}\left(\frac{a}{z}, t, t\right)\\
\mathbf{if}\;z \leq -1.16 \cdot 10^{+198}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq -1.52 \cdot 10^{-114}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 2.8 \cdot 10^{-187}:\\
\;\;\;\;\frac{y}{a - z} \cdot t\\
\mathbf{elif}\;z \leq 9.2 \cdot 10^{+64}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if z < -1.16000000000000001e198 or 9.2e64 < z Initial program 61.0%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6487.5
Applied rewrites87.5%
Taylor expanded in y around 0
Applied rewrites70.1%
Taylor expanded in t around inf
Applied rewrites60.6%
if -1.16000000000000001e198 < z < -1.51999999999999997e-114 or 2.8e-187 < z < 9.2e64Initial program 87.1%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6453.9
Applied rewrites53.9%
Taylor expanded in y around inf
Applied rewrites38.0%
if -1.51999999999999997e-114 < z < 2.8e-187Initial program 95.6%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6445.6
Applied rewrites45.6%
Taylor expanded in y around inf
Applied rewrites43.9%
Final simplification46.1%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (fma (/ a z) t t)))
(if (<= z -2.15e-14)
t_1
(if (<= z -1.56e-114)
(/ (* y x) z)
(if (<= z 3.5e-234)
(* (/ y a) t)
(if (<= z 7.2e+58) (* (/ y (- z)) t) t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = fma((a / z), t, t);
double tmp;
if (z <= -2.15e-14) {
tmp = t_1;
} else if (z <= -1.56e-114) {
tmp = (y * x) / z;
} else if (z <= 3.5e-234) {
tmp = (y / a) * t;
} else if (z <= 7.2e+58) {
tmp = (y / -z) * t;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = fma(Float64(a / z), t, t) tmp = 0.0 if (z <= -2.15e-14) tmp = t_1; elseif (z <= -1.56e-114) tmp = Float64(Float64(y * x) / z); elseif (z <= 3.5e-234) tmp = Float64(Float64(y / a) * t); elseif (z <= 7.2e+58) tmp = Float64(Float64(y / Float64(-z)) * t); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(a / z), $MachinePrecision] * t + t), $MachinePrecision]}, If[LessEqual[z, -2.15e-14], t$95$1, If[LessEqual[z, -1.56e-114], N[(N[(y * x), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[z, 3.5e-234], N[(N[(y / a), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, 7.2e+58], N[(N[(y / (-z)), $MachinePrecision] * t), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(\frac{a}{z}, t, t\right)\\
\mathbf{if}\;z \leq -2.15 \cdot 10^{-14}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -1.56 \cdot 10^{-114}:\\
\;\;\;\;\frac{y \cdot x}{z}\\
\mathbf{elif}\;z \leq 3.5 \cdot 10^{-234}:\\
\;\;\;\;\frac{y}{a} \cdot t\\
\mathbf{elif}\;z \leq 7.2 \cdot 10^{+58}:\\
\;\;\;\;\frac{y}{-z} \cdot t\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -2.14999999999999999e-14 or 7.19999999999999993e58 < z Initial program 67.3%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6477.5
Applied rewrites77.5%
Taylor expanded in y around 0
Applied rewrites56.4%
Taylor expanded in t around inf
Applied rewrites47.7%
if -2.14999999999999999e-14 < z < -1.5599999999999999e-114Initial program 93.6%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6462.0
Applied rewrites62.0%
Taylor expanded in x around inf
Applied rewrites43.8%
Taylor expanded in y around inf
Applied rewrites37.4%
if -1.5599999999999999e-114 < z < 3.5000000000000001e-234Initial program 96.5%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6449.1
Applied rewrites49.1%
Taylor expanded in z around 0
Applied rewrites44.0%
if 3.5000000000000001e-234 < z < 7.19999999999999993e58Initial program 90.5%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6440.6
Applied rewrites40.6%
Taylor expanded in y around -inf
Applied rewrites35.4%
Taylor expanded in x around 0
Applied rewrites27.3%
Final simplification41.2%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (- t (* (- y a) (/ (- x) z)))))
(if (<= z -1.1e+76)
t_1
(if (<= z 8e+53)
(fma (/ (- y z) a) (- t x) x)
(if (<= z 3.2e+160) (* (/ t (- z a)) (- z y)) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t - ((y - a) * (-x / z));
double tmp;
if (z <= -1.1e+76) {
tmp = t_1;
} else if (z <= 8e+53) {
tmp = fma(((y - z) / a), (t - x), x);
} else if (z <= 3.2e+160) {
tmp = (t / (z - a)) * (z - y);
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(t - Float64(Float64(y - a) * Float64(Float64(-x) / z))) tmp = 0.0 if (z <= -1.1e+76) tmp = t_1; elseif (z <= 8e+53) tmp = fma(Float64(Float64(y - z) / a), Float64(t - x), x); elseif (z <= 3.2e+160) tmp = Float64(Float64(t / Float64(z - a)) * Float64(z - y)); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t - N[(N[(y - a), $MachinePrecision] * N[((-x) / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.1e+76], t$95$1, If[LessEqual[z, 8e+53], N[(N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 3.2e+160], N[(N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision] * N[(z - y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t - \left(y - a\right) \cdot \frac{-x}{z}\\
\mathbf{if}\;z \leq -1.1 \cdot 10^{+76}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 8 \cdot 10^{+53}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y - z}{a}, t - x, x\right)\\
\mathbf{elif}\;z \leq 3.2 \cdot 10^{+160}:\\
\;\;\;\;\frac{t}{z - a} \cdot \left(z - y\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.1e76 or 3.1999999999999998e160 < z Initial program 57.5%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6485.2
Applied rewrites85.2%
Taylor expanded in x around inf
Applied rewrites81.6%
if -1.1e76 < z < 7.9999999999999999e53Initial program 93.5%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6494.8
Applied rewrites94.8%
Taylor expanded in a around inf
lower-/.f64N/A
lower--.f6474.3
Applied rewrites74.3%
if 7.9999999999999999e53 < z < 3.1999999999999998e160Initial program 79.9%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6474.0
Applied rewrites74.0%
Final simplification76.5%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.55e+203)
(* (/ z (- z a)) t)
(if (<= z 8e+53)
(fma (/ (- y z) a) (- t x) x)
(if (<= z 4.45e+164) (* (/ t (- z a)) (- z y)) (fma a (/ (- t x) z) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.55e+203) {
tmp = (z / (z - a)) * t;
} else if (z <= 8e+53) {
tmp = fma(((y - z) / a), (t - x), x);
} else if (z <= 4.45e+164) {
tmp = (t / (z - a)) * (z - y);
} else {
tmp = fma(a, ((t - x) / z), t);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.55e+203) tmp = Float64(Float64(z / Float64(z - a)) * t); elseif (z <= 8e+53) tmp = fma(Float64(Float64(y - z) / a), Float64(t - x), x); elseif (z <= 4.45e+164) tmp = Float64(Float64(t / Float64(z - a)) * Float64(z - y)); else tmp = fma(a, Float64(Float64(t - x) / z), t); end return tmp end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.55e+203], N[(N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, 8e+53], N[(N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 4.45e+164], N[(N[(t / N[(z - a), $MachinePrecision]), $MachinePrecision] * N[(z - y), $MachinePrecision]), $MachinePrecision], N[(a * N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.55 \cdot 10^{+203}:\\
\;\;\;\;\frac{z}{z - a} \cdot t\\
\mathbf{elif}\;z \leq 8 \cdot 10^{+53}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y - z}{a}, t - x, x\right)\\
\mathbf{elif}\;z \leq 4.45 \cdot 10^{+164}:\\
\;\;\;\;\frac{t}{z - a} \cdot \left(z - y\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{t - x}{z}, t\right)\\
\end{array}
\end{array}
if z < -1.55e203Initial program 60.7%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6470.3
Applied rewrites70.3%
Taylor expanded in y around 0
Applied rewrites91.3%
if -1.55e203 < z < 7.9999999999999999e53Initial program 90.2%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6492.3
Applied rewrites92.3%
Taylor expanded in a around inf
lower-/.f64N/A
lower--.f6469.2
Applied rewrites69.2%
if 7.9999999999999999e53 < z < 4.4499999999999999e164Initial program 76.4%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6470.9
Applied rewrites70.9%
if 4.4499999999999999e164 < z Initial program 48.7%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6495.1
Applied rewrites95.1%
Taylor expanded in y around 0
Applied rewrites80.3%
Final simplification72.5%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.9e+203)
(* (/ z (- z a)) t)
(if (<= z -1.7e+81)
(* (/ y (- z a)) (- x t))
(if (<= z 5.2e+67) (fma (/ y a) (- t x) x) (fma a (/ (- t x) z) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.9e+203) {
tmp = (z / (z - a)) * t;
} else if (z <= -1.7e+81) {
tmp = (y / (z - a)) * (x - t);
} else if (z <= 5.2e+67) {
tmp = fma((y / a), (t - x), x);
} else {
tmp = fma(a, ((t - x) / z), t);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.9e+203) tmp = Float64(Float64(z / Float64(z - a)) * t); elseif (z <= -1.7e+81) tmp = Float64(Float64(y / Float64(z - a)) * Float64(x - t)); elseif (z <= 5.2e+67) tmp = fma(Float64(y / a), Float64(t - x), x); else tmp = fma(a, Float64(Float64(t - x) / z), t); end return tmp end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.9e+203], N[(N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, -1.7e+81], N[(N[(y / N[(z - a), $MachinePrecision]), $MachinePrecision] * N[(x - t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.2e+67], N[(N[(y / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision], N[(a * N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{+203}:\\
\;\;\;\;\frac{z}{z - a} \cdot t\\
\mathbf{elif}\;z \leq -1.7 \cdot 10^{+81}:\\
\;\;\;\;\frac{y}{z - a} \cdot \left(x - t\right)\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{+67}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{t - x}{z}, t\right)\\
\end{array}
\end{array}
if z < -1.90000000000000012e203Initial program 60.7%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6470.3
Applied rewrites70.3%
Taylor expanded in y around 0
Applied rewrites91.3%
if -1.90000000000000012e203 < z < -1.70000000000000001e81Initial program 66.5%
Taylor expanded in y around inf
div-subN/A
associate-/l*N/A
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6454.0
Applied rewrites54.0%
if -1.70000000000000001e81 < z < 5.2000000000000001e67Initial program 93.6%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6494.8
Applied rewrites94.8%
Taylor expanded in z around 0
lower-/.f6470.7
Applied rewrites70.7%
if 5.2000000000000001e67 < z Initial program 59.7%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6489.4
Applied rewrites89.4%
Taylor expanded in y around 0
Applied rewrites67.6%
Final simplification70.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (fma (/ a z) t t)))
(if (<= z -1.9e+198)
t_1
(if (<= z -7e-114)
(* (/ x z) (- y a))
(if (<= z 6.2e+64) (* (/ y (- a z)) t) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = fma((a / z), t, t);
double tmp;
if (z <= -1.9e+198) {
tmp = t_1;
} else if (z <= -7e-114) {
tmp = (x / z) * (y - a);
} else if (z <= 6.2e+64) {
tmp = (y / (a - z)) * t;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = fma(Float64(a / z), t, t) tmp = 0.0 if (z <= -1.9e+198) tmp = t_1; elseif (z <= -7e-114) tmp = Float64(Float64(x / z) * Float64(y - a)); elseif (z <= 6.2e+64) tmp = Float64(Float64(y / Float64(a - z)) * t); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(a / z), $MachinePrecision] * t + t), $MachinePrecision]}, If[LessEqual[z, -1.9e+198], t$95$1, If[LessEqual[z, -7e-114], N[(N[(x / z), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 6.2e+64], N[(N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(\frac{a}{z}, t, t\right)\\
\mathbf{if}\;z \leq -1.9 \cdot 10^{+198}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -7 \cdot 10^{-114}:\\
\;\;\;\;\frac{x}{z} \cdot \left(y - a\right)\\
\mathbf{elif}\;z \leq 6.2 \cdot 10^{+64}:\\
\;\;\;\;\frac{y}{a - z} \cdot t\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.89999999999999994e198 or 6.1999999999999998e64 < z Initial program 61.0%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6487.5
Applied rewrites87.5%
Taylor expanded in y around 0
Applied rewrites70.1%
Taylor expanded in t around inf
Applied rewrites60.6%
if -1.89999999999999994e198 < z < -7e-114Initial program 84.5%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6460.3
Applied rewrites60.3%
Taylor expanded in x around inf
Applied rewrites33.4%
Applied rewrites34.9%
if -7e-114 < z < 6.1999999999999998e64Initial program 93.4%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6441.5
Applied rewrites41.5%
Taylor expanded in y around inf
Applied rewrites37.0%
Final simplification43.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (fma (/ a z) t t)))
(if (<= z -1.9e+198)
t_1
(if (<= z -7e-114)
(* (/ (- y a) z) x)
(if (<= z 6.2e+64) (* (/ y (- a z)) t) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = fma((a / z), t, t);
double tmp;
if (z <= -1.9e+198) {
tmp = t_1;
} else if (z <= -7e-114) {
tmp = ((y - a) / z) * x;
} else if (z <= 6.2e+64) {
tmp = (y / (a - z)) * t;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = fma(Float64(a / z), t, t) tmp = 0.0 if (z <= -1.9e+198) tmp = t_1; elseif (z <= -7e-114) tmp = Float64(Float64(Float64(y - a) / z) * x); elseif (z <= 6.2e+64) tmp = Float64(Float64(y / Float64(a - z)) * t); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(a / z), $MachinePrecision] * t + t), $MachinePrecision]}, If[LessEqual[z, -1.9e+198], t$95$1, If[LessEqual[z, -7e-114], N[(N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision] * x), $MachinePrecision], If[LessEqual[z, 6.2e+64], N[(N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(\frac{a}{z}, t, t\right)\\
\mathbf{if}\;z \leq -1.9 \cdot 10^{+198}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -7 \cdot 10^{-114}:\\
\;\;\;\;\frac{y - a}{z} \cdot x\\
\mathbf{elif}\;z \leq 6.2 \cdot 10^{+64}:\\
\;\;\;\;\frac{y}{a - z} \cdot t\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.89999999999999994e198 or 6.1999999999999998e64 < z Initial program 61.0%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6487.5
Applied rewrites87.5%
Taylor expanded in y around 0
Applied rewrites70.1%
Taylor expanded in t around inf
Applied rewrites60.6%
if -1.89999999999999994e198 < z < -7e-114Initial program 84.5%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6460.3
Applied rewrites60.3%
Taylor expanded in x around inf
Applied rewrites33.4%
Applied rewrites34.8%
if -7e-114 < z < 6.1999999999999998e64Initial program 93.4%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6441.5
Applied rewrites41.5%
Taylor expanded in y around inf
Applied rewrites37.0%
Final simplification43.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (fma (/ a z) t t)))
(if (<= z -2.15e-14)
t_1
(if (<= z -7e-114)
(/ (* y x) z)
(if (<= z 6.2e+64) (* (/ y (- a z)) t) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = fma((a / z), t, t);
double tmp;
if (z <= -2.15e-14) {
tmp = t_1;
} else if (z <= -7e-114) {
tmp = (y * x) / z;
} else if (z <= 6.2e+64) {
tmp = (y / (a - z)) * t;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = fma(Float64(a / z), t, t) tmp = 0.0 if (z <= -2.15e-14) tmp = t_1; elseif (z <= -7e-114) tmp = Float64(Float64(y * x) / z); elseif (z <= 6.2e+64) tmp = Float64(Float64(y / Float64(a - z)) * t); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(a / z), $MachinePrecision] * t + t), $MachinePrecision]}, If[LessEqual[z, -2.15e-14], t$95$1, If[LessEqual[z, -7e-114], N[(N[(y * x), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[z, 6.2e+64], N[(N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(\frac{a}{z}, t, t\right)\\
\mathbf{if}\;z \leq -2.15 \cdot 10^{-14}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -7 \cdot 10^{-114}:\\
\;\;\;\;\frac{y \cdot x}{z}\\
\mathbf{elif}\;z \leq 6.2 \cdot 10^{+64}:\\
\;\;\;\;\frac{y}{a - z} \cdot t\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -2.14999999999999999e-14 or 6.1999999999999998e64 < z Initial program 67.3%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6477.5
Applied rewrites77.5%
Taylor expanded in y around 0
Applied rewrites56.4%
Taylor expanded in t around inf
Applied rewrites47.7%
if -2.14999999999999999e-14 < z < -7e-114Initial program 93.6%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6462.0
Applied rewrites62.0%
Taylor expanded in x around inf
Applied rewrites43.8%
Taylor expanded in y around inf
Applied rewrites37.4%
if -7e-114 < z < 6.1999999999999998e64Initial program 93.4%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6441.5
Applied rewrites41.5%
Taylor expanded in y around inf
Applied rewrites37.0%
Final simplification41.9%
(FPCore (x y z t a)
:precision binary64
(if (<= a -6.4e-24)
(fma (/ (- y z) a) (- t x) x)
(if (<= a 2.8e+42)
(- t (* (/ (- t x) z) (- y a)))
(fma (/ (- z) (- a z)) (- t x) x))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -6.4e-24) {
tmp = fma(((y - z) / a), (t - x), x);
} else if (a <= 2.8e+42) {
tmp = t - (((t - x) / z) * (y - a));
} else {
tmp = fma((-z / (a - z)), (t - x), x);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if (a <= -6.4e-24) tmp = fma(Float64(Float64(y - z) / a), Float64(t - x), x); elseif (a <= 2.8e+42) tmp = Float64(t - Float64(Float64(Float64(t - x) / z) * Float64(y - a))); else tmp = fma(Float64(Float64(-z) / Float64(a - z)), Float64(t - x), x); end return tmp end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -6.4e-24], N[(N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[a, 2.8e+42], N[(t - N[(N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[((-z) / N[(a - z), $MachinePrecision]), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -6.4 \cdot 10^{-24}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y - z}{a}, t - x, x\right)\\
\mathbf{elif}\;a \leq 2.8 \cdot 10^{+42}:\\
\;\;\;\;t - \frac{t - x}{z} \cdot \left(y - a\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(\frac{-z}{a - z}, t - x, x\right)\\
\end{array}
\end{array}
if a < -6.40000000000000025e-24Initial program 88.9%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6492.6
Applied rewrites92.6%
Taylor expanded in a around inf
lower-/.f64N/A
lower--.f6486.0
Applied rewrites86.0%
if -6.40000000000000025e-24 < a < 2.7999999999999999e42Initial program 74.3%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6482.7
Applied rewrites82.7%
if 2.7999999999999999e42 < a Initial program 89.0%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6493.9
Applied rewrites93.9%
Taylor expanded in y around 0
mul-1-negN/A
lower-neg.f6471.9
Applied rewrites71.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (fma (/ (- y z) a) (- t x) x)))
(if (<= a -6.4e-24)
t_1
(if (<= a 6.2e+64) (- t (* (/ (- t x) z) (- y a))) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = fma(((y - z) / a), (t - x), x);
double tmp;
if (a <= -6.4e-24) {
tmp = t_1;
} else if (a <= 6.2e+64) {
tmp = t - (((t - x) / z) * (y - a));
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = fma(Float64(Float64(y - z) / a), Float64(t - x), x) tmp = 0.0 if (a <= -6.4e-24) tmp = t_1; elseif (a <= 6.2e+64) tmp = Float64(t - Float64(Float64(Float64(t - x) / z) * Float64(y - a))); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[a, -6.4e-24], t$95$1, If[LessEqual[a, 6.2e+64], N[(t - N[(N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(\frac{y - z}{a}, t - x, x\right)\\
\mathbf{if}\;a \leq -6.4 \cdot 10^{-24}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 6.2 \cdot 10^{+64}:\\
\;\;\;\;t - \frac{t - x}{z} \cdot \left(y - a\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -6.40000000000000025e-24 or 6.1999999999999998e64 < a Initial program 88.7%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6493.2
Applied rewrites93.2%
Taylor expanded in a around inf
lower-/.f64N/A
lower--.f6479.7
Applied rewrites79.7%
if -6.40000000000000025e-24 < a < 6.1999999999999998e64Initial program 75.3%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6481.4
Applied rewrites81.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (fma (/ a z) t t)))
(if (<= z -2.15e-14)
t_1
(if (<= z -1.56e-114)
(/ (* y x) z)
(if (<= z 9e+57) (* (/ y a) t) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = fma((a / z), t, t);
double tmp;
if (z <= -2.15e-14) {
tmp = t_1;
} else if (z <= -1.56e-114) {
tmp = (y * x) / z;
} else if (z <= 9e+57) {
tmp = (y / a) * t;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = fma(Float64(a / z), t, t) tmp = 0.0 if (z <= -2.15e-14) tmp = t_1; elseif (z <= -1.56e-114) tmp = Float64(Float64(y * x) / z); elseif (z <= 9e+57) tmp = Float64(Float64(y / a) * t); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(a / z), $MachinePrecision] * t + t), $MachinePrecision]}, If[LessEqual[z, -2.15e-14], t$95$1, If[LessEqual[z, -1.56e-114], N[(N[(y * x), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[z, 9e+57], N[(N[(y / a), $MachinePrecision] * t), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(\frac{a}{z}, t, t\right)\\
\mathbf{if}\;z \leq -2.15 \cdot 10^{-14}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -1.56 \cdot 10^{-114}:\\
\;\;\;\;\frac{y \cdot x}{z}\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+57}:\\
\;\;\;\;\frac{y}{a} \cdot t\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -2.14999999999999999e-14 or 8.99999999999999991e57 < z Initial program 67.3%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6477.5
Applied rewrites77.5%
Taylor expanded in y around 0
Applied rewrites56.4%
Taylor expanded in t around inf
Applied rewrites47.7%
if -2.14999999999999999e-14 < z < -1.5599999999999999e-114Initial program 93.6%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6462.0
Applied rewrites62.0%
Taylor expanded in x around inf
Applied rewrites43.8%
Taylor expanded in y around inf
Applied rewrites37.4%
if -1.5599999999999999e-114 < z < 8.99999999999999991e57Initial program 93.4%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6441.5
Applied rewrites41.5%
Taylor expanded in z around 0
Applied rewrites31.3%
Final simplification39.3%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ (- t x) x)))
(if (<= z -1e+201)
t_1
(if (<= z -1.56e-114)
(/ (* y x) z)
(if (<= z 1.05e+58) (* (/ y a) t) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (t - x) + x;
double tmp;
if (z <= -1e+201) {
tmp = t_1;
} else if (z <= -1.56e-114) {
tmp = (y * x) / z;
} else if (z <= 1.05e+58) {
tmp = (y / a) * t;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = (t - x) + x
if (z <= (-1d+201)) then
tmp = t_1
else if (z <= (-1.56d-114)) then
tmp = (y * x) / z
else if (z <= 1.05d+58) then
tmp = (y / a) * t
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = (t - x) + x;
double tmp;
if (z <= -1e+201) {
tmp = t_1;
} else if (z <= -1.56e-114) {
tmp = (y * x) / z;
} else if (z <= 1.05e+58) {
tmp = (y / a) * t;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (t - x) + x tmp = 0 if z <= -1e+201: tmp = t_1 elif z <= -1.56e-114: tmp = (y * x) / z elif z <= 1.05e+58: tmp = (y / a) * t else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(t - x) + x) tmp = 0.0 if (z <= -1e+201) tmp = t_1; elseif (z <= -1.56e-114) tmp = Float64(Float64(y * x) / z); elseif (z <= 1.05e+58) tmp = Float64(Float64(y / a) * t); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (t - x) + x; tmp = 0.0; if (z <= -1e+201) tmp = t_1; elseif (z <= -1.56e-114) tmp = (y * x) / z; elseif (z <= 1.05e+58) tmp = (y / a) * t; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[z, -1e+201], t$95$1, If[LessEqual[z, -1.56e-114], N[(N[(y * x), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[z, 1.05e+58], N[(N[(y / a), $MachinePrecision] * t), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(t - x\right) + x\\
\mathbf{if}\;z \leq -1 \cdot 10^{+201}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -1.56 \cdot 10^{-114}:\\
\;\;\;\;\frac{y \cdot x}{z}\\
\mathbf{elif}\;z \leq 1.05 \cdot 10^{+58}:\\
\;\;\;\;\frac{y}{a} \cdot t\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.00000000000000004e201 or 1.05000000000000006e58 < z Initial program 60.5%
Taylor expanded in z around inf
lower--.f6443.2
Applied rewrites43.2%
if -1.00000000000000004e201 < z < -1.5599999999999999e-114Initial program 84.8%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6459.5
Applied rewrites59.5%
Taylor expanded in x around inf
Applied rewrites32.9%
Taylor expanded in y around inf
Applied rewrites28.0%
if -1.5599999999999999e-114 < z < 1.05000000000000006e58Initial program 93.4%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6441.5
Applied rewrites41.5%
Taylor expanded in z around 0
Applied rewrites31.3%
Final simplification33.8%
(FPCore (x y z t a) :precision binary64 (if (<= z -1.95e+127) (* (/ z (- z a)) t) (if (<= z 5.2e+67) (fma (/ y a) (- t x) x) (fma a (/ (- t x) z) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.95e+127) {
tmp = (z / (z - a)) * t;
} else if (z <= 5.2e+67) {
tmp = fma((y / a), (t - x), x);
} else {
tmp = fma(a, ((t - x) / z), t);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.95e+127) tmp = Float64(Float64(z / Float64(z - a)) * t); elseif (z <= 5.2e+67) tmp = fma(Float64(y / a), Float64(t - x), x); else tmp = fma(a, Float64(Float64(t - x) / z), t); end return tmp end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.95e+127], N[(N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[z, 5.2e+67], N[(N[(y / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision], N[(a * N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.95 \cdot 10^{+127}:\\
\;\;\;\;\frac{z}{z - a} \cdot t\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{+67}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{t - x}{z}, t\right)\\
\end{array}
\end{array}
if z < -1.94999999999999991e127Initial program 64.6%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6454.9
Applied rewrites54.9%
Taylor expanded in y around 0
Applied rewrites66.7%
if -1.94999999999999991e127 < z < 5.2000000000000001e67Initial program 92.2%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6493.9
Applied rewrites93.9%
Taylor expanded in z around 0
lower-/.f6469.6
Applied rewrites69.6%
if 5.2000000000000001e67 < z Initial program 59.7%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6489.4
Applied rewrites89.4%
Taylor expanded in y around 0
Applied rewrites67.6%
Final simplification68.8%
(FPCore (x y z t a) :precision binary64 (if (<= z -1.95e+127) (fma a (/ (- x) z) t) (if (<= z 5.2e+67) (fma (/ y a) (- t x) x) (fma a (/ (- t x) z) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.95e+127) {
tmp = fma(a, (-x / z), t);
} else if (z <= 5.2e+67) {
tmp = fma((y / a), (t - x), x);
} else {
tmp = fma(a, ((t - x) / z), t);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.95e+127) tmp = fma(a, Float64(Float64(-x) / z), t); elseif (z <= 5.2e+67) tmp = fma(Float64(y / a), Float64(t - x), x); else tmp = fma(a, Float64(Float64(t - x) / z), t); end return tmp end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.95e+127], N[(a * N[((-x) / z), $MachinePrecision] + t), $MachinePrecision], If[LessEqual[z, 5.2e+67], N[(N[(y / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision], N[(a * N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.95 \cdot 10^{+127}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{-x}{z}, t\right)\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{+67}:\\
\;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{t - x}{z}, t\right)\\
\end{array}
\end{array}
if z < -1.94999999999999991e127Initial program 64.6%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6481.8
Applied rewrites81.8%
Taylor expanded in y around 0
Applied rewrites61.6%
Taylor expanded in x around inf
Applied rewrites61.7%
if -1.94999999999999991e127 < z < 5.2000000000000001e67Initial program 92.2%
lift-+.f64N/A
+-commutativeN/A
lift-*.f64N/A
lift-/.f64N/A
clear-numN/A
associate-*r/N/A
div-invN/A
times-fracN/A
lift--.f64N/A
flip3--N/A
clear-num-revN/A
clear-numN/A
flip3--N/A
lift--.f64N/A
lower-fma.f64N/A
lower-/.f6493.9
Applied rewrites93.9%
Taylor expanded in z around 0
lower-/.f6469.6
Applied rewrites69.6%
if 5.2000000000000001e67 < z Initial program 59.7%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6489.4
Applied rewrites89.4%
Taylor expanded in y around 0
Applied rewrites67.6%
(FPCore (x y z t a) :precision binary64 (if (<= z -1.35e+124) (fma a (/ (- x) z) t) (if (<= z 5.2e+67) (fma (/ (- t x) a) y x) (fma a (/ (- t x) z) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.35e+124) {
tmp = fma(a, (-x / z), t);
} else if (z <= 5.2e+67) {
tmp = fma(((t - x) / a), y, x);
} else {
tmp = fma(a, ((t - x) / z), t);
}
return tmp;
}
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.35e+124) tmp = fma(a, Float64(Float64(-x) / z), t); elseif (z <= 5.2e+67) tmp = fma(Float64(Float64(t - x) / a), y, x); else tmp = fma(a, Float64(Float64(t - x) / z), t); end return tmp end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.35e+124], N[(a * N[((-x) / z), $MachinePrecision] + t), $MachinePrecision], If[LessEqual[z, 5.2e+67], N[(N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision] * y + x), $MachinePrecision], N[(a * N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] + t), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.35 \cdot 10^{+124}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{-x}{z}, t\right)\\
\mathbf{elif}\;z \leq 5.2 \cdot 10^{+67}:\\
\;\;\;\;\mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{t - x}{z}, t\right)\\
\end{array}
\end{array}
if z < -1.34999999999999989e124Initial program 63.0%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6479.8
Applied rewrites79.8%
Taylor expanded in y around 0
Applied rewrites60.1%
Taylor expanded in x around inf
Applied rewrites60.2%
if -1.34999999999999989e124 < z < 5.2000000000000001e67Initial program 92.7%
Taylor expanded in z around 0
+-commutativeN/A
associate-/l*N/A
*-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
lower--.f6468.4
Applied rewrites68.4%
if 5.2000000000000001e67 < z Initial program 59.7%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6489.4
Applied rewrites89.4%
Taylor expanded in y around 0
Applied rewrites67.6%
(FPCore (x y z t a) :precision binary64 (let* ((t_1 (/ (* (- x t) y) z))) (if (<= y -1.78e+50) t_1 (if (<= y 4.7e+32) (fma a (/ (- x) z) t) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = ((x - t) * y) / z;
double tmp;
if (y <= -1.78e+50) {
tmp = t_1;
} else if (y <= 4.7e+32) {
tmp = fma(a, (-x / z), t);
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(Float64(Float64(x - t) * y) / z) tmp = 0.0 if (y <= -1.78e+50) tmp = t_1; elseif (y <= 4.7e+32) tmp = fma(a, Float64(Float64(-x) / z), t); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(x - t), $MachinePrecision] * y), $MachinePrecision] / z), $MachinePrecision]}, If[LessEqual[y, -1.78e+50], t$95$1, If[LessEqual[y, 4.7e+32], N[(a * N[((-x) / z), $MachinePrecision] + t), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\left(x - t\right) \cdot y}{z}\\
\mathbf{if}\;y \leq -1.78 \cdot 10^{+50}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 4.7 \cdot 10^{+32}:\\
\;\;\;\;\mathsf{fma}\left(a, \frac{-x}{z}, t\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -1.78e50 or 4.70000000000000023e32 < y Initial program 94.9%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6454.4
Applied rewrites54.4%
Taylor expanded in y around inf
Applied rewrites45.8%
if -1.78e50 < y < 4.70000000000000023e32Initial program 70.0%
Taylor expanded in z around inf
metadata-evalN/A
cancel-sign-sub-invN/A
*-lft-identityN/A
mul-1-negN/A
unsub-negN/A
associate-+l-N/A
div-subN/A
lower--.f64N/A
div-subN/A
associate-/l*N/A
associate-/l*N/A
distribute-rgt-out--N/A
lower-*.f64N/A
lower-/.f64N/A
lower--.f64N/A
lower--.f6456.7
Applied rewrites56.7%
Taylor expanded in y around 0
Applied rewrites48.3%
Taylor expanded in x around inf
Applied rewrites50.5%
(FPCore (x y z t a) :precision binary64 (let* ((t_1 (+ (- t x) x))) (if (<= z -1.25e-126) t_1 (if (<= z 1.05e+58) (* (/ y a) t) t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (t - x) + x;
double tmp;
if (z <= -1.25e-126) {
tmp = t_1;
} else if (z <= 1.05e+58) {
tmp = (y / a) * t;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = (t - x) + x
if (z <= (-1.25d-126)) then
tmp = t_1
else if (z <= 1.05d+58) then
tmp = (y / a) * t
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = (t - x) + x;
double tmp;
if (z <= -1.25e-126) {
tmp = t_1;
} else if (z <= 1.05e+58) {
tmp = (y / a) * t;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (t - x) + x tmp = 0 if z <= -1.25e-126: tmp = t_1 elif z <= 1.05e+58: tmp = (y / a) * t else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(t - x) + x) tmp = 0.0 if (z <= -1.25e-126) tmp = t_1; elseif (z <= 1.05e+58) tmp = Float64(Float64(y / a) * t); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (t - x) + x; tmp = 0.0; if (z <= -1.25e-126) tmp = t_1; elseif (z <= 1.05e+58) tmp = (y / a) * t; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[z, -1.25e-126], t$95$1, If[LessEqual[z, 1.05e+58], N[(N[(y / a), $MachinePrecision] * t), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(t - x\right) + x\\
\mathbf{if}\;z \leq -1.25 \cdot 10^{-126}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 1.05 \cdot 10^{+58}:\\
\;\;\;\;\frac{y}{a} \cdot t\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.25000000000000001e-126 or 1.05000000000000006e58 < z Initial program 72.5%
Taylor expanded in z around inf
lower--.f6431.1
Applied rewrites31.1%
if -1.25000000000000001e-126 < z < 1.05000000000000006e58Initial program 93.3%
Taylor expanded in x around 0
*-commutativeN/A
associate-/l*N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower--.f6441.3
Applied rewrites41.3%
Taylor expanded in z around 0
Applied rewrites31.7%
Final simplification31.4%
(FPCore (x y z t a) :precision binary64 (+ (- t x) x))
double code(double x, double y, double z, double t, double a) {
return (t - x) + x;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = (t - x) + x
end function
public static double code(double x, double y, double z, double t, double a) {
return (t - x) + x;
}
def code(x, y, z, t, a): return (t - x) + x
function code(x, y, z, t, a) return Float64(Float64(t - x) + x) end
function tmp = code(x, y, z, t, a) tmp = (t - x) + x; end
code[x_, y_, z_, t_, a_] := N[(N[(t - x), $MachinePrecision] + x), $MachinePrecision]
\begin{array}{l}
\\
\left(t - x\right) + x
\end{array}
Initial program 81.6%
Taylor expanded in z around inf
lower--.f6420.0
Applied rewrites20.0%
Final simplification20.0%
(FPCore (x y z t a) :precision binary64 (+ (- x) x))
double code(double x, double y, double z, double t, double a) {
return -x + x;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = -x + x
end function
public static double code(double x, double y, double z, double t, double a) {
return -x + x;
}
def code(x, y, z, t, a): return -x + x
function code(x, y, z, t, a) return Float64(Float64(-x) + x) end
function tmp = code(x, y, z, t, a) tmp = -x + x; end
code[x_, y_, z_, t_, a_] := N[((-x) + x), $MachinePrecision]
\begin{array}{l}
\\
\left(-x\right) + x
\end{array}
Initial program 81.6%
Taylor expanded in z around inf
lower--.f6420.0
Applied rewrites20.0%
Taylor expanded in x around inf
Applied rewrites2.9%
Final simplification2.9%
herbie shell --seed 2024298
(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)))))