
(FPCore (x y z t a b) :precision binary64 (+ (- (- x (* (- y 1.0) z)) (* (- t 1.0) a)) (* (- (+ y t) 2.0) b)))
double code(double x, double y, double z, double t, double a, double b) {
return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = ((x - ((y - 1.0d0) * z)) - ((t - 1.0d0) * a)) + (((y + t) - 2.0d0) * b)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
}
def code(x, y, z, t, a, b): return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b)
function code(x, y, z, t, a, b) return Float64(Float64(Float64(x - Float64(Float64(y - 1.0) * z)) - Float64(Float64(t - 1.0) * a)) + Float64(Float64(Float64(y + t) - 2.0) * b)) end
function tmp = code(x, y, z, t, a, b) tmp = ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x - N[(N[(y - 1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] - N[(N[(t - 1.0), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 25 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b) :precision binary64 (+ (- (- x (* (- y 1.0) z)) (* (- t 1.0) a)) (* (- (+ y t) 2.0) b)))
double code(double x, double y, double z, double t, double a, double b) {
return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = ((x - ((y - 1.0d0) * z)) - ((t - 1.0d0) * a)) + (((y + t) - 2.0d0) * b)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
}
def code(x, y, z, t, a, b): return ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b)
function code(x, y, z, t, a, b) return Float64(Float64(Float64(x - Float64(Float64(y - 1.0) * z)) - Float64(Float64(t - 1.0) * a)) + Float64(Float64(Float64(y + t) - 2.0) * b)) end
function tmp = code(x, y, z, t, a, b) tmp = ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x - N[(N[(y - 1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] - N[(N[(t - 1.0), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b
\end{array}
(FPCore (x y z t a b) :precision binary64 (fma (- 1.0 t) a (+ z (fma (- b z) y (fma (- t 2.0) b x)))))
double code(double x, double y, double z, double t, double a, double b) {
return fma((1.0 - t), a, (z + fma((b - z), y, fma((t - 2.0), b, x))));
}
function code(x, y, z, t, a, b) return fma(Float64(1.0 - t), a, Float64(z + fma(Float64(b - z), y, fma(Float64(t - 2.0), b, x)))) end
code[x_, y_, z_, t_, a_, b_] := N[(N[(1.0 - t), $MachinePrecision] * a + N[(z + N[(N[(b - z), $MachinePrecision] * y + N[(N[(t - 2.0), $MachinePrecision] * b + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(1 - t, a, z + \mathsf{fma}\left(b - z, y, \mathsf{fma}\left(t - 2, b, x\right)\right)\right)
\end{array}
Initial program 95.3%
Taylor expanded in x around 0
Applied rewrites97.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1
(+ (- (- x (* (- y 1.0) z)) (* (- t 1.0) a)) (* (- (+ y t) 2.0) b))))
(if (<= t_1 (- INFINITY))
(* b t)
(if (<= t_1 5e+302) (+ a x) (* (- a) t)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = b * t;
} else if (t_1 <= 5e+302) {
tmp = a + x;
} else {
tmp = -a * t;
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b);
double tmp;
if (t_1 <= -Double.POSITIVE_INFINITY) {
tmp = b * t;
} else if (t_1 <= 5e+302) {
tmp = a + x;
} else {
tmp = -a * t;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b) tmp = 0 if t_1 <= -math.inf: tmp = b * t elif t_1 <= 5e+302: tmp = a + x else: tmp = -a * t return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64(x - Float64(Float64(y - 1.0) * z)) - Float64(Float64(t - 1.0) * a)) + Float64(Float64(Float64(y + t) - 2.0) * b)) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = Float64(b * t); elseif (t_1 <= 5e+302) tmp = Float64(a + x); else tmp = Float64(Float64(-a) * t); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = ((x - ((y - 1.0) * z)) - ((t - 1.0) * a)) + (((y + t) - 2.0) * b); tmp = 0.0; if (t_1 <= -Inf) tmp = b * t; elseif (t_1 <= 5e+302) tmp = a + x; else tmp = -a * t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(x - N[(N[(y - 1.0), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] - N[(N[(t - 1.0), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y + t), $MachinePrecision] - 2.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(b * t), $MachinePrecision], If[LessEqual[t$95$1, 5e+302], N[(a + x), $MachinePrecision], N[((-a) * t), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(\left(x - \left(y - 1\right) \cdot z\right) - \left(t - 1\right) \cdot a\right) + \left(\left(y + t\right) - 2\right) \cdot b\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;b \cdot t\\
\mathbf{elif}\;t\_1 \leq 5 \cdot 10^{+302}:\\
\;\;\;\;a + x\\
\mathbf{else}:\\
\;\;\;\;\left(-a\right) \cdot t\\
\end{array}
\end{array}
if (+.f64 (-.f64 (-.f64 x (*.f64 (-.f64 y #s(literal 1 binary64)) z)) (*.f64 (-.f64 t #s(literal 1 binary64)) a)) (*.f64 (-.f64 (+.f64 y t) #s(literal 2 binary64)) b)) < -inf.0Initial program 100.0%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6481.3
Applied rewrites81.3%
Taylor expanded in t around 0
Applied rewrites51.6%
Taylor expanded in t around inf
Applied rewrites41.4%
if -inf.0 < (+.f64 (-.f64 (-.f64 x (*.f64 (-.f64 y #s(literal 1 binary64)) z)) (*.f64 (-.f64 t #s(literal 1 binary64)) a)) (*.f64 (-.f64 (+.f64 y t) #s(literal 2 binary64)) b)) < 5e302Initial program 100.0%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6475.2
Applied rewrites75.2%
Taylor expanded in b around 0
Applied rewrites46.7%
Taylor expanded in t around 0
Applied rewrites39.0%
if 5e302 < (+.f64 (-.f64 (-.f64 x (*.f64 (-.f64 y #s(literal 1 binary64)) z)) (*.f64 (-.f64 t #s(literal 1 binary64)) a)) (*.f64 (-.f64 (+.f64 y t) #s(literal 2 binary64)) b)) Initial program 78.6%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6460.1
Applied rewrites60.1%
Taylor expanded in a around inf
Applied rewrites42.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (- b z) y)) (t_2 (fma -2.0 b (+ a x))) (t_3 (* (- b a) t)))
(if (<= t -2.15e+129)
t_3
(if (<= t -1.3e+20)
t_1
(if (<= t 1.85e-304)
t_2
(if (<= t 1.15e-147) t_1 (if (<= t 25500000.0) t_2 t_3)))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (b - z) * y;
double t_2 = fma(-2.0, b, (a + x));
double t_3 = (b - a) * t;
double tmp;
if (t <= -2.15e+129) {
tmp = t_3;
} else if (t <= -1.3e+20) {
tmp = t_1;
} else if (t <= 1.85e-304) {
tmp = t_2;
} else if (t <= 1.15e-147) {
tmp = t_1;
} else if (t <= 25500000.0) {
tmp = t_2;
} else {
tmp = t_3;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(b - z) * y) t_2 = fma(-2.0, b, Float64(a + x)) t_3 = Float64(Float64(b - a) * t) tmp = 0.0 if (t <= -2.15e+129) tmp = t_3; elseif (t <= -1.3e+20) tmp = t_1; elseif (t <= 1.85e-304) tmp = t_2; elseif (t <= 1.15e-147) tmp = t_1; elseif (t <= 25500000.0) tmp = t_2; else tmp = t_3; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - z), $MachinePrecision] * y), $MachinePrecision]}, Block[{t$95$2 = N[(-2.0 * b + N[(a + x), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(b - a), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[t, -2.15e+129], t$95$3, If[LessEqual[t, -1.3e+20], t$95$1, If[LessEqual[t, 1.85e-304], t$95$2, If[LessEqual[t, 1.15e-147], t$95$1, If[LessEqual[t, 25500000.0], t$95$2, t$95$3]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(b - z\right) \cdot y\\
t_2 := \mathsf{fma}\left(-2, b, a + x\right)\\
t_3 := \left(b - a\right) \cdot t\\
\mathbf{if}\;t \leq -2.15 \cdot 10^{+129}:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;t \leq -1.3 \cdot 10^{+20}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 1.85 \cdot 10^{-304}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq 1.15 \cdot 10^{-147}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 25500000:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_3\\
\end{array}
\end{array}
if t < -2.1500000000000001e129 or 2.55e7 < t Initial program 90.6%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6474.8
Applied rewrites74.8%
if -2.1500000000000001e129 < t < -1.3e20 or 1.8500000000000001e-304 < t < 1.14999999999999995e-147Initial program 96.8%
Taylor expanded in y around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6460.8
Applied rewrites60.8%
if -1.3e20 < t < 1.8500000000000001e-304 or 1.14999999999999995e-147 < t < 2.55e7Initial program 100.0%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6474.9
Applied rewrites74.9%
Taylor expanded in t around 0
Applied rewrites72.4%
Taylor expanded in y around 0
Applied rewrites60.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (- b z) y)) (t_2 (* (- b a) t)))
(if (<= t -2.15e+129)
t_2
(if (<= t -2.45e-114)
t_1
(if (<= t 1.8e-304)
(+ a x)
(if (<= t 1.18e-147) t_1 (if (<= t 25500000.0) (+ a x) t_2)))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (b - z) * y;
double t_2 = (b - a) * t;
double tmp;
if (t <= -2.15e+129) {
tmp = t_2;
} else if (t <= -2.45e-114) {
tmp = t_1;
} else if (t <= 1.8e-304) {
tmp = a + x;
} else if (t <= 1.18e-147) {
tmp = t_1;
} else if (t <= 25500000.0) {
tmp = a + x;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (b - z) * y
t_2 = (b - a) * t
if (t <= (-2.15d+129)) then
tmp = t_2
else if (t <= (-2.45d-114)) then
tmp = t_1
else if (t <= 1.8d-304) then
tmp = a + x
else if (t <= 1.18d-147) then
tmp = t_1
else if (t <= 25500000.0d0) then
tmp = a + x
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (b - z) * y;
double t_2 = (b - a) * t;
double tmp;
if (t <= -2.15e+129) {
tmp = t_2;
} else if (t <= -2.45e-114) {
tmp = t_1;
} else if (t <= 1.8e-304) {
tmp = a + x;
} else if (t <= 1.18e-147) {
tmp = t_1;
} else if (t <= 25500000.0) {
tmp = a + x;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (b - z) * y t_2 = (b - a) * t tmp = 0 if t <= -2.15e+129: tmp = t_2 elif t <= -2.45e-114: tmp = t_1 elif t <= 1.8e-304: tmp = a + x elif t <= 1.18e-147: tmp = t_1 elif t <= 25500000.0: tmp = a + x else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(b - z) * y) t_2 = Float64(Float64(b - a) * t) tmp = 0.0 if (t <= -2.15e+129) tmp = t_2; elseif (t <= -2.45e-114) tmp = t_1; elseif (t <= 1.8e-304) tmp = Float64(a + x); elseif (t <= 1.18e-147) tmp = t_1; elseif (t <= 25500000.0) tmp = Float64(a + x); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (b - z) * y; t_2 = (b - a) * t; tmp = 0.0; if (t <= -2.15e+129) tmp = t_2; elseif (t <= -2.45e-114) tmp = t_1; elseif (t <= 1.8e-304) tmp = a + x; elseif (t <= 1.18e-147) tmp = t_1; elseif (t <= 25500000.0) tmp = a + x; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - z), $MachinePrecision] * y), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b - a), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[t, -2.15e+129], t$95$2, If[LessEqual[t, -2.45e-114], t$95$1, If[LessEqual[t, 1.8e-304], N[(a + x), $MachinePrecision], If[LessEqual[t, 1.18e-147], t$95$1, If[LessEqual[t, 25500000.0], N[(a + x), $MachinePrecision], t$95$2]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(b - z\right) \cdot y\\
t_2 := \left(b - a\right) \cdot t\\
\mathbf{if}\;t \leq -2.15 \cdot 10^{+129}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -2.45 \cdot 10^{-114}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 1.8 \cdot 10^{-304}:\\
\;\;\;\;a + x\\
\mathbf{elif}\;t \leq 1.18 \cdot 10^{-147}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 25500000:\\
\;\;\;\;a + x\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -2.1500000000000001e129 or 2.55e7 < t Initial program 90.6%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6474.8
Applied rewrites74.8%
if -2.1500000000000001e129 < t < -2.4499999999999999e-114 or 1.8000000000000001e-304 < t < 1.18000000000000003e-147Initial program 97.7%
Taylor expanded in y around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6453.4
Applied rewrites53.4%
if -2.4499999999999999e-114 < t < 1.8000000000000001e-304 or 1.18000000000000003e-147 < t < 2.55e7Initial program 100.0%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6476.2
Applied rewrites76.2%
Taylor expanded in b around 0
Applied rewrites50.5%
Taylor expanded in t around 0
Applied rewrites50.5%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (fma 1.0 z (fma (- (+ t y) 2.0) b x))))
(if (<= b -2.35e+39)
t_1
(if (<= b 9.2e-26)
(fma (- 1.0 y) z (fma (- 1.0 t) a x))
(if (<= b 2.7e+72) (+ (fma (- b z) y (* (- t 2.0) b)) x) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = fma(1.0, z, fma(((t + y) - 2.0), b, x));
double tmp;
if (b <= -2.35e+39) {
tmp = t_1;
} else if (b <= 9.2e-26) {
tmp = fma((1.0 - y), z, fma((1.0 - t), a, x));
} else if (b <= 2.7e+72) {
tmp = fma((b - z), y, ((t - 2.0) * b)) + x;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = fma(1.0, z, fma(Float64(Float64(t + y) - 2.0), b, x)) tmp = 0.0 if (b <= -2.35e+39) tmp = t_1; elseif (b <= 9.2e-26) tmp = fma(Float64(1.0 - y), z, fma(Float64(1.0 - t), a, x)); elseif (b <= 2.7e+72) tmp = Float64(fma(Float64(b - z), y, Float64(Float64(t - 2.0) * b)) + x); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(1.0 * z + N[(N[(N[(t + y), $MachinePrecision] - 2.0), $MachinePrecision] * b + x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -2.35e+39], t$95$1, If[LessEqual[b, 9.2e-26], N[(N[(1.0 - y), $MachinePrecision] * z + N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 2.7e+72], N[(N[(N[(b - z), $MachinePrecision] * y + N[(N[(t - 2.0), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(1, z, \mathsf{fma}\left(\left(t + y\right) - 2, b, x\right)\right)\\
\mathbf{if}\;b \leq -2.35 \cdot 10^{+39}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 9.2 \cdot 10^{-26}:\\
\;\;\;\;\mathsf{fma}\left(1 - y, z, \mathsf{fma}\left(1 - t, a, x\right)\right)\\
\mathbf{elif}\;b \leq 2.7 \cdot 10^{+72}:\\
\;\;\;\;\mathsf{fma}\left(b - z, y, \left(t - 2\right) \cdot b\right) + x\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -2.35e39 or 2.7000000000000001e72 < b Initial program 90.3%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6486.9
Applied rewrites86.9%
Taylor expanded in y around 0
Applied rewrites84.4%
if -2.35e39 < b < 9.20000000000000035e-26Initial program 100.0%
Taylor expanded in x around 0
Applied rewrites100.0%
Taylor expanded in b around 0
sub-negN/A
+-commutativeN/A
Applied rewrites93.8%
if 9.20000000000000035e-26 < b < 2.7000000000000001e72Initial program 96.3%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6483.8
Applied rewrites83.8%
Taylor expanded in t around 0
Applied rewrites66.6%
Taylor expanded in y around 0
Applied rewrites83.8%
Taylor expanded in z around 0
Applied rewrites84.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (fma (- 1.0 t) a x)))
(if (<= a -8.5e+143)
t_1
(if (<= a 6400000000000.0)
(fma 1.0 z (fma (- (+ t y) 2.0) b x))
(if (<= a 1.08e+164) (fma (- 1.0 y) z (fma (- y 2.0) b x)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = fma((1.0 - t), a, x);
double tmp;
if (a <= -8.5e+143) {
tmp = t_1;
} else if (a <= 6400000000000.0) {
tmp = fma(1.0, z, fma(((t + y) - 2.0), b, x));
} else if (a <= 1.08e+164) {
tmp = fma((1.0 - y), z, fma((y - 2.0), b, x));
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = fma(Float64(1.0 - t), a, x) tmp = 0.0 if (a <= -8.5e+143) tmp = t_1; elseif (a <= 6400000000000.0) tmp = fma(1.0, z, fma(Float64(Float64(t + y) - 2.0), b, x)); elseif (a <= 1.08e+164) tmp = fma(Float64(1.0 - y), z, fma(Float64(y - 2.0), b, x)); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision]}, If[LessEqual[a, -8.5e+143], t$95$1, If[LessEqual[a, 6400000000000.0], N[(1.0 * z + N[(N[(N[(t + y), $MachinePrecision] - 2.0), $MachinePrecision] * b + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.08e+164], N[(N[(1.0 - y), $MachinePrecision] * z + N[(N[(y - 2.0), $MachinePrecision] * b + x), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(1 - t, a, x\right)\\
\mathbf{if}\;a \leq -8.5 \cdot 10^{+143}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 6400000000000:\\
\;\;\;\;\mathsf{fma}\left(1, z, \mathsf{fma}\left(\left(t + y\right) - 2, b, x\right)\right)\\
\mathbf{elif}\;a \leq 1.08 \cdot 10^{+164}:\\
\;\;\;\;\mathsf{fma}\left(1 - y, z, \mathsf{fma}\left(y - 2, b, x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -8.4999999999999998e143 or 1.08e164 < a Initial program 90.9%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6485.3
Applied rewrites85.3%
Taylor expanded in b around 0
Applied rewrites83.1%
if -8.4999999999999998e143 < a < 6.4e12Initial program 96.8%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6494.7
Applied rewrites94.7%
Taylor expanded in y around 0
Applied rewrites80.2%
if 6.4e12 < a < 1.08e164Initial program 96.8%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6479.6
Applied rewrites79.6%
Taylor expanded in t around 0
Applied rewrites76.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (fma (- 1.0 t) a x)))
(if (<= a -8.5e+143)
t_1
(if (<= a 6400000000000.0)
(fma 1.0 z (fma (- (+ t y) 2.0) b x))
(if (<= a 1.08e+164) (+ (fma (- b z) y (fma -2.0 b z)) x) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = fma((1.0 - t), a, x);
double tmp;
if (a <= -8.5e+143) {
tmp = t_1;
} else if (a <= 6400000000000.0) {
tmp = fma(1.0, z, fma(((t + y) - 2.0), b, x));
} else if (a <= 1.08e+164) {
tmp = fma((b - z), y, fma(-2.0, b, z)) + x;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = fma(Float64(1.0 - t), a, x) tmp = 0.0 if (a <= -8.5e+143) tmp = t_1; elseif (a <= 6400000000000.0) tmp = fma(1.0, z, fma(Float64(Float64(t + y) - 2.0), b, x)); elseif (a <= 1.08e+164) tmp = Float64(fma(Float64(b - z), y, fma(-2.0, b, z)) + x); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision]}, If[LessEqual[a, -8.5e+143], t$95$1, If[LessEqual[a, 6400000000000.0], N[(1.0 * z + N[(N[(N[(t + y), $MachinePrecision] - 2.0), $MachinePrecision] * b + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.08e+164], N[(N[(N[(b - z), $MachinePrecision] * y + N[(-2.0 * b + z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(1 - t, a, x\right)\\
\mathbf{if}\;a \leq -8.5 \cdot 10^{+143}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 6400000000000:\\
\;\;\;\;\mathsf{fma}\left(1, z, \mathsf{fma}\left(\left(t + y\right) - 2, b, x\right)\right)\\
\mathbf{elif}\;a \leq 1.08 \cdot 10^{+164}:\\
\;\;\;\;\mathsf{fma}\left(b - z, y, \mathsf{fma}\left(-2, b, z\right)\right) + x\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -8.4999999999999998e143 or 1.08e164 < a Initial program 90.9%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6485.3
Applied rewrites85.3%
Taylor expanded in b around 0
Applied rewrites83.1%
if -8.4999999999999998e143 < a < 6.4e12Initial program 96.8%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6494.7
Applied rewrites94.7%
Taylor expanded in y around 0
Applied rewrites80.2%
if 6.4e12 < a < 1.08e164Initial program 96.8%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6479.6
Applied rewrites79.6%
Taylor expanded in t around 0
Applied rewrites76.4%
Taylor expanded in y around 0
Applied rewrites76.4%
Taylor expanded in t around 0
Applied rewrites76.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (fma (- 1.0 y) z x)) (t_2 (* (- b a) t)))
(if (<= t -2.15e+129)
t_2
(if (<= t -7e-39)
t_1
(if (<= t -1.5e-297)
(fma (- y 2.0) b a)
(if (<= t 3.5e+35) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = fma((1.0 - y), z, x);
double t_2 = (b - a) * t;
double tmp;
if (t <= -2.15e+129) {
tmp = t_2;
} else if (t <= -7e-39) {
tmp = t_1;
} else if (t <= -1.5e-297) {
tmp = fma((y - 2.0), b, a);
} else if (t <= 3.5e+35) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = fma(Float64(1.0 - y), z, x) t_2 = Float64(Float64(b - a) * t) tmp = 0.0 if (t <= -2.15e+129) tmp = t_2; elseif (t <= -7e-39) tmp = t_1; elseif (t <= -1.5e-297) tmp = fma(Float64(y - 2.0), b, a); elseif (t <= 3.5e+35) tmp = t_1; else tmp = t_2; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(1.0 - y), $MachinePrecision] * z + x), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b - a), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[t, -2.15e+129], t$95$2, If[LessEqual[t, -7e-39], t$95$1, If[LessEqual[t, -1.5e-297], N[(N[(y - 2.0), $MachinePrecision] * b + a), $MachinePrecision], If[LessEqual[t, 3.5e+35], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(1 - y, z, x\right)\\
t_2 := \left(b - a\right) \cdot t\\
\mathbf{if}\;t \leq -2.15 \cdot 10^{+129}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -7 \cdot 10^{-39}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.5 \cdot 10^{-297}:\\
\;\;\;\;\mathsf{fma}\left(y - 2, b, a\right)\\
\mathbf{elif}\;t \leq 3.5 \cdot 10^{+35}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -2.1500000000000001e129 or 3.5000000000000001e35 < t Initial program 90.4%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6476.4
Applied rewrites76.4%
if -2.1500000000000001e129 < t < -6.99999999999999999e-39 or -1.49999999999999997e-297 < t < 3.5000000000000001e35Initial program 98.2%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6483.7
Applied rewrites83.7%
Taylor expanded in b around 0
Applied rewrites62.8%
if -6.99999999999999999e-39 < t < -1.49999999999999997e-297Initial program 100.0%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6474.8
Applied rewrites74.8%
Taylor expanded in t around 0
Applied rewrites74.8%
Taylor expanded in x around 0
Applied rewrites63.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (- b a) t)))
(if (<= t -2.15e+129)
t_1
(if (<= t -1.3e+20)
(* (- b z) y)
(if (<= t -1.55e-37)
(+ a x)
(if (<= t 3.4e+39) (fma (- y 2.0) b a) t_1))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (b - a) * t;
double tmp;
if (t <= -2.15e+129) {
tmp = t_1;
} else if (t <= -1.3e+20) {
tmp = (b - z) * y;
} else if (t <= -1.55e-37) {
tmp = a + x;
} else if (t <= 3.4e+39) {
tmp = fma((y - 2.0), b, a);
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(b - a) * t) tmp = 0.0 if (t <= -2.15e+129) tmp = t_1; elseif (t <= -1.3e+20) tmp = Float64(Float64(b - z) * y); elseif (t <= -1.55e-37) tmp = Float64(a + x); elseif (t <= 3.4e+39) tmp = fma(Float64(y - 2.0), b, a); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - a), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[t, -2.15e+129], t$95$1, If[LessEqual[t, -1.3e+20], N[(N[(b - z), $MachinePrecision] * y), $MachinePrecision], If[LessEqual[t, -1.55e-37], N[(a + x), $MachinePrecision], If[LessEqual[t, 3.4e+39], N[(N[(y - 2.0), $MachinePrecision] * b + a), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(b - a\right) \cdot t\\
\mathbf{if}\;t \leq -2.15 \cdot 10^{+129}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.3 \cdot 10^{+20}:\\
\;\;\;\;\left(b - z\right) \cdot y\\
\mathbf{elif}\;t \leq -1.55 \cdot 10^{-37}:\\
\;\;\;\;a + x\\
\mathbf{elif}\;t \leq 3.4 \cdot 10^{+39}:\\
\;\;\;\;\mathsf{fma}\left(y - 2, b, a\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -2.1500000000000001e129 or 3.3999999999999999e39 < t Initial program 90.1%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6477.5
Applied rewrites77.5%
if -2.1500000000000001e129 < t < -1.3e20Initial program 100.0%
Taylor expanded in y around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6460.1
Applied rewrites60.1%
if -1.3e20 < t < -1.54999999999999997e-37Initial program 100.0%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6472.9
Applied rewrites72.9%
Taylor expanded in b around 0
Applied rewrites73.4%
Taylor expanded in t around 0
Applied rewrites53.8%
if -1.54999999999999997e-37 < t < 3.3999999999999999e39Initial program 98.2%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6471.7
Applied rewrites71.7%
Taylor expanded in t around 0
Applied rewrites69.9%
Taylor expanded in x around 0
Applied rewrites51.1%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -1.95e+110)
(+ (fma (- b z) y (fma (- t 2.0) b z)) x)
(if (<= z 4.2e+159)
(fma (- 1.0 t) a (fma (- (+ t y) 2.0) b x))
(fma (- 1.0 y) z (fma (- 1.0 t) a x)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.95e+110) {
tmp = fma((b - z), y, fma((t - 2.0), b, z)) + x;
} else if (z <= 4.2e+159) {
tmp = fma((1.0 - t), a, fma(((t + y) - 2.0), b, x));
} else {
tmp = fma((1.0 - y), z, fma((1.0 - t), a, x));
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -1.95e+110) tmp = Float64(fma(Float64(b - z), y, fma(Float64(t - 2.0), b, z)) + x); elseif (z <= 4.2e+159) tmp = fma(Float64(1.0 - t), a, fma(Float64(Float64(t + y) - 2.0), b, x)); else tmp = fma(Float64(1.0 - y), z, fma(Float64(1.0 - t), a, x)); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -1.95e+110], N[(N[(N[(b - z), $MachinePrecision] * y + N[(N[(t - 2.0), $MachinePrecision] * b + z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 4.2e+159], N[(N[(1.0 - t), $MachinePrecision] * a + N[(N[(N[(t + y), $MachinePrecision] - 2.0), $MachinePrecision] * b + x), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 - y), $MachinePrecision] * z + N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.95 \cdot 10^{+110}:\\
\;\;\;\;\mathsf{fma}\left(b - z, y, \mathsf{fma}\left(t - 2, b, z\right)\right) + x\\
\mathbf{elif}\;z \leq 4.2 \cdot 10^{+159}:\\
\;\;\;\;\mathsf{fma}\left(1 - t, a, \mathsf{fma}\left(\left(t + y\right) - 2, b, x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(1 - y, z, \mathsf{fma}\left(1 - t, a, x\right)\right)\\
\end{array}
\end{array}
if z < -1.9500000000000002e110Initial program 89.4%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6490.3
Applied rewrites90.3%
Taylor expanded in t around 0
Applied rewrites78.2%
Taylor expanded in y around 0
Applied rewrites92.5%
if -1.9500000000000002e110 < z < 4.19999999999999978e159Initial program 97.7%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6493.2
Applied rewrites93.2%
if 4.19999999999999978e159 < z Initial program 91.2%
Taylor expanded in x around 0
Applied rewrites91.1%
Taylor expanded in b around 0
sub-negN/A
+-commutativeN/A
Applied rewrites91.2%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -1.95e+110)
(+ (fma (- b z) y (fma (- t 2.0) b z)) x)
(if (<= z 8e+159)
(+ (fma (- y 2.0) b x) (fma (- b a) t a))
(fma (- 1.0 y) z (fma (- 1.0 t) a x)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.95e+110) {
tmp = fma((b - z), y, fma((t - 2.0), b, z)) + x;
} else if (z <= 8e+159) {
tmp = fma((y - 2.0), b, x) + fma((b - a), t, a);
} else {
tmp = fma((1.0 - y), z, fma((1.0 - t), a, x));
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -1.95e+110) tmp = Float64(fma(Float64(b - z), y, fma(Float64(t - 2.0), b, z)) + x); elseif (z <= 8e+159) tmp = Float64(fma(Float64(y - 2.0), b, x) + fma(Float64(b - a), t, a)); else tmp = fma(Float64(1.0 - y), z, fma(Float64(1.0 - t), a, x)); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -1.95e+110], N[(N[(N[(b - z), $MachinePrecision] * y + N[(N[(t - 2.0), $MachinePrecision] * b + z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 8e+159], N[(N[(N[(y - 2.0), $MachinePrecision] * b + x), $MachinePrecision] + N[(N[(b - a), $MachinePrecision] * t + a), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 - y), $MachinePrecision] * z + N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.95 \cdot 10^{+110}:\\
\;\;\;\;\mathsf{fma}\left(b - z, y, \mathsf{fma}\left(t - 2, b, z\right)\right) + x\\
\mathbf{elif}\;z \leq 8 \cdot 10^{+159}:\\
\;\;\;\;\mathsf{fma}\left(y - 2, b, x\right) + \mathsf{fma}\left(b - a, t, a\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(1 - y, z, \mathsf{fma}\left(1 - t, a, x\right)\right)\\
\end{array}
\end{array}
if z < -1.9500000000000002e110Initial program 89.4%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6490.3
Applied rewrites90.3%
Taylor expanded in t around 0
Applied rewrites78.2%
Taylor expanded in y around 0
Applied rewrites92.5%
if -1.9500000000000002e110 < z < 7.9999999999999994e159Initial program 97.7%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6493.2
Applied rewrites93.2%
Taylor expanded in t around 0
Applied rewrites92.6%
if 7.9999999999999994e159 < z Initial program 91.2%
Taylor expanded in x around 0
Applied rewrites91.1%
Taylor expanded in b around 0
sub-negN/A
+-commutativeN/A
Applied rewrites91.2%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -2.8e+110)
(+ (fma (- b z) y (fma -2.0 b z)) x)
(if (<= z 8e+159)
(+ (fma (- y 2.0) b x) (fma (- b a) t a))
(fma (- 1.0 y) z (fma (- 1.0 t) a x)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -2.8e+110) {
tmp = fma((b - z), y, fma(-2.0, b, z)) + x;
} else if (z <= 8e+159) {
tmp = fma((y - 2.0), b, x) + fma((b - a), t, a);
} else {
tmp = fma((1.0 - y), z, fma((1.0 - t), a, x));
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -2.8e+110) tmp = Float64(fma(Float64(b - z), y, fma(-2.0, b, z)) + x); elseif (z <= 8e+159) tmp = Float64(fma(Float64(y - 2.0), b, x) + fma(Float64(b - a), t, a)); else tmp = fma(Float64(1.0 - y), z, fma(Float64(1.0 - t), a, x)); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -2.8e+110], N[(N[(N[(b - z), $MachinePrecision] * y + N[(-2.0 * b + z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 8e+159], N[(N[(N[(y - 2.0), $MachinePrecision] * b + x), $MachinePrecision] + N[(N[(b - a), $MachinePrecision] * t + a), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 - y), $MachinePrecision] * z + N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.8 \cdot 10^{+110}:\\
\;\;\;\;\mathsf{fma}\left(b - z, y, \mathsf{fma}\left(-2, b, z\right)\right) + x\\
\mathbf{elif}\;z \leq 8 \cdot 10^{+159}:\\
\;\;\;\;\mathsf{fma}\left(y - 2, b, x\right) + \mathsf{fma}\left(b - a, t, a\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(1 - y, z, \mathsf{fma}\left(1 - t, a, x\right)\right)\\
\end{array}
\end{array}
if z < -2.79999999999999987e110Initial program 89.4%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6490.3
Applied rewrites90.3%
Taylor expanded in t around 0
Applied rewrites78.2%
Taylor expanded in y around 0
Applied rewrites92.5%
Taylor expanded in t around 0
Applied rewrites82.4%
if -2.79999999999999987e110 < z < 7.9999999999999994e159Initial program 97.7%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6493.2
Applied rewrites93.2%
Taylor expanded in t around 0
Applied rewrites92.6%
if 7.9999999999999994e159 < z Initial program 91.2%
Taylor expanded in x around 0
Applied rewrites91.1%
Taylor expanded in b around 0
sub-negN/A
+-commutativeN/A
Applied rewrites91.2%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -2.35e+39) (not (<= b 1.25))) (fma 1.0 z (fma (- (+ t y) 2.0) b x)) (fma (- 1.0 y) z (fma (- 1.0 t) a x))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -2.35e+39) || !(b <= 1.25)) {
tmp = fma(1.0, z, fma(((t + y) - 2.0), b, x));
} else {
tmp = fma((1.0 - y), z, fma((1.0 - t), a, x));
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -2.35e+39) || !(b <= 1.25)) tmp = fma(1.0, z, fma(Float64(Float64(t + y) - 2.0), b, x)); else tmp = fma(Float64(1.0 - y), z, fma(Float64(1.0 - t), a, x)); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -2.35e+39], N[Not[LessEqual[b, 1.25]], $MachinePrecision]], N[(1.0 * z + N[(N[(N[(t + y), $MachinePrecision] - 2.0), $MachinePrecision] * b + x), $MachinePrecision]), $MachinePrecision], N[(N[(1.0 - y), $MachinePrecision] * z + N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -2.35 \cdot 10^{+39} \lor \neg \left(b \leq 1.25\right):\\
\;\;\;\;\mathsf{fma}\left(1, z, \mathsf{fma}\left(\left(t + y\right) - 2, b, x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(1 - y, z, \mathsf{fma}\left(1 - t, a, x\right)\right)\\
\end{array}
\end{array}
if b < -2.35e39 or 1.25 < b Initial program 91.0%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6485.9
Applied rewrites85.9%
Taylor expanded in y around 0
Applied rewrites81.7%
if -2.35e39 < b < 1.25Initial program 100.0%
Taylor expanded in x around 0
Applied rewrites100.0%
Taylor expanded in b around 0
sub-negN/A
+-commutativeN/A
Applied rewrites92.6%
Final simplification86.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -4.3e+129) (not (<= t 1.4e+61))) (* (- b a) t) (+ (fma (- b z) y (fma -2.0 b z)) x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -4.3e+129) || !(t <= 1.4e+61)) {
tmp = (b - a) * t;
} else {
tmp = fma((b - z), y, fma(-2.0, b, z)) + x;
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -4.3e+129) || !(t <= 1.4e+61)) tmp = Float64(Float64(b - a) * t); else tmp = Float64(fma(Float64(b - z), y, fma(-2.0, b, z)) + x); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -4.3e+129], N[Not[LessEqual[t, 1.4e+61]], $MachinePrecision]], N[(N[(b - a), $MachinePrecision] * t), $MachinePrecision], N[(N[(N[(b - z), $MachinePrecision] * y + N[(-2.0 * b + z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.3 \cdot 10^{+129} \lor \neg \left(t \leq 1.4 \cdot 10^{+61}\right):\\
\;\;\;\;\left(b - a\right) \cdot t\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(b - z, y, \mathsf{fma}\left(-2, b, z\right)\right) + x\\
\end{array}
\end{array}
if t < -4.30000000000000021e129 or 1.4000000000000001e61 < t Initial program 89.9%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6478.1
Applied rewrites78.1%
if -4.30000000000000021e129 < t < 1.4000000000000001e61Initial program 98.7%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6481.4
Applied rewrites81.4%
Taylor expanded in t around 0
Applied rewrites78.2%
Taylor expanded in y around 0
Applied rewrites81.4%
Taylor expanded in t around 0
Applied rewrites78.9%
Final simplification78.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (- b a) t)))
(if (<= t -2.55e+129)
t_1
(if (<= t -1.55e-108)
(fma (- y) z (fma (- y 2.0) b x))
(if (<= t 3.4e+58) (fma (- y 2.0) b (+ a x)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (b - a) * t;
double tmp;
if (t <= -2.55e+129) {
tmp = t_1;
} else if (t <= -1.55e-108) {
tmp = fma(-y, z, fma((y - 2.0), b, x));
} else if (t <= 3.4e+58) {
tmp = fma((y - 2.0), b, (a + x));
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(b - a) * t) tmp = 0.0 if (t <= -2.55e+129) tmp = t_1; elseif (t <= -1.55e-108) tmp = fma(Float64(-y), z, fma(Float64(y - 2.0), b, x)); elseif (t <= 3.4e+58) tmp = fma(Float64(y - 2.0), b, Float64(a + x)); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - a), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[t, -2.55e+129], t$95$1, If[LessEqual[t, -1.55e-108], N[((-y) * z + N[(N[(y - 2.0), $MachinePrecision] * b + x), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.4e+58], N[(N[(y - 2.0), $MachinePrecision] * b + N[(a + x), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(b - a\right) \cdot t\\
\mathbf{if}\;t \leq -2.55 \cdot 10^{+129}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.55 \cdot 10^{-108}:\\
\;\;\;\;\mathsf{fma}\left(-y, z, \mathsf{fma}\left(y - 2, b, x\right)\right)\\
\mathbf{elif}\;t \leq 3.4 \cdot 10^{+58}:\\
\;\;\;\;\mathsf{fma}\left(y - 2, b, a + x\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -2.54999999999999998e129 or 3.4000000000000001e58 < t Initial program 89.9%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6478.1
Applied rewrites78.1%
if -2.54999999999999998e129 < t < -1.55000000000000007e-108Initial program 100.0%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6487.8
Applied rewrites87.8%
Taylor expanded in t around 0
Applied rewrites82.4%
Taylor expanded in y around inf
Applied rewrites74.9%
if -1.55000000000000007e-108 < t < 3.4000000000000001e58Initial program 98.0%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6472.8
Applied rewrites72.8%
Taylor expanded in t around 0
Applied rewrites69.9%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (- b z) y)))
(if (<= y -6.6e+165)
t_1
(if (<= y -1.25e+17)
(fma (- 1.0 t) a x)
(if (<= y 1.95e+17) (+ (fma (- t 2.0) b z) x) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (b - z) * y;
double tmp;
if (y <= -6.6e+165) {
tmp = t_1;
} else if (y <= -1.25e+17) {
tmp = fma((1.0 - t), a, x);
} else if (y <= 1.95e+17) {
tmp = fma((t - 2.0), b, z) + x;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(b - z) * y) tmp = 0.0 if (y <= -6.6e+165) tmp = t_1; elseif (y <= -1.25e+17) tmp = fma(Float64(1.0 - t), a, x); elseif (y <= 1.95e+17) tmp = Float64(fma(Float64(t - 2.0), b, z) + x); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - z), $MachinePrecision] * y), $MachinePrecision]}, If[LessEqual[y, -6.6e+165], t$95$1, If[LessEqual[y, -1.25e+17], N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision], If[LessEqual[y, 1.95e+17], N[(N[(N[(t - 2.0), $MachinePrecision] * b + z), $MachinePrecision] + x), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(b - z\right) \cdot y\\
\mathbf{if}\;y \leq -6.6 \cdot 10^{+165}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -1.25 \cdot 10^{+17}:\\
\;\;\;\;\mathsf{fma}\left(1 - t, a, x\right)\\
\mathbf{elif}\;y \leq 1.95 \cdot 10^{+17}:\\
\;\;\;\;\mathsf{fma}\left(t - 2, b, z\right) + x\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -6.5999999999999997e165 or 1.95e17 < y Initial program 90.6%
Taylor expanded in y around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6473.3
Applied rewrites73.3%
if -6.5999999999999997e165 < y < -1.25e17Initial program 92.2%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6483.5
Applied rewrites83.5%
Taylor expanded in b around 0
Applied rewrites63.1%
if -1.25e17 < y < 1.95e17Initial program 99.3%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6475.0
Applied rewrites75.0%
Taylor expanded in t around 0
Applied rewrites51.2%
Taylor expanded in y around 0
Applied rewrites74.0%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (- b a) t)))
(if (<= t -2.15e+129)
t_1
(if (<= t -1.55e-37)
(fma (- 1.0 y) z x)
(if (<= t 3.4e+58) (fma (- y 2.0) b (+ a x)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (b - a) * t;
double tmp;
if (t <= -2.15e+129) {
tmp = t_1;
} else if (t <= -1.55e-37) {
tmp = fma((1.0 - y), z, x);
} else if (t <= 3.4e+58) {
tmp = fma((y - 2.0), b, (a + x));
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(b - a) * t) tmp = 0.0 if (t <= -2.15e+129) tmp = t_1; elseif (t <= -1.55e-37) tmp = fma(Float64(1.0 - y), z, x); elseif (t <= 3.4e+58) tmp = fma(Float64(y - 2.0), b, Float64(a + x)); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - a), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[t, -2.15e+129], t$95$1, If[LessEqual[t, -1.55e-37], N[(N[(1.0 - y), $MachinePrecision] * z + x), $MachinePrecision], If[LessEqual[t, 3.4e+58], N[(N[(y - 2.0), $MachinePrecision] * b + N[(a + x), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(b - a\right) \cdot t\\
\mathbf{if}\;t \leq -2.15 \cdot 10^{+129}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.55 \cdot 10^{-37}:\\
\;\;\;\;\mathsf{fma}\left(1 - y, z, x\right)\\
\mathbf{elif}\;t \leq 3.4 \cdot 10^{+58}:\\
\;\;\;\;\mathsf{fma}\left(y - 2, b, a + x\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -2.1500000000000001e129 or 3.4000000000000001e58 < t Initial program 89.9%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6478.1
Applied rewrites78.1%
if -2.1500000000000001e129 < t < -1.54999999999999997e-37Initial program 100.0%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6486.7
Applied rewrites86.7%
Taylor expanded in b around 0
Applied rewrites62.9%
if -1.54999999999999997e-37 < t < 3.4000000000000001e58Initial program 98.2%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6472.2
Applied rewrites72.2%
Taylor expanded in t around 0
Applied rewrites69.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (- b a) t)))
(if (<= t -9.6e+100)
t_1
(if (<= t -5.2e-202)
(* (- 1.0 y) z)
(if (<= t 25500000.0) (+ a x) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (b - a) * t;
double tmp;
if (t <= -9.6e+100) {
tmp = t_1;
} else if (t <= -5.2e-202) {
tmp = (1.0 - y) * z;
} else if (t <= 25500000.0) {
tmp = a + x;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (b - a) * t
if (t <= (-9.6d+100)) then
tmp = t_1
else if (t <= (-5.2d-202)) then
tmp = (1.0d0 - y) * z
else if (t <= 25500000.0d0) then
tmp = a + x
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 b) {
double t_1 = (b - a) * t;
double tmp;
if (t <= -9.6e+100) {
tmp = t_1;
} else if (t <= -5.2e-202) {
tmp = (1.0 - y) * z;
} else if (t <= 25500000.0) {
tmp = a + x;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (b - a) * t tmp = 0 if t <= -9.6e+100: tmp = t_1 elif t <= -5.2e-202: tmp = (1.0 - y) * z elif t <= 25500000.0: tmp = a + x else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(b - a) * t) tmp = 0.0 if (t <= -9.6e+100) tmp = t_1; elseif (t <= -5.2e-202) tmp = Float64(Float64(1.0 - y) * z); elseif (t <= 25500000.0) tmp = Float64(a + x); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (b - a) * t; tmp = 0.0; if (t <= -9.6e+100) tmp = t_1; elseif (t <= -5.2e-202) tmp = (1.0 - y) * z; elseif (t <= 25500000.0) tmp = a + x; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - a), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[t, -9.6e+100], t$95$1, If[LessEqual[t, -5.2e-202], N[(N[(1.0 - y), $MachinePrecision] * z), $MachinePrecision], If[LessEqual[t, 25500000.0], N[(a + x), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(b - a\right) \cdot t\\
\mathbf{if}\;t \leq -9.6 \cdot 10^{+100}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -5.2 \cdot 10^{-202}:\\
\;\;\;\;\left(1 - y\right) \cdot z\\
\mathbf{elif}\;t \leq 25500000:\\
\;\;\;\;a + x\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -9.60000000000000046e100 or 2.55e7 < t Initial program 91.2%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6472.1
Applied rewrites72.1%
if -9.60000000000000046e100 < t < -5.20000000000000019e-202Initial program 100.0%
Taylor expanded in z around inf
*-commutativeN/A
sub-negN/A
neg-mul-1N/A
+-commutativeN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
sub-negN/A
lower-*.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f6440.4
Applied rewrites40.4%
if -5.20000000000000019e-202 < t < 2.55e7Initial program 97.6%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6471.5
Applied rewrites71.5%
Taylor expanded in b around 0
Applied rewrites45.6%
Taylor expanded in t around 0
Applied rewrites45.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (- z) y)))
(if (<= y -1.6e+162)
t_1
(if (<= y 3.3e+22) (fma (- t) a x) (if (<= y 5.1e+150) t_1 (* b y))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = -z * y;
double tmp;
if (y <= -1.6e+162) {
tmp = t_1;
} else if (y <= 3.3e+22) {
tmp = fma(-t, a, x);
} else if (y <= 5.1e+150) {
tmp = t_1;
} else {
tmp = b * y;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(-z) * y) tmp = 0.0 if (y <= -1.6e+162) tmp = t_1; elseif (y <= 3.3e+22) tmp = fma(Float64(-t), a, x); elseif (y <= 5.1e+150) tmp = t_1; else tmp = Float64(b * y); end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[((-z) * y), $MachinePrecision]}, If[LessEqual[y, -1.6e+162], t$95$1, If[LessEqual[y, 3.3e+22], N[((-t) * a + x), $MachinePrecision], If[LessEqual[y, 5.1e+150], t$95$1, N[(b * y), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(-z\right) \cdot y\\
\mathbf{if}\;y \leq -1.6 \cdot 10^{+162}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 3.3 \cdot 10^{+22}:\\
\;\;\;\;\mathsf{fma}\left(-t, a, x\right)\\
\mathbf{elif}\;y \leq 5.1 \cdot 10^{+150}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;b \cdot y\\
\end{array}
\end{array}
if y < -1.6000000000000001e162 or 3.2999999999999998e22 < y < 5.1000000000000001e150Initial program 93.7%
Taylor expanded in y around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6468.6
Applied rewrites68.6%
Taylor expanded in z around inf
Applied rewrites45.6%
if -1.6000000000000001e162 < y < 3.2999999999999998e22Initial program 97.5%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6482.3
Applied rewrites82.3%
Taylor expanded in b around 0
Applied rewrites54.4%
Taylor expanded in t around inf
Applied rewrites44.5%
if 5.1000000000000001e150 < y Initial program 87.5%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6475.9
Applied rewrites75.9%
Taylor expanded in y around inf
Applied rewrites61.0%
(FPCore (x y z t a b) :precision binary64 (if (<= t -1.7e+103) (* b t) (if (<= t -3.6e+21) (* (- z) y) (if (<= t 38000000.0) (+ a x) (* b t)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -1.7e+103) {
tmp = b * t;
} else if (t <= -3.6e+21) {
tmp = -z * y;
} else if (t <= 38000000.0) {
tmp = a + x;
} else {
tmp = b * t;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (t <= (-1.7d+103)) then
tmp = b * t
else if (t <= (-3.6d+21)) then
tmp = -z * y
else if (t <= 38000000.0d0) then
tmp = a + x
else
tmp = b * t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -1.7e+103) {
tmp = b * t;
} else if (t <= -3.6e+21) {
tmp = -z * y;
} else if (t <= 38000000.0) {
tmp = a + x;
} else {
tmp = b * t;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -1.7e+103: tmp = b * t elif t <= -3.6e+21: tmp = -z * y elif t <= 38000000.0: tmp = a + x else: tmp = b * t return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -1.7e+103) tmp = Float64(b * t); elseif (t <= -3.6e+21) tmp = Float64(Float64(-z) * y); elseif (t <= 38000000.0) tmp = Float64(a + x); else tmp = Float64(b * t); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -1.7e+103) tmp = b * t; elseif (t <= -3.6e+21) tmp = -z * y; elseif (t <= 38000000.0) tmp = a + x; else tmp = b * t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -1.7e+103], N[(b * t), $MachinePrecision], If[LessEqual[t, -3.6e+21], N[((-z) * y), $MachinePrecision], If[LessEqual[t, 38000000.0], N[(a + x), $MachinePrecision], N[(b * t), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.7 \cdot 10^{+103}:\\
\;\;\;\;b \cdot t\\
\mathbf{elif}\;t \leq -3.6 \cdot 10^{+21}:\\
\;\;\;\;\left(-z\right) \cdot y\\
\mathbf{elif}\;t \leq 38000000:\\
\;\;\;\;a + x\\
\mathbf{else}:\\
\;\;\;\;b \cdot t\\
\end{array}
\end{array}
if t < -1.6999999999999999e103 or 3.8e7 < t Initial program 91.2%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6471.6
Applied rewrites71.6%
Taylor expanded in t around 0
Applied rewrites35.2%
Taylor expanded in t around inf
Applied rewrites43.3%
if -1.6999999999999999e103 < t < -3.6e21Initial program 100.0%
Taylor expanded in y around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6466.2
Applied rewrites66.2%
Taylor expanded in z around inf
Applied rewrites43.4%
if -3.6e21 < t < 3.8e7Initial program 98.3%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6471.2
Applied rewrites71.2%
Taylor expanded in b around 0
Applied rewrites42.3%
Taylor expanded in t around 0
Applied rewrites40.5%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -6.6e+165) (not (<= y 6.5e+33))) (* (- b z) y) (fma (- 1.0 t) a x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -6.6e+165) || !(y <= 6.5e+33)) {
tmp = (b - z) * y;
} else {
tmp = fma((1.0 - t), a, x);
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -6.6e+165) || !(y <= 6.5e+33)) tmp = Float64(Float64(b - z) * y); else tmp = fma(Float64(1.0 - t), a, x); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -6.6e+165], N[Not[LessEqual[y, 6.5e+33]], $MachinePrecision]], N[(N[(b - z), $MachinePrecision] * y), $MachinePrecision], N[(N[(1.0 - t), $MachinePrecision] * a + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.6 \cdot 10^{+165} \lor \neg \left(y \leq 6.5 \cdot 10^{+33}\right):\\
\;\;\;\;\left(b - z\right) \cdot y\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(1 - t, a, x\right)\\
\end{array}
\end{array}
if y < -6.5999999999999997e165 or 6.49999999999999993e33 < y Initial program 91.1%
Taylor expanded in y around inf
*-commutativeN/A
lower-*.f64N/A
lower--.f6476.0
Applied rewrites76.0%
if -6.5999999999999997e165 < y < 6.49999999999999993e33Initial program 97.6%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6482.1
Applied rewrites82.1%
Taylor expanded in b around 0
Applied rewrites54.3%
Final simplification61.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -6.1e+118) (not (<= z 1.4e+165))) (* (- 1.0 y) z) (fma (- t) a x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -6.1e+118) || !(z <= 1.4e+165)) {
tmp = (1.0 - y) * z;
} else {
tmp = fma(-t, a, x);
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -6.1e+118) || !(z <= 1.4e+165)) tmp = Float64(Float64(1.0 - y) * z); else tmp = fma(Float64(-t), a, x); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -6.1e+118], N[Not[LessEqual[z, 1.4e+165]], $MachinePrecision]], N[(N[(1.0 - y), $MachinePrecision] * z), $MachinePrecision], N[((-t) * a + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.1 \cdot 10^{+118} \lor \neg \left(z \leq 1.4 \cdot 10^{+165}\right):\\
\;\;\;\;\left(1 - y\right) \cdot z\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(-t, a, x\right)\\
\end{array}
\end{array}
if z < -6.1000000000000003e118 or 1.3999999999999999e165 < z Initial program 90.7%
Taylor expanded in z around inf
*-commutativeN/A
sub-negN/A
neg-mul-1N/A
+-commutativeN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
sub-negN/A
lower-*.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f6470.0
Applied rewrites70.0%
if -6.1000000000000003e118 < z < 1.3999999999999999e165Initial program 97.2%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6491.8
Applied rewrites91.8%
Taylor expanded in b around 0
Applied rewrites53.3%
Taylor expanded in t around inf
Applied rewrites42.4%
Final simplification50.5%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -1.65e+129) (not (<= t 38000000.0))) (* b t) (+ a x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -1.65e+129) || !(t <= 38000000.0)) {
tmp = b * t;
} else {
tmp = a + x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if ((t <= (-1.65d+129)) .or. (.not. (t <= 38000000.0d0))) then
tmp = b * t
else
tmp = a + x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -1.65e+129) || !(t <= 38000000.0)) {
tmp = b * t;
} else {
tmp = a + x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -1.65e+129) or not (t <= 38000000.0): tmp = b * t else: tmp = a + x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -1.65e+129) || !(t <= 38000000.0)) tmp = Float64(b * t); else tmp = Float64(a + x); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -1.65e+129) || ~((t <= 38000000.0))) tmp = b * t; else tmp = a + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -1.65e+129], N[Not[LessEqual[t, 38000000.0]], $MachinePrecision]], N[(b * t), $MachinePrecision], N[(a + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.65 \cdot 10^{+129} \lor \neg \left(t \leq 38000000\right):\\
\;\;\;\;b \cdot t\\
\mathbf{else}:\\
\;\;\;\;a + x\\
\end{array}
\end{array}
if t < -1.64999999999999995e129 or 3.8e7 < t Initial program 90.6%
Taylor expanded in a around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6469.7
Applied rewrites69.7%
Taylor expanded in t around 0
Applied rewrites32.9%
Taylor expanded in t around inf
Applied rewrites44.1%
if -1.64999999999999995e129 < t < 3.8e7Initial program 98.6%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6469.1
Applied rewrites69.1%
Taylor expanded in b around 0
Applied rewrites39.5%
Taylor expanded in t around 0
Applied rewrites35.6%
Final simplification39.1%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -6.6e+165) (not (<= y 1.25e+63))) (* b y) (+ a x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -6.6e+165) || !(y <= 1.25e+63)) {
tmp = b * y;
} else {
tmp = a + x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if ((y <= (-6.6d+165)) .or. (.not. (y <= 1.25d+63))) then
tmp = b * y
else
tmp = a + x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -6.6e+165) || !(y <= 1.25e+63)) {
tmp = b * y;
} else {
tmp = a + x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -6.6e+165) or not (y <= 1.25e+63): tmp = b * y else: tmp = a + x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -6.6e+165) || !(y <= 1.25e+63)) tmp = Float64(b * y); else tmp = Float64(a + x); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -6.6e+165) || ~((y <= 1.25e+63))) tmp = b * y; else tmp = a + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -6.6e+165], N[Not[LessEqual[y, 1.25e+63]], $MachinePrecision]], N[(b * y), $MachinePrecision], N[(a + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.6 \cdot 10^{+165} \lor \neg \left(y \leq 1.25 \cdot 10^{+63}\right):\\
\;\;\;\;b \cdot y\\
\mathbf{else}:\\
\;\;\;\;a + x\\
\end{array}
\end{array}
if y < -6.5999999999999997e165 or 1.25000000000000003e63 < y Initial program 90.8%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6467.5
Applied rewrites67.5%
Taylor expanded in y around inf
Applied rewrites43.5%
if -6.5999999999999997e165 < y < 1.25000000000000003e63Initial program 97.6%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6480.8
Applied rewrites80.8%
Taylor expanded in b around 0
Applied rewrites53.4%
Taylor expanded in t around 0
Applied rewrites33.4%
Final simplification36.8%
(FPCore (x y z t a b) :precision binary64 (+ a x))
double code(double x, double y, double z, double t, double a, double b) {
return a + x;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = a + x
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return a + x;
}
def code(x, y, z, t, a, b): return a + x
function code(x, y, z, t, a, b) return Float64(a + x) end
function tmp = code(x, y, z, t, a, b) tmp = a + x; end
code[x_, y_, z_, t_, a_, b_] := N[(a + x), $MachinePrecision]
\begin{array}{l}
\\
a + x
\end{array}
Initial program 95.3%
Taylor expanded in z around 0
sub-negN/A
+-commutativeN/A
*-commutativeN/A
distribute-lft-neg-inN/A
mul-1-negN/A
lower-fma.f64N/A
sub-negN/A
metadata-evalN/A
distribute-lft-inN/A
metadata-evalN/A
+-commutativeN/A
neg-mul-1N/A
sub-negN/A
lower--.f64N/A
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower--.f64N/A
lower-+.f6476.3
Applied rewrites76.3%
Taylor expanded in b around 0
Applied rewrites43.5%
Taylor expanded in t around 0
Applied rewrites25.1%
herbie shell --seed 2024324
(FPCore (x y z t a b)
:name "Statistics.Distribution.Beta:$centropy from math-functions-0.1.5.2"
:precision binary64
(+ (- (- x (* (- y 1.0) z)) (* (- t 1.0) a)) (* (- (+ y t) 2.0) b)))