
(FPCore (x y z t a b c i) :precision binary64 (/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + 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 * y) + z) * y) + 27464.7644705d0) * y) + 230661.510616d0) * y) + t) / (((((((y + a) * y) + b) * y) + 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 * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i);
}
def code(x, y, z, t, a, b, c, i): return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i)
function code(x, y, z, t, a, b, c, i) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(y + a) * y) + b) * y) + c) * y) + i)) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision] * y), $MachinePrecision] + 27464.7644705), $MachinePrecision] * y), $MachinePrecision] + 230661.510616), $MachinePrecision] * y), $MachinePrecision] + t), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(y + a), $MachinePrecision] * y), $MachinePrecision] + b), $MachinePrecision] * y), $MachinePrecision] + c), $MachinePrecision] * y), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + 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 y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + 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 * y) + z) * y) + 27464.7644705d0) * y) + 230661.510616d0) * y) + t) / (((((((y + a) * y) + b) * y) + 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 * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i);
}
def code(x, y, z, t, a, b, c, i): return ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i)
function code(x, y, z, t, a, b, c, i) return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(y + a) * y) + b) * y) + c) * y) + i)) end
function tmp = code(x, y, z, t, a, b, c, i) tmp = ((((((((x * y) + z) * y) + 27464.7644705) * y) + 230661.510616) * y) + t) / (((((((y + a) * y) + b) * y) + c) * y) + i); end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision] * y), $MachinePrecision] + 27464.7644705), $MachinePrecision] * y), $MachinePrecision] + 230661.510616), $MachinePrecision] * y), $MachinePrecision] + t), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(y + a), $MachinePrecision] * y), $MachinePrecision] + b), $MachinePrecision] * y), $MachinePrecision] + c), $MachinePrecision] * y), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}
\end{array}
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1
(/
(+
t
(* y (+ 230661.510616 (* y (+ 27464.7644705 (* y (+ z (* x y))))))))
(+ i (* y (+ c (* y (+ (* y (+ y a)) b))))))))
(if (<= t_1 INFINITY) t_1 (+ (/ z y) (- x (/ a (/ y x)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (x * y)))))))) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = (z / y) + (x - (a / (y / x)));
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (x * y)))))))) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = (z / y) + (x - (a / (y / x)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (x * y)))))))) / (i + (y * (c + (y * ((y * (y + a)) + b))))) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = (z / y) + (x - (a / (y / x))) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * Float64(z + Float64(x * y)))))))) / Float64(i + Float64(y * Float64(c + Float64(y * Float64(Float64(y * Float64(y + a)) + b)))))) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (x * y)))))))) / (i + (y * (c + (y * ((y * (y + a)) + b))))); tmp = 0.0; if (t_1 <= Inf) tmp = t_1; else tmp = (z / y) + (x - (a / (y / x))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(t + N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * N[(z + N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot \left(z + x \cdot y\right)\right)\right)}{i + y \cdot \left(c + y \cdot \left(y \cdot \left(y + a\right) + b\right)\right)}\\
\mathbf{if}\;t_1 \leq \infty:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\end{array}
\end{array}
if (/.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x y) z) y) 54929528941/2000000) y) 28832688827/125000) y) t) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 y a) y) b) y) c) y) i)) < +inf.0Initial program 94.3%
if +inf.0 < (/.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x y) z) y) 54929528941/2000000) y) 28832688827/125000) y) t) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 y a) y) b) y) c) y) i)) Initial program 0.0%
Taylor expanded in y around inf 63.5%
associate--l+63.5%
associate-/l*66.0%
Simplified66.0%
Final simplification81.6%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (/ z y) (- x (/ a (/ y x))))))
(if (<= y -5.5e+144)
t_1
(if (<= y -4.6e+51)
(/ 1.0 (+ (/ 1.0 x) (/ (- (/ a x) (/ z (* x x))) y)))
(if (<= y -2.8e+33)
(/ z y)
(if (<= y 1.65e+47)
(/
(+ t (* y (+ 230661.510616 (* z (* y y)))))
(+ i (* y (+ c (* y (+ (* y (+ y a)) b))))))
t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -5.5e+144) {
tmp = t_1;
} else if (y <= -4.6e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -2.8e+33) {
tmp = z / y;
} else if (y <= 1.65e+47) {
tmp = (t + (y * (230661.510616 + (z * (y * y))))) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} 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 = (z / y) + (x - (a / (y / x)))
if (y <= (-5.5d+144)) then
tmp = t_1
else if (y <= (-4.6d+51)) then
tmp = 1.0d0 / ((1.0d0 / x) + (((a / x) - (z / (x * x))) / y))
else if (y <= (-2.8d+33)) then
tmp = z / y
else if (y <= 1.65d+47) then
tmp = (t + (y * (230661.510616d0 + (z * (y * y))))) / (i + (y * (c + (y * ((y * (y + a)) + b)))))
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 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -5.5e+144) {
tmp = t_1;
} else if (y <= -4.6e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -2.8e+33) {
tmp = z / y;
} else if (y <= 1.65e+47) {
tmp = (t + (y * (230661.510616 + (z * (y * y))))) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (z / y) + (x - (a / (y / x))) tmp = 0 if y <= -5.5e+144: tmp = t_1 elif y <= -4.6e+51: tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)) elif y <= -2.8e+33: tmp = z / y elif y <= 1.65e+47: tmp = (t + (y * (230661.510616 + (z * (y * y))))) / (i + (y * (c + (y * ((y * (y + a)) + b))))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))) tmp = 0.0 if (y <= -5.5e+144) tmp = t_1; elseif (y <= -4.6e+51) tmp = Float64(1.0 / Float64(Float64(1.0 / x) + Float64(Float64(Float64(a / x) - Float64(z / Float64(x * x))) / y))); elseif (y <= -2.8e+33) tmp = Float64(z / y); elseif (y <= 1.65e+47) tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(z * Float64(y * y))))) / Float64(i + Float64(y * Float64(c + Float64(y * Float64(Float64(y * Float64(y + a)) + b)))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (z / y) + (x - (a / (y / x))); tmp = 0.0; if (y <= -5.5e+144) tmp = t_1; elseif (y <= -4.6e+51) tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)); elseif (y <= -2.8e+33) tmp = z / y; elseif (y <= 1.65e+47) tmp = (t + (y * (230661.510616 + (z * (y * y))))) / (i + (y * (c + (y * ((y * (y + a)) + b))))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -5.5e+144], t$95$1, If[LessEqual[y, -4.6e+51], N[(1.0 / N[(N[(1.0 / x), $MachinePrecision] + N[(N[(N[(a / x), $MachinePrecision] - N[(z / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.8e+33], N[(z / y), $MachinePrecision], If[LessEqual[y, 1.65e+47], N[(N[(t + N[(y * N[(230661.510616 + N[(z * N[(y * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{if}\;y \leq -5.5 \cdot 10^{+144}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.6 \cdot 10^{+51}:\\
\;\;\;\;\frac{1}{\frac{1}{x} + \frac{\frac{a}{x} - \frac{z}{x \cdot x}}{y}}\\
\mathbf{elif}\;y \leq -2.8 \cdot 10^{+33}:\\
\;\;\;\;\frac{z}{y}\\
\mathbf{elif}\;y \leq 1.65 \cdot 10^{+47}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + z \cdot \left(y \cdot y\right)\right)}{i + y \cdot \left(c + y \cdot \left(y \cdot \left(y + a\right) + b\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -5.50000000000000022e144 or 1.65e47 < y Initial program 2.2%
Taylor expanded in y around inf 70.0%
associate--l+70.0%
associate-/l*72.9%
Simplified72.9%
if -5.50000000000000022e144 < y < -4.6000000000000001e51Initial program 5.3%
clear-num5.3%
inv-pow5.3%
Applied egg-rr5.3%
unpow-15.3%
fma-udef5.3%
*-commutative5.3%
fma-def5.3%
Simplified5.3%
Taylor expanded in y around -inf 57.1%
mul-1-neg57.1%
distribute-lft-out--57.1%
unpow257.1%
Simplified57.1%
if -4.6000000000000001e51 < y < -2.8000000000000001e33Initial program 34.8%
Taylor expanded in z around inf 34.8%
associate-/l*67.3%
fma-def67.3%
+-commutative67.3%
*-commutative67.3%
fma-udef67.3%
fma-udef67.3%
Simplified67.3%
Taylor expanded in y around inf 67.0%
if -2.8000000000000001e33 < y < 1.65e47Initial program 95.3%
Taylor expanded in z around inf 89.1%
*-commutative89.1%
unpow289.1%
Simplified89.1%
Final simplification80.2%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (/ z y) (- x (/ a (/ y x))))))
(if (<= y -1.35e+145)
t_1
(if (<= y -4.6e+51)
(/ 1.0 (+ (/ 1.0 x) (/ (- (/ a x) (/ z (* x x))) y)))
(if (<= y -4.5e+36)
(/ z y)
(if (<= y 1.35e+48)
(/
(+ t (* y (+ 230661.510616 (* y 27464.7644705))))
(+ i (* y (+ c (* y (+ (* y (+ y a)) b))))))
t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -1.35e+145) {
tmp = t_1;
} else if (y <= -4.6e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -4.5e+36) {
tmp = z / y;
} else if (y <= 1.35e+48) {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} 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 = (z / y) + (x - (a / (y / x)))
if (y <= (-1.35d+145)) then
tmp = t_1
else if (y <= (-4.6d+51)) then
tmp = 1.0d0 / ((1.0d0 / x) + (((a / x) - (z / (x * x))) / y))
else if (y <= (-4.5d+36)) then
tmp = z / y
else if (y <= 1.35d+48) then
tmp = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / (i + (y * (c + (y * ((y * (y + a)) + b)))))
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 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -1.35e+145) {
tmp = t_1;
} else if (y <= -4.6e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -4.5e+36) {
tmp = z / y;
} else if (y <= 1.35e+48) {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (z / y) + (x - (a / (y / x))) tmp = 0 if y <= -1.35e+145: tmp = t_1 elif y <= -4.6e+51: tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)) elif y <= -4.5e+36: tmp = z / y elif y <= 1.35e+48: tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * ((y * (y + a)) + b))))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))) tmp = 0.0 if (y <= -1.35e+145) tmp = t_1; elseif (y <= -4.6e+51) tmp = Float64(1.0 / Float64(Float64(1.0 / x) + Float64(Float64(Float64(a / x) - Float64(z / Float64(x * x))) / y))); elseif (y <= -4.5e+36) tmp = Float64(z / y); elseif (y <= 1.35e+48) tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * 27464.7644705)))) / Float64(i + Float64(y * Float64(c + Float64(y * Float64(Float64(y * Float64(y + a)) + b)))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (z / y) + (x - (a / (y / x))); tmp = 0.0; if (y <= -1.35e+145) tmp = t_1; elseif (y <= -4.6e+51) tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)); elseif (y <= -4.5e+36) tmp = z / y; elseif (y <= 1.35e+48) tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * ((y * (y + a)) + b))))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.35e+145], t$95$1, If[LessEqual[y, -4.6e+51], N[(1.0 / N[(N[(1.0 / x), $MachinePrecision] + N[(N[(N[(a / x), $MachinePrecision] - N[(z / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -4.5e+36], N[(z / y), $MachinePrecision], If[LessEqual[y, 1.35e+48], N[(N[(t + N[(y * N[(230661.510616 + N[(y * 27464.7644705), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{if}\;y \leq -1.35 \cdot 10^{+145}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.6 \cdot 10^{+51}:\\
\;\;\;\;\frac{1}{\frac{1}{x} + \frac{\frac{a}{x} - \frac{z}{x \cdot x}}{y}}\\
\mathbf{elif}\;y \leq -4.5 \cdot 10^{+36}:\\
\;\;\;\;\frac{z}{y}\\
\mathbf{elif}\;y \leq 1.35 \cdot 10^{+48}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{i + y \cdot \left(c + y \cdot \left(y \cdot \left(y + a\right) + b\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -1.35000000000000011e145 or 1.35000000000000002e48 < y Initial program 2.2%
Taylor expanded in y around inf 70.0%
associate--l+70.0%
associate-/l*72.9%
Simplified72.9%
if -1.35000000000000011e145 < y < -4.6000000000000001e51Initial program 5.3%
clear-num5.3%
inv-pow5.3%
Applied egg-rr5.3%
unpow-15.3%
fma-udef5.3%
*-commutative5.3%
fma-def5.3%
Simplified5.3%
Taylor expanded in y around -inf 57.1%
mul-1-neg57.1%
distribute-lft-out--57.1%
unpow257.1%
Simplified57.1%
if -4.6000000000000001e51 < y < -4.49999999999999997e36Initial program 52.2%
Taylor expanded in z around inf 52.2%
associate-/l*99.2%
fma-def99.2%
+-commutative99.2%
*-commutative99.2%
fma-udef99.2%
fma-udef99.2%
Simplified99.2%
Taylor expanded in y around inf 100.0%
if -4.49999999999999997e36 < y < 1.35000000000000002e48Initial program 94.6%
Taylor expanded in y around 0 83.0%
*-commutative83.0%
Simplified83.0%
Final simplification77.3%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (/ z y) (- x (/ a (/ y x))))))
(if (<= y -2.1e+145)
t_1
(if (<= y -5.7e+51)
(/ 1.0 (+ (/ 1.0 x) (/ (- (/ a x) (/ z (* x x))) y)))
(if (<= y -1.62e+35)
(/ z y)
(if (<= y 1.48e+47)
(/
(+ t (* y 230661.510616))
(+ i (* y (+ c (* y (+ (* y (+ y a)) b))))))
t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -2.1e+145) {
tmp = t_1;
} else if (y <= -5.7e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -1.62e+35) {
tmp = z / y;
} else if (y <= 1.48e+47) {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} 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 = (z / y) + (x - (a / (y / x)))
if (y <= (-2.1d+145)) then
tmp = t_1
else if (y <= (-5.7d+51)) then
tmp = 1.0d0 / ((1.0d0 / x) + (((a / x) - (z / (x * x))) / y))
else if (y <= (-1.62d+35)) then
tmp = z / y
else if (y <= 1.48d+47) then
tmp = (t + (y * 230661.510616d0)) / (i + (y * (c + (y * ((y * (y + a)) + b)))))
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 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -2.1e+145) {
tmp = t_1;
} else if (y <= -5.7e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -1.62e+35) {
tmp = z / y;
} else if (y <= 1.48e+47) {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (z / y) + (x - (a / (y / x))) tmp = 0 if y <= -2.1e+145: tmp = t_1 elif y <= -5.7e+51: tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)) elif y <= -1.62e+35: tmp = z / y elif y <= 1.48e+47: tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * ((y * (y + a)) + b))))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))) tmp = 0.0 if (y <= -2.1e+145) tmp = t_1; elseif (y <= -5.7e+51) tmp = Float64(1.0 / Float64(Float64(1.0 / x) + Float64(Float64(Float64(a / x) - Float64(z / Float64(x * x))) / y))); elseif (y <= -1.62e+35) tmp = Float64(z / y); elseif (y <= 1.48e+47) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * Float64(c + Float64(y * Float64(Float64(y * Float64(y + a)) + b)))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (z / y) + (x - (a / (y / x))); tmp = 0.0; if (y <= -2.1e+145) tmp = t_1; elseif (y <= -5.7e+51) tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)); elseif (y <= -1.62e+35) tmp = z / y; elseif (y <= 1.48e+47) tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * ((y * (y + a)) + b))))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.1e+145], t$95$1, If[LessEqual[y, -5.7e+51], N[(1.0 / N[(N[(1.0 / x), $MachinePrecision] + N[(N[(N[(a / x), $MachinePrecision] - N[(z / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.62e+35], N[(z / y), $MachinePrecision], If[LessEqual[y, 1.48e+47], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{if}\;y \leq -2.1 \cdot 10^{+145}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -5.7 \cdot 10^{+51}:\\
\;\;\;\;\frac{1}{\frac{1}{x} + \frac{\frac{a}{x} - \frac{z}{x \cdot x}}{y}}\\
\mathbf{elif}\;y \leq -1.62 \cdot 10^{+35}:\\
\;\;\;\;\frac{z}{y}\\
\mathbf{elif}\;y \leq 1.48 \cdot 10^{+47}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot \left(y \cdot \left(y + a\right) + b\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -2.09999999999999989e145 or 1.47999999999999996e47 < y Initial program 2.2%
Taylor expanded in y around inf 70.0%
associate--l+70.0%
associate-/l*72.9%
Simplified72.9%
if -2.09999999999999989e145 < y < -5.7000000000000002e51Initial program 5.3%
clear-num5.3%
inv-pow5.3%
Applied egg-rr5.3%
unpow-15.3%
fma-udef5.3%
*-commutative5.3%
fma-def5.3%
Simplified5.3%
Taylor expanded in y around -inf 57.1%
mul-1-neg57.1%
distribute-lft-out--57.1%
unpow257.1%
Simplified57.1%
if -5.7000000000000002e51 < y < -1.62e35Initial program 52.2%
Taylor expanded in z around inf 52.2%
associate-/l*99.2%
fma-def99.2%
+-commutative99.2%
*-commutative99.2%
fma-udef99.2%
fma-udef99.2%
Simplified99.2%
Taylor expanded in y around inf 100.0%
if -1.62e35 < y < 1.47999999999999996e47Initial program 94.6%
Taylor expanded in y around 0 81.9%
*-commutative81.9%
Simplified81.9%
Final simplification76.7%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (/ z y) (- x (/ a (/ y x))))))
(if (<= y -5.1e+144)
t_1
(if (<= y -4.6e+51)
(/ 1.0 (+ (/ 1.0 x) (/ (- (/ a x) (/ z (* x x))) y)))
(if (<= y -3e-14)
(/
(+
t
(* y (+ 230661.510616 (* y (+ 27464.7644705 (* y (+ z (* x y))))))))
(* y c))
(if (<= y 6.1e+47)
(/
(+ t (* y 230661.510616))
(+ i (* y (+ c (* y (+ (* y (+ y a)) b))))))
t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -5.1e+144) {
tmp = t_1;
} else if (y <= -4.6e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -3e-14) {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (x * y)))))))) / (y * c);
} else if (y <= 6.1e+47) {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} 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 = (z / y) + (x - (a / (y / x)))
if (y <= (-5.1d+144)) then
tmp = t_1
else if (y <= (-4.6d+51)) then
tmp = 1.0d0 / ((1.0d0 / x) + (((a / x) - (z / (x * x))) / y))
else if (y <= (-3d-14)) then
tmp = (t + (y * (230661.510616d0 + (y * (27464.7644705d0 + (y * (z + (x * y)))))))) / (y * c)
else if (y <= 6.1d+47) then
tmp = (t + (y * 230661.510616d0)) / (i + (y * (c + (y * ((y * (y + a)) + b)))))
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 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -5.1e+144) {
tmp = t_1;
} else if (y <= -4.6e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -3e-14) {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (x * y)))))))) / (y * c);
} else if (y <= 6.1e+47) {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (z / y) + (x - (a / (y / x))) tmp = 0 if y <= -5.1e+144: tmp = t_1 elif y <= -4.6e+51: tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)) elif y <= -3e-14: tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (x * y)))))))) / (y * c) elif y <= 6.1e+47: tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * ((y * (y + a)) + b))))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))) tmp = 0.0 if (y <= -5.1e+144) tmp = t_1; elseif (y <= -4.6e+51) tmp = Float64(1.0 / Float64(Float64(1.0 / x) + Float64(Float64(Float64(a / x) - Float64(z / Float64(x * x))) / y))); elseif (y <= -3e-14) tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * Float64(z + Float64(x * y)))))))) / Float64(y * c)); elseif (y <= 6.1e+47) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * Float64(c + Float64(y * Float64(Float64(y * Float64(y + a)) + b)))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (z / y) + (x - (a / (y / x))); tmp = 0.0; if (y <= -5.1e+144) tmp = t_1; elseif (y <= -4.6e+51) tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)); elseif (y <= -3e-14) tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (x * y)))))))) / (y * c); elseif (y <= 6.1e+47) tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * ((y * (y + a)) + b))))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -5.1e+144], t$95$1, If[LessEqual[y, -4.6e+51], N[(1.0 / N[(N[(1.0 / x), $MachinePrecision] + N[(N[(N[(a / x), $MachinePrecision] - N[(z / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3e-14], N[(N[(t + N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * N[(z + N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.1e+47], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{if}\;y \leq -5.1 \cdot 10^{+144}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.6 \cdot 10^{+51}:\\
\;\;\;\;\frac{1}{\frac{1}{x} + \frac{\frac{a}{x} - \frac{z}{x \cdot x}}{y}}\\
\mathbf{elif}\;y \leq -3 \cdot 10^{-14}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot \left(z + x \cdot y\right)\right)\right)}{y \cdot c}\\
\mathbf{elif}\;y \leq 6.1 \cdot 10^{+47}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot \left(y \cdot \left(y + a\right) + b\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -5.0999999999999999e144 or 6.10000000000000019e47 < y Initial program 2.2%
Taylor expanded in y around inf 70.0%
associate--l+70.0%
associate-/l*72.9%
Simplified72.9%
if -5.0999999999999999e144 < y < -4.6000000000000001e51Initial program 5.3%
clear-num5.3%
inv-pow5.3%
Applied egg-rr5.3%
unpow-15.3%
fma-udef5.3%
*-commutative5.3%
fma-def5.3%
Simplified5.3%
Taylor expanded in y around -inf 57.1%
mul-1-neg57.1%
distribute-lft-out--57.1%
unpow257.1%
Simplified57.1%
if -4.6000000000000001e51 < y < -2.9999999999999998e-14Initial program 75.2%
Taylor expanded in c around inf 38.3%
if -2.9999999999999998e-14 < y < 6.10000000000000019e47Initial program 95.8%
Taylor expanded in y around 0 86.6%
*-commutative86.6%
Simplified86.6%
Final simplification76.9%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (/ z y) (- x (/ a (/ y x))))))
(if (<= y -1.5e+145)
t_1
(if (<= y -4.6e+51)
(/ 1.0 (+ (/ 1.0 x) (/ (- (/ a x) (/ z (* x x))) y)))
(if (<= y -9e+35)
(/ z y)
(if (<= y 1.55e+47)
(/ t (+ i (* y (+ c (* y (+ (* y (+ y a)) b))))))
t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -1.5e+145) {
tmp = t_1;
} else if (y <= -4.6e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -9e+35) {
tmp = z / y;
} else if (y <= 1.55e+47) {
tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} 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 = (z / y) + (x - (a / (y / x)))
if (y <= (-1.5d+145)) then
tmp = t_1
else if (y <= (-4.6d+51)) then
tmp = 1.0d0 / ((1.0d0 / x) + (((a / x) - (z / (x * x))) / y))
else if (y <= (-9d+35)) then
tmp = z / y
else if (y <= 1.55d+47) then
tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b)))))
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 = (z / y) + (x - (a / (y / x)));
double tmp;
if (y <= -1.5e+145) {
tmp = t_1;
} else if (y <= -4.6e+51) {
tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y));
} else if (y <= -9e+35) {
tmp = z / y;
} else if (y <= 1.55e+47) {
tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b)))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (z / y) + (x - (a / (y / x))) tmp = 0 if y <= -1.5e+145: tmp = t_1 elif y <= -4.6e+51: tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)) elif y <= -9e+35: tmp = z / y elif y <= 1.55e+47: tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b))))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))) tmp = 0.0 if (y <= -1.5e+145) tmp = t_1; elseif (y <= -4.6e+51) tmp = Float64(1.0 / Float64(Float64(1.0 / x) + Float64(Float64(Float64(a / x) - Float64(z / Float64(x * x))) / y))); elseif (y <= -9e+35) tmp = Float64(z / y); elseif (y <= 1.55e+47) tmp = Float64(t / Float64(i + Float64(y * Float64(c + Float64(y * Float64(Float64(y * Float64(y + a)) + b)))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (z / y) + (x - (a / (y / x))); tmp = 0.0; if (y <= -1.5e+145) tmp = t_1; elseif (y <= -4.6e+51) tmp = 1.0 / ((1.0 / x) + (((a / x) - (z / (x * x))) / y)); elseif (y <= -9e+35) tmp = z / y; elseif (y <= 1.55e+47) tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b))))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.5e+145], t$95$1, If[LessEqual[y, -4.6e+51], N[(1.0 / N[(N[(1.0 / x), $MachinePrecision] + N[(N[(N[(a / x), $MachinePrecision] - N[(z / N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -9e+35], N[(z / y), $MachinePrecision], If[LessEqual[y, 1.55e+47], N[(t / N[(i + N[(y * N[(c + N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{if}\;y \leq -1.5 \cdot 10^{+145}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq -4.6 \cdot 10^{+51}:\\
\;\;\;\;\frac{1}{\frac{1}{x} + \frac{\frac{a}{x} - \frac{z}{x \cdot x}}{y}}\\
\mathbf{elif}\;y \leq -9 \cdot 10^{+35}:\\
\;\;\;\;\frac{z}{y}\\
\mathbf{elif}\;y \leq 1.55 \cdot 10^{+47}:\\
\;\;\;\;\frac{t}{i + y \cdot \left(c + y \cdot \left(y \cdot \left(y + a\right) + b\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -1.5000000000000001e145 or 1.55e47 < y Initial program 2.2%
Taylor expanded in y around inf 70.0%
associate--l+70.0%
associate-/l*72.9%
Simplified72.9%
if -1.5000000000000001e145 < y < -4.6000000000000001e51Initial program 5.3%
clear-num5.3%
inv-pow5.3%
Applied egg-rr5.3%
unpow-15.3%
fma-udef5.3%
*-commutative5.3%
fma-def5.3%
Simplified5.3%
Taylor expanded in y around -inf 57.1%
mul-1-neg57.1%
distribute-lft-out--57.1%
unpow257.1%
Simplified57.1%
if -4.6000000000000001e51 < y < -8.9999999999999993e35Initial program 52.2%
Taylor expanded in z around inf 52.2%
associate-/l*99.2%
fma-def99.2%
+-commutative99.2%
*-commutative99.2%
fma-udef99.2%
fma-udef99.2%
Simplified99.2%
Taylor expanded in y around inf 100.0%
if -8.9999999999999993e35 < y < 1.55e47Initial program 94.6%
Taylor expanded in t around inf 74.7%
Final simplification72.9%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -1.15e+35) (not (<= y 1.72e+47))) (+ (/ z y) (- x (/ a (/ y x)))) (/ t (+ i (* y (+ c (* y (+ (* y (+ y a)) b))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.15e+35) || !(y <= 1.72e+47)) {
tmp = (z / y) + (x - (a / (y / x)));
} else {
tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b)))));
}
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.15d+35)) .or. (.not. (y <= 1.72d+47))) then
tmp = (z / y) + (x - (a / (y / x)))
else
tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b)))))
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.15e+35) || !(y <= 1.72e+47)) {
tmp = (z / y) + (x - (a / (y / x)));
} else {
tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b)))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.15e+35) or not (y <= 1.72e+47): tmp = (z / y) + (x - (a / (y / x))) else: tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b))))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.15e+35) || !(y <= 1.72e+47)) tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))); else tmp = Float64(t / Float64(i + Float64(y * Float64(c + Float64(y * Float64(Float64(y * Float64(y + a)) + b)))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.15e+35) || ~((y <= 1.72e+47))) tmp = (z / y) + (x - (a / (y / x))); else tmp = t / (i + (y * (c + (y * ((y * (y + a)) + b))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.15e+35], N[Not[LessEqual[y, 1.72e+47]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t / N[(i + N[(y * N[(c + N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.15 \cdot 10^{+35} \lor \neg \left(y \leq 1.72 \cdot 10^{+47}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{i + y \cdot \left(c + y \cdot \left(y \cdot \left(y + a\right) + b\right)\right)}\\
\end{array}
\end{array}
if y < -1.1499999999999999e35 or 1.72000000000000002e47 < y Initial program 3.6%
Taylor expanded in y around inf 65.1%
associate--l+65.1%
associate-/l*67.5%
Simplified67.5%
if -1.1499999999999999e35 < y < 1.72000000000000002e47Initial program 94.6%
Taylor expanded in t around inf 74.7%
Final simplification71.3%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -2.4e+34) (not (<= y 7.1e+47))) (+ (/ z y) (- x (/ a (/ y x)))) (/ (+ t (* y (+ 230661.510616 (* y 27464.7644705)))) (+ i (* y c)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -2.4e+34) || !(y <= 7.1e+47)) {
tmp = (z / y) + (x - (a / (y / x)));
} else {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * 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 <= (-2.4d+34)) .or. (.not. (y <= 7.1d+47))) then
tmp = (z / y) + (x - (a / (y / x)))
else
tmp = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / (i + (y * 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 <= -2.4e+34) || !(y <= 7.1e+47)) {
tmp = (z / y) + (x - (a / (y / x)));
} else {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * c));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -2.4e+34) or not (y <= 7.1e+47): tmp = (z / y) + (x - (a / (y / x))) else: tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * c)) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -2.4e+34) || !(y <= 7.1e+47)) tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))); else tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * 27464.7644705)))) / Float64(i + Float64(y * c))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -2.4e+34) || ~((y <= 7.1e+47))) tmp = (z / y) + (x - (a / (y / x))); else tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * c)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -2.4e+34], N[Not[LessEqual[y, 7.1e+47]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t + N[(y * N[(230661.510616 + N[(y * 27464.7644705), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.4 \cdot 10^{+34} \lor \neg \left(y \leq 7.1 \cdot 10^{+47}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{i + y \cdot c}\\
\end{array}
\end{array}
if y < -2.39999999999999987e34 or 7.1000000000000002e47 < y Initial program 3.6%
Taylor expanded in y around inf 65.1%
associate--l+65.1%
associate-/l*67.5%
Simplified67.5%
if -2.39999999999999987e34 < y < 7.1000000000000002e47Initial program 94.6%
Taylor expanded in y around 0 83.0%
*-commutative83.0%
Simplified83.0%
Taylor expanded in y around 0 72.7%
*-commutative72.7%
Simplified72.7%
Final simplification70.2%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -1.25e+35) (not (<= y 3e+47))) (+ (/ z y) (- x (/ a (/ y x)))) (/ 1.0 (/ (+ i (* y (+ c (* y b)))) t))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.25e+35) || !(y <= 3e+47)) {
tmp = (z / y) + (x - (a / (y / x)));
} else {
tmp = 1.0 / ((i + (y * (c + (y * b)))) / 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 ((y <= (-1.25d+35)) .or. (.not. (y <= 3d+47))) then
tmp = (z / y) + (x - (a / (y / x)))
else
tmp = 1.0d0 / ((i + (y * (c + (y * b)))) / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.25e+35) || !(y <= 3e+47)) {
tmp = (z / y) + (x - (a / (y / x)));
} else {
tmp = 1.0 / ((i + (y * (c + (y * b)))) / t);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.25e+35) or not (y <= 3e+47): tmp = (z / y) + (x - (a / (y / x))) else: tmp = 1.0 / ((i + (y * (c + (y * b)))) / t) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.25e+35) || !(y <= 3e+47)) tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))); else tmp = Float64(1.0 / Float64(Float64(i + Float64(y * Float64(c + Float64(y * b)))) / t)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.25e+35) || ~((y <= 3e+47))) tmp = (z / y) + (x - (a / (y / x))); else tmp = 1.0 / ((i + (y * (c + (y * b)))) / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.25e+35], N[Not[LessEqual[y, 3e+47]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.25 \cdot 10^{+35} \lor \neg \left(y \leq 3 \cdot 10^{+47}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\frac{i + y \cdot \left(c + y \cdot b\right)}{t}}\\
\end{array}
\end{array}
if y < -1.25000000000000005e35 or 3.0000000000000001e47 < y Initial program 3.6%
Taylor expanded in y around inf 65.1%
associate--l+65.1%
associate-/l*67.5%
Simplified67.5%
if -1.25000000000000005e35 < y < 3.0000000000000001e47Initial program 94.6%
clear-num93.6%
inv-pow93.6%
Applied egg-rr93.6%
unpow-193.6%
fma-udef93.6%
*-commutative93.6%
fma-def93.6%
Simplified93.6%
Taylor expanded in t around inf 73.7%
Taylor expanded in y around 0 72.5%
Final simplification70.1%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -6.8e+28)
x
(if (<= y -3.2e-62)
(/ (/ t c) y)
(if (<= y 1.65e-40) (/ t i) (if (<= y 1.6e+48) (* x (/ (* y y) b)) x)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -6.8e+28) {
tmp = x;
} else if (y <= -3.2e-62) {
tmp = (t / c) / y;
} else if (y <= 1.65e-40) {
tmp = t / i;
} else if (y <= 1.6e+48) {
tmp = x * ((y * y) / b);
} else {
tmp = x;
}
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 <= (-6.8d+28)) then
tmp = x
else if (y <= (-3.2d-62)) then
tmp = (t / c) / y
else if (y <= 1.65d-40) then
tmp = t / i
else if (y <= 1.6d+48) then
tmp = x * ((y * y) / b)
else
tmp = x
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 <= -6.8e+28) {
tmp = x;
} else if (y <= -3.2e-62) {
tmp = (t / c) / y;
} else if (y <= 1.65e-40) {
tmp = t / i;
} else if (y <= 1.6e+48) {
tmp = x * ((y * y) / b);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -6.8e+28: tmp = x elif y <= -3.2e-62: tmp = (t / c) / y elif y <= 1.65e-40: tmp = t / i elif y <= 1.6e+48: tmp = x * ((y * y) / b) else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -6.8e+28) tmp = x; elseif (y <= -3.2e-62) tmp = Float64(Float64(t / c) / y); elseif (y <= 1.65e-40) tmp = Float64(t / i); elseif (y <= 1.6e+48) tmp = Float64(x * Float64(Float64(y * y) / b)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -6.8e+28) tmp = x; elseif (y <= -3.2e-62) tmp = (t / c) / y; elseif (y <= 1.65e-40) tmp = t / i; elseif (y <= 1.6e+48) tmp = x * ((y * y) / b); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -6.8e+28], x, If[LessEqual[y, -3.2e-62], N[(N[(t / c), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[y, 1.65e-40], N[(t / i), $MachinePrecision], If[LessEqual[y, 1.6e+48], N[(x * N[(N[(y * y), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision], x]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.8 \cdot 10^{+28}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -3.2 \cdot 10^{-62}:\\
\;\;\;\;\frac{\frac{t}{c}}{y}\\
\mathbf{elif}\;y \leq 1.65 \cdot 10^{-40}:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{elif}\;y \leq 1.6 \cdot 10^{+48}:\\
\;\;\;\;x \cdot \frac{y \cdot y}{b}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -6.8e28 or 1.6000000000000001e48 < y Initial program 3.5%
Taylor expanded in y around inf 51.9%
if -6.8e28 < y < -3.20000000000000021e-62Initial program 94.7%
Taylor expanded in c around inf 46.1%
Taylor expanded in y around 0 35.2%
associate-/r*35.4%
Simplified35.4%
if -3.20000000000000021e-62 < y < 1.64999999999999996e-40Initial program 99.7%
Taylor expanded in y around 0 61.8%
if 1.64999999999999996e-40 < y < 1.6000000000000001e48Initial program 71.1%
Taylor expanded in x around inf 26.0%
Taylor expanded in b around inf 16.0%
associate-/l*32.3%
unpow232.3%
Simplified32.3%
associate-/r/32.3%
Applied egg-rr32.3%
Final simplification53.0%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -5.7e+51)
x
(if (<= y -1.14e-63)
(+ (/ (/ t c) y) (/ 230661.510616 c))
(if (<= y 2.1e-40) (/ t i) (if (<= y 3.05e+49) (* x (/ (* y y) b)) x)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -5.7e+51) {
tmp = x;
} else if (y <= -1.14e-63) {
tmp = ((t / c) / y) + (230661.510616 / c);
} else if (y <= 2.1e-40) {
tmp = t / i;
} else if (y <= 3.05e+49) {
tmp = x * ((y * y) / b);
} else {
tmp = x;
}
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 <= (-5.7d+51)) then
tmp = x
else if (y <= (-1.14d-63)) then
tmp = ((t / c) / y) + (230661.510616d0 / c)
else if (y <= 2.1d-40) then
tmp = t / i
else if (y <= 3.05d+49) then
tmp = x * ((y * y) / b)
else
tmp = x
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 <= -5.7e+51) {
tmp = x;
} else if (y <= -1.14e-63) {
tmp = ((t / c) / y) + (230661.510616 / c);
} else if (y <= 2.1e-40) {
tmp = t / i;
} else if (y <= 3.05e+49) {
tmp = x * ((y * y) / b);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -5.7e+51: tmp = x elif y <= -1.14e-63: tmp = ((t / c) / y) + (230661.510616 / c) elif y <= 2.1e-40: tmp = t / i elif y <= 3.05e+49: tmp = x * ((y * y) / b) else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -5.7e+51) tmp = x; elseif (y <= -1.14e-63) tmp = Float64(Float64(Float64(t / c) / y) + Float64(230661.510616 / c)); elseif (y <= 2.1e-40) tmp = Float64(t / i); elseif (y <= 3.05e+49) tmp = Float64(x * Float64(Float64(y * y) / b)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -5.7e+51) tmp = x; elseif (y <= -1.14e-63) tmp = ((t / c) / y) + (230661.510616 / c); elseif (y <= 2.1e-40) tmp = t / i; elseif (y <= 3.05e+49) tmp = x * ((y * y) / b); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -5.7e+51], x, If[LessEqual[y, -1.14e-63], N[(N[(N[(t / c), $MachinePrecision] / y), $MachinePrecision] + N[(230661.510616 / c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.1e-40], N[(t / i), $MachinePrecision], If[LessEqual[y, 3.05e+49], N[(x * N[(N[(y * y), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision], x]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.7 \cdot 10^{+51}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -1.14 \cdot 10^{-63}:\\
\;\;\;\;\frac{\frac{t}{c}}{y} + \frac{230661.510616}{c}\\
\mathbf{elif}\;y \leq 2.1 \cdot 10^{-40}:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{elif}\;y \leq 3.05 \cdot 10^{+49}:\\
\;\;\;\;x \cdot \frac{y \cdot y}{b}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -5.7000000000000002e51 or 3.04999999999999982e49 < y Initial program 2.7%
Taylor expanded in y around inf 53.1%
if -5.7000000000000002e51 < y < -1.1400000000000001e-63Initial program 87.2%
Taylor expanded in c around inf 40.7%
Taylor expanded in y around 0 31.9%
+-commutative31.9%
associate-/r*32.0%
associate-*r/32.0%
metadata-eval32.0%
Simplified32.0%
if -1.1400000000000001e-63 < y < 2.10000000000000018e-40Initial program 99.7%
Taylor expanded in y around 0 61.8%
if 2.10000000000000018e-40 < y < 3.04999999999999982e49Initial program 71.1%
Taylor expanded in x around inf 26.0%
Taylor expanded in b around inf 16.0%
associate-/l*32.3%
unpow232.3%
Simplified32.3%
associate-/r/32.3%
Applied egg-rr32.3%
Final simplification53.1%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -4.8e+33) (not (<= y 1.48e+47))) (+ (/ z y) (- x (/ a (/ y x)))) (/ 1.0 (/ (+ i (* y c)) t))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -4.8e+33) || !(y <= 1.48e+47)) {
tmp = (z / y) + (x - (a / (y / x)));
} else {
tmp = 1.0 / ((i + (y * c)) / 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 ((y <= (-4.8d+33)) .or. (.not. (y <= 1.48d+47))) then
tmp = (z / y) + (x - (a / (y / x)))
else
tmp = 1.0d0 / ((i + (y * c)) / 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 ((y <= -4.8e+33) || !(y <= 1.48e+47)) {
tmp = (z / y) + (x - (a / (y / x)));
} else {
tmp = 1.0 / ((i + (y * c)) / t);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -4.8e+33) or not (y <= 1.48e+47): tmp = (z / y) + (x - (a / (y / x))) else: tmp = 1.0 / ((i + (y * c)) / t) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -4.8e+33) || !(y <= 1.48e+47)) tmp = Float64(Float64(z / y) + Float64(x - Float64(a / Float64(y / x)))); else tmp = Float64(1.0 / Float64(Float64(i + Float64(y * c)) / t)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -4.8e+33) || ~((y <= 1.48e+47))) tmp = (z / y) + (x - (a / (y / x))); else tmp = 1.0 / ((i + (y * c)) / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -4.8e+33], N[Not[LessEqual[y, 1.48e+47]], $MachinePrecision]], N[(N[(z / y), $MachinePrecision] + N[(x - N[(a / N[(y / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(N[(i + N[(y * c), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.8 \cdot 10^{+33} \lor \neg \left(y \leq 1.48 \cdot 10^{+47}\right):\\
\;\;\;\;\frac{z}{y} + \left(x - \frac{a}{\frac{y}{x}}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{\frac{i + y \cdot c}{t}}\\
\end{array}
\end{array}
if y < -4.8e33 or 1.47999999999999996e47 < y Initial program 3.6%
Taylor expanded in y around inf 65.1%
associate--l+65.1%
associate-/l*67.5%
Simplified67.5%
if -4.8e33 < y < 1.47999999999999996e47Initial program 94.6%
clear-num93.6%
inv-pow93.6%
Applied egg-rr93.6%
unpow-193.6%
fma-udef93.6%
*-commutative93.6%
fma-def93.6%
Simplified93.6%
Taylor expanded in t around inf 73.7%
Taylor expanded in y around 0 65.5%
Final simplification66.5%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -2.3e+35) x (if (<= y 2.6e+48) (/ 1.0 (/ (+ i (* y c)) t)) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -2.3e+35) {
tmp = x;
} else if (y <= 2.6e+48) {
tmp = 1.0 / ((i + (y * c)) / t);
} else {
tmp = x;
}
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 <= (-2.3d+35)) then
tmp = x
else if (y <= 2.6d+48) then
tmp = 1.0d0 / ((i + (y * c)) / t)
else
tmp = x
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 <= -2.3e+35) {
tmp = x;
} else if (y <= 2.6e+48) {
tmp = 1.0 / ((i + (y * c)) / t);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -2.3e+35: tmp = x elif y <= 2.6e+48: tmp = 1.0 / ((i + (y * c)) / t) else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -2.3e+35) tmp = x; elseif (y <= 2.6e+48) tmp = Float64(1.0 / Float64(Float64(i + Float64(y * c)) / t)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -2.3e+35) tmp = x; elseif (y <= 2.6e+48) tmp = 1.0 / ((i + (y * c)) / t); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -2.3e+35], x, If[LessEqual[y, 2.6e+48], N[(1.0 / N[(N[(i + N[(y * c), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.3 \cdot 10^{+35}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 2.6 \cdot 10^{+48}:\\
\;\;\;\;\frac{1}{\frac{i + y \cdot c}{t}}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -2.2999999999999998e35 or 2.59999999999999995e48 < y Initial program 3.6%
Taylor expanded in y around inf 52.3%
if -2.2999999999999998e35 < y < 2.59999999999999995e48Initial program 94.6%
clear-num93.6%
inv-pow93.6%
Applied egg-rr93.6%
unpow-193.6%
fma-udef93.6%
*-commutative93.6%
fma-def93.6%
Simplified93.6%
Taylor expanded in t around inf 73.7%
Taylor expanded in y around 0 65.5%
Final simplification59.3%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -2.5e+28) x (if (<= y -1.32e-61) (/ t (* y c)) (if (<= y 6200000000.0) (/ t i) x))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -2.5e+28) {
tmp = x;
} else if (y <= -1.32e-61) {
tmp = t / (y * c);
} else if (y <= 6200000000.0) {
tmp = t / i;
} else {
tmp = x;
}
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 <= (-2.5d+28)) then
tmp = x
else if (y <= (-1.32d-61)) then
tmp = t / (y * c)
else if (y <= 6200000000.0d0) then
tmp = t / i
else
tmp = x
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 <= -2.5e+28) {
tmp = x;
} else if (y <= -1.32e-61) {
tmp = t / (y * c);
} else if (y <= 6200000000.0) {
tmp = t / i;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -2.5e+28: tmp = x elif y <= -1.32e-61: tmp = t / (y * c) elif y <= 6200000000.0: tmp = t / i else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -2.5e+28) tmp = x; elseif (y <= -1.32e-61) tmp = Float64(t / Float64(y * c)); elseif (y <= 6200000000.0) tmp = Float64(t / i); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -2.5e+28) tmp = x; elseif (y <= -1.32e-61) tmp = t / (y * c); elseif (y <= 6200000000.0) tmp = t / i; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -2.5e+28], x, If[LessEqual[y, -1.32e-61], N[(t / N[(y * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6200000000.0], N[(t / i), $MachinePrecision], x]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.5 \cdot 10^{+28}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -1.32 \cdot 10^{-61}:\\
\;\;\;\;\frac{t}{y \cdot c}\\
\mathbf{elif}\;y \leq 6200000000:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -2.49999999999999979e28 or 6.2e9 < y Initial program 5.0%
Taylor expanded in y around inf 49.3%
if -2.49999999999999979e28 < y < -1.32000000000000002e-61Initial program 94.7%
Taylor expanded in c around inf 46.1%
Taylor expanded in y around 0 35.2%
if -1.32000000000000002e-61 < y < 6.2e9Initial program 99.7%
Taylor expanded in y around 0 56.4%
Final simplification51.1%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -4.2e+29) x (if (<= y -7e-62) (/ (/ t c) y) (if (<= y 12500000000000.0) (/ t i) x))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -4.2e+29) {
tmp = x;
} else if (y <= -7e-62) {
tmp = (t / c) / y;
} else if (y <= 12500000000000.0) {
tmp = t / i;
} else {
tmp = x;
}
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 <= (-4.2d+29)) then
tmp = x
else if (y <= (-7d-62)) then
tmp = (t / c) / y
else if (y <= 12500000000000.0d0) then
tmp = t / i
else
tmp = x
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 <= -4.2e+29) {
tmp = x;
} else if (y <= -7e-62) {
tmp = (t / c) / y;
} else if (y <= 12500000000000.0) {
tmp = t / i;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -4.2e+29: tmp = x elif y <= -7e-62: tmp = (t / c) / y elif y <= 12500000000000.0: tmp = t / i else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -4.2e+29) tmp = x; elseif (y <= -7e-62) tmp = Float64(Float64(t / c) / y); elseif (y <= 12500000000000.0) tmp = Float64(t / i); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -4.2e+29) tmp = x; elseif (y <= -7e-62) tmp = (t / c) / y; elseif (y <= 12500000000000.0) tmp = t / i; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -4.2e+29], x, If[LessEqual[y, -7e-62], N[(N[(t / c), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[y, 12500000000000.0], N[(t / i), $MachinePrecision], x]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.2 \cdot 10^{+29}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -7 \cdot 10^{-62}:\\
\;\;\;\;\frac{\frac{t}{c}}{y}\\
\mathbf{elif}\;y \leq 12500000000000:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -4.2000000000000003e29 or 1.25e13 < y Initial program 5.0%
Taylor expanded in y around inf 49.3%
if -4.2000000000000003e29 < y < -7.0000000000000003e-62Initial program 94.7%
Taylor expanded in c around inf 46.1%
Taylor expanded in y around 0 35.2%
associate-/r*35.4%
Simplified35.4%
if -7.0000000000000003e-62 < y < 1.25e13Initial program 99.7%
Taylor expanded in y around 0 56.4%
Final simplification51.1%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -3e-14) x (if (<= y 820000000.0) (/ t i) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -3e-14) {
tmp = x;
} else if (y <= 820000000.0) {
tmp = t / i;
} else {
tmp = x;
}
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 <= (-3d-14)) then
tmp = x
else if (y <= 820000000.0d0) then
tmp = t / i
else
tmp = x
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 <= -3e-14) {
tmp = x;
} else if (y <= 820000000.0) {
tmp = t / i;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -3e-14: tmp = x elif y <= 820000000.0: tmp = t / i else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -3e-14) tmp = x; elseif (y <= 820000000.0) tmp = Float64(t / i); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -3e-14) tmp = x; elseif (y <= 820000000.0) tmp = t / i; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -3e-14], x, If[LessEqual[y, 820000000.0], N[(t / i), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3 \cdot 10^{-14}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 820000000:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -2.9999999999999998e-14 or 8.2e8 < y Initial program 10.5%
Taylor expanded in y around inf 47.0%
if -2.9999999999999998e-14 < y < 8.2e8Initial program 99.6%
Taylor expanded in y around 0 52.2%
Final simplification49.4%
(FPCore (x y z t a b c i) :precision binary64 x)
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return x;
}
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
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
return x;
}
def code(x, y, z, t, a, b, c, i): return x
function code(x, y, z, t, a, b, c, i) return x end
function tmp = code(x, y, z, t, a, b, c, i) tmp = x; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 51.9%
Taylor expanded in y around inf 26.7%
Final simplification26.7%
herbie shell --seed 2023185
(FPCore (x y z t a b c i)
:name "Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2"
:precision binary64
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))