
(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 17 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 (+ (+ (+ (+ (+ (* 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}
Initial program 99.9%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y 7e-50) (+ (* x (log y)) (+ (* (log c) (+ b -0.5)) (+ a (+ z t)))) (+ (* y i) (+ (+ z a) (* b (log c))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= 7e-50) {
tmp = (x * log(y)) + ((log(c) * (b + -0.5)) + (a + (z + t)));
} else {
tmp = (y * i) + ((z + a) + (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 (y <= 7d-50) then
tmp = (x * log(y)) + ((log(c) * (b + (-0.5d0))) + (a + (z + t)))
else
tmp = (y * i) + ((z + a) + (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 (y <= 7e-50) {
tmp = (x * Math.log(y)) + ((Math.log(c) * (b + -0.5)) + (a + (z + t)));
} else {
tmp = (y * i) + ((z + a) + (b * Math.log(c)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= 7e-50: tmp = (x * math.log(y)) + ((math.log(c) * (b + -0.5)) + (a + (z + t))) else: tmp = (y * i) + ((z + a) + (b * math.log(c))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= 7e-50) tmp = Float64(Float64(x * log(y)) + Float64(Float64(log(c) * Float64(b + -0.5)) + Float64(a + Float64(z + t)))); else tmp = Float64(Float64(y * i) + Float64(Float64(z + a) + Float64(b * log(c)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= 7e-50) tmp = (x * log(y)) + ((log(c) * (b + -0.5)) + (a + (z + t))); else tmp = (y * i) + ((z + a) + (b * log(c))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, 7e-50], N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + N[(N[(N[Log[c], $MachinePrecision] * N[(b + -0.5), $MachinePrecision]), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(N[(z + a), $MachinePrecision] + N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 7 \cdot 10^{-50}:\\
\;\;\;\;x \cdot \log y + \left(\log c \cdot \left(b + -0.5\right) + \left(a + \left(z + t\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(\left(z + a\right) + b \cdot \log c\right)\\
\end{array}
\end{array}
if y < 6.99999999999999993e-50Initial program 99.8%
Taylor expanded in y around 0
associate-+r+N/A
sum4-defineN/A
cancel-sign-subN/A
log-recN/A
unsub-negN/A
mul-1-negN/A
+-commutativeN/A
sum4-defineN/A
associate-+r+N/A
associate-+r+N/A
Simplified98.4%
if 6.99999999999999993e-50 < y Initial program 99.9%
Taylor expanded in z around inf
Simplified81.7%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6481.7%
Simplified81.7%
Final simplification88.4%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (+ (* x (log y)) z) (* y i))))
(if (<= x -6.4e+193)
t_1
(if (<= x 6e+198)
(+ (* y i) (+ (* (- b 0.5) (log c)) (+ 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 = ((x * log(y)) + z) + (y * i);
double tmp;
if (x <= -6.4e+193) {
tmp = t_1;
} else if (x <= 6e+198) {
tmp = (y * i) + (((b - 0.5) * log(c)) + (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 = ((x * log(y)) + z) + (y * i)
if (x <= (-6.4d+193)) then
tmp = t_1
else if (x <= 6d+198) then
tmp = (y * i) + (((b - 0.5d0) * log(c)) + (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 = ((x * Math.log(y)) + z) + (y * i);
double tmp;
if (x <= -6.4e+193) {
tmp = t_1;
} else if (x <= 6e+198) {
tmp = (y * i) + (((b - 0.5) * Math.log(c)) + (a + (z + t)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = ((x * math.log(y)) + z) + (y * i) tmp = 0 if x <= -6.4e+193: tmp = t_1 elif x <= 6e+198: tmp = (y * i) + (((b - 0.5) * math.log(c)) + (a + (z + t))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(Float64(x * log(y)) + z) + Float64(y * i)) tmp = 0.0 if (x <= -6.4e+193) tmp = t_1; elseif (x <= 6e+198) tmp = Float64(Float64(y * i) + Float64(Float64(Float64(b - 0.5) * log(c)) + 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 = ((x * log(y)) + z) + (y * i); tmp = 0.0; if (x <= -6.4e+193) tmp = t_1; elseif (x <= 6e+198) tmp = (y * i) + (((b - 0.5) * log(c)) + (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[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + z), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6.4e+193], t$95$1, If[LessEqual[x, 6e+198], N[(N[(y * i), $MachinePrecision] + N[(N[(N[(b - 0.5), $MachinePrecision] * N[Log[c], $MachinePrecision]), $MachinePrecision] + N[(a + N[(z + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(x \cdot \log y + z\right) + y \cdot i\\
\mathbf{if}\;x \leq -6.4 \cdot 10^{+193}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 6 \cdot 10^{+198}:\\
\;\;\;\;y \cdot i + \left(\left(b - 0.5\right) \cdot \log c + \left(a + \left(z + t\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -6.40000000000000026e193 or 6.00000000000000037e198 < x Initial program 99.7%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-lowering-+.f64N/A
log-lowering-log.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
associate-+r+N/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
log-lowering-log.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6499.7%
Simplified99.7%
Taylor expanded in z around inf
/-lowering-/.f6476.4%
Simplified76.4%
Taylor expanded in x around 0
+-commutativeN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
log-lowering-log.f6476.5%
Simplified76.5%
if -6.40000000000000026e193 < x < 6.00000000000000037e198Initial program 99.9%
Taylor expanded in x around 0
Simplified94.1%
Final simplification91.7%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (+ (* x (log y)) z) (* y i))))
(if (<= x -5.8e+193)
t_1
(if (<= x 7e+199) (+ (* y i) (+ (* (- b 0.5) (log c)) (+ z a))) t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = ((x * log(y)) + z) + (y * i);
double tmp;
if (x <= -5.8e+193) {
tmp = t_1;
} else if (x <= 7e+199) {
tmp = (y * i) + (((b - 0.5) * log(c)) + (z + a));
} 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 = ((x * log(y)) + z) + (y * i)
if (x <= (-5.8d+193)) then
tmp = t_1
else if (x <= 7d+199) then
tmp = (y * i) + (((b - 0.5d0) * log(c)) + (z + a))
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 = ((x * Math.log(y)) + z) + (y * i);
double tmp;
if (x <= -5.8e+193) {
tmp = t_1;
} else if (x <= 7e+199) {
tmp = (y * i) + (((b - 0.5) * Math.log(c)) + (z + a));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = ((x * math.log(y)) + z) + (y * i) tmp = 0 if x <= -5.8e+193: tmp = t_1 elif x <= 7e+199: tmp = (y * i) + (((b - 0.5) * math.log(c)) + (z + a)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(Float64(x * log(y)) + z) + Float64(y * i)) tmp = 0.0 if (x <= -5.8e+193) tmp = t_1; elseif (x <= 7e+199) tmp = Float64(Float64(y * i) + Float64(Float64(Float64(b - 0.5) * log(c)) + Float64(z + a))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = ((x * log(y)) + z) + (y * i); tmp = 0.0; if (x <= -5.8e+193) tmp = t_1; elseif (x <= 7e+199) tmp = (y * i) + (((b - 0.5) * log(c)) + (z + a)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + z), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -5.8e+193], t$95$1, If[LessEqual[x, 7e+199], N[(N[(y * i), $MachinePrecision] + N[(N[(N[(b - 0.5), $MachinePrecision] * N[Log[c], $MachinePrecision]), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(x \cdot \log y + z\right) + y \cdot i\\
\mathbf{if}\;x \leq -5.8 \cdot 10^{+193}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 7 \cdot 10^{+199}:\\
\;\;\;\;y \cdot i + \left(\left(b - 0.5\right) \cdot \log c + \left(z + a\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -5.80000000000000026e193 or 6.99999999999999962e199 < x Initial program 99.7%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-lowering-+.f64N/A
log-lowering-log.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
associate-+r+N/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
log-lowering-log.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6499.7%
Simplified99.7%
Taylor expanded in z around inf
/-lowering-/.f6476.4%
Simplified76.4%
Taylor expanded in x around 0
+-commutativeN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
log-lowering-log.f6476.5%
Simplified76.5%
if -5.80000000000000026e193 < x < 6.99999999999999962e199Initial program 99.9%
Taylor expanded in z around inf
Simplified79.6%
Final simplification79.2%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (+ (* x (log y)) z) (* y i))))
(if (<= x -6.4e+193)
t_1
(if (<= x 1.55e+199) (+ (* y i) (+ (+ z a) (* b (log c)))) t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = ((x * log(y)) + z) + (y * i);
double tmp;
if (x <= -6.4e+193) {
tmp = t_1;
} else if (x <= 1.55e+199) {
tmp = (y * i) + ((z + a) + (b * log(c)));
} 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 = ((x * log(y)) + z) + (y * i)
if (x <= (-6.4d+193)) then
tmp = t_1
else if (x <= 1.55d+199) then
tmp = (y * i) + ((z + a) + (b * log(c)))
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 = ((x * Math.log(y)) + z) + (y * i);
double tmp;
if (x <= -6.4e+193) {
tmp = t_1;
} else if (x <= 1.55e+199) {
tmp = (y * i) + ((z + a) + (b * Math.log(c)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = ((x * math.log(y)) + z) + (y * i) tmp = 0 if x <= -6.4e+193: tmp = t_1 elif x <= 1.55e+199: tmp = (y * i) + ((z + a) + (b * math.log(c))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(Float64(x * log(y)) + z) + Float64(y * i)) tmp = 0.0 if (x <= -6.4e+193) tmp = t_1; elseif (x <= 1.55e+199) tmp = Float64(Float64(y * i) + Float64(Float64(z + a) + Float64(b * log(c)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = ((x * log(y)) + z) + (y * i); tmp = 0.0; if (x <= -6.4e+193) tmp = t_1; elseif (x <= 1.55e+199) tmp = (y * i) + ((z + a) + (b * log(c))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision] + z), $MachinePrecision] + N[(y * i), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6.4e+193], t$95$1, If[LessEqual[x, 1.55e+199], N[(N[(y * i), $MachinePrecision] + N[(N[(z + a), $MachinePrecision] + N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(x \cdot \log y + z\right) + y \cdot i\\
\mathbf{if}\;x \leq -6.4 \cdot 10^{+193}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 1.55 \cdot 10^{+199}:\\
\;\;\;\;y \cdot i + \left(\left(z + a\right) + b \cdot \log c\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -6.40000000000000026e193 or 1.54999999999999993e199 < x Initial program 99.7%
Taylor expanded in x around inf
*-lowering-*.f64N/A
+-lowering-+.f64N/A
log-lowering-log.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
associate-+r+N/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
log-lowering-log.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
/-lowering-/.f6499.7%
Simplified99.7%
Taylor expanded in z around inf
/-lowering-/.f6476.4%
Simplified76.4%
Taylor expanded in x around 0
+-commutativeN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
log-lowering-log.f6476.5%
Simplified76.5%
if -6.40000000000000026e193 < x < 1.54999999999999993e199Initial program 99.9%
Taylor expanded in z around inf
Simplified79.6%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6478.1%
Simplified78.1%
Final simplification77.9%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y i) (+ z (* (- b 0.5) (log c))))))
(if (<= b -3.4e+83)
t_1
(if (<= b 1.05e+136) (+ (* y i) (+ (+ z a) (* (log c) -0.5))) 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) + (z + ((b - 0.5) * log(c)));
double tmp;
if (b <= -3.4e+83) {
tmp = t_1;
} else if (b <= 1.05e+136) {
tmp = (y * i) + ((z + a) + (log(c) * -0.5));
} 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 = (y * i) + (z + ((b - 0.5d0) * log(c)))
if (b <= (-3.4d+83)) then
tmp = t_1
else if (b <= 1.05d+136) then
tmp = (y * i) + ((z + a) + (log(c) * (-0.5d0)))
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) + (z + ((b - 0.5) * Math.log(c)));
double tmp;
if (b <= -3.4e+83) {
tmp = t_1;
} else if (b <= 1.05e+136) {
tmp = (y * i) + ((z + a) + (Math.log(c) * -0.5));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * i) + (z + ((b - 0.5) * math.log(c))) tmp = 0 if b <= -3.4e+83: tmp = t_1 elif b <= 1.05e+136: tmp = (y * i) + ((z + a) + (math.log(c) * -0.5)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(y * i) + Float64(z + Float64(Float64(b - 0.5) * log(c)))) tmp = 0.0 if (b <= -3.4e+83) tmp = t_1; elseif (b <= 1.05e+136) tmp = Float64(Float64(y * i) + Float64(Float64(z + a) + Float64(log(c) * -0.5))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (y * i) + (z + ((b - 0.5) * log(c))); tmp = 0.0; if (b <= -3.4e+83) tmp = t_1; elseif (b <= 1.05e+136) tmp = (y * i) + ((z + a) + (log(c) * -0.5)); 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[(z + N[(N[(b - 0.5), $MachinePrecision] * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -3.4e+83], t$95$1, If[LessEqual[b, 1.05e+136], N[(N[(y * i), $MachinePrecision] + N[(N[(z + a), $MachinePrecision] + N[(N[Log[c], $MachinePrecision] * -0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot i + \left(z + \left(b - 0.5\right) \cdot \log c\right)\\
\mathbf{if}\;b \leq -3.4 \cdot 10^{+83}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 1.05 \cdot 10^{+136}:\\
\;\;\;\;y \cdot i + \left(\left(z + a\right) + \log c \cdot -0.5\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -3.3999999999999998e83 or 1.05e136 < b Initial program 99.8%
Taylor expanded in z around inf
Simplified80.9%
if -3.3999999999999998e83 < b < 1.05e136Initial program 99.9%
Taylor expanded in z around inf
Simplified65.1%
Taylor expanded in b around 0
associate-+r+N/A
+-lowering-+.f64N/A
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6463.3%
Simplified63.3%
Final simplification69.1%
(FPCore (x y z t a b c i) :precision binary64 (if (<= z -1.05e+115) (+ (* y i) (+ z a)) (+ (* y i) (+ a (* (- b 0.5) (log c))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (z <= -1.05e+115) {
tmp = (y * i) + (z + a);
} else {
tmp = (y * i) + (a + ((b - 0.5) * 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 (z <= (-1.05d+115)) then
tmp = (y * i) + (z + a)
else
tmp = (y * i) + (a + ((b - 0.5d0) * 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 (z <= -1.05e+115) {
tmp = (y * i) + (z + a);
} else {
tmp = (y * i) + (a + ((b - 0.5) * Math.log(c)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if z <= -1.05e+115: tmp = (y * i) + (z + a) else: tmp = (y * i) + (a + ((b - 0.5) * math.log(c))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (z <= -1.05e+115) tmp = Float64(Float64(y * i) + Float64(z + a)); else tmp = Float64(Float64(y * i) + Float64(a + Float64(Float64(b - 0.5) * log(c)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (z <= -1.05e+115) tmp = (y * i) + (z + a); else tmp = (y * i) + (a + ((b - 0.5) * log(c))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[z, -1.05e+115], N[(N[(y * i), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(a + N[(N[(b - 0.5), $MachinePrecision] * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.05 \cdot 10^{+115}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(a + \left(b - 0.5\right) \cdot \log c\right)\\
\end{array}
\end{array}
if z < -1.05000000000000002e115Initial program 99.9%
Taylor expanded in z around inf
Simplified76.3%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6476.3%
Simplified76.3%
Taylor expanded in b around 0
associate-+r+N/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6469.5%
Simplified69.5%
if -1.05000000000000002e115 < z Initial program 99.9%
Taylor expanded in a around inf
Simplified61.6%
Final simplification62.9%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y 3.6e+52) (+ (* (log c) (+ b -0.5)) (+ z a)) (+ (* y i) (+ z a))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= 3.6e+52) {
tmp = (log(c) * (b + -0.5)) + (z + a);
} else {
tmp = (y * i) + (z + a);
}
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 (y <= 3.6d+52) then
tmp = (log(c) * (b + (-0.5d0))) + (z + a)
else
tmp = (y * i) + (z + a)
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 (y <= 3.6e+52) {
tmp = (Math.log(c) * (b + -0.5)) + (z + a);
} else {
tmp = (y * i) + (z + a);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= 3.6e+52: tmp = (math.log(c) * (b + -0.5)) + (z + a) else: tmp = (y * i) + (z + a) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= 3.6e+52) tmp = Float64(Float64(log(c) * Float64(b + -0.5)) + Float64(z + a)); else tmp = Float64(Float64(y * i) + Float64(z + a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= 3.6e+52) tmp = (log(c) * (b + -0.5)) + (z + a); else tmp = (y * i) + (z + a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, 3.6e+52], N[(N[(N[Log[c], $MachinePrecision] * N[(b + -0.5), $MachinePrecision]), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 3.6 \cdot 10^{+52}:\\
\;\;\;\;\log c \cdot \left(b + -0.5\right) + \left(z + a\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\end{array}
\end{array}
if y < 3.6e52Initial program 99.9%
Taylor expanded in z around inf
Simplified65.3%
Taylor expanded in y around 0
associate-+r+N/A
+-lowering-+.f64N/A
+-commutativeN/A
+-lowering-+.f64N/A
*-lowering-*.f64N/A
log-lowering-log.f64N/A
sub-negN/A
metadata-evalN/A
+-lowering-+.f6458.7%
Simplified58.7%
if 3.6e52 < y Initial program 99.9%
Taylor expanded in z around inf
Simplified83.5%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6483.5%
Simplified83.5%
Taylor expanded in b around 0
associate-+r+N/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6475.2%
Simplified75.2%
Final simplification65.4%
(FPCore (x y z t a b c i) :precision binary64 (let* ((t_1 (* b (log c)))) (if (<= b -5e+229) t_1 (if (<= b 1.22e+238) (+ (* y i) (+ z a)) t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = b * log(c);
double tmp;
if (b <= -5e+229) {
tmp = t_1;
} else if (b <= 1.22e+238) {
tmp = (y * i) + (z + a);
} 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 = b * log(c)
if (b <= (-5d+229)) then
tmp = t_1
else if (b <= 1.22d+238) then
tmp = (y * i) + (z + a)
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 = b * Math.log(c);
double tmp;
if (b <= -5e+229) {
tmp = t_1;
} else if (b <= 1.22e+238) {
tmp = (y * i) + (z + a);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = b * math.log(c) tmp = 0 if b <= -5e+229: tmp = t_1 elif b <= 1.22e+238: tmp = (y * i) + (z + a) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(b * log(c)) tmp = 0.0 if (b <= -5e+229) tmp = t_1; elseif (b <= 1.22e+238) tmp = Float64(Float64(y * i) + Float64(z + a)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = b * log(c); tmp = 0.0; if (b <= -5e+229) tmp = t_1; elseif (b <= 1.22e+238) tmp = (y * i) + (z + a); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -5e+229], t$95$1, If[LessEqual[b, 1.22e+238], N[(N[(y * i), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := b \cdot \log c\\
\mathbf{if}\;b \leq -5 \cdot 10^{+229}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 1.22 \cdot 10^{+238}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -5.0000000000000005e229 or 1.2200000000000001e238 < b Initial program 99.7%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6475.9%
Simplified75.9%
if -5.0000000000000005e229 < b < 1.2200000000000001e238Initial program 99.9%
Taylor expanded in z around inf
Simplified69.4%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6467.9%
Simplified67.9%
Taylor expanded in b around 0
associate-+r+N/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6459.3%
Simplified59.3%
Final simplification61.1%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y 1.45e+52) (+ a (+ z (* b (log c)))) (+ (* y i) (+ z a))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= 1.45e+52) {
tmp = a + (z + (b * log(c)));
} else {
tmp = (y * i) + (z + a);
}
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 (y <= 1.45d+52) then
tmp = a + (z + (b * log(c)))
else
tmp = (y * i) + (z + a)
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 (y <= 1.45e+52) {
tmp = a + (z + (b * Math.log(c)));
} else {
tmp = (y * i) + (z + a);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= 1.45e+52: tmp = a + (z + (b * math.log(c))) else: tmp = (y * i) + (z + a) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= 1.45e+52) tmp = Float64(a + Float64(z + Float64(b * log(c)))); else tmp = Float64(Float64(y * i) + Float64(z + a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= 1.45e+52) tmp = a + (z + (b * log(c))); else tmp = (y * i) + (z + a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, 1.45e+52], N[(a + N[(z + N[(b * N[Log[c], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * i), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq 1.45 \cdot 10^{+52}:\\
\;\;\;\;a + \left(z + b \cdot \log c\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\end{array}
\end{array}
if y < 1.45e52Initial program 99.9%
Taylor expanded in z around inf
Simplified65.3%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6463.1%
Simplified63.1%
Taylor expanded in y around 0
+-lowering-+.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6456.8%
Simplified56.8%
if 1.45e52 < y Initial program 99.9%
Taylor expanded in z around inf
Simplified83.5%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6483.5%
Simplified83.5%
Taylor expanded in b around 0
associate-+r+N/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6475.2%
Simplified75.2%
Final simplification64.2%
(FPCore (x y z t a b c i) :precision binary64 (if (<= x 8e+191) (+ (* y i) (+ z a)) (* x (log y))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (x <= 8e+191) {
tmp = (y * i) + (z + a);
} else {
tmp = x * log(y);
}
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 <= 8d+191) then
tmp = (y * i) + (z + a)
else
tmp = x * log(y)
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 <= 8e+191) {
tmp = (y * i) + (z + a);
} else {
tmp = x * Math.log(y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if x <= 8e+191: tmp = (y * i) + (z + a) else: tmp = x * math.log(y) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (x <= 8e+191) tmp = Float64(Float64(y * i) + Float64(z + a)); else tmp = Float64(x * log(y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (x <= 8e+191) tmp = (y * i) + (z + a); else tmp = x * log(y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[x, 8e+191], N[(N[(y * i), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision], N[(x * N[Log[y], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 8 \cdot 10^{+191}:\\
\;\;\;\;y \cdot i + \left(z + a\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \log y\\
\end{array}
\end{array}
if x < 8.00000000000000058e191Initial program 99.9%
Taylor expanded in z around inf
Simplified75.4%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6473.9%
Simplified73.9%
Taylor expanded in b around 0
associate-+r+N/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6458.2%
Simplified58.2%
if 8.00000000000000058e191 < x Initial program 99.9%
Taylor expanded in x around inf
*-lowering-*.f64N/A
log-lowering-log.f6455.0%
Simplified55.0%
Final simplification57.9%
(FPCore (x y z t a b c i) :precision binary64 (if (<= z -2e+152) z (if (<= z -7e-303) (* y i) a)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (z <= -2e+152) {
tmp = z;
} else if (z <= -7e-303) {
tmp = y * i;
} else {
tmp = a;
}
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 <= (-2d+152)) then
tmp = z
else if (z <= (-7d-303)) then
tmp = y * i
else
tmp = a
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 <= -2e+152) {
tmp = z;
} else if (z <= -7e-303) {
tmp = y * i;
} else {
tmp = a;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if z <= -2e+152: tmp = z elif z <= -7e-303: tmp = y * i else: tmp = a return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (z <= -2e+152) tmp = z; elseif (z <= -7e-303) tmp = Float64(y * i); else tmp = a; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (z <= -2e+152) tmp = z; elseif (z <= -7e-303) tmp = y * i; else tmp = a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[z, -2e+152], z, If[LessEqual[z, -7e-303], N[(y * i), $MachinePrecision], a]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2 \cdot 10^{+152}:\\
\;\;\;\;z\\
\mathbf{elif}\;z \leq -7 \cdot 10^{-303}:\\
\;\;\;\;y \cdot i\\
\mathbf{else}:\\
\;\;\;\;a\\
\end{array}
\end{array}
if z < -2.0000000000000001e152Initial program 99.9%
Taylor expanded in z around inf
Simplified61.3%
if -2.0000000000000001e152 < z < -7e-303Initial program 99.9%
Taylor expanded in y around inf
*-lowering-*.f6436.0%
Simplified36.0%
if -7e-303 < z Initial program 99.9%
Taylor expanded in a around inf
Simplified15.7%
Final simplification28.6%
(FPCore (x y z t a b c i) :precision binary64 (if (<= a 1.9e+103) (+ 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.9e+103) {
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.9d+103) 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.9e+103) {
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.9e+103: 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.9e+103) 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.9e+103) 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.9e+103], 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.9 \cdot 10^{+103}:\\
\;\;\;\;z + y \cdot i\\
\mathbf{else}:\\
\;\;\;\;a + y \cdot i\\
\end{array}
\end{array}
if a < 1.8999999999999998e103Initial program 99.9%
Taylor expanded in z around inf
Simplified44.5%
if 1.8999999999999998e103 < a Initial program 99.9%
Taylor expanded in a around inf
Simplified54.7%
(FPCore (x y z t a b c i) :precision binary64 (if (<= z -3.8e+152) 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 (z <= -3.8e+152) {
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 (z <= (-3.8d+152)) 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 (z <= -3.8e+152) {
tmp = z;
} else {
tmp = a + (y * i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if z <= -3.8e+152: tmp = z else: tmp = a + (y * i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (z <= -3.8e+152) 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 (z <= -3.8e+152) tmp = z; else tmp = a + (y * i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[z, -3.8e+152], z, N[(a + N[(y * i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.8 \cdot 10^{+152}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;a + y \cdot i\\
\end{array}
\end{array}
if z < -3.8e152Initial program 99.9%
Taylor expanded in z around inf
Simplified61.3%
if -3.8e152 < z Initial program 99.9%
Taylor expanded in a around inf
Simplified42.9%
(FPCore (x y z t a b c i) :precision binary64 (+ (* y i) (+ z a)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return (y * i) + (z + a);
}
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
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);
}
def code(x, y, z, t, a, b, c, i): return (y * i) + (z + a)
function code(x, y, z, t, a, b, c, i) return Float64(Float64(y * i) + Float64(z + a)) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = (y * i) + (z + a); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(y * i), $MachinePrecision] + N[(z + a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
y \cdot i + \left(z + a\right)
\end{array}
Initial program 99.9%
Taylor expanded in z around inf
Simplified72.7%
Taylor expanded in b around inf
*-commutativeN/A
*-lowering-*.f64N/A
log-lowering-log.f6471.4%
Simplified71.4%
Taylor expanded in b around 0
associate-+r+N/A
+-lowering-+.f64N/A
+-lowering-+.f64N/A
*-commutativeN/A
*-lowering-*.f6455.5%
Simplified55.5%
Final simplification55.5%
(FPCore (x y z t a b c i) :precision binary64 (if (<= a 8e+108) z a))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (a <= 8e+108) {
tmp = z;
} else {
tmp = a;
}
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 <= 8d+108) then
tmp = z
else
tmp = a
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 <= 8e+108) {
tmp = z;
} else {
tmp = a;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if a <= 8e+108: tmp = z else: tmp = a return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (a <= 8e+108) tmp = z; else tmp = a; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (a <= 8e+108) tmp = z; else tmp = a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[a, 8e+108], z, a]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq 8 \cdot 10^{+108}:\\
\;\;\;\;z\\
\mathbf{else}:\\
\;\;\;\;a\\
\end{array}
\end{array}
if a < 8.0000000000000003e108Initial program 99.9%
Taylor expanded in z around inf
Simplified18.1%
if 8.0000000000000003e108 < a Initial program 99.9%
Taylor expanded in a around inf
Simplified41.1%
(FPCore (x y z t a b c i) :precision binary64 a)
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return a;
}
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
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return a;
}
def code(x, y, z, t, a, b, c, i): return a
function code(x, y, z, t, a, b, c, i) return a end
function tmp = code(x, y, z, t, a, b, c, i) tmp = a; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := a
\begin{array}{l}
\\
a
\end{array}
Initial program 99.9%
Taylor expanded in a around inf
Simplified15.2%
herbie shell --seed 2024161
(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)))