
(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 15 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
(/
(+
(* y (+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616))
t)
(+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
(if (<= t_1 1e+263) t_1 (+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
double tmp;
if (t_1 <= 1e+263) {
tmp = t_1;
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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) :: t_1
real(8) :: tmp
t_1 = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705d0)) + 230661.510616d0)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
if (t_1 <= 1d+263) then
tmp = t_1
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 t_1 = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
double tmp;
if (t_1 <= 1e+263) {
tmp = t_1;
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i) tmp = 0 if t_1 <= 1e+263: tmp = t_1 else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(Float64(x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i)) tmp = 0.0 if (t_1 <= 1e+263) tmp = t_1; else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i); tmp = 0.0; if (t_1 <= 1e+263) tmp = t_1; else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(N[(y * N[(N[(y * N[(N[(y * N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] + 27464.7644705), $MachinePrecision]), $MachinePrecision] + 230661.510616), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision] / N[(N[(y * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 1e+263], t$95$1, N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{y \cdot \left(y \cdot \left(y \cdot \left(x \cdot y + z\right) + 27464.7644705\right) + 230661.510616\right) + t}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\
\mathbf{if}\;t\_1 \leq 10^{+263}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if (/.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x y) z) y) #s(literal 54929528941/2000000 binary64)) y) #s(literal 28832688827/125000 binary64)) y) t) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 y a) y) b) y) c) y) i)) < 1.00000000000000002e263Initial program 90.4%
if 1.00000000000000002e263 < (/.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x y) z) y) #s(literal 54929528941/2000000 binary64)) y) #s(literal 28832688827/125000 binary64)) y) t) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 y a) y) b) y) c) y) i)) Initial program 2.9%
Taylor expanded in y around inf 3.0%
Taylor expanded in y around -inf 77.3%
mul-1-neg77.3%
cancel-sign-sub-inv77.3%
mul-1-neg77.3%
metadata-eval77.3%
Simplified77.3%
Final simplification84.8%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y (+ (* y (+ y a)) b)) c))
(t_2
(/
(+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616)
t_1)))
(if (<= y -3.3e+50)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y -3.5e+15)
t_2
(if (<= y 1.15e+30)
(/
(+ t (* y (+ 230661.510616 (* y (+ 27464.7644705 (* y z))))))
(+ (* y t_1) i))
(if (<= y 3.1e+62)
t_2
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (y * ((y * (y + a)) + b)) + c;
double t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1;
double tmp;
if (y <= -3.3e+50) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= -3.5e+15) {
tmp = t_2;
} else if (y <= 1.15e+30) {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / ((y * t_1) + i);
} else if (y <= 3.1e+62) {
tmp = t_2;
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (y * ((y * (y + a)) + b)) + c
t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705d0)) + 230661.510616d0) / t_1
if (y <= (-3.3d+50)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= (-3.5d+15)) then
tmp = t_2
else if (y <= 1.15d+30) then
tmp = (t + (y * (230661.510616d0 + (y * (27464.7644705d0 + (y * z)))))) / ((y * t_1) + i)
else if (y <= 3.1d+62) then
tmp = t_2
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 t_1 = (y * ((y * (y + a)) + b)) + c;
double t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1;
double tmp;
if (y <= -3.3e+50) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= -3.5e+15) {
tmp = t_2;
} else if (y <= 1.15e+30) {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / ((y * t_1) + i);
} else if (y <= 3.1e+62) {
tmp = t_2;
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * ((y * (y + a)) + b)) + c t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1 tmp = 0 if y <= -3.3e+50: tmp = x + ((z / y) - (a * (x / y))) elif y <= -3.5e+15: tmp = t_2 elif y <= 1.15e+30: tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / ((y * t_1) + i) elif y <= 3.1e+62: tmp = t_2 else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c) t_2 = Float64(Float64(Float64(y * Float64(Float64(y * Float64(Float64(x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1) tmp = 0.0 if (y <= -3.3e+50) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= -3.5e+15) tmp = t_2; elseif (y <= 1.15e+30) tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * z)))))) / Float64(Float64(y * t_1) + i)); elseif (y <= 3.1e+62) tmp = t_2; else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (y * ((y * (y + a)) + b)) + c; t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1; tmp = 0.0; if (y <= -3.3e+50) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= -3.5e+15) tmp = t_2; elseif (y <= 1.15e+30) tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / ((y * t_1) + i); elseif (y <= 3.1e+62) tmp = t_2; else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(y * N[(N[(y * N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] + 27464.7644705), $MachinePrecision]), $MachinePrecision] + 230661.510616), $MachinePrecision] / t$95$1), $MachinePrecision]}, If[LessEqual[y, -3.3e+50], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3.5e+15], t$95$2, If[LessEqual[y, 1.15e+30], N[(N[(t + N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(y * t$95$1), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.1e+62], t$95$2, N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\\
t_2 := \frac{y \cdot \left(y \cdot \left(x \cdot y + z\right) + 27464.7644705\right) + 230661.510616}{t\_1}\\
\mathbf{if}\;y \leq -3.3 \cdot 10^{+50}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq -3.5 \cdot 10^{+15}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq 1.15 \cdot 10^{+30}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot z\right)\right)}{y \cdot t\_1 + i}\\
\mathbf{elif}\;y \leq 3.1 \cdot 10^{+62}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -3.3e50Initial program 3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
Simplified3.4%
Taylor expanded in y around inf 67.7%
associate--l+67.7%
associate-/l*75.0%
Simplified75.0%
if -3.3e50 < y < -3.5e15 or 1.15e30 < y < 3.10000000000000014e62Initial program 35.7%
fma-define35.7%
fma-define35.7%
fma-define35.7%
fma-define35.7%
fma-define35.7%
fma-define35.7%
fma-define35.7%
Simplified35.7%
Taylor expanded in i around 0 34.6%
Taylor expanded in t around 0 77.8%
if -3.5e15 < y < 1.15e30Initial program 99.4%
Taylor expanded in x around 0 94.2%
if 3.10000000000000014e62 < y Initial program 2.6%
Taylor expanded in y around inf 2.5%
Taylor expanded in y around -inf 73.9%
mul-1-neg73.9%
cancel-sign-sub-inv73.9%
mul-1-neg73.9%
metadata-eval73.9%
Simplified73.9%
Final simplification84.5%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616))
(t_2 (/ t_1 (+ (* y (+ (* y (+ y a)) b)) c))))
(if (<= y -2.45e+53)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y -1.85e-11)
t_2
(if (<= y 6e-26)
(/ (+ (* y t_1) t) (+ i (* y (+ c (* y b)))))
(if (<= y 5.8e+66)
t_2
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616;
double t_2 = t_1 / ((y * ((y * (y + a)) + b)) + c);
double tmp;
if (y <= -2.45e+53) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= -1.85e-11) {
tmp = t_2;
} else if (y <= 6e-26) {
tmp = ((y * t_1) + t) / (i + (y * (c + (y * b))));
} else if (y <= 5.8e+66) {
tmp = t_2;
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705d0)) + 230661.510616d0
t_2 = t_1 / ((y * ((y * (y + a)) + b)) + c)
if (y <= (-2.45d+53)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= (-1.85d-11)) then
tmp = t_2
else if (y <= 6d-26) then
tmp = ((y * t_1) + t) / (i + (y * (c + (y * b))))
else if (y <= 5.8d+66) then
tmp = t_2
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616;
double t_2 = t_1 / ((y * ((y * (y + a)) + b)) + c);
double tmp;
if (y <= -2.45e+53) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= -1.85e-11) {
tmp = t_2;
} else if (y <= 6e-26) {
tmp = ((y * t_1) + t) / (i + (y * (c + (y * b))));
} else if (y <= 5.8e+66) {
tmp = t_2;
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616 t_2 = t_1 / ((y * ((y * (y + a)) + b)) + c) tmp = 0 if y <= -2.45e+53: tmp = x + ((z / y) - (a * (x / y))) elif y <= -1.85e-11: tmp = t_2 elif y <= 6e-26: tmp = ((y * t_1) + t) / (i + (y * (c + (y * b)))) elif y <= 5.8e+66: tmp = t_2 else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(y * Float64(Float64(y * Float64(Float64(x * y) + z)) + 27464.7644705)) + 230661.510616) t_2 = Float64(t_1 / Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) tmp = 0.0 if (y <= -2.45e+53) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= -1.85e-11) tmp = t_2; elseif (y <= 6e-26) tmp = Float64(Float64(Float64(y * t_1) + t) / Float64(i + Float64(y * Float64(c + Float64(y * b))))); elseif (y <= 5.8e+66) tmp = t_2; else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616; t_2 = t_1 / ((y * ((y * (y + a)) + b)) + c); tmp = 0.0; if (y <= -2.45e+53) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= -1.85e-11) tmp = t_2; elseif (y <= 6e-26) tmp = ((y * t_1) + t) / (i + (y * (c + (y * b)))); elseif (y <= 5.8e+66) tmp = t_2; else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * N[(N[(y * N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] + 27464.7644705), $MachinePrecision]), $MachinePrecision] + 230661.510616), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 / N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.45e+53], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.85e-11], t$95$2, If[LessEqual[y, 6e-26], N[(N[(N[(y * t$95$1), $MachinePrecision] + t), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.8e+66], t$95$2, N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(y \cdot \left(x \cdot y + z\right) + 27464.7644705\right) + 230661.510616\\
t_2 := \frac{t\_1}{y \cdot \left(y \cdot \left(y + a\right) + b\right) + c}\\
\mathbf{if}\;y \leq -2.45 \cdot 10^{+53}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq -1.85 \cdot 10^{-11}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq 6 \cdot 10^{-26}:\\
\;\;\;\;\frac{y \cdot t\_1 + t}{i + y \cdot \left(c + y \cdot b\right)}\\
\mathbf{elif}\;y \leq 5.8 \cdot 10^{+66}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -2.45000000000000009e53Initial program 3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
Simplified3.4%
Taylor expanded in y around inf 67.7%
associate--l+67.7%
associate-/l*75.0%
Simplified75.0%
if -2.45000000000000009e53 < y < -1.8500000000000001e-11 or 6.00000000000000023e-26 < y < 5.79999999999999972e66Initial program 65.6%
fma-define65.6%
fma-define65.6%
fma-define65.6%
fma-define65.6%
fma-define65.6%
fma-define65.7%
fma-define65.7%
Simplified65.7%
Taylor expanded in i around 0 56.8%
Taylor expanded in t around 0 67.1%
if -1.8500000000000001e-11 < y < 6.00000000000000023e-26Initial program 99.7%
Taylor expanded in y around 0 96.3%
*-commutative96.3%
Simplified96.3%
if 5.79999999999999972e66 < y Initial program 2.6%
Taylor expanded in y around inf 2.5%
Taylor expanded in y around -inf 73.9%
mul-1-neg73.9%
cancel-sign-sub-inv73.9%
mul-1-neg73.9%
metadata-eval73.9%
Simplified73.9%
Final simplification82.9%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y (+ (* y (+ y a)) b)) c))
(t_2
(/
(+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616)
t_1)))
(if (<= y -2.3e+53)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y -2.15e-24)
t_2
(if (<= y 6e-26)
(/ (+ t (* y 230661.510616)) (+ (* y t_1) i))
(if (<= y 2.52e+64)
t_2
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (y * ((y * (y + a)) + b)) + c;
double t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1;
double tmp;
if (y <= -2.3e+53) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= -2.15e-24) {
tmp = t_2;
} else if (y <= 6e-26) {
tmp = (t + (y * 230661.510616)) / ((y * t_1) + i);
} else if (y <= 2.52e+64) {
tmp = t_2;
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (y * ((y * (y + a)) + b)) + c
t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705d0)) + 230661.510616d0) / t_1
if (y <= (-2.3d+53)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= (-2.15d-24)) then
tmp = t_2
else if (y <= 6d-26) then
tmp = (t + (y * 230661.510616d0)) / ((y * t_1) + i)
else if (y <= 2.52d+64) then
tmp = t_2
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 t_1 = (y * ((y * (y + a)) + b)) + c;
double t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1;
double tmp;
if (y <= -2.3e+53) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= -2.15e-24) {
tmp = t_2;
} else if (y <= 6e-26) {
tmp = (t + (y * 230661.510616)) / ((y * t_1) + i);
} else if (y <= 2.52e+64) {
tmp = t_2;
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * ((y * (y + a)) + b)) + c t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1 tmp = 0 if y <= -2.3e+53: tmp = x + ((z / y) - (a * (x / y))) elif y <= -2.15e-24: tmp = t_2 elif y <= 6e-26: tmp = (t + (y * 230661.510616)) / ((y * t_1) + i) elif y <= 2.52e+64: tmp = t_2 else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c) t_2 = Float64(Float64(Float64(y * Float64(Float64(y * Float64(Float64(x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1) tmp = 0.0 if (y <= -2.3e+53) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= -2.15e-24) tmp = t_2; elseif (y <= 6e-26) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(Float64(y * t_1) + i)); elseif (y <= 2.52e+64) tmp = t_2; else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (y * ((y * (y + a)) + b)) + c; t_2 = ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) / t_1; tmp = 0.0; if (y <= -2.3e+53) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= -2.15e-24) tmp = t_2; elseif (y <= 6e-26) tmp = (t + (y * 230661.510616)) / ((y * t_1) + i); elseif (y <= 2.52e+64) tmp = t_2; else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(y * N[(N[(y * N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] + 27464.7644705), $MachinePrecision]), $MachinePrecision] + 230661.510616), $MachinePrecision] / t$95$1), $MachinePrecision]}, If[LessEqual[y, -2.3e+53], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.15e-24], t$95$2, If[LessEqual[y, 6e-26], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(N[(y * t$95$1), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.52e+64], t$95$2, N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\\
t_2 := \frac{y \cdot \left(y \cdot \left(x \cdot y + z\right) + 27464.7644705\right) + 230661.510616}{t\_1}\\
\mathbf{if}\;y \leq -2.3 \cdot 10^{+53}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq -2.15 \cdot 10^{-24}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq 6 \cdot 10^{-26}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{y \cdot t\_1 + i}\\
\mathbf{elif}\;y \leq 2.52 \cdot 10^{+64}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -2.3000000000000002e53Initial program 3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
Simplified3.4%
Taylor expanded in y around inf 67.7%
associate--l+67.7%
associate-/l*75.0%
Simplified75.0%
if -2.3000000000000002e53 < y < -2.1500000000000002e-24 or 6.00000000000000023e-26 < y < 2.5199999999999999e64Initial program 67.4%
fma-define67.4%
fma-define67.4%
fma-define67.4%
fma-define67.4%
fma-define67.4%
fma-define67.5%
fma-define67.5%
Simplified67.5%
Taylor expanded in i around 0 56.5%
Taylor expanded in t around 0 66.2%
if -2.1500000000000002e-24 < y < 6.00000000000000023e-26Initial program 99.7%
Taylor expanded in y around 0 96.3%
*-commutative96.3%
Simplified96.3%
if 2.5199999999999999e64 < y Initial program 2.6%
Taylor expanded in y around inf 2.5%
Taylor expanded in y around -inf 73.9%
mul-1-neg73.9%
cancel-sign-sub-inv73.9%
mul-1-neg73.9%
metadata-eval73.9%
Simplified73.9%
Final simplification82.5%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616)))
(if (<= y -1.35e+47)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y 3.5e+29)
(/ (+ (* y t_1) t) (+ i (* y (+ c (* y (+ b (* y a)))))))
(if (<= y 3.5e+61)
(/ t_1 (+ (* y (+ (* y (+ y a)) b)) c))
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616;
double tmp;
if (y <= -1.35e+47) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 3.5e+29) {
tmp = ((y * t_1) + t) / (i + (y * (c + (y * (b + (y * a))))));
} else if (y <= 3.5e+61) {
tmp = t_1 / ((y * ((y * (y + a)) + b)) + c);
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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) :: t_1
real(8) :: tmp
t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705d0)) + 230661.510616d0
if (y <= (-1.35d+47)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= 3.5d+29) then
tmp = ((y * t_1) + t) / (i + (y * (c + (y * (b + (y * a))))))
else if (y <= 3.5d+61) then
tmp = t_1 / ((y * ((y * (y + a)) + b)) + c)
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616;
double tmp;
if (y <= -1.35e+47) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 3.5e+29) {
tmp = ((y * t_1) + t) / (i + (y * (c + (y * (b + (y * a))))));
} else if (y <= 3.5e+61) {
tmp = t_1 / ((y * ((y * (y + a)) + b)) + c);
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616 tmp = 0 if y <= -1.35e+47: tmp = x + ((z / y) - (a * (x / y))) elif y <= 3.5e+29: tmp = ((y * t_1) + t) / (i + (y * (c + (y * (b + (y * a)))))) elif y <= 3.5e+61: tmp = t_1 / ((y * ((y * (y + a)) + b)) + c) else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(y * Float64(Float64(y * Float64(Float64(x * y) + z)) + 27464.7644705)) + 230661.510616) tmp = 0.0 if (y <= -1.35e+47) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= 3.5e+29) tmp = Float64(Float64(Float64(y * t_1) + t) / Float64(i + Float64(y * Float64(c + Float64(y * Float64(b + Float64(y * a))))))); elseif (y <= 3.5e+61) tmp = Float64(t_1 / Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)); else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616; tmp = 0.0; if (y <= -1.35e+47) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= 3.5e+29) tmp = ((y * t_1) + t) / (i + (y * (c + (y * (b + (y * a)))))); elseif (y <= 3.5e+61) tmp = t_1 / ((y * ((y * (y + a)) + b)) + c); else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * N[(N[(y * N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] + 27464.7644705), $MachinePrecision]), $MachinePrecision] + 230661.510616), $MachinePrecision]}, If[LessEqual[y, -1.35e+47], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.5e+29], N[(N[(N[(y * t$95$1), $MachinePrecision] + t), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * N[(b + N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.5e+61], N[(t$95$1 / N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(y \cdot \left(x \cdot y + z\right) + 27464.7644705\right) + 230661.510616\\
\mathbf{if}\;y \leq -1.35 \cdot 10^{+47}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq 3.5 \cdot 10^{+29}:\\
\;\;\;\;\frac{y \cdot t\_1 + t}{i + y \cdot \left(c + y \cdot \left(b + y \cdot a\right)\right)}\\
\mathbf{elif}\;y \leq 3.5 \cdot 10^{+61}:\\
\;\;\;\;\frac{t\_1}{y \cdot \left(y \cdot \left(y + a\right) + b\right) + c}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -1.34999999999999998e47Initial program 3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
fma-define3.4%
Simplified3.4%
Taylor expanded in y around inf 67.7%
associate--l+67.7%
associate-/l*75.0%
Simplified75.0%
if -1.34999999999999998e47 < y < 3.49999999999999979e29Initial program 96.6%
Taylor expanded in y around 0 94.8%
if 3.49999999999999979e29 < y < 3.50000000000000018e61Initial program 35.2%
fma-define35.2%
fma-define35.2%
fma-define35.2%
fma-define35.2%
fma-define35.2%
fma-define35.2%
fma-define35.2%
Simplified35.2%
Taylor expanded in i around 0 35.2%
Taylor expanded in t around 0 68.5%
if 3.50000000000000018e61 < y Initial program 2.6%
Taylor expanded in y around inf 2.5%
Taylor expanded in y around -inf 73.9%
mul-1-neg73.9%
cancel-sign-sub-inv73.9%
mul-1-neg73.9%
metadata-eval73.9%
Simplified73.9%
Final simplification84.8%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -5e+22)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y 1.9e+30)
(/
(+ t (* y (+ 230661.510616 (* y (+ 27464.7644705 (* y z))))))
(+ i (* y (+ c (* y b)))))
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -5e+22) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 1.9e+30) {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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 (y <= (-5d+22)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= 1.9d+30) then
tmp = (t + (y * (230661.510616d0 + (y * (27464.7644705d0 + (y * z)))))) / (i + (y * (c + (y * b))))
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 (y <= -5e+22) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 1.9e+30) {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -5e+22: tmp = x + ((z / y) - (a * (x / y))) elif y <= 1.9e+30: tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * (c + (y * b)))) else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -5e+22) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= 1.9e+30) tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * z)))))) / Float64(i + Float64(y * Float64(c + Float64(y * b))))); else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -5e+22) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= 1.9e+30) tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * (c + (y * b)))); else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -5e+22], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.9e+30], N[(N[(t + N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5 \cdot 10^{+22}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq 1.9 \cdot 10^{+30}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot z\right)\right)}{i + y \cdot \left(c + y \cdot b\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -4.9999999999999996e22Initial program 3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
Simplified3.5%
Taylor expanded in y around inf 64.0%
associate--l+64.0%
associate-/l*70.9%
Simplified70.9%
if -4.9999999999999996e22 < y < 1.9000000000000001e30Initial program 99.4%
Taylor expanded in x around 0 93.5%
Taylor expanded in y around 0 86.4%
*-commutative89.0%
Simplified86.4%
if 1.9000000000000001e30 < y Initial program 9.3%
Taylor expanded in y around inf 4.2%
Taylor expanded in y around -inf 60.9%
mul-1-neg60.9%
cancel-sign-sub-inv60.9%
mul-1-neg60.9%
metadata-eval60.9%
Simplified60.9%
Final simplification76.4%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -3.5e+53)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y 2e+32)
(/ (+ t (* y 230661.510616)) (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -3.5e+53) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 2e+32) {
tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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 (y <= (-3.5d+53)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= 2d+32) then
tmp = (t + (y * 230661.510616d0)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 (y <= -3.5e+53) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 2e+32) {
tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -3.5e+53: tmp = x + ((z / y) - (a * (x / y))) elif y <= 2e+32: tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i) else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -3.5e+53) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= 2e+32) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i)); else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -3.5e+53) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= 2e+32) tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i); else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -3.5e+53], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2e+32], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(N[(y * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.5 \cdot 10^{+53}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq 2 \cdot 10^{+32}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -3.50000000000000019e53Initial program 1.9%
fma-define1.9%
fma-define1.9%
fma-define1.9%
fma-define1.9%
fma-define1.9%
fma-define1.9%
fma-define1.9%
Simplified1.9%
Taylor expanded in y around inf 68.6%
associate--l+68.6%
associate-/l*75.9%
Simplified75.9%
if -3.50000000000000019e53 < y < 2.00000000000000011e32Initial program 96.6%
Taylor expanded in y around 0 82.8%
*-commutative82.8%
Simplified82.8%
if 2.00000000000000011e32 < y Initial program 9.3%
Taylor expanded in y around inf 4.2%
Taylor expanded in y around -inf 60.9%
mul-1-neg60.9%
cancel-sign-sub-inv60.9%
mul-1-neg60.9%
metadata-eval60.9%
Simplified60.9%
Final simplification76.1%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -3.85e+25)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y 1.2e+33)
(/
(+ t (* y (+ 230661.510616 (* y 27464.7644705))))
(+ i (* y (+ c (* y b)))))
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -3.85e+25) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 1.2e+33) {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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 (y <= (-3.85d+25)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= 1.2d+33) then
tmp = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / (i + (y * (c + (y * b))))
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 (y <= -3.85e+25) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 1.2e+33) {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -3.85e+25: tmp = x + ((z / y) - (a * (x / y))) elif y <= 1.2e+33: tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * b)))) else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -3.85e+25) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= 1.2e+33) tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * 27464.7644705)))) / Float64(i + Float64(y * Float64(c + Float64(y * b))))); else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -3.85e+25) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= 1.2e+33) tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * b)))); else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -3.85e+25], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.2e+33], N[(N[(t + N[(y * N[(230661.510616 + N[(y * 27464.7644705), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.85 \cdot 10^{+25}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq 1.2 \cdot 10^{+33}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{i + y \cdot \left(c + y \cdot b\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -3.85000000000000012e25Initial program 3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
Simplified3.5%
Taylor expanded in y around inf 64.0%
associate--l+64.0%
associate-/l*70.9%
Simplified70.9%
if -3.85000000000000012e25 < y < 1.2e33Initial program 99.4%
Taylor expanded in x around 0 93.5%
Taylor expanded in y around 0 86.4%
*-commutative89.0%
Simplified86.4%
Taylor expanded in y around 0 81.9%
if 1.2e33 < y Initial program 9.3%
Taylor expanded in y around inf 4.2%
Taylor expanded in y around -inf 60.9%
mul-1-neg60.9%
cancel-sign-sub-inv60.9%
mul-1-neg60.9%
metadata-eval60.9%
Simplified60.9%
Final simplification74.2%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -1.9e+20)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y 1.2e+30)
(/ (+ t (* y 230661.510616)) (+ i (* y (+ c (* y b)))))
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -1.9e+20) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 1.2e+30) {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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 (y <= (-1.9d+20)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= 1.2d+30) then
tmp = (t + (y * 230661.510616d0)) / (i + (y * (c + (y * b))))
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 (y <= -1.9e+20) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 1.2e+30) {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -1.9e+20: tmp = x + ((z / y) - (a * (x / y))) elif y <= 1.2e+30: tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b)))) else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -1.9e+20) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= 1.2e+30) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * Float64(c + Float64(y * b))))); else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -1.9e+20) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= 1.2e+30) tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b)))); else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -1.9e+20], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.2e+30], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.9 \cdot 10^{+20}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq 1.2 \cdot 10^{+30}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot b\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -1.9e20Initial program 4.9%
fma-define4.9%
fma-define4.9%
fma-define4.9%
fma-define4.9%
fma-define4.9%
fma-define4.9%
fma-define4.9%
Simplified4.9%
Taylor expanded in y around inf 63.1%
associate--l+63.1%
associate-/l*69.9%
Simplified69.9%
if -1.9e20 < y < 1.2e30Initial program 99.4%
Taylor expanded in x around 0 93.5%
Taylor expanded in y around 0 86.3%
*-commutative88.9%
Simplified86.3%
Taylor expanded in y around 0 81.8%
if 1.2e30 < y Initial program 9.3%
Taylor expanded in y around inf 4.2%
Taylor expanded in y around -inf 60.9%
mul-1-neg60.9%
cancel-sign-sub-inv60.9%
mul-1-neg60.9%
metadata-eval60.9%
Simplified60.9%
Final simplification73.8%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -1.48e+23) (not (<= y 5.5e+30))) (+ x (- (/ z y) (* a (/ x y)))) (/ t (+ i (* y (+ c (* y b)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.48e+23) || !(y <= 5.5e+30)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = t / (i + (y * (c + (y * 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.48d+23)) .or. (.not. (y <= 5.5d+30))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = t / (i + (y * (c + (y * 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.48e+23) || !(y <= 5.5e+30)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = t / (i + (y * (c + (y * b))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.48e+23) or not (y <= 5.5e+30): tmp = x + ((z / y) - (a * (x / y))) else: tmp = t / (i + (y * (c + (y * b)))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.48e+23) || !(y <= 5.5e+30)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(t / Float64(i + Float64(y * Float64(c + Float64(y * b))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.48e+23) || ~((y <= 5.5e+30))) tmp = x + ((z / y) - (a * (x / y))); else tmp = t / (i + (y * (c + (y * b)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.48e+23], N[Not[LessEqual[y, 5.5e+30]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.48 \cdot 10^{+23} \lor \neg \left(y \leq 5.5 \cdot 10^{+30}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{i + y \cdot \left(c + y \cdot b\right)}\\
\end{array}
\end{array}
if y < -1.4799999999999999e23 or 5.50000000000000025e30 < y Initial program 6.2%
fma-define6.2%
fma-define6.2%
fma-define6.2%
fma-define6.2%
fma-define6.2%
fma-define6.2%
fma-define6.2%
Simplified6.2%
Taylor expanded in y around inf 61.1%
associate--l+61.1%
associate-/l*66.1%
Simplified66.1%
if -1.4799999999999999e23 < y < 5.50000000000000025e30Initial program 99.4%
Taylor expanded in x around 0 93.5%
Taylor expanded in y around 0 86.4%
*-commutative89.0%
Simplified86.4%
Taylor expanded in t around inf 70.4%
Final simplification68.3%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -1.05e-8) (not (<= y 4.6e+31))) (+ x (- (/ z y) (* a (/ x y)))) (+ (* 230661.510616 (/ y i)) (/ t i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.05e-8) || !(y <= 4.6e+31)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (230661.510616 * (y / i)) + (t / 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 ((y <= (-1.05d-8)) .or. (.not. (y <= 4.6d+31))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = (230661.510616d0 * (y / i)) + (t / 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 ((y <= -1.05e-8) || !(y <= 4.6e+31)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (230661.510616 * (y / i)) + (t / i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.05e-8) or not (y <= 4.6e+31): tmp = x + ((z / y) - (a * (x / y))) else: tmp = (230661.510616 * (y / i)) + (t / i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.05e-8) || !(y <= 4.6e+31)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(Float64(230661.510616 * Float64(y / i)) + Float64(t / i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.05e-8) || ~((y <= 4.6e+31))) tmp = x + ((z / y) - (a * (x / y))); else tmp = (230661.510616 * (y / i)) + (t / i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.05e-8], N[Not[LessEqual[y, 4.6e+31]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(230661.510616 * N[(y / i), $MachinePrecision]), $MachinePrecision] + N[(t / i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.05 \cdot 10^{-8} \lor \neg \left(y \leq 4.6 \cdot 10^{+31}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;230661.510616 \cdot \frac{y}{i} + \frac{t}{i}\\
\end{array}
\end{array}
if y < -1.04999999999999997e-8 or 4.5999999999999999e31 < y Initial program 11.0%
fma-define11.0%
fma-define11.0%
fma-define11.0%
fma-define11.0%
fma-define11.0%
fma-define11.0%
fma-define11.0%
Simplified11.0%
Taylor expanded in y around inf 58.4%
associate--l+58.4%
associate-/l*63.2%
Simplified63.2%
if -1.04999999999999997e-8 < y < 4.5999999999999999e31Initial program 99.4%
Taylor expanded in y around inf 65.3%
Taylor expanded in y around 0 61.1%
Final simplification62.2%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -2.25e+24)
(+ x (- (/ z y) (* a (/ x y))))
(if (<= y 9e+29)
(/ t (+ i (* y (+ c (* y b)))))
(+ x (/ (+ z (* -27464.7644705 (/ -1.0 y))) y)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -2.25e+24) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 9e+29) {
tmp = t / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / 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 (y <= (-2.25d+24)) then
tmp = x + ((z / y) - (a * (x / y)))
else if (y <= 9d+29) then
tmp = t / (i + (y * (c + (y * b))))
else
tmp = x + ((z + ((-27464.7644705d0) * ((-1.0d0) / y))) / 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 (y <= -2.25e+24) {
tmp = x + ((z / y) - (a * (x / y)));
} else if (y <= 9e+29) {
tmp = t / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -2.25e+24: tmp = x + ((z / y) - (a * (x / y))) elif y <= 9e+29: tmp = t / (i + (y * (c + (y * b)))) else: tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -2.25e+24) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); elseif (y <= 9e+29) tmp = Float64(t / Float64(i + Float64(y * Float64(c + Float64(y * b))))); else tmp = Float64(x + Float64(Float64(z + Float64(-27464.7644705 * Float64(-1.0 / y))) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -2.25e+24) tmp = x + ((z / y) - (a * (x / y))); elseif (y <= 9e+29) tmp = t / (i + (y * (c + (y * b)))); else tmp = x + ((z + (-27464.7644705 * (-1.0 / y))) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -2.25e+24], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9e+29], N[(t / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z + N[(-27464.7644705 * N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.25 \cdot 10^{+24}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{elif}\;y \leq 9 \cdot 10^{+29}:\\
\;\;\;\;\frac{t}{i + y \cdot \left(c + y \cdot b\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \frac{z + -27464.7644705 \cdot \frac{-1}{y}}{y}\\
\end{array}
\end{array}
if y < -2.2500000000000001e24Initial program 3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
fma-define3.5%
Simplified3.5%
Taylor expanded in y around inf 64.0%
associate--l+64.0%
associate-/l*70.9%
Simplified70.9%
if -2.2500000000000001e24 < y < 9.0000000000000005e29Initial program 99.4%
Taylor expanded in x around 0 93.5%
Taylor expanded in y around 0 86.4%
*-commutative89.0%
Simplified86.4%
Taylor expanded in t around inf 70.4%
if 9.0000000000000005e29 < y Initial program 9.3%
Taylor expanded in y around inf 4.2%
Taylor expanded in y around -inf 60.9%
mul-1-neg60.9%
cancel-sign-sub-inv60.9%
mul-1-neg60.9%
metadata-eval60.9%
Simplified60.9%
Final simplification68.4%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -1.85e-11) x (if (<= y 3.2e+29) (+ (* 230661.510616 (/ y i)) (/ 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 <= -1.85e-11) {
tmp = x;
} else if (y <= 3.2e+29) {
tmp = (230661.510616 * (y / i)) + (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 <= (-1.85d-11)) then
tmp = x
else if (y <= 3.2d+29) then
tmp = (230661.510616d0 * (y / i)) + (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 <= -1.85e-11) {
tmp = x;
} else if (y <= 3.2e+29) {
tmp = (230661.510616 * (y / i)) + (t / i);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -1.85e-11: tmp = x elif y <= 3.2e+29: tmp = (230661.510616 * (y / i)) + (t / i) else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -1.85e-11) tmp = x; elseif (y <= 3.2e+29) tmp = Float64(Float64(230661.510616 * Float64(y / i)) + 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 <= -1.85e-11) tmp = x; elseif (y <= 3.2e+29) tmp = (230661.510616 * (y / i)) + (t / i); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -1.85e-11], x, If[LessEqual[y, 3.2e+29], N[(N[(230661.510616 * N[(y / i), $MachinePrecision]), $MachinePrecision] + N[(t / i), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.85 \cdot 10^{-11}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 3.2 \cdot 10^{+29}:\\
\;\;\;\;230661.510616 \cdot \frac{y}{i} + \frac{t}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -1.8500000000000001e-11 or 3.19999999999999987e29 < y Initial program 12.3%
fma-define12.3%
fma-define12.3%
fma-define12.3%
fma-define12.3%
fma-define12.3%
fma-define12.3%
fma-define12.3%
Simplified12.3%
Taylor expanded in y around inf 49.5%
if -1.8500000000000001e-11 < y < 3.19999999999999987e29Initial program 99.4%
Taylor expanded in y around inf 66.3%
Taylor expanded in y around 0 62.1%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -2.15e-24) x (if (<= y 3.05e+60) (/ 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.15e-24) {
tmp = x;
} else if (y <= 3.05e+60) {
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.15d-24)) then
tmp = x
else if (y <= 3.05d+60) 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.15e-24) {
tmp = x;
} else if (y <= 3.05e+60) {
tmp = t / i;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -2.15e-24: tmp = x elif y <= 3.05e+60: tmp = t / i else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -2.15e-24) tmp = x; elseif (y <= 3.05e+60) 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.15e-24) tmp = x; elseif (y <= 3.05e+60) tmp = t / i; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -2.15e-24], x, If[LessEqual[y, 3.05e+60], N[(t / i), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.15 \cdot 10^{-24}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 3.05 \cdot 10^{+60}:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -2.1500000000000002e-24 or 3.05e60 < y Initial program 11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
Simplified11.5%
Taylor expanded in y around inf 53.2%
if -2.1500000000000002e-24 < y < 3.05e60Initial program 93.5%
fma-define93.5%
fma-define93.5%
fma-define93.5%
fma-define93.5%
fma-define93.5%
fma-define93.5%
fma-define93.5%
Simplified93.5%
Taylor expanded in y around 0 50.3%
(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 53.1%
fma-define53.1%
fma-define53.1%
fma-define53.1%
fma-define53.1%
fma-define53.1%
fma-define53.1%
fma-define53.1%
Simplified53.1%
Taylor expanded in y around inf 27.9%
herbie shell --seed 2024145
(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)))