
(FPCore (x y z t a b c i) :precision binary64 (+ (+ (+ (+ (+ (* x (log y)) z) t) a) (* (- b 0.5) (log c))) (* y i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((((x * log(y)) + z) + t) + a) + ((b - 0.5) * log(c))) + (y * i);
}
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
code = (((((x * log(y)) + z) + t) + a) + ((b - 0.5d0) * log(c))) + (y * i)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((((x * Math.log(y)) + z) + t) + a) + ((b - 0.5) * Math.log(c))) + (y * i);
}
def code(x, y, z, t, a, b, c, i): return (((((x * math.log(y)) + z) + t) + a) + ((b - 0.5) * math.log(c))) + (y * i)
function code(x, y, z, t, a, b, c, i) return Float64(Float64(Float64(Float64(Float64(Float64(x * log(y)) + z) + t) + a) + Float64(Float64(b - 0.5) * log(c))) + Float64(y * i)) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = (((((x * log(y)) + z) + t) + a) + ((b - 0.5) * log(c))) + (y * i); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + z), $MachinePrecision] + t), $MachinePrecision] + a), $MachinePrecision] + N[(N[(b - 0.5), $MachinePrecision] * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(x \cdot \log y + z\right) + t\right) + a\right) + \left(b - 0.5\right) \cdot \log c\right) + y \cdot i
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 19 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c i) :precision binary64 (+ (+ (+ (+ (+ (* x (log y)) z) t) a) (* (- b 0.5) (log c))) (* y i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((((x * log(y)) + z) + t) + a) + ((b - 0.5) * log(c))) + (y * i);
}
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
code = (((((x * log(y)) + z) + t) + a) + ((b - 0.5d0) * log(c))) + (y * i)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (((((x * Math.log(y)) + z) + t) + a) + ((b - 0.5) * Math.log(c))) + (y * i);
}
def code(x, y, z, t, a, b, c, i): return (((((x * math.log(y)) + z) + t) + a) + ((b - 0.5) * math.log(c))) + (y * i)
function code(x, y, z, t, a, b, c, i) return Float64(Float64(Float64(Float64(Float64(Float64(x * log(y)) + z) + t) + a) + Float64(Float64(b - 0.5) * log(c))) + Float64(y * i)) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = (((((x * log(y)) + z) + t) + a) + ((b - 0.5) * log(c))) + (y * i); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + z), $MachinePrecision] + t), $MachinePrecision] + a), $MachinePrecision] + N[(N[(b - 0.5), $MachinePrecision] * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(\left(\left(x \cdot \log y + z\right) + t\right) + a\right) + \left(b - 0.5\right) \cdot \log c\right) + y \cdot i
\end{array}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (fma y i (fma (+ b -0.5) (log c) (+ z (fma x (log y) (+ t a))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return fma(y, i, fma((b + -0.5), log(c), (z + fma(x, log(y), (t + a)))));
}
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) return fma(y, i, fma(Float64(b + -0.5), log(c), Float64(z + fma(x, log(y), Float64(t + a))))) end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(y * i + N[(N[(b + -0.5), $MachinePrecision] * N[Log[c], $MachinePrecision] + N[(z + N[(x * N[Log[y], $MachinePrecision] + N[(t + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\mathsf{fma}\left(y, i, \mathsf{fma}\left(b + -0.5, \log c, z + \mathsf{fma}\left(x, \log y, t + a\right)\right)\right)
\end{array}
Initial program 99.5%
associate-+l+99.5%
+-commutative99.5%
associate-+l+99.5%
associate-+r+99.5%
+-commutative99.5%
+-commutative99.5%
associate-+l+99.5%
associate-+l+99.5%
+-commutative99.5%
fma-define99.5%
+-commutative99.5%
fma-define99.5%
sub-neg99.5%
metadata-eval99.5%
+-commutative99.5%
Simplified99.5%
Final simplification99.5%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (* (log c) (- b 0.5))))
(if (<= y 2.7e+51)
(+ a (+ t (+ z (+ (* x (log y)) t_1))))
(+ (* y i) (+ a (+ z t_1))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = log(c) * (b - 0.5);
double tmp;
if (y <= 2.7e+51) {
tmp = a + (t + (z + ((x * log(y)) + t_1)));
} else {
tmp = (y * i) + (a + (z + t_1));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = log(c) * (b - 0.5d0)
if (y <= 2.7d+51) then
tmp = a + (t + (z + ((x * log(y)) + t_1)))
else
tmp = (y * i) + (a + (z + t_1))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = Math.log(c) * (b - 0.5);
double tmp;
if (y <= 2.7e+51) {
tmp = a + (t + (z + ((x * Math.log(y)) + t_1)));
} else {
tmp = (y * i) + (a + (z + t_1));
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): t_1 = math.log(c) * (b - 0.5) tmp = 0 if y <= 2.7e+51: tmp = a + (t + (z + ((x * math.log(y)) + t_1))) else: tmp = (y * i) + (a + (z + t_1)) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) t_1 = Float64(log(c) * Float64(b - 0.5)) tmp = 0.0 if (y <= 2.7e+51) tmp = Float64(a + Float64(t + Float64(z + Float64(Float64(x * log(y)) + t_1)))); else tmp = Float64(Float64(y * i) + Float64(a + Float64(z + t_1))); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
t_1 = log(c) * (b - 0.5);
tmp = 0.0;
if (y <= 2.7e+51)
tmp = a + (t + (z + ((x * log(y)) + t_1)));
else
tmp = (y * i) + (a + (z + t_1));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, 2.7e+51], N[(a + N[(t + N[(z + N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
t_1 := \log c \cdot \left(b - 0.5\right)\\
\mathbf{if}\;y \leq 2.7 \cdot 10^{+51}:\\
\;\;\;\;a + \left(t + \left(z + \left(x \cdot \log y + t\_1\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(a + \left(z + t\_1\right)\right)\\
\end{array}
\end{array}
if y < 2.69999999999999992e51Initial program 99.9%
Taylor expanded in y around 0 96.1%
if 2.69999999999999992e51 < y Initial program 99.0%
Taylor expanded in x around 0 91.3%
Taylor expanded in t around 0 79.1%
Final simplification89.4%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (+ (+ (* (log c) (- b 0.5)) (+ a (+ t (+ z (* x (log y)))))) (* y i)))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return ((log(c) * (b - 0.5)) + (a + (t + (z + (x * log(y)))))) + (y * i);
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
code = ((log(c) * (b - 0.5d0)) + (a + (t + (z + (x * log(y)))))) + (y * i)
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return ((Math.log(c) * (b - 0.5)) + (a + (t + (z + (x * Math.log(y)))))) + (y * i);
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): return ((math.log(c) * (b - 0.5)) + (a + (t + (z + (x * math.log(y)))))) + (y * i)
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) return Float64(Float64(Float64(log(c) * Float64(b - 0.5)) + Float64(a + Float64(t + Float64(z + Float64(x * log(y)))))) + Float64(y * i)) end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp = code(x, y, z, t, a, b, c, i)
tmp = ((log(c) * (b - 0.5)) + (a + (t + (z + (x * log(y)))))) + (y * i);
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision] + N[(a + N[(t + N[(z + N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\left(\log c \cdot \left(b - 0.5\right) + \left(a + \left(t + \left(z + x \cdot \log y\right)\right)\right)\right) + y \cdot i
\end{array}
Initial program 99.5%
Final simplification99.5%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (if (<= y 8e+51) (+ a (+ t (+ z (+ (* x (log y)) (* b (log c)))))) (+ (* y i) (+ a (+ z (* (log c) (- b 0.5)))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= 8e+51) {
tmp = a + (t + (z + ((x * log(y)) + (b * log(c)))));
} else {
tmp = (y * i) + (a + (z + (log(c) * (b - 0.5))));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if (y <= 8d+51) then
tmp = a + (t + (z + ((x * log(y)) + (b * log(c)))))
else
tmp = (y * i) + (a + (z + (log(c) * (b - 0.5d0))))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= 8e+51) {
tmp = a + (t + (z + ((x * Math.log(y)) + (b * Math.log(c)))));
} else {
tmp = (y * i) + (a + (z + (Math.log(c) * (b - 0.5))));
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= 8e+51: tmp = a + (t + (z + ((x * math.log(y)) + (b * math.log(c))))) else: tmp = (y * i) + (a + (z + (math.log(c) * (b - 0.5)))) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= 8e+51) tmp = Float64(a + Float64(t + Float64(z + Float64(Float64(x * log(y)) + Float64(b * log(c)))))); else tmp = Float64(Float64(y * i) + Float64(a + Float64(z + Float64(log(c) * Float64(b - 0.5))))); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if (y <= 8e+51)
tmp = a + (t + (z + ((x * log(y)) + (b * log(c)))));
else
tmp = (y * i) + (a + (z + (log(c) * (b - 0.5))));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, 8e+51], N[(a + N[(t + N[(z + N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq 8 \cdot 10^{+51}:\\
\;\;\;\;a + \left(t + \left(z + \left(x \cdot \log y + b \cdot \log c\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(a + \left(z + \log c \cdot \left(b - 0.5\right)\right)\right)\\
\end{array}
\end{array}
if y < 8e51Initial program 99.9%
Taylor expanded in y around 0 96.1%
Taylor expanded in b around inf 92.9%
if 8e51 < y Initial program 99.0%
Taylor expanded in x around 0 91.3%
Taylor expanded in t around 0 79.1%
Final simplification87.5%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i)
:precision binary64
(if (<= x -7.5e+180)
(+ a (+ t (+ z (* x (log y)))))
(if (<= x 9.6e+247)
(+ (* y i) (+ a (+ t (+ z (* (log c) (- b 0.5))))))
(+ (* y i) (* x (- (log y) (/ (* a (- -1.0 (/ t a))) x)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (x <= -7.5e+180) {
tmp = a + (t + (z + (x * log(y))));
} else if (x <= 9.6e+247) {
tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5)))));
} else {
tmp = (y * i) + (x * (log(y) - ((a * (-1.0 - (t / a))) / x)));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if (x <= (-7.5d+180)) then
tmp = a + (t + (z + (x * log(y))))
else if (x <= 9.6d+247) then
tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5d0)))))
else
tmp = (y * i) + (x * (log(y) - ((a * ((-1.0d0) - (t / a))) / x)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (x <= -7.5e+180) {
tmp = a + (t + (z + (x * Math.log(y))));
} else if (x <= 9.6e+247) {
tmp = (y * i) + (a + (t + (z + (Math.log(c) * (b - 0.5)))));
} else {
tmp = (y * i) + (x * (Math.log(y) - ((a * (-1.0 - (t / a))) / x)));
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if x <= -7.5e+180: tmp = a + (t + (z + (x * math.log(y)))) elif x <= 9.6e+247: tmp = (y * i) + (a + (t + (z + (math.log(c) * (b - 0.5))))) else: tmp = (y * i) + (x * (math.log(y) - ((a * (-1.0 - (t / a))) / x))) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (x <= -7.5e+180) tmp = Float64(a + Float64(t + Float64(z + Float64(x * log(y))))); elseif (x <= 9.6e+247) tmp = Float64(Float64(y * i) + Float64(a + Float64(t + Float64(z + Float64(log(c) * Float64(b - 0.5)))))); else tmp = Float64(Float64(y * i) + Float64(x * Float64(log(y) - Float64(Float64(a * Float64(-1.0 - Float64(t / a))) / x)))); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if (x <= -7.5e+180)
tmp = a + (t + (z + (x * log(y))));
elseif (x <= 9.6e+247)
tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5)))));
else
tmp = (y * i) + (x * (log(y) - ((a * (-1.0 - (t / a))) / x)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[x, -7.5e+180], N[(a + N[(t + N[(z + N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 9.6e+247], N[(N[(y * i), $MachinePrecision] + N[(a + N[(t + N[(z + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(x * N[(N[Log[y], $MachinePrecision] - N[(N[(a * N[(-1.0 - N[(t / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -7.5 \cdot 10^{+180}:\\
\;\;\;\;a + \left(t + \left(z + x \cdot \log y\right)\right)\\
\mathbf{elif}\;x \leq 9.6 \cdot 10^{+247}:\\
\;\;\;\;y \cdot i + \left(a + \left(t + \left(z + \log c \cdot \left(b - 0.5\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + x \cdot \left(\log y - \frac{a \cdot \left(-1 - \frac{t}{a}\right)}{x}\right)\\
\end{array}
\end{array}
if x < -7.5000000000000003e180Initial program 99.7%
Taylor expanded in y around 0 91.4%
Taylor expanded in x around inf 87.2%
if -7.5000000000000003e180 < x < 9.6e247Initial program 99.9%
Taylor expanded in x around 0 93.4%
if 9.6e247 < x Initial program 93.6%
Taylor expanded in a around inf 58.6%
associate-/l*58.6%
sub-neg58.6%
metadata-eval58.6%
associate-/l*58.7%
Simplified58.7%
Taylor expanded in x around inf 52.5%
associate-*r/52.5%
Simplified52.5%
Taylor expanded in x around inf 75.4%
Final simplification91.8%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (* x (log y))))
(if (<= x -1.12e+176)
(+ a (+ t (+ z t_1)))
(if (<= x 3.35e+258)
(+ (* y i) (+ a (+ t (+ z (* (log c) (- b 0.5))))))
(+ t_1 (* y i))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x * log(y);
double tmp;
if (x <= -1.12e+176) {
tmp = a + (t + (z + t_1));
} else if (x <= 3.35e+258) {
tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5)))));
} else {
tmp = t_1 + (y * i);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = x * log(y)
if (x <= (-1.12d+176)) then
tmp = a + (t + (z + t_1))
else if (x <= 3.35d+258) then
tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5d0)))))
else
tmp = t_1 + (y * i)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x * Math.log(y);
double tmp;
if (x <= -1.12e+176) {
tmp = a + (t + (z + t_1));
} else if (x <= 3.35e+258) {
tmp = (y * i) + (a + (t + (z + (Math.log(c) * (b - 0.5)))));
} else {
tmp = t_1 + (y * i);
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): t_1 = x * math.log(y) tmp = 0 if x <= -1.12e+176: tmp = a + (t + (z + t_1)) elif x <= 3.35e+258: tmp = (y * i) + (a + (t + (z + (math.log(c) * (b - 0.5))))) else: tmp = t_1 + (y * i) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) t_1 = Float64(x * log(y)) tmp = 0.0 if (x <= -1.12e+176) tmp = Float64(a + Float64(t + Float64(z + t_1))); elseif (x <= 3.35e+258) tmp = Float64(Float64(y * i) + Float64(a + Float64(t + Float64(z + Float64(log(c) * Float64(b - 0.5)))))); else tmp = Float64(t_1 + Float64(y * i)); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
t_1 = x * log(y);
tmp = 0.0;
if (x <= -1.12e+176)
tmp = a + (t + (z + t_1));
elseif (x <= 3.35e+258)
tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5)))));
else
tmp = t_1 + (y * i);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.12e+176], N[(a + N[(t + N[(z + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.35e+258], N[(N[(y * i), $MachinePrecision] + N[(a + N[(t + N[(z + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(y * i), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
t_1 := x \cdot \log y\\
\mathbf{if}\;x \leq -1.12 \cdot 10^{+176}:\\
\;\;\;\;a + \left(t + \left(z + t\_1\right)\right)\\
\mathbf{elif}\;x \leq 3.35 \cdot 10^{+258}:\\
\;\;\;\;y \cdot i + \left(a + \left(t + \left(z + \log c \cdot \left(b - 0.5\right)\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1 + y \cdot i\\
\end{array}
\end{array}
if x < -1.12e176Initial program 99.7%
Taylor expanded in y around 0 91.4%
Taylor expanded in x around inf 87.2%
if -1.12e176 < x < 3.34999999999999988e258Initial program 99.9%
Taylor expanded in x around 0 93.4%
if 3.34999999999999988e258 < x Initial program 93.1%
Taylor expanded in a around -inf 62.7%
Taylor expanded in x around inf 74.8%
mul-1-neg74.8%
*-commutative74.8%
distribute-rgt-neg-in74.8%
Simplified74.8%
Final simplification91.8%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i)
:precision binary64
(if (or (<= b -1.65e+249)
(not
(or (<= b -7.2e+206) (and (not (<= b -9.4e+188)) (<= b 1.08e+250)))))
(* b (log c))
(+ (* y i) (+ t (+ z a)))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((b <= -1.65e+249) || !((b <= -7.2e+206) || (!(b <= -9.4e+188) && (b <= 1.08e+250)))) {
tmp = b * log(c);
} else {
tmp = (y * i) + (t + (z + a));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((b <= (-1.65d+249)) .or. (.not. (b <= (-7.2d+206)) .or. (.not. (b <= (-9.4d+188))) .and. (b <= 1.08d+250))) then
tmp = b * log(c)
else
tmp = (y * i) + (t + (z + a))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((b <= -1.65e+249) || !((b <= -7.2e+206) || (!(b <= -9.4e+188) && (b <= 1.08e+250)))) {
tmp = b * Math.log(c);
} else {
tmp = (y * i) + (t + (z + a));
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if (b <= -1.65e+249) or not ((b <= -7.2e+206) or (not (b <= -9.4e+188) and (b <= 1.08e+250))): tmp = b * math.log(c) else: tmp = (y * i) + (t + (z + a)) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((b <= -1.65e+249) || !((b <= -7.2e+206) || (!(b <= -9.4e+188) && (b <= 1.08e+250)))) tmp = Float64(b * log(c)); else tmp = Float64(Float64(y * i) + Float64(t + Float64(z + a))); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if ((b <= -1.65e+249) || ~(((b <= -7.2e+206) || (~((b <= -9.4e+188)) && (b <= 1.08e+250)))))
tmp = b * log(c);
else
tmp = (y * i) + (t + (z + a));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[b, -1.65e+249], N[Not[Or[LessEqual[b, -7.2e+206], And[N[Not[LessEqual[b, -9.4e+188]], $MachinePrecision], LessEqual[b, 1.08e+250]]]], $MachinePrecision]], N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(t + N[(z + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.65 \cdot 10^{+249} \lor \neg \left(b \leq -7.2 \cdot 10^{+206} \lor \neg \left(b \leq -9.4 \cdot 10^{+188}\right) \land b \leq 1.08 \cdot 10^{+250}\right):\\
\;\;\;\;b \cdot \log c\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(t + \left(z + a\right)\right)\\
\end{array}
\end{array}
if b < -1.65000000000000007e249 or -7.20000000000000057e206 < b < -9.3999999999999995e188 or 1.08000000000000007e250 < b Initial program 99.6%
Taylor expanded in b around inf 76.4%
*-commutative76.4%
Simplified76.4%
if -1.65000000000000007e249 < b < -7.20000000000000057e206 or -9.3999999999999995e188 < b < 1.08000000000000007e250Initial program 99.5%
Taylor expanded in a around inf 76.7%
associate-/l*76.7%
sub-neg76.7%
metadata-eval76.7%
associate-/l*76.7%
Simplified76.7%
Taylor expanded in z around inf 62.9%
Taylor expanded in a around 0 75.4%
+-commutative75.4%
associate-+l+75.4%
Simplified75.4%
Final simplification75.5%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i)
:precision binary64
(if (<= (- b 0.5) -5e+145)
(+ (* y i) (* b (log c)))
(if (<= (- b 0.5) 5e+109)
(+ (* y i) (+ t (+ z a)))
(+ a (+ z (* (log c) (- b 0.5)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((b - 0.5) <= -5e+145) {
tmp = (y * i) + (b * log(c));
} else if ((b - 0.5) <= 5e+109) {
tmp = (y * i) + (t + (z + a));
} else {
tmp = a + (z + (log(c) * (b - 0.5)));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((b - 0.5d0) <= (-5d+145)) then
tmp = (y * i) + (b * log(c))
else if ((b - 0.5d0) <= 5d+109) then
tmp = (y * i) + (t + (z + a))
else
tmp = a + (z + (log(c) * (b - 0.5d0)))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((b - 0.5) <= -5e+145) {
tmp = (y * i) + (b * Math.log(c));
} else if ((b - 0.5) <= 5e+109) {
tmp = (y * i) + (t + (z + a));
} else {
tmp = a + (z + (Math.log(c) * (b - 0.5)));
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if (b - 0.5) <= -5e+145: tmp = (y * i) + (b * math.log(c)) elif (b - 0.5) <= 5e+109: tmp = (y * i) + (t + (z + a)) else: tmp = a + (z + (math.log(c) * (b - 0.5))) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (Float64(b - 0.5) <= -5e+145) tmp = Float64(Float64(y * i) + Float64(b * log(c))); elseif (Float64(b - 0.5) <= 5e+109) tmp = Float64(Float64(y * i) + Float64(t + Float64(z + a))); else tmp = Float64(a + Float64(z + Float64(log(c) * Float64(b - 0.5)))); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if ((b - 0.5) <= -5e+145)
tmp = (y * i) + (b * log(c));
elseif ((b - 0.5) <= 5e+109)
tmp = (y * i) + (t + (z + a));
else
tmp = a + (z + (log(c) * (b - 0.5)));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[N[(b - 0.5), $MachinePrecision], -5e+145], N[(N[(y * i), $MachinePrecision] + N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b - 0.5), $MachinePrecision], 5e+109], N[(N[(y * i), $MachinePrecision] + N[(t + N[(z + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a + N[(z + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;b - 0.5 \leq -5 \cdot 10^{+145}:\\
\;\;\;\;y \cdot i + b \cdot \log c\\
\mathbf{elif}\;b - 0.5 \leq 5 \cdot 10^{+109}:\\
\;\;\;\;y \cdot i + \left(t + \left(z + a\right)\right)\\
\mathbf{else}:\\
\;\;\;\;a + \left(z + \log c \cdot \left(b - 0.5\right)\right)\\
\end{array}
\end{array}
if (-.f64 b #s(literal 1/2 binary64)) < -4.99999999999999967e145Initial program 99.7%
Taylor expanded in x around 0 87.7%
Taylor expanded in t around 0 81.5%
Taylor expanded in b around inf 74.7%
*-commutative74.7%
Simplified74.7%
if -4.99999999999999967e145 < (-.f64 b #s(literal 1/2 binary64)) < 5.0000000000000001e109Initial program 99.4%
Taylor expanded in a around inf 80.0%
associate-/l*80.0%
sub-neg80.0%
metadata-eval80.0%
associate-/l*80.0%
Simplified80.0%
Taylor expanded in z around inf 68.2%
Taylor expanded in a around 0 80.2%
+-commutative80.2%
associate-+l+80.2%
Simplified80.2%
if 5.0000000000000001e109 < (-.f64 b #s(literal 1/2 binary64)) Initial program 99.8%
Taylor expanded in x around 0 87.3%
Taylor expanded in t around 0 71.7%
Taylor expanded in y around 0 54.9%
Final simplification75.3%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (* x (log y))))
(if (<= x -1.28e+182)
(+ a (+ t (+ z t_1)))
(if (<= x 3.9e+258)
(+ (* y i) (+ a (+ t (+ z (* b (log c))))))
(+ t_1 (* y i))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x * log(y);
double tmp;
if (x <= -1.28e+182) {
tmp = a + (t + (z + t_1));
} else if (x <= 3.9e+258) {
tmp = (y * i) + (a + (t + (z + (b * log(c)))));
} else {
tmp = t_1 + (y * i);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = x * log(y)
if (x <= (-1.28d+182)) then
tmp = a + (t + (z + t_1))
else if (x <= 3.9d+258) then
tmp = (y * i) + (a + (t + (z + (b * log(c)))))
else
tmp = t_1 + (y * i)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x * Math.log(y);
double tmp;
if (x <= -1.28e+182) {
tmp = a + (t + (z + t_1));
} else if (x <= 3.9e+258) {
tmp = (y * i) + (a + (t + (z + (b * Math.log(c)))));
} else {
tmp = t_1 + (y * i);
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): t_1 = x * math.log(y) tmp = 0 if x <= -1.28e+182: tmp = a + (t + (z + t_1)) elif x <= 3.9e+258: tmp = (y * i) + (a + (t + (z + (b * math.log(c))))) else: tmp = t_1 + (y * i) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) t_1 = Float64(x * log(y)) tmp = 0.0 if (x <= -1.28e+182) tmp = Float64(a + Float64(t + Float64(z + t_1))); elseif (x <= 3.9e+258) tmp = Float64(Float64(y * i) + Float64(a + Float64(t + Float64(z + Float64(b * log(c)))))); else tmp = Float64(t_1 + Float64(y * i)); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
t_1 = x * log(y);
tmp = 0.0;
if (x <= -1.28e+182)
tmp = a + (t + (z + t_1));
elseif (x <= 3.9e+258)
tmp = (y * i) + (a + (t + (z + (b * log(c)))));
else
tmp = t_1 + (y * i);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.28e+182], N[(a + N[(t + N[(z + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.9e+258], N[(N[(y * i), $MachinePrecision] + N[(a + N[(t + N[(z + N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(y * i), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
t_1 := x \cdot \log y\\
\mathbf{if}\;x \leq -1.28 \cdot 10^{+182}:\\
\;\;\;\;a + \left(t + \left(z + t\_1\right)\right)\\
\mathbf{elif}\;x \leq 3.9 \cdot 10^{+258}:\\
\;\;\;\;y \cdot i + \left(a + \left(t + \left(z + b \cdot \log c\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1 + y \cdot i\\
\end{array}
\end{array}
if x < -1.28e182Initial program 99.7%
Taylor expanded in y around 0 91.4%
Taylor expanded in x around inf 87.2%
if -1.28e182 < x < 3.90000000000000037e258Initial program 99.9%
Taylor expanded in x around 0 93.4%
Taylor expanded in b around inf 91.2%
if 3.90000000000000037e258 < x Initial program 93.1%
Taylor expanded in a around -inf 62.7%
Taylor expanded in x around inf 74.8%
mul-1-neg74.8%
*-commutative74.8%
distribute-rgt-neg-in74.8%
Simplified74.8%
Final simplification89.9%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (* x (log y))))
(if (<= x -4.15e+180)
(+ a (+ t (+ z t_1)))
(if (<= x 3.6e+258)
(+ (* y i) (+ a (+ z (* (log c) (- b 0.5)))))
(+ t_1 (* y i))))))assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x * log(y);
double tmp;
if (x <= -4.15e+180) {
tmp = a + (t + (z + t_1));
} else if (x <= 3.6e+258) {
tmp = (y * i) + (a + (z + (log(c) * (b - 0.5))));
} else {
tmp = t_1 + (y * i);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = x * log(y)
if (x <= (-4.15d+180)) then
tmp = a + (t + (z + t_1))
else if (x <= 3.6d+258) then
tmp = (y * i) + (a + (z + (log(c) * (b - 0.5d0))))
else
tmp = t_1 + (y * i)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x * Math.log(y);
double tmp;
if (x <= -4.15e+180) {
tmp = a + (t + (z + t_1));
} else if (x <= 3.6e+258) {
tmp = (y * i) + (a + (z + (Math.log(c) * (b - 0.5))));
} else {
tmp = t_1 + (y * i);
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): t_1 = x * math.log(y) tmp = 0 if x <= -4.15e+180: tmp = a + (t + (z + t_1)) elif x <= 3.6e+258: tmp = (y * i) + (a + (z + (math.log(c) * (b - 0.5)))) else: tmp = t_1 + (y * i) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) t_1 = Float64(x * log(y)) tmp = 0.0 if (x <= -4.15e+180) tmp = Float64(a + Float64(t + Float64(z + t_1))); elseif (x <= 3.6e+258) tmp = Float64(Float64(y * i) + Float64(a + Float64(z + Float64(log(c) * Float64(b - 0.5))))); else tmp = Float64(t_1 + Float64(y * i)); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
t_1 = x * log(y);
tmp = 0.0;
if (x <= -4.15e+180)
tmp = a + (t + (z + t_1));
elseif (x <= 3.6e+258)
tmp = (y * i) + (a + (z + (log(c) * (b - 0.5))));
else
tmp = t_1 + (y * i);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -4.15e+180], N[(a + N[(t + N[(z + t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 3.6e+258], N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(y * i), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
t_1 := x \cdot \log y\\
\mathbf{if}\;x \leq -4.15 \cdot 10^{+180}:\\
\;\;\;\;a + \left(t + \left(z + t\_1\right)\right)\\
\mathbf{elif}\;x \leq 3.6 \cdot 10^{+258}:\\
\;\;\;\;y \cdot i + \left(a + \left(z + \log c \cdot \left(b - 0.5\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1 + y \cdot i\\
\end{array}
\end{array}
if x < -4.1500000000000004e180Initial program 99.7%
Taylor expanded in y around 0 91.4%
Taylor expanded in x around inf 87.2%
if -4.1500000000000004e180 < x < 3.5999999999999999e258Initial program 99.9%
Taylor expanded in x around 0 93.4%
Taylor expanded in t around 0 74.3%
if 3.5999999999999999e258 < x Initial program 93.1%
Taylor expanded in a around -inf 62.7%
Taylor expanded in x around inf 74.8%
mul-1-neg74.8%
*-commutative74.8%
distribute-rgt-neg-in74.8%
Simplified74.8%
Final simplification75.4%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (if (or (<= b -5.2e+145) (not (<= b 3.8e+109))) (+ (* y i) (* b (log c))) (+ (* y i) (+ t (+ z a)))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((b <= -5.2e+145) || !(b <= 3.8e+109)) {
tmp = (y * i) + (b * log(c));
} else {
tmp = (y * i) + (t + (z + a));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((b <= (-5.2d+145)) .or. (.not. (b <= 3.8d+109))) then
tmp = (y * i) + (b * log(c))
else
tmp = (y * i) + (t + (z + a))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((b <= -5.2e+145) || !(b <= 3.8e+109)) {
tmp = (y * i) + (b * Math.log(c));
} else {
tmp = (y * i) + (t + (z + a));
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if (b <= -5.2e+145) or not (b <= 3.8e+109): tmp = (y * i) + (b * math.log(c)) else: tmp = (y * i) + (t + (z + a)) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((b <= -5.2e+145) || !(b <= 3.8e+109)) tmp = Float64(Float64(y * i) + Float64(b * log(c))); else tmp = Float64(Float64(y * i) + Float64(t + Float64(z + a))); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if ((b <= -5.2e+145) || ~((b <= 3.8e+109)))
tmp = (y * i) + (b * log(c));
else
tmp = (y * i) + (t + (z + a));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[b, -5.2e+145], N[Not[LessEqual[b, 3.8e+109]], $MachinePrecision]], N[(N[(y * i), $MachinePrecision] + N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(t + N[(z + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;b \leq -5.2 \cdot 10^{+145} \lor \neg \left(b \leq 3.8 \cdot 10^{+109}\right):\\
\;\;\;\;y \cdot i + b \cdot \log c\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(t + \left(z + a\right)\right)\\
\end{array}
\end{array}
if b < -5.20000000000000005e145 or 3.80000000000000039e109 < b Initial program 99.8%
Taylor expanded in x around 0 87.7%
Taylor expanded in t around 0 77.1%
Taylor expanded in b around inf 70.0%
*-commutative70.0%
Simplified70.0%
if -5.20000000000000005e145 < b < 3.80000000000000039e109Initial program 99.4%
Taylor expanded in a around inf 79.9%
associate-/l*79.9%
sub-neg79.9%
metadata-eval79.9%
associate-/l*79.9%
Simplified79.9%
Taylor expanded in z around inf 68.0%
Taylor expanded in a around 0 80.1%
+-commutative80.1%
associate-+l+80.1%
Simplified80.1%
Final simplification76.8%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (if (<= x -1.06e+192) (* x (log y)) (+ (* y i) (+ t (+ z a)))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (x <= -1.06e+192) {
tmp = x * log(y);
} else {
tmp = (y * i) + (t + (z + a));
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if (x <= (-1.06d+192)) then
tmp = x * log(y)
else
tmp = (y * i) + (t + (z + a))
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (x <= -1.06e+192) {
tmp = x * Math.log(y);
} else {
tmp = (y * i) + (t + (z + a));
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if x <= -1.06e+192: tmp = x * math.log(y) else: tmp = (y * i) + (t + (z + a)) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (x <= -1.06e+192) tmp = Float64(x * log(y)); else tmp = Float64(Float64(y * i) + Float64(t + Float64(z + a))); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if (x <= -1.06e+192)
tmp = x * log(y);
else
tmp = (y * i) + (t + (z + a));
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[x, -1.06e+192], N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(t + N[(z + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.06 \cdot 10^{+192}:\\
\;\;\;\;x \cdot \log y\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(t + \left(z + a\right)\right)\\
\end{array}
\end{array}
if x < -1.06000000000000006e192Initial program 99.6%
Taylor expanded in a around -inf 70.7%
Taylor expanded in x around inf 74.0%
if -1.06000000000000006e192 < x Initial program 99.5%
Taylor expanded in a around inf 74.0%
associate-/l*73.9%
sub-neg73.9%
metadata-eval73.9%
associate-/l*73.9%
Simplified73.9%
Taylor expanded in z around inf 58.0%
Taylor expanded in a around 0 69.5%
+-commutative69.5%
associate-+l+69.5%
Simplified69.5%
Final simplification69.8%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (if (or (<= z -3.2e+204) (and (not (<= z -8.8e+161)) (<= z -5e+113))) z (+ a (* y i))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((z <= -3.2e+204) || (!(z <= -8.8e+161) && (z <= -5e+113))) {
tmp = z;
} else {
tmp = a + (y * i);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((z <= (-3.2d+204)) .or. (.not. (z <= (-8.8d+161))) .and. (z <= (-5d+113))) then
tmp = z
else
tmp = a + (y * i)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((z <= -3.2e+204) || (!(z <= -8.8e+161) && (z <= -5e+113))) {
tmp = z;
} else {
tmp = a + (y * i);
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if (z <= -3.2e+204) or (not (z <= -8.8e+161) and (z <= -5e+113)): tmp = z else: tmp = a + (y * i) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((z <= -3.2e+204) || (!(z <= -8.8e+161) && (z <= -5e+113))) tmp = z; else tmp = Float64(a + Float64(y * i)); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if ((z <= -3.2e+204) || (~((z <= -8.8e+161)) && (z <= -5e+113)))
tmp = z;
else
tmp = a + (y * i);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[z, -3.2e+204], And[N[Not[LessEqual[z, -8.8e+161]], $MachinePrecision], LessEqual[z, -5e+113]]], z, N[(a + N[(y * i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.2 \cdot 10^{+204} \lor \neg \left(z \leq -8.8 \cdot 10^{+161}\right) \land z \leq -5 \cdot 10^{+113}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;a + y \cdot i\\
\end{array}
\end{array}
if z < -3.2e204 or -8.7999999999999999e161 < z < -5e113Initial program 99.9%
Taylor expanded in z around inf 53.0%
if -3.2e204 < z < -8.7999999999999999e161 or -5e113 < z Initial program 99.5%
Taylor expanded in x around 0 84.8%
Taylor expanded in a around inf 40.4%
Final simplification41.8%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (if (<= y 5.8e-229) z (if (<= y 3e-218) a (if (<= y 1.16e+51) z (* y i)))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= 5.8e-229) {
tmp = z;
} else if (y <= 3e-218) {
tmp = a;
} else if (y <= 1.16e+51) {
tmp = z;
} else {
tmp = y * i;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if (y <= 5.8d-229) then
tmp = z
else if (y <= 3d-218) then
tmp = a
else if (y <= 1.16d+51) then
tmp = z
else
tmp = y * i
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= 5.8e-229) {
tmp = z;
} else if (y <= 3e-218) {
tmp = a;
} else if (y <= 1.16e+51) {
tmp = z;
} else {
tmp = y * i;
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= 5.8e-229: tmp = z elif y <= 3e-218: tmp = a elif y <= 1.16e+51: tmp = z else: tmp = y * i return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= 5.8e-229) tmp = z; elseif (y <= 3e-218) tmp = a; elseif (y <= 1.16e+51) tmp = z; else tmp = Float64(y * i); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if (y <= 5.8e-229)
tmp = z;
elseif (y <= 3e-218)
tmp = a;
elseif (y <= 1.16e+51)
tmp = z;
else
tmp = y * i;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, 5.8e-229], z, If[LessEqual[y, 3e-218], a, If[LessEqual[y, 1.16e+51], z, N[(y * i), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq 5.8 \cdot 10^{-229}:\\
\;\;\;\;z\\
\mathbf{elif}\;y \leq 3 \cdot 10^{-218}:\\
\;\;\;\;a\\
\mathbf{elif}\;y \leq 1.16 \cdot 10^{+51}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;y \cdot i\\
\end{array}
\end{array}
if y < 5.7999999999999999e-229 or 2.9999999999999998e-218 < y < 1.16e51Initial program 99.9%
Taylor expanded in z around inf 15.9%
if 5.7999999999999999e-229 < y < 2.9999999999999998e-218Initial program 100.0%
Taylor expanded in a around inf 44.3%
if 1.16e51 < y Initial program 99.0%
Taylor expanded in y around inf 53.4%
*-commutative53.4%
Simplified53.4%
Final simplification31.6%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (if (<= z -1.8e+71) (+ z (* y i)) (+ a (* y i))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (z <= -1.8e+71) {
tmp = z + (y * i);
} else {
tmp = a + (y * i);
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if (z <= (-1.8d+71)) then
tmp = z + (y * i)
else
tmp = a + (y * i)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (z <= -1.8e+71) {
tmp = z + (y * i);
} else {
tmp = a + (y * i);
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if z <= -1.8e+71: tmp = z + (y * i) else: tmp = a + (y * i) return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (z <= -1.8e+71) tmp = Float64(z + Float64(y * i)); else tmp = Float64(a + Float64(y * i)); end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if (z <= -1.8e+71)
tmp = z + (y * i);
else
tmp = a + (y * i);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[z, -1.8e+71], N[(z + N[(y * i), $MachinePrecision]), $MachinePrecision], N[(a + N[(y * i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.8 \cdot 10^{+71}:\\
\;\;\;\;z + y \cdot i\\
\mathbf{else}:\\
\;\;\;\;a + y \cdot i\\
\end{array}
\end{array}
if z < -1.8e71Initial program 99.9%
Taylor expanded in x around 0 95.0%
Taylor expanded in z around inf 57.0%
if -1.8e71 < z Initial program 99.4%
Taylor expanded in x around 0 84.1%
Taylor expanded in a around inf 40.5%
Final simplification43.7%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (+ (* y i) (+ t (+ z a))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + (t + (z + a));
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
code = (y * i) + (t + (z + a))
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + (t + (z + a));
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): return (y * i) + (t + (z + a))
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) return Float64(Float64(y * i) + Float64(t + Float64(z + a))) end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp = code(x, y, z, t, a, b, c, i)
tmp = (y * i) + (t + (z + a));
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(y * i), $MachinePrecision] + N[(t + N[(z + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
y \cdot i + \left(t + \left(z + a\right)\right)
\end{array}
Initial program 99.5%
Taylor expanded in a around inf 73.7%
associate-/l*73.6%
sub-neg73.6%
metadata-eval73.6%
associate-/l*73.6%
Simplified73.6%
Taylor expanded in z around inf 55.4%
Taylor expanded in a around 0 66.4%
+-commutative66.4%
associate-+l+66.4%
Simplified66.4%
Final simplification66.4%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (+ (* y i) (+ z a)))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + (z + a);
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
code = (y * i) + (z + a)
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + (z + a);
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): return (y * i) + (z + a)
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) return Float64(Float64(y * i) + Float64(z + a)) end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp = code(x, y, z, t, a, b, c, i)
tmp = (y * i) + (z + a);
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(y * i), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
y \cdot i + \left(z + a\right)
\end{array}
Initial program 99.5%
Taylor expanded in a around inf 73.7%
associate-/l*73.6%
sub-neg73.6%
metadata-eval73.6%
associate-/l*73.6%
Simplified73.6%
Taylor expanded in z around inf 55.4%
Taylor expanded in t around 0 44.9%
Taylor expanded in a around 0 50.0%
+-commutative50.0%
Simplified50.0%
Final simplification50.0%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 (if (<= z -2.8e+71) z a))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (z <= -2.8e+71) {
tmp = z;
} else {
tmp = a;
}
return tmp;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if (z <= (-2.8d+71)) then
tmp = z
else
tmp = a
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (z <= -2.8e+71) {
tmp = z;
} else {
tmp = a;
}
return tmp;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): tmp = 0 if z <= -2.8e+71: tmp = z else: tmp = a return tmp
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (z <= -2.8e+71) tmp = z; else tmp = a; end return tmp end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i)
tmp = 0.0;
if (z <= -2.8e+71)
tmp = z;
else
tmp = a;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[z, -2.8e+71], z, a]
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.8 \cdot 10^{+71}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;a\\
\end{array}
\end{array}
if z < -2.80000000000000002e71Initial program 99.9%
Taylor expanded in z around inf 39.3%
if -2.80000000000000002e71 < z Initial program 99.4%
Taylor expanded in a around inf 16.6%
Final simplification20.9%
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. (FPCore (x y z t a b c i) :precision binary64 a)
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i);
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return a;
}
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i)
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), intent (in) :: c
real(8), intent (in) :: i
code = a
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return a;
}
[x, y, z, t, a, b, c, i] = sort([x, y, z, t, a, b, c, i]) def code(x, y, z, t, a, b, c, i): return a
x, y, z, t, a, b, c, i = sort([x, y, z, t, a, b, c, i]) function code(x, y, z, t, a, b, c, i) return a end
x, y, z, t, a, b, c, i = num2cell(sort([x, y, z, t, a, b, c, i])){:}
function tmp = code(x, y, z, t, a, b, c, i)
tmp = a;
end
NOTE: x, y, z, t, a, b, c, and i should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_, i_] := a
\begin{array}{l}
[x, y, z, t, a, b, c, i] = \mathsf{sort}([x, y, z, t, a, b, c, i])\\
\\
a
\end{array}
Initial program 99.5%
Taylor expanded in a around inf 15.5%
Final simplification15.5%
herbie shell --seed 2024078
(FPCore (x y z t a b c i)
:name "Numeric.SpecFunctions:logBeta from math-functions-0.1.5.2, B"
:precision binary64
(+ (+ (+ (+ (+ (* x (log y)) z) t) a) (* (- b 0.5) (log c))) (* y i)))