
(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 21 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}
(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))))))
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)))));
}
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
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}
\\
\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.8%
associate-+l+99.8%
+-commutative99.8%
associate-+l+99.8%
associate-+r+99.8%
+-commutative99.8%
+-commutative99.8%
associate-+l+99.8%
associate-+l+99.8%
+-commutative99.8%
fma-define99.8%
+-commutative99.8%
fma-define99.8%
sub-neg99.8%
metadata-eval99.8%
+-commutative99.8%
Simplified99.8%
(FPCore (x y z t a b c i) :precision binary64 (+ (+ (+ a (+ t (+ z (* x (log y))))) (* (log c) (- b 0.5))) (* y i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return ((a + (t + (z + (x * log(y))))) + (log(c) * (b - 0.5))) + (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 = ((a + (t + (z + (x * log(y))))) + (log(c) * (b - 0.5d0))) + (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 ((a + (t + (z + (x * Math.log(y))))) + (Math.log(c) * (b - 0.5))) + (y * i);
}
def code(x, y, z, t, a, b, c, i): return ((a + (t + (z + (x * math.log(y))))) + (math.log(c) * (b - 0.5))) + (y * i)
function code(x, y, z, t, a, b, c, i) return Float64(Float64(Float64(a + Float64(t + Float64(z + Float64(x * log(y))))) + Float64(log(c) * Float64(b - 0.5))) + Float64(y * i)) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = ((a + (t + (z + (x * log(y))))) + (log(c) * (b - 0.5))) + (y * i); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(a + N[(t + N[(z + N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(a + \left(t + \left(z + x \cdot \log y\right)\right)\right) + \log c \cdot \left(b - 0.5\right)\right) + y \cdot i
\end{array}
Initial program 99.8%
Final simplification99.8%
(FPCore (x y z t a b c i) :precision binary64 (+ (* y i) (+ (+ a (+ z (* x (log y)))) (* (log c) (- b 0.5)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + ((a + (z + (x * log(y)))) + (log(c) * (b - 0.5)));
}
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) + ((a + (z + (x * log(y)))) + (log(c) * (b - 0.5d0)))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + ((a + (z + (x * Math.log(y)))) + (Math.log(c) * (b - 0.5)));
}
def code(x, y, z, t, a, b, c, i): return (y * i) + ((a + (z + (x * math.log(y)))) + (math.log(c) * (b - 0.5)))
function code(x, y, z, t, a, b, c, i) return Float64(Float64(y * i) + Float64(Float64(a + Float64(z + Float64(x * log(y)))) + Float64(log(c) * Float64(b - 0.5)))) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = (y * i) + ((a + (z + (x * log(y)))) + (log(c) * (b - 0.5))); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(y * i), $MachinePrecision] + N[(N[(a + N[(z + N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
y \cdot i + \left(\left(a + \left(z + x \cdot \log y\right)\right) + \log c \cdot \left(b - 0.5\right)\right)
\end{array}
Initial program 99.8%
Taylor expanded in t around 0 83.9%
Final simplification83.9%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y i) (+ (+ z a) (* -0.5 (log c)))))
(t_2 (+ a (+ (* x (log y)) (* y i)))))
(if (<= x -6.4e+151)
t_2
(if (<= x -2.6e+19)
t_1
(if (<= x -0.09)
t_2
(if (<= x -7.8e-70)
(+ a (+ z (* (log c) (- b 0.5))))
(if (<= x 7.8e+31) t_1 t_2)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (y * i) + ((z + a) + (-0.5 * log(c)));
double t_2 = a + ((x * log(y)) + (y * i));
double tmp;
if (x <= -6.4e+151) {
tmp = t_2;
} else if (x <= -2.6e+19) {
tmp = t_1;
} else if (x <= -0.09) {
tmp = t_2;
} else if (x <= -7.8e-70) {
tmp = a + (z + (log(c) * (b - 0.5)));
} else if (x <= 7.8e+31) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
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) :: t_2
real(8) :: tmp
t_1 = (y * i) + ((z + a) + ((-0.5d0) * log(c)))
t_2 = a + ((x * log(y)) + (y * i))
if (x <= (-6.4d+151)) then
tmp = t_2
else if (x <= (-2.6d+19)) then
tmp = t_1
else if (x <= (-0.09d0)) then
tmp = t_2
else if (x <= (-7.8d-70)) then
tmp = a + (z + (log(c) * (b - 0.5d0)))
else if (x <= 7.8d+31) then
tmp = t_1
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 c, double i) {
double t_1 = (y * i) + ((z + a) + (-0.5 * Math.log(c)));
double t_2 = a + ((x * Math.log(y)) + (y * i));
double tmp;
if (x <= -6.4e+151) {
tmp = t_2;
} else if (x <= -2.6e+19) {
tmp = t_1;
} else if (x <= -0.09) {
tmp = t_2;
} else if (x <= -7.8e-70) {
tmp = a + (z + (Math.log(c) * (b - 0.5)));
} else if (x <= 7.8e+31) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * i) + ((z + a) + (-0.5 * math.log(c))) t_2 = a + ((x * math.log(y)) + (y * i)) tmp = 0 if x <= -6.4e+151: tmp = t_2 elif x <= -2.6e+19: tmp = t_1 elif x <= -0.09: tmp = t_2 elif x <= -7.8e-70: tmp = a + (z + (math.log(c) * (b - 0.5))) elif x <= 7.8e+31: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(y * i) + Float64(Float64(z + a) + Float64(-0.5 * log(c)))) t_2 = Float64(a + Float64(Float64(x * log(y)) + Float64(y * i))) tmp = 0.0 if (x <= -6.4e+151) tmp = t_2; elseif (x <= -2.6e+19) tmp = t_1; elseif (x <= -0.09) tmp = t_2; elseif (x <= -7.8e-70) tmp = Float64(a + Float64(z + Float64(log(c) * Float64(b - 0.5)))); elseif (x <= 7.8e+31) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (y * i) + ((z + a) + (-0.5 * log(c))); t_2 = a + ((x * log(y)) + (y * i)); tmp = 0.0; if (x <= -6.4e+151) tmp = t_2; elseif (x <= -2.6e+19) tmp = t_1; elseif (x <= -0.09) tmp = t_2; elseif (x <= -7.8e-70) tmp = a + (z + (log(c) * (b - 0.5))); elseif (x <= 7.8e+31) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * i), $MachinePrecision] + N[(N[(z + a), $MachinePrecision] + N[(-0.5 * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(a + N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6.4e+151], t$95$2, If[LessEqual[x, -2.6e+19], t$95$1, If[LessEqual[x, -0.09], t$95$2, If[LessEqual[x, -7.8e-70], N[(a + N[(z + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 7.8e+31], t$95$1, t$95$2]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot i + \left(\left(z + a\right) + -0.5 \cdot \log c\right)\\
t_2 := a + \left(x \cdot \log y + y \cdot i\right)\\
\mathbf{if}\;x \leq -6.4 \cdot 10^{+151}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq -2.6 \cdot 10^{+19}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq -0.09:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq -7.8 \cdot 10^{-70}:\\
\;\;\;\;a + \left(z + \log c \cdot \left(b - 0.5\right)\right)\\
\mathbf{elif}\;x \leq 7.8 \cdot 10^{+31}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if x < -6.39999999999999988e151 or -2.6e19 < x < -0.089999999999999997 or 7.79999999999999999e31 < x Initial program 99.8%
Taylor expanded in x around inf 99.8%
associate-+r+99.8%
+-commutative99.8%
+-commutative99.8%
sub-neg99.8%
metadata-eval99.8%
associate-/l*99.8%
fma-define99.8%
+-commutative99.8%
Simplified99.8%
Taylor expanded in a around inf 78.9%
Taylor expanded in x around 0 78.9%
if -6.39999999999999988e151 < x < -2.6e19 or -7.80000000000000038e-70 < x < 7.79999999999999999e31Initial program 99.9%
Taylor expanded in x around 0 98.2%
+-commutative98.2%
sub-neg98.2%
metadata-eval98.2%
fma-define98.2%
+-commutative98.2%
Simplified98.2%
Taylor expanded in t around 0 75.1%
Taylor expanded in b around 0 60.8%
associate-+r+60.8%
Simplified60.8%
if -0.089999999999999997 < x < -7.80000000000000038e-70Initial program 99.6%
Taylor expanded in x around 0 99.6%
+-commutative99.6%
sub-neg99.6%
metadata-eval99.6%
fma-define99.5%
+-commutative99.5%
Simplified99.5%
Taylor expanded in t around 0 92.1%
Taylor expanded in y around 0 92.1%
Final simplification69.4%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (* (log c) (- b 0.5))) (t_2 (+ (* y i) (+ a (+ z t)))))
(if (<= z -3.3e+240)
t_2
(if (<= z -1.25e+207)
(+ a (+ z t_1))
(if (<= z -1.2e+117)
t_2
(if (or (<= z -3.7e-250) (not (<= z -1.26e-281)))
(+ a (+ (* x (log y)) (* y i)))
(+ (* y i) t_1)))))))
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 t_2 = (y * i) + (a + (z + t));
double tmp;
if (z <= -3.3e+240) {
tmp = t_2;
} else if (z <= -1.25e+207) {
tmp = a + (z + t_1);
} else if (z <= -1.2e+117) {
tmp = t_2;
} else if ((z <= -3.7e-250) || !(z <= -1.26e-281)) {
tmp = a + ((x * log(y)) + (y * i));
} else {
tmp = (y * i) + t_1;
}
return tmp;
}
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) :: t_2
real(8) :: tmp
t_1 = log(c) * (b - 0.5d0)
t_2 = (y * i) + (a + (z + t))
if (z <= (-3.3d+240)) then
tmp = t_2
else if (z <= (-1.25d+207)) then
tmp = a + (z + t_1)
else if (z <= (-1.2d+117)) then
tmp = t_2
else if ((z <= (-3.7d-250)) .or. (.not. (z <= (-1.26d-281)))) then
tmp = a + ((x * log(y)) + (y * i))
else
tmp = (y * i) + 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 c, double i) {
double t_1 = Math.log(c) * (b - 0.5);
double t_2 = (y * i) + (a + (z + t));
double tmp;
if (z <= -3.3e+240) {
tmp = t_2;
} else if (z <= -1.25e+207) {
tmp = a + (z + t_1);
} else if (z <= -1.2e+117) {
tmp = t_2;
} else if ((z <= -3.7e-250) || !(z <= -1.26e-281)) {
tmp = a + ((x * Math.log(y)) + (y * i));
} else {
tmp = (y * i) + t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = math.log(c) * (b - 0.5) t_2 = (y * i) + (a + (z + t)) tmp = 0 if z <= -3.3e+240: tmp = t_2 elif z <= -1.25e+207: tmp = a + (z + t_1) elif z <= -1.2e+117: tmp = t_2 elif (z <= -3.7e-250) or not (z <= -1.26e-281): tmp = a + ((x * math.log(y)) + (y * i)) else: tmp = (y * i) + t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(log(c) * Float64(b - 0.5)) t_2 = Float64(Float64(y * i) + Float64(a + Float64(z + t))) tmp = 0.0 if (z <= -3.3e+240) tmp = t_2; elseif (z <= -1.25e+207) tmp = Float64(a + Float64(z + t_1)); elseif (z <= -1.2e+117) tmp = t_2; elseif ((z <= -3.7e-250) || !(z <= -1.26e-281)) tmp = Float64(a + Float64(Float64(x * log(y)) + Float64(y * i))); else tmp = Float64(Float64(y * i) + t_1); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = log(c) * (b - 0.5); t_2 = (y * i) + (a + (z + t)); tmp = 0.0; if (z <= -3.3e+240) tmp = t_2; elseif (z <= -1.25e+207) tmp = a + (z + t_1); elseif (z <= -1.2e+117) tmp = t_2; elseif ((z <= -3.7e-250) || ~((z <= -1.26e-281))) tmp = a + ((x * log(y)) + (y * i)); else tmp = (y * i) + t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.3e+240], t$95$2, If[LessEqual[z, -1.25e+207], N[(a + N[(z + t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.2e+117], t$95$2, If[Or[LessEqual[z, -3.7e-250], N[Not[LessEqual[z, -1.26e-281]], $MachinePrecision]], N[(a + N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + t$95$1), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \log c \cdot \left(b - 0.5\right)\\
t_2 := y \cdot i + \left(a + \left(z + t\right)\right)\\
\mathbf{if}\;z \leq -3.3 \cdot 10^{+240}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq -1.25 \cdot 10^{+207}:\\
\;\;\;\;a + \left(z + t\_1\right)\\
\mathbf{elif}\;z \leq -1.2 \cdot 10^{+117}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq -3.7 \cdot 10^{-250} \lor \neg \left(z \leq -1.26 \cdot 10^{-281}\right):\\
\;\;\;\;a + \left(x \cdot \log y + y \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + t\_1\\
\end{array}
\end{array}
if z < -3.2999999999999998e240 or -1.25e207 < z < -1.1999999999999999e117Initial program 99.9%
Taylor expanded in x around 0 96.2%
+-commutative96.2%
sub-neg96.2%
metadata-eval96.2%
fma-define96.2%
+-commutative96.2%
Simplified96.2%
Taylor expanded in z around inf 83.8%
if -3.2999999999999998e240 < z < -1.25e207Initial program 99.2%
Taylor expanded in x around 0 76.2%
+-commutative76.2%
sub-neg76.2%
metadata-eval76.2%
fma-define76.2%
+-commutative76.2%
Simplified76.2%
Taylor expanded in t around 0 76.2%
Taylor expanded in y around 0 76.2%
if -1.1999999999999999e117 < z < -3.6999999999999998e-250 or -1.26e-281 < z Initial program 99.8%
Taylor expanded in x around inf 71.3%
associate-+r+71.3%
+-commutative71.3%
+-commutative71.3%
sub-neg71.3%
metadata-eval71.3%
associate-/l*71.3%
fma-define71.3%
+-commutative71.3%
Simplified71.3%
Taylor expanded in a around inf 48.0%
Taylor expanded in x around 0 58.5%
if -3.6999999999999998e-250 < z < -1.26e-281Initial program 100.0%
Taylor expanded in x around 0 89.4%
+-commutative89.4%
sub-neg89.4%
metadata-eval89.4%
fma-define89.4%
+-commutative89.4%
Simplified89.4%
Taylor expanded in t around 0 77.9%
Taylor expanded in a around inf 68.1%
associate-+r+68.1%
sub-neg68.1%
metadata-eval68.1%
associate-/l*67.9%
Simplified67.9%
Taylor expanded in z around 0 68.1%
sub-neg68.1%
metadata-eval68.1%
associate-*r/67.9%
Simplified67.9%
Taylor expanded in a around 0 78.4%
Final simplification62.2%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (* (log c) (- b 0.5))) (t_2 (+ (* y i) (+ a (+ z t)))))
(if (<= z -3.3e+240)
t_2
(if (<= z -1.3e+207)
(+ a (+ z t_1))
(if (<= z -7.8e+117)
t_2
(if (or (<= z -4.3e-253) (not (<= z -1.26e-281)))
(+ a (+ (* x (log y)) (* y i)))
(+ a t_1)))))))
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 t_2 = (y * i) + (a + (z + t));
double tmp;
if (z <= -3.3e+240) {
tmp = t_2;
} else if (z <= -1.3e+207) {
tmp = a + (z + t_1);
} else if (z <= -7.8e+117) {
tmp = t_2;
} else if ((z <= -4.3e-253) || !(z <= -1.26e-281)) {
tmp = a + ((x * log(y)) + (y * i));
} else {
tmp = a + t_1;
}
return tmp;
}
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) :: t_2
real(8) :: tmp
t_1 = log(c) * (b - 0.5d0)
t_2 = (y * i) + (a + (z + t))
if (z <= (-3.3d+240)) then
tmp = t_2
else if (z <= (-1.3d+207)) then
tmp = a + (z + t_1)
else if (z <= (-7.8d+117)) then
tmp = t_2
else if ((z <= (-4.3d-253)) .or. (.not. (z <= (-1.26d-281)))) then
tmp = a + ((x * log(y)) + (y * i))
else
tmp = a + 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 c, double i) {
double t_1 = Math.log(c) * (b - 0.5);
double t_2 = (y * i) + (a + (z + t));
double tmp;
if (z <= -3.3e+240) {
tmp = t_2;
} else if (z <= -1.3e+207) {
tmp = a + (z + t_1);
} else if (z <= -7.8e+117) {
tmp = t_2;
} else if ((z <= -4.3e-253) || !(z <= -1.26e-281)) {
tmp = a + ((x * Math.log(y)) + (y * i));
} else {
tmp = a + t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = math.log(c) * (b - 0.5) t_2 = (y * i) + (a + (z + t)) tmp = 0 if z <= -3.3e+240: tmp = t_2 elif z <= -1.3e+207: tmp = a + (z + t_1) elif z <= -7.8e+117: tmp = t_2 elif (z <= -4.3e-253) or not (z <= -1.26e-281): tmp = a + ((x * math.log(y)) + (y * i)) else: tmp = a + t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(log(c) * Float64(b - 0.5)) t_2 = Float64(Float64(y * i) + Float64(a + Float64(z + t))) tmp = 0.0 if (z <= -3.3e+240) tmp = t_2; elseif (z <= -1.3e+207) tmp = Float64(a + Float64(z + t_1)); elseif (z <= -7.8e+117) tmp = t_2; elseif ((z <= -4.3e-253) || !(z <= -1.26e-281)) tmp = Float64(a + Float64(Float64(x * log(y)) + Float64(y * i))); else tmp = Float64(a + t_1); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = log(c) * (b - 0.5); t_2 = (y * i) + (a + (z + t)); tmp = 0.0; if (z <= -3.3e+240) tmp = t_2; elseif (z <= -1.3e+207) tmp = a + (z + t_1); elseif (z <= -7.8e+117) tmp = t_2; elseif ((z <= -4.3e-253) || ~((z <= -1.26e-281))) tmp = a + ((x * log(y)) + (y * i)); else tmp = a + t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.3e+240], t$95$2, If[LessEqual[z, -1.3e+207], N[(a + N[(z + t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -7.8e+117], t$95$2, If[Or[LessEqual[z, -4.3e-253], N[Not[LessEqual[z, -1.26e-281]], $MachinePrecision]], N[(a + N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a + t$95$1), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \log c \cdot \left(b - 0.5\right)\\
t_2 := y \cdot i + \left(a + \left(z + t\right)\right)\\
\mathbf{if}\;z \leq -3.3 \cdot 10^{+240}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq -1.3 \cdot 10^{+207}:\\
\;\;\;\;a + \left(z + t\_1\right)\\
\mathbf{elif}\;z \leq -7.8 \cdot 10^{+117}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;z \leq -4.3 \cdot 10^{-253} \lor \neg \left(z \leq -1.26 \cdot 10^{-281}\right):\\
\;\;\;\;a + \left(x \cdot \log y + y \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;a + t\_1\\
\end{array}
\end{array}
if z < -3.2999999999999998e240 or -1.2999999999999999e207 < z < -7.79999999999999981e117Initial program 99.9%
Taylor expanded in x around 0 96.2%
+-commutative96.2%
sub-neg96.2%
metadata-eval96.2%
fma-define96.2%
+-commutative96.2%
Simplified96.2%
Taylor expanded in z around inf 83.8%
if -3.2999999999999998e240 < z < -1.2999999999999999e207Initial program 99.2%
Taylor expanded in x around 0 76.2%
+-commutative76.2%
sub-neg76.2%
metadata-eval76.2%
fma-define76.2%
+-commutative76.2%
Simplified76.2%
Taylor expanded in t around 0 76.2%
Taylor expanded in y around 0 76.2%
if -7.79999999999999981e117 < z < -4.3000000000000002e-253 or -1.26e-281 < z Initial program 99.8%
Taylor expanded in x around inf 71.4%
associate-+r+71.4%
+-commutative71.4%
+-commutative71.4%
sub-neg71.4%
metadata-eval71.4%
associate-/l*71.4%
fma-define71.4%
+-commutative71.4%
Simplified71.4%
Taylor expanded in a around inf 48.2%
Taylor expanded in x around 0 58.7%
if -4.3000000000000002e-253 < z < -1.26e-281Initial program 100.0%
Taylor expanded in x around 0 88.1%
+-commutative88.1%
sub-neg88.1%
metadata-eval88.1%
fma-define88.1%
+-commutative88.1%
Simplified88.1%
Taylor expanded in t around 0 75.1%
Taylor expanded in y around 0 50.5%
Taylor expanded in z around 0 50.5%
Final simplification61.4%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y i) (+ a (+ z t)))) (t_2 (+ (* x (log y)) (* y i))))
(if (<= x -8.5e+192)
t_2
(if (<= x -1.45e+80)
t_1
(if (<= x 1e+70)
(+ a (+ z (* (log c) (- b 0.5))))
(if (or (<= x 7.2e+127) (not (<= x 2.25e+216))) t_2 t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (y * i) + (a + (z + t));
double t_2 = (x * log(y)) + (y * i);
double tmp;
if (x <= -8.5e+192) {
tmp = t_2;
} else if (x <= -1.45e+80) {
tmp = t_1;
} else if (x <= 1e+70) {
tmp = a + (z + (log(c) * (b - 0.5)));
} else if ((x <= 7.2e+127) || !(x <= 2.25e+216)) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
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) :: t_2
real(8) :: tmp
t_1 = (y * i) + (a + (z + t))
t_2 = (x * log(y)) + (y * i)
if (x <= (-8.5d+192)) then
tmp = t_2
else if (x <= (-1.45d+80)) then
tmp = t_1
else if (x <= 1d+70) then
tmp = a + (z + (log(c) * (b - 0.5d0)))
else if ((x <= 7.2d+127) .or. (.not. (x <= 2.25d+216))) then
tmp = t_2
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 c, double i) {
double t_1 = (y * i) + (a + (z + t));
double t_2 = (x * Math.log(y)) + (y * i);
double tmp;
if (x <= -8.5e+192) {
tmp = t_2;
} else if (x <= -1.45e+80) {
tmp = t_1;
} else if (x <= 1e+70) {
tmp = a + (z + (Math.log(c) * (b - 0.5)));
} else if ((x <= 7.2e+127) || !(x <= 2.25e+216)) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * i) + (a + (z + t)) t_2 = (x * math.log(y)) + (y * i) tmp = 0 if x <= -8.5e+192: tmp = t_2 elif x <= -1.45e+80: tmp = t_1 elif x <= 1e+70: tmp = a + (z + (math.log(c) * (b - 0.5))) elif (x <= 7.2e+127) or not (x <= 2.25e+216): tmp = t_2 else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(y * i) + Float64(a + Float64(z + t))) t_2 = Float64(Float64(x * log(y)) + Float64(y * i)) tmp = 0.0 if (x <= -8.5e+192) tmp = t_2; elseif (x <= -1.45e+80) tmp = t_1; elseif (x <= 1e+70) tmp = Float64(a + Float64(z + Float64(log(c) * Float64(b - 0.5)))); elseif ((x <= 7.2e+127) || !(x <= 2.25e+216)) tmp = t_2; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (y * i) + (a + (z + t)); t_2 = (x * log(y)) + (y * i); tmp = 0.0; if (x <= -8.5e+192) tmp = t_2; elseif (x <= -1.45e+80) tmp = t_1; elseif (x <= 1e+70) tmp = a + (z + (log(c) * (b - 0.5))); elseif ((x <= 7.2e+127) || ~((x <= 2.25e+216))) tmp = t_2; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -8.5e+192], t$95$2, If[LessEqual[x, -1.45e+80], t$95$1, If[LessEqual[x, 1e+70], N[(a + N[(z + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[x, 7.2e+127], N[Not[LessEqual[x, 2.25e+216]], $MachinePrecision]], t$95$2, t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot i + \left(a + \left(z + t\right)\right)\\
t_2 := x \cdot \log y + y \cdot i\\
\mathbf{if}\;x \leq -8.5 \cdot 10^{+192}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq -1.45 \cdot 10^{+80}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 10^{+70}:\\
\;\;\;\;a + \left(z + \log c \cdot \left(b - 0.5\right)\right)\\
\mathbf{elif}\;x \leq 7.2 \cdot 10^{+127} \lor \neg \left(x \leq 2.25 \cdot 10^{+216}\right):\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -8.49999999999999965e192 or 1.00000000000000007e70 < x < 7.19999999999999958e127 or 2.25000000000000012e216 < x Initial program 99.8%
Taylor expanded in x around inf 86.6%
if -8.49999999999999965e192 < x < -1.44999999999999993e80 or 7.19999999999999958e127 < x < 2.25000000000000012e216Initial program 99.9%
Taylor expanded in x around 0 80.5%
+-commutative80.5%
sub-neg80.5%
metadata-eval80.5%
fma-define80.5%
+-commutative80.5%
Simplified80.5%
Taylor expanded in z around inf 74.1%
if -1.44999999999999993e80 < x < 1.00000000000000007e70Initial program 99.9%
Taylor expanded in x around 0 96.6%
+-commutative96.6%
sub-neg96.6%
metadata-eval96.6%
fma-define96.6%
+-commutative96.6%
Simplified96.6%
Taylor expanded in t around 0 75.0%
Taylor expanded in y around 0 58.2%
Final simplification67.0%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= z -3.7e+130) (and (not (<= z -3.8e-250)) (<= z -8.8e-283))) (+ t (+ z (+ (* y i) (* (log c) (- b 0.5))))) (+ a (+ (* x (log y)) (* y i)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((z <= -3.7e+130) || (!(z <= -3.8e-250) && (z <= -8.8e-283))) {
tmp = t + (z + ((y * i) + (log(c) * (b - 0.5))));
} else {
tmp = a + ((x * log(y)) + (y * i));
}
return tmp;
}
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.7d+130)) .or. (.not. (z <= (-3.8d-250))) .and. (z <= (-8.8d-283))) then
tmp = t + (z + ((y * i) + (log(c) * (b - 0.5d0))))
else
tmp = a + ((x * log(y)) + (y * i))
end if
code = tmp
end function
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.7e+130) || (!(z <= -3.8e-250) && (z <= -8.8e-283))) {
tmp = t + (z + ((y * i) + (Math.log(c) * (b - 0.5))));
} else {
tmp = a + ((x * Math.log(y)) + (y * i));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (z <= -3.7e+130) or (not (z <= -3.8e-250) and (z <= -8.8e-283)): tmp = t + (z + ((y * i) + (math.log(c) * (b - 0.5)))) else: tmp = a + ((x * math.log(y)) + (y * i)) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((z <= -3.7e+130) || (!(z <= -3.8e-250) && (z <= -8.8e-283))) tmp = Float64(t + Float64(z + Float64(Float64(y * i) + Float64(log(c) * Float64(b - 0.5))))); else tmp = Float64(a + Float64(Float64(x * log(y)) + Float64(y * i))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((z <= -3.7e+130) || (~((z <= -3.8e-250)) && (z <= -8.8e-283))) tmp = t + (z + ((y * i) + (log(c) * (b - 0.5)))); else tmp = a + ((x * log(y)) + (y * i)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[z, -3.7e+130], And[N[Not[LessEqual[z, -3.8e-250]], $MachinePrecision], LessEqual[z, -8.8e-283]]], N[(t + N[(z + N[(N[(y * i), $MachinePrecision] + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a + N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.7 \cdot 10^{+130} \lor \neg \left(z \leq -3.8 \cdot 10^{-250}\right) \land z \leq -8.8 \cdot 10^{-283}:\\
\;\;\;\;t + \left(z + \left(y \cdot i + \log c \cdot \left(b - 0.5\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;a + \left(x \cdot \log y + y \cdot i\right)\\
\end{array}
\end{array}
if z < -3.7000000000000001e130 or -3.79999999999999971e-250 < z < -8.7999999999999992e-283Initial program 99.9%
Taylor expanded in x around 0 91.9%
+-commutative91.9%
sub-neg91.9%
metadata-eval91.9%
fma-define91.9%
+-commutative91.9%
Simplified91.9%
Taylor expanded in a around 0 89.2%
if -3.7000000000000001e130 < z < -3.79999999999999971e-250 or -8.7999999999999992e-283 < z Initial program 99.8%
Taylor expanded in x around inf 71.4%
associate-+r+71.4%
+-commutative71.4%
+-commutative71.4%
sub-neg71.4%
metadata-eval71.4%
associate-/l*71.4%
fma-define71.4%
+-commutative71.4%
Simplified71.4%
Taylor expanded in a around inf 47.6%
Taylor expanded in x around 0 58.0%
Final simplification62.4%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= x -3e+230) (not (<= x 1.8e+67))) (+ a (+ (* x (log y)) (* y i))) (+ (* y i) (+ a (+ t (+ z (* (log c) (- b 0.5))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x <= -3e+230) || !(x <= 1.8e+67)) {
tmp = a + ((x * log(y)) + (y * i));
} else {
tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5)))));
}
return tmp;
}
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 <= (-3d+230)) .or. (.not. (x <= 1.8d+67))) then
tmp = a + ((x * log(y)) + (y * i))
else
tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5d0)))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x <= -3e+230) || !(x <= 1.8e+67)) {
tmp = a + ((x * Math.log(y)) + (y * i));
} else {
tmp = (y * i) + (a + (t + (z + (Math.log(c) * (b - 0.5)))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (x <= -3e+230) or not (x <= 1.8e+67): tmp = a + ((x * math.log(y)) + (y * i)) else: tmp = (y * i) + (a + (t + (z + (math.log(c) * (b - 0.5))))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((x <= -3e+230) || !(x <= 1.8e+67)) tmp = Float64(a + Float64(Float64(x * log(y)) + Float64(y * i))); else tmp = Float64(Float64(y * i) + Float64(a + Float64(t + Float64(z + Float64(log(c) * Float64(b - 0.5)))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((x <= -3e+230) || ~((x <= 1.8e+67))) tmp = a + ((x * log(y)) + (y * i)); else tmp = (y * i) + (a + (t + (z + (log(c) * (b - 0.5))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[x, -3e+230], N[Not[LessEqual[x, 1.8e+67]], $MachinePrecision]], N[(a + N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 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]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3 \cdot 10^{+230} \lor \neg \left(x \leq 1.8 \cdot 10^{+67}\right):\\
\;\;\;\;a + \left(x \cdot \log y + y \cdot i\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(a + \left(t + \left(z + \log c \cdot \left(b - 0.5\right)\right)\right)\right)\\
\end{array}
\end{array}
if x < -3.00000000000000008e230 or 1.7999999999999999e67 < x Initial program 99.8%
Taylor expanded in x around inf 99.8%
associate-+r+99.8%
+-commutative99.8%
+-commutative99.8%
sub-neg99.8%
metadata-eval99.8%
associate-/l*99.8%
fma-define99.8%
+-commutative99.8%
Simplified99.8%
Taylor expanded in a around inf 83.5%
Taylor expanded in x around 0 83.5%
if -3.00000000000000008e230 < x < 1.7999999999999999e67Initial program 99.9%
Taylor expanded in x around 0 95.3%
Final simplification91.8%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= x -3e+230) (not (<= x 1.15e+67))) (+ a (+ (* x (log y)) (* y i))) (+ (* y i) (+ a (+ z (* (log c) (- b 0.5)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x <= -3e+230) || !(x <= 1.15e+67)) {
tmp = a + ((x * log(y)) + (y * i));
} else {
tmp = (y * i) + (a + (z + (log(c) * (b - 0.5))));
}
return tmp;
}
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 <= (-3d+230)) .or. (.not. (x <= 1.15d+67))) then
tmp = a + ((x * log(y)) + (y * i))
else
tmp = (y * i) + (a + (z + (log(c) * (b - 0.5d0))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x <= -3e+230) || !(x <= 1.15e+67)) {
tmp = a + ((x * Math.log(y)) + (y * i));
} else {
tmp = (y * i) + (a + (z + (Math.log(c) * (b - 0.5))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (x <= -3e+230) or not (x <= 1.15e+67): tmp = a + ((x * math.log(y)) + (y * i)) else: tmp = (y * i) + (a + (z + (math.log(c) * (b - 0.5)))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((x <= -3e+230) || !(x <= 1.15e+67)) tmp = Float64(a + Float64(Float64(x * log(y)) + Float64(y * i))); else tmp = Float64(Float64(y * i) + Float64(a + Float64(z + Float64(log(c) * Float64(b - 0.5))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((x <= -3e+230) || ~((x <= 1.15e+67))) tmp = a + ((x * log(y)) + (y * i)); else tmp = (y * i) + (a + (z + (log(c) * (b - 0.5)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[x, -3e+230], N[Not[LessEqual[x, 1.15e+67]], $MachinePrecision]], N[(a + N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(y * i), $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}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3 \cdot 10^{+230} \lor \neg \left(x \leq 1.15 \cdot 10^{+67}\right):\\
\;\;\;\;a + \left(x \cdot \log y + y \cdot i\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 x < -3.00000000000000008e230 or 1.1499999999999999e67 < x Initial program 99.8%
Taylor expanded in x around inf 99.8%
associate-+r+99.8%
+-commutative99.8%
+-commutative99.8%
sub-neg99.8%
metadata-eval99.8%
associate-/l*99.8%
fma-define99.8%
+-commutative99.8%
Simplified99.8%
Taylor expanded in a around inf 83.5%
Taylor expanded in x around 0 83.5%
if -3.00000000000000008e230 < x < 1.1499999999999999e67Initial program 99.9%
Taylor expanded in x around 0 95.3%
+-commutative95.3%
sub-neg95.3%
metadata-eval95.3%
fma-define95.3%
+-commutative95.3%
Simplified95.3%
Taylor expanded in t around 0 75.1%
Final simplification77.6%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (* (log c) (- b 0.5))))
(if (<= (- b 0.5) -1e+272)
(+ a t_1)
(if (<= (- b 0.5) 1e+212) (+ (* y i) (+ a (+ z t))) t_1))))
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 ((b - 0.5) <= -1e+272) {
tmp = a + t_1;
} else if ((b - 0.5) <= 1e+212) {
tmp = (y * i) + (a + (z + t));
} else {
tmp = t_1;
}
return tmp;
}
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 ((b - 0.5d0) <= (-1d+272)) then
tmp = a + t_1
else if ((b - 0.5d0) <= 1d+212) then
tmp = (y * i) + (a + (z + t))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = Math.log(c) * (b - 0.5);
double tmp;
if ((b - 0.5) <= -1e+272) {
tmp = a + t_1;
} else if ((b - 0.5) <= 1e+212) {
tmp = (y * i) + (a + (z + t));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = math.log(c) * (b - 0.5) tmp = 0 if (b - 0.5) <= -1e+272: tmp = a + t_1 elif (b - 0.5) <= 1e+212: tmp = (y * i) + (a + (z + t)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(log(c) * Float64(b - 0.5)) tmp = 0.0 if (Float64(b - 0.5) <= -1e+272) tmp = Float64(a + t_1); elseif (Float64(b - 0.5) <= 1e+212) tmp = Float64(Float64(y * i) + Float64(a + Float64(z + t))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = log(c) * (b - 0.5); tmp = 0.0; if ((b - 0.5) <= -1e+272) tmp = a + t_1; elseif ((b - 0.5) <= 1e+212) tmp = (y * i) + (a + (z + t)); else tmp = t_1; end tmp_2 = tmp; end
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[N[(b - 0.5), $MachinePrecision], -1e+272], N[(a + t$95$1), $MachinePrecision], If[LessEqual[N[(b - 0.5), $MachinePrecision], 1e+212], N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \log c \cdot \left(b - 0.5\right)\\
\mathbf{if}\;b - 0.5 \leq -1 \cdot 10^{+272}:\\
\;\;\;\;a + t\_1\\
\mathbf{elif}\;b - 0.5 \leq 10^{+212}:\\
\;\;\;\;y \cdot i + \left(a + \left(z + t\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (-.f64 b #s(literal 1/2 binary64)) < -1.0000000000000001e272Initial program 99.8%
Taylor expanded in x around 0 99.8%
+-commutative99.8%
sub-neg99.8%
metadata-eval99.8%
fma-define99.8%
+-commutative99.8%
Simplified99.8%
Taylor expanded in t around 0 87.1%
Taylor expanded in y around 0 72.8%
Taylor expanded in z around 0 72.8%
if -1.0000000000000001e272 < (-.f64 b #s(literal 1/2 binary64)) < 9.9999999999999991e211Initial program 99.9%
Taylor expanded in x around 0 79.4%
+-commutative79.4%
sub-neg79.4%
metadata-eval79.4%
fma-define79.4%
+-commutative79.4%
Simplified79.4%
Taylor expanded in z around inf 69.3%
if 9.9999999999999991e211 < (-.f64 b #s(literal 1/2 binary64)) Initial program 99.4%
Taylor expanded in x around 0 93.3%
+-commutative93.3%
sub-neg93.3%
metadata-eval93.3%
fma-define93.3%
+-commutative93.3%
Simplified93.3%
Taylor expanded in t around 0 93.3%
Taylor expanded in a around inf 56.4%
associate-+r+56.4%
sub-neg56.4%
metadata-eval56.4%
associate-/l*56.4%
Simplified56.4%
Taylor expanded in z around 0 50.6%
sub-neg50.6%
metadata-eval50.6%
associate-*r/50.6%
Simplified50.6%
Taylor expanded in a around 0 74.8%
Taylor expanded in y around 0 61.5%
Final simplification68.9%
(FPCore (x y z t a b c i) :precision binary64 (if (<= (- b 0.5) -1e+256) (* b (log c)) (if (<= (- b 0.5) 1e+212) (+ (* y i) (+ a (+ z t))) (* (log c) (- b 0.5)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((b - 0.5) <= -1e+256) {
tmp = b * log(c);
} else if ((b - 0.5) <= 1e+212) {
tmp = (y * i) + (a + (z + t));
} else {
tmp = log(c) * (b - 0.5);
}
return tmp;
}
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) <= (-1d+256)) then
tmp = b * log(c)
else if ((b - 0.5d0) <= 1d+212) then
tmp = (y * i) + (a + (z + t))
else
tmp = log(c) * (b - 0.5d0)
end if
code = tmp
end function
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) <= -1e+256) {
tmp = b * Math.log(c);
} else if ((b - 0.5) <= 1e+212) {
tmp = (y * i) + (a + (z + t));
} else {
tmp = Math.log(c) * (b - 0.5);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (b - 0.5) <= -1e+256: tmp = b * math.log(c) elif (b - 0.5) <= 1e+212: tmp = (y * i) + (a + (z + t)) else: tmp = math.log(c) * (b - 0.5) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (Float64(b - 0.5) <= -1e+256) tmp = Float64(b * log(c)); elseif (Float64(b - 0.5) <= 1e+212) tmp = Float64(Float64(y * i) + Float64(a + Float64(z + t))); else tmp = Float64(log(c) * Float64(b - 0.5)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((b - 0.5) <= -1e+256) tmp = b * log(c); elseif ((b - 0.5) <= 1e+212) tmp = (y * i) + (a + (z + t)); else tmp = log(c) * (b - 0.5); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[N[(b - 0.5), $MachinePrecision], -1e+256], N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b - 0.5), $MachinePrecision], 1e+212], N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b - 0.5 \leq -1 \cdot 10^{+256}:\\
\;\;\;\;b \cdot \log c\\
\mathbf{elif}\;b - 0.5 \leq 10^{+212}:\\
\;\;\;\;y \cdot i + \left(a + \left(z + t\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\log c \cdot \left(b - 0.5\right)\\
\end{array}
\end{array}
if (-.f64 b #s(literal 1/2 binary64)) < -1e256Initial program 99.7%
Taylor expanded in x around 0 99.8%
+-commutative99.8%
sub-neg99.8%
metadata-eval99.8%
fma-define99.8%
+-commutative99.8%
Simplified99.8%
Taylor expanded in t around 0 79.8%
Taylor expanded in a around inf 54.2%
associate-+r+54.2%
sub-neg54.2%
metadata-eval54.2%
associate-/l*54.2%
Simplified54.2%
Taylor expanded in z around 0 54.2%
sub-neg54.2%
metadata-eval54.2%
associate-*r/54.2%
Simplified54.2%
Taylor expanded in a around 0 77.1%
Taylor expanded in b around inf 67.1%
*-commutative67.1%
Simplified67.1%
if -1e256 < (-.f64 b #s(literal 1/2 binary64)) < 9.9999999999999991e211Initial program 99.9%
Taylor expanded in x around 0 79.1%
+-commutative79.1%
sub-neg79.1%
metadata-eval79.1%
fma-define79.1%
+-commutative79.1%
Simplified79.1%
Taylor expanded in z around inf 70.1%
if 9.9999999999999991e211 < (-.f64 b #s(literal 1/2 binary64)) Initial program 99.4%
Taylor expanded in x around 0 93.3%
+-commutative93.3%
sub-neg93.3%
metadata-eval93.3%
fma-define93.3%
+-commutative93.3%
Simplified93.3%
Taylor expanded in t around 0 93.3%
Taylor expanded in a around inf 56.4%
associate-+r+56.4%
sub-neg56.4%
metadata-eval56.4%
associate-/l*56.4%
Simplified56.4%
Taylor expanded in z around 0 50.6%
sub-neg50.6%
metadata-eval50.6%
associate-*r/50.6%
Simplified50.6%
Taylor expanded in a around 0 74.8%
Taylor expanded in y around 0 61.5%
Final simplification69.5%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= x -5.6e+188) (not (<= x 2.55e+216))) (+ (* x (log y)) (* y i)) (+ (* y i) (+ a (+ z t)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x <= -5.6e+188) || !(x <= 2.55e+216)) {
tmp = (x * log(y)) + (y * i);
} else {
tmp = (y * i) + (a + (z + t));
}
return tmp;
}
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 <= (-5.6d+188)) .or. (.not. (x <= 2.55d+216))) then
tmp = (x * log(y)) + (y * i)
else
tmp = (y * i) + (a + (z + t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((x <= -5.6e+188) || !(x <= 2.55e+216)) {
tmp = (x * Math.log(y)) + (y * i);
} else {
tmp = (y * i) + (a + (z + t));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (x <= -5.6e+188) or not (x <= 2.55e+216): tmp = (x * math.log(y)) + (y * i) else: tmp = (y * i) + (a + (z + t)) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((x <= -5.6e+188) || !(x <= 2.55e+216)) tmp = Float64(Float64(x * log(y)) + Float64(y * i)); else tmp = Float64(Float64(y * i) + Float64(a + Float64(z + t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((x <= -5.6e+188) || ~((x <= 2.55e+216))) tmp = (x * log(y)) + (y * i); else tmp = (y * i) + (a + (z + t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[x, -5.6e+188], N[Not[LessEqual[x, 2.55e+216]], $MachinePrecision]], N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -5.6 \cdot 10^{+188} \lor \neg \left(x \leq 2.55 \cdot 10^{+216}\right):\\
\;\;\;\;x \cdot \log y + y \cdot i\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(a + \left(z + t\right)\right)\\
\end{array}
\end{array}
if x < -5.5999999999999996e188 or 2.55e216 < x Initial program 99.8%
Taylor expanded in x around inf 89.5%
if -5.5999999999999996e188 < x < 2.55e216Initial program 99.9%
Taylor expanded in x around 0 91.6%
+-commutative91.6%
sub-neg91.6%
metadata-eval91.6%
fma-define91.6%
+-commutative91.6%
Simplified91.6%
Taylor expanded in z around inf 73.7%
Final simplification76.7%
(FPCore (x y z t a b c i) :precision binary64 (if (<= b -4.6e+265) (+ a (* (log c) (- b 0.5))) (if (<= b 2.25e+192) (+ (* y i) (+ a (+ z t))) (+ t (+ z (* b (log c)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (b <= -4.6e+265) {
tmp = a + (log(c) * (b - 0.5));
} else if (b <= 2.25e+192) {
tmp = (y * i) + (a + (z + t));
} else {
tmp = t + (z + (b * log(c)));
}
return tmp;
}
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 <= (-4.6d+265)) then
tmp = a + (log(c) * (b - 0.5d0))
else if (b <= 2.25d+192) then
tmp = (y * i) + (a + (z + t))
else
tmp = t + (z + (b * log(c)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (b <= -4.6e+265) {
tmp = a + (Math.log(c) * (b - 0.5));
} else if (b <= 2.25e+192) {
tmp = (y * i) + (a + (z + t));
} else {
tmp = t + (z + (b * Math.log(c)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if b <= -4.6e+265: tmp = a + (math.log(c) * (b - 0.5)) elif b <= 2.25e+192: tmp = (y * i) + (a + (z + t)) else: tmp = t + (z + (b * math.log(c))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (b <= -4.6e+265) tmp = Float64(a + Float64(log(c) * Float64(b - 0.5))); elseif (b <= 2.25e+192) tmp = Float64(Float64(y * i) + Float64(a + Float64(z + t))); else tmp = Float64(t + Float64(z + Float64(b * log(c)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (b <= -4.6e+265) tmp = a + (log(c) * (b - 0.5)); elseif (b <= 2.25e+192) tmp = (y * i) + (a + (z + t)); else tmp = t + (z + (b * log(c))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[b, -4.6e+265], N[(a + N[(N[Log[c], $MachinePrecision] * N[(b - 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 2.25e+192], N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t + N[(z + N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -4.6 \cdot 10^{+265}:\\
\;\;\;\;a + \log c \cdot \left(b - 0.5\right)\\
\mathbf{elif}\;b \leq 2.25 \cdot 10^{+192}:\\
\;\;\;\;y \cdot i + \left(a + \left(z + t\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t + \left(z + b \cdot \log c\right)\\
\end{array}
\end{array}
if b < -4.5999999999999999e265Initial program 99.8%
Taylor expanded in x around 0 99.8%
+-commutative99.8%
sub-neg99.8%
metadata-eval99.8%
fma-define99.8%
+-commutative99.8%
Simplified99.8%
Taylor expanded in t around 0 87.1%
Taylor expanded in y around 0 72.8%
Taylor expanded in z around 0 72.8%
if -4.5999999999999999e265 < b < 2.25e192Initial program 99.9%
Taylor expanded in x around 0 79.0%
+-commutative79.0%
sub-neg79.0%
metadata-eval79.0%
fma-define79.0%
+-commutative79.0%
Simplified79.0%
Taylor expanded in z around inf 68.7%
if 2.25e192 < b Initial program 99.5%
Taylor expanded in x around 0 94.7%
+-commutative94.7%
sub-neg94.7%
metadata-eval94.7%
fma-define94.7%
+-commutative94.7%
Simplified94.7%
Taylor expanded in a around 0 84.7%
Taylor expanded in b around inf 58.7%
*-commutative58.7%
Simplified58.7%
Final simplification68.1%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= b -1.56e+249) (not (<= b 1.05e+213))) (* b (log c)) (+ (* y i) (+ a (+ z t)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((b <= -1.56e+249) || !(b <= 1.05e+213)) {
tmp = b * log(c);
} else {
tmp = (y * i) + (a + (z + t));
}
return tmp;
}
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.56d+249)) .or. (.not. (b <= 1.05d+213))) then
tmp = b * log(c)
else
tmp = (y * i) + (a + (z + t))
end if
code = tmp
end function
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.56e+249) || !(b <= 1.05e+213)) {
tmp = b * Math.log(c);
} else {
tmp = (y * i) + (a + (z + t));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (b <= -1.56e+249) or not (b <= 1.05e+213): tmp = b * math.log(c) else: tmp = (y * i) + (a + (z + t)) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((b <= -1.56e+249) || !(b <= 1.05e+213)) tmp = Float64(b * log(c)); else tmp = Float64(Float64(y * i) + Float64(a + Float64(z + t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((b <= -1.56e+249) || ~((b <= 1.05e+213))) tmp = b * log(c); else tmp = (y * i) + (a + (z + t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[b, -1.56e+249], N[Not[LessEqual[b, 1.05e+213]], $MachinePrecision]], N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.56 \cdot 10^{+249} \lor \neg \left(b \leq 1.05 \cdot 10^{+213}\right):\\
\;\;\;\;b \cdot \log c\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(a + \left(z + t\right)\right)\\
\end{array}
\end{array}
if b < -1.56e249 or 1.05e213 < b Initial program 99.5%
Taylor expanded in x around 0 95.9%
+-commutative95.9%
sub-neg95.9%
metadata-eval95.9%
fma-define95.9%
+-commutative95.9%
Simplified95.9%
Taylor expanded in t around 0 87.9%
Taylor expanded in a around inf 55.5%
associate-+r+55.5%
sub-neg55.5%
metadata-eval55.5%
associate-/l*55.5%
Simplified55.5%
Taylor expanded in z around 0 52.0%
sub-neg52.0%
metadata-eval52.0%
associate-*r/52.0%
Simplified52.0%
Taylor expanded in a around 0 75.7%
Taylor expanded in b around inf 63.7%
*-commutative63.7%
Simplified63.7%
if -1.56e249 < b < 1.05e213Initial program 99.9%
Taylor expanded in x around 0 79.1%
+-commutative79.1%
sub-neg79.1%
metadata-eval79.1%
fma-define79.1%
+-commutative79.1%
Simplified79.1%
Taylor expanded in z around inf 70.1%
Final simplification69.5%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= i -7.5e+145) (not (<= i 1.45e+65))) (* y i) z))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((i <= -7.5e+145) || !(i <= 1.45e+65)) {
tmp = y * i;
} else {
tmp = z;
}
return tmp;
}
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 ((i <= (-7.5d+145)) .or. (.not. (i <= 1.45d+65))) then
tmp = y * i
else
tmp = z
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((i <= -7.5e+145) || !(i <= 1.45e+65)) {
tmp = y * i;
} else {
tmp = z;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (i <= -7.5e+145) or not (i <= 1.45e+65): tmp = y * i else: tmp = z return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((i <= -7.5e+145) || !(i <= 1.45e+65)) tmp = Float64(y * i); else tmp = z; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((i <= -7.5e+145) || ~((i <= 1.45e+65))) tmp = y * i; else tmp = z; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[i, -7.5e+145], N[Not[LessEqual[i, 1.45e+65]], $MachinePrecision]], N[(y * i), $MachinePrecision], z]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;i \leq -7.5 \cdot 10^{+145} \lor \neg \left(i \leq 1.45 \cdot 10^{+65}\right):\\
\;\;\;\;y \cdot i\\
\mathbf{else}:\\
\;\;\;\;z\\
\end{array}
\end{array}
if i < -7.50000000000000006e145 or 1.45e65 < i Initial program 100.0%
Taylor expanded in x around 0 90.5%
+-commutative90.5%
sub-neg90.5%
metadata-eval90.5%
fma-define90.5%
+-commutative90.5%
Simplified90.5%
Taylor expanded in y around inf 52.3%
if -7.50000000000000006e145 < i < 1.45e65Initial program 99.8%
Taylor expanded in z around inf 23.3%
Taylor expanded in i around inf 13.2%
Taylor expanded in z around inf 12.8%
Taylor expanded in i around 0 9.9%
Taylor expanded in i around 0 19.9%
Final simplification30.3%
(FPCore (x y z t a b c i) :precision binary64 (if (<= a 2.8e+83) (+ z (* y i)) (+ (+ t a) (* y i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (a <= 2.8e+83) {
tmp = z + (y * i);
} else {
tmp = (t + a) + (y * i);
}
return tmp;
}
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 (a <= 2.8d+83) then
tmp = z + (y * i)
else
tmp = (t + a) + (y * i)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (a <= 2.8e+83) {
tmp = z + (y * i);
} else {
tmp = (t + a) + (y * i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if a <= 2.8e+83: tmp = z + (y * i) else: tmp = (t + a) + (y * i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (a <= 2.8e+83) tmp = Float64(z + Float64(y * i)); else tmp = Float64(Float64(t + a) + Float64(y * i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (a <= 2.8e+83) tmp = z + (y * i); else tmp = (t + a) + (y * i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[a, 2.8e+83], N[(z + N[(y * i), $MachinePrecision]), $MachinePrecision], N[(N[(t + a), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq 2.8 \cdot 10^{+83}:\\
\;\;\;\;z + y \cdot i\\
\mathbf{else}:\\
\;\;\;\;\left(t + a\right) + y \cdot i\\
\end{array}
\end{array}
if a < 2.8e83Initial program 99.8%
Taylor expanded in z around inf 36.2%
if 2.8e83 < a Initial program 99.9%
Taylor expanded in x around 0 88.9%
+-commutative88.9%
sub-neg88.9%
metadata-eval88.9%
fma-define88.9%
+-commutative88.9%
Simplified88.9%
Taylor expanded in t around inf 75.7%
Final simplification43.0%
(FPCore (x y z t a b c i) :precision binary64 (if (<= a 1.35e+110) (+ z (* y i)) (+ a (* y i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (a <= 1.35e+110) {
tmp = z + (y * i);
} else {
tmp = a + (y * i);
}
return tmp;
}
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 (a <= 1.35d+110) then
tmp = z + (y * i)
else
tmp = a + (y * i)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (a <= 1.35e+110) {
tmp = z + (y * i);
} else {
tmp = a + (y * i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if a <= 1.35e+110: tmp = z + (y * i) else: tmp = a + (y * i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (a <= 1.35e+110) tmp = Float64(z + Float64(y * i)); else tmp = Float64(a + Float64(y * i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (a <= 1.35e+110) tmp = z + (y * i); else tmp = a + (y * i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[a, 1.35e+110], N[(z + N[(y * i), $MachinePrecision]), $MachinePrecision], N[(a + N[(y * i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq 1.35 \cdot 10^{+110}:\\
\;\;\;\;z + y \cdot i\\
\mathbf{else}:\\
\;\;\;\;a + y \cdot i\\
\end{array}
\end{array}
if a < 1.35000000000000005e110Initial program 99.8%
Taylor expanded in z around inf 36.6%
if 1.35000000000000005e110 < a Initial program 99.9%
Taylor expanded in a around inf 67.1%
(FPCore (x y z t a b c i) :precision binary64 (if (<= t -5.6e-33) z (+ a (* y i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (t <= -5.6e-33) {
tmp = z;
} else {
tmp = a + (y * i);
}
return tmp;
}
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 (t <= (-5.6d-33)) then
tmp = z
else
tmp = a + (y * i)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (t <= -5.6e-33) {
tmp = z;
} else {
tmp = a + (y * i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if t <= -5.6e-33: tmp = z else: tmp = a + (y * i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (t <= -5.6e-33) tmp = z; else tmp = Float64(a + Float64(y * i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (t <= -5.6e-33) tmp = z; else tmp = a + (y * i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[t, -5.6e-33], z, N[(a + N[(y * i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.6 \cdot 10^{-33}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;a + y \cdot i\\
\end{array}
\end{array}
if t < -5.6e-33Initial program 99.9%
Taylor expanded in z around inf 33.7%
Taylor expanded in i around inf 25.8%
Taylor expanded in z around inf 25.9%
Taylor expanded in i around 0 11.6%
Taylor expanded in i around 0 19.4%
if -5.6e-33 < t Initial program 99.8%
Taylor expanded in a around inf 38.7%
(FPCore (x y z t a b c i) :precision binary64 (+ (* y i) (+ a (+ z t))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + (a + (z + t));
}
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) + (a + (z + t))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + (a + (z + t));
}
def code(x, y, z, t, a, b, c, i): return (y * i) + (a + (z + t))
function code(x, y, z, t, a, b, c, i) return Float64(Float64(y * i) + Float64(a + Float64(z + t))) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = (y * i) + (a + (z + t)); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(y * i), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
y \cdot i + \left(a + \left(z + t\right)\right)
\end{array}
Initial program 99.8%
Taylor expanded in x around 0 80.8%
+-commutative80.8%
sub-neg80.8%
metadata-eval80.8%
fma-define80.8%
+-commutative80.8%
Simplified80.8%
Taylor expanded in z around inf 65.8%
Final simplification65.8%
(FPCore (x y z t a b c i) :precision binary64 z)
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return z;
}
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 = z
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return z;
}
def code(x, y, z, t, a, b, c, i): return z
function code(x, y, z, t, a, b, c, i) return z end
function tmp = code(x, y, z, t, a, b, c, i) tmp = z; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := z
\begin{array}{l}
\\
z
\end{array}
Initial program 99.8%
Taylor expanded in z around inf 35.1%
Taylor expanded in i around inf 28.3%
Taylor expanded in z around inf 27.6%
Taylor expanded in i around 0 9.7%
Taylor expanded in i around 0 16.6%
herbie shell --seed 2024107
(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)))