
(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
(if (<=
(/
(+
(* y (+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616))
t)
(+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))
INFINITY)
(/
(fma (fma (fma (fma x y z) y 27464.7644705) y 230661.510616) y t)
(fma (fma (fma (+ y a) y b) y c) y i))
(+ x (- (/ z y) (* a (/ x y))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)) <= ((double) INFINITY)) {
tmp = fma(fma(fma(fma(x, y, z), y, 27464.7644705), y, 230661.510616), y, t) / fma(fma(fma((y + a), y, b), y, c), y, i);
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
return tmp;
}
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (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)) <= Inf) tmp = Float64(fma(fma(fma(fma(x, y, z), y, 27464.7644705), y, 230661.510616), y, t) / fma(fma(fma(Float64(y + a), y, b), y, c), y, i)); else tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); end return tmp end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[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], Infinity], N[(N[(N[(N[(N[(x * y + z), $MachinePrecision] * y + 27464.7644705), $MachinePrecision] * y + 230661.510616), $MachinePrecision] * y + t), $MachinePrecision] / N[(N[(N[(N[(y + a), $MachinePrecision] * y + b), $MachinePrecision] * y + c), $MachinePrecision] * y + i), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\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} \leq \infty:\\
\;\;\;\;\frac{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(x, y, z\right), y, 27464.7644705\right), y, 230661.510616\right), y, t\right)}{\mathsf{fma}\left(\mathsf{fma}\left(\mathsf{fma}\left(y + a, y, b\right), y, c\right), y, i\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\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 91.5%
fma-define91.6%
fma-define91.6%
fma-define91.6%
fma-define91.6%
fma-define91.6%
fma-define91.6%
fma-define91.6%
Simplified91.6%
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.9%
associate--l+63.9%
associate-/l*69.9%
Simplified69.9%
Final simplification83.6%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))
(t_2
(* y (+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616))))
(if (<= (/ (+ t_2 t) t_1) INFINITY)
(+ (/ t t_1) (/ t_2 t_1))
(+ x (- (/ z y) (* a (/ x 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 * (y + a)) + b)) + c)) + i;
double t_2 = y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616);
double tmp;
if (((t_2 + t) / t_1) <= ((double) INFINITY)) {
tmp = (t / t_1) + (t_2 / t_1);
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
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 = (y * ((y * ((y * (y + a)) + b)) + c)) + i;
double t_2 = y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616);
double tmp;
if (((t_2 + t) / t_1) <= Double.POSITIVE_INFINITY) {
tmp = (t / t_1) + (t_2 / t_1);
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * ((y * ((y * (y + a)) + b)) + c)) + i t_2 = y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616) tmp = 0 if ((t_2 + t) / t_1) <= math.inf: tmp = (t / t_1) + (t_2 / t_1) else: tmp = x + ((z / y) - (a * (x / y))) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i) t_2 = Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(Float64(x * y) + z)) + 27464.7644705)) + 230661.510616)) tmp = 0.0 if (Float64(Float64(t_2 + t) / t_1) <= Inf) tmp = Float64(Float64(t / t_1) + Float64(t_2 / t_1)); else tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (y * ((y * ((y * (y + a)) + b)) + c)) + i; t_2 = y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616); tmp = 0.0; if (((t_2 + t) / t_1) <= Inf) tmp = (t / t_1) + (t_2 / t_1); else tmp = x + ((z / y) - (a * (x / 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[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(N[(y * N[(N[(y * N[(N[(x * y), $MachinePrecision] + z), $MachinePrecision]), $MachinePrecision] + 27464.7644705), $MachinePrecision]), $MachinePrecision] + 230661.510616), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(N[(t$95$2 + t), $MachinePrecision] / t$95$1), $MachinePrecision], Infinity], N[(N[(t / t$95$1), $MachinePrecision] + N[(t$95$2 / t$95$1), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i\\
t_2 := y \cdot \left(y \cdot \left(y \cdot \left(x \cdot y + z\right) + 27464.7644705\right) + 230661.510616\right)\\
\mathbf{if}\;\frac{t\_2 + t}{t\_1} \leq \infty:\\
\;\;\;\;\frac{t}{t\_1} + \frac{t\_2}{t\_1}\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\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 91.5%
Taylor expanded in t around 0 91.6%
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.9%
associate--l+63.9%
associate-/l*69.9%
Simplified69.9%
Final simplification83.6%
(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 INFINITY) t_1 (+ x (- (/ z y) (* a (/ x 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 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
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 = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = x + ((z / y) - (a * (x / 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 <= math.inf: tmp = t_1 else: tmp = x + ((z / y) - (a * (x / 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 <= Inf) tmp = t_1; else tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / 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 <= Inf) tmp = t_1; else tmp = x + ((z / y) - (a * (x / 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, Infinity], t$95$1, N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $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 \infty:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\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 91.5%
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.9%
associate--l+63.9%
associate-/l*69.9%
Simplified69.9%
Final simplification83.6%
(FPCore (x y z t a b c i)
:precision binary64
(if (or (<= y -1.45e+62) (not (<= y 2.1e+46)))
(+ x (- (/ z y) (* a (/ x y))))
(/
(+ t (* y (+ 230661.510616 (* y (+ 27464.7644705 (* y z))))))
(+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.45e+62) || !(y <= 2.1e+46)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + 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.45d+62)) .or. (.not. (y <= 2.1d+46))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = (t + (y * (230661.510616d0 + (y * (27464.7644705d0 + (y * z)))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + 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.45e+62) || !(y <= 2.1e+46)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.45e+62) or not (y <= 2.1e+46): tmp = x + ((z / y) - (a * (x / y))) else: tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.45e+62) || !(y <= 2.1e+46)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * z)))))) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.45e+62) || ~((y <= 2.1e+46))) tmp = x + ((z / y) - (a * (x / y))); else tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.45e+62], N[Not[LessEqual[y, 2.1e+46]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 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 * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.45 \cdot 10^{+62} \lor \neg \left(y \leq 2.1 \cdot 10^{+46}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot z\right)\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\
\end{array}
\end{array}
if y < -1.44999999999999992e62 or 2.1e46 < y Initial program 2.3%
Taylor expanded in y around inf 63.1%
associate--l+63.1%
associate-/l*68.6%
Simplified68.6%
if -1.44999999999999992e62 < y < 2.1e46Initial program 96.0%
Taylor expanded in x around 0 90.0%
Final simplification81.3%
(FPCore (x y z t a b c i)
:precision binary64
(if (or (<= y -9.5e+53) (not (<= y 1.8e+42)))
(+ x (- (/ z y) (* a (/ x y))))
(/
(+ (* y (+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616)) 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 <= -9.5e+53) || !(y <= 1.8e+42)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + 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 <= (-9.5d+53)) .or. (.not. (y <= 1.8d+42))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705d0)) + 230661.510616d0)) + 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 <= -9.5e+53) || !(y <= 1.8e+42)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / (i + (y * (c + (y * b))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -9.5e+53) or not (y <= 1.8e+42): tmp = x + ((z / y) - (a * (x / y))) else: tmp = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / (i + (y * (c + (y * b)))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -9.5e+53) || !(y <= 1.8e+42)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(Float64(x * y) + z)) + 27464.7644705)) + 230661.510616)) + 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 <= -9.5e+53) || ~((y <= 1.8e+42))) tmp = x + ((z / y) - (a * (x / y))); else tmp = ((y * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / (i + (y * (c + (y * b)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -9.5e+53], N[Not[LessEqual[y, 1.8e+42]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 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[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -9.5 \cdot 10^{+53} \lor \neg \left(y \leq 1.8 \cdot 10^{+42}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{y \cdot \left(y \cdot \left(y \cdot \left(x \cdot y + z\right) + 27464.7644705\right) + 230661.510616\right) + t}{i + y \cdot \left(c + y \cdot b\right)}\\
\end{array}
\end{array}
if y < -9.5000000000000006e53 or 1.8e42 < y Initial program 2.3%
Taylor expanded in y around inf 63.1%
associate--l+63.1%
associate-/l*68.6%
Simplified68.6%
if -9.5000000000000006e53 < y < 1.8e42Initial program 96.0%
Taylor expanded in y around 0 88.4%
*-commutative79.5%
Simplified88.4%
Final simplification80.3%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1
(/ (+ t (* y (+ 230661.510616 (* y (+ 27464.7644705 (* y z)))))) i))
(t_2 (+ x (- (/ z y) (* a (/ x y))))))
(if (<= y -1.45e+50)
t_2
(if (<= y -1.5e-116)
t_1
(if (<= y -1.5e-181)
(/ (+ t (* y 230661.510616)) (* y c))
(if (<= y 9.5e+48) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / i;
double t_2 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -1.45e+50) {
tmp = t_2;
} else if (y <= -1.5e-116) {
tmp = t_1;
} else if (y <= -1.5e-181) {
tmp = (t + (y * 230661.510616)) / (y * c);
} else if (y <= 9.5e+48) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (t + (y * (230661.510616d0 + (y * (27464.7644705d0 + (y * z)))))) / i
t_2 = x + ((z / y) - (a * (x / y)))
if (y <= (-1.45d+50)) then
tmp = t_2
else if (y <= (-1.5d-116)) then
tmp = t_1
else if (y <= (-1.5d-181)) then
tmp = (t + (y * 230661.510616d0)) / (y * c)
else if (y <= 9.5d+48) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / i;
double t_2 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -1.45e+50) {
tmp = t_2;
} else if (y <= -1.5e-116) {
tmp = t_1;
} else if (y <= -1.5e-181) {
tmp = (t + (y * 230661.510616)) / (y * c);
} else if (y <= 9.5e+48) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / i t_2 = x + ((z / y) - (a * (x / y))) tmp = 0 if y <= -1.45e+50: tmp = t_2 elif y <= -1.5e-116: tmp = t_1 elif y <= -1.5e-181: tmp = (t + (y * 230661.510616)) / (y * c) elif y <= 9.5e+48: tmp = t_1 else: tmp = t_2 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 * z)))))) / i) t_2 = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))) tmp = 0.0 if (y <= -1.45e+50) tmp = t_2; elseif (y <= -1.5e-116) tmp = t_1; elseif (y <= -1.5e-181) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(y * c)); elseif (y <= 9.5e+48) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / i; t_2 = x + ((z / y) - (a * (x / y))); tmp = 0.0; if (y <= -1.45e+50) tmp = t_2; elseif (y <= -1.5e-116) tmp = t_1; elseif (y <= -1.5e-181) tmp = (t + (y * 230661.510616)) / (y * c); elseif (y <= 9.5e+48) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(t + N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.45e+50], t$95$2, If[LessEqual[y, -1.5e-116], t$95$1, If[LessEqual[y, -1.5e-181], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(y * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.5e+48], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot z\right)\right)}{i}\\
t_2 := x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -1.45 \cdot 10^{+50}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-116}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-181}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{y \cdot c}\\
\mathbf{elif}\;y \leq 9.5 \cdot 10^{+48}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y < -1.45e50 or 9.4999999999999997e48 < y Initial program 2.3%
Taylor expanded in y around inf 63.7%
associate--l+63.7%
associate-/l*69.2%
Simplified69.2%
if -1.45e50 < y < -1.50000000000000013e-116 or -1.49999999999999987e-181 < y < 9.4999999999999997e48Initial program 95.1%
Taylor expanded in i around inf 64.8%
Taylor expanded in x around 0 63.2%
if -1.50000000000000013e-116 < y < -1.49999999999999987e-181Initial program 99.5%
Taylor expanded in c around inf 74.2%
Taylor expanded in y around 0 74.2%
Final simplification66.1%
(FPCore (x y z t a b c i)
:precision binary64
(if (or (<= y -1.55e+52) (not (<= y 2.5e+49)))
(+ x (- (/ z y) (* a (/ x y))))
(/
(+ t (* y (+ 230661.510616 (* y 27464.7644705))))
(+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.55e+52) || !(y <= 2.5e+49)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + 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.55d+52)) .or. (.not. (y <= 2.5d+49))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + 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.55e+52) || !(y <= 2.5e+49)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.55e+52) or not (y <= 2.5e+49): tmp = x + ((z / y) - (a * (x / y))) else: tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.55e+52) || !(y <= 2.5e+49)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * 27464.7644705)))) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.55e+52) || ~((y <= 2.5e+49))) tmp = x + ((z / y) - (a * (x / y))); else tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.55e+52], N[Not[LessEqual[y, 2.5e+49]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(t + N[(y * N[(230661.510616 + N[(y * 27464.7644705), $MachinePrecision]), $MachinePrecision]), $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]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.55 \cdot 10^{+52} \lor \neg \left(y \leq 2.5 \cdot 10^{+49}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\
\end{array}
\end{array}
if y < -1.55e52 or 2.5000000000000002e49 < y Initial program 2.4%
Taylor expanded in y around inf 64.3%
associate--l+64.3%
associate-/l*69.9%
Simplified69.9%
if -1.55e52 < y < 2.5000000000000002e49Initial program 94.7%
Taylor expanded in y around 0 83.4%
*-commutative83.4%
Simplified83.4%
Final simplification78.0%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ t (* y 230661.510616)))
(t_2 (/ t_1 i))
(t_3 (+ x (- (/ z y) (* a (/ x y))))))
(if (<= y -170000000.0)
t_3
(if (<= y -1.5e-116)
t_2
(if (<= y -1.5e-181)
(/ t_1 (* y c))
(if (<= y 49000000000000.0) t_2 t_3))))))
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);
double t_2 = t_1 / i;
double t_3 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -170000000.0) {
tmp = t_3;
} else if (y <= -1.5e-116) {
tmp = t_2;
} else if (y <= -1.5e-181) {
tmp = t_1 / (y * c);
} else if (y <= 49000000000000.0) {
tmp = t_2;
} else {
tmp = t_3;
}
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) :: t_3
real(8) :: tmp
t_1 = t + (y * 230661.510616d0)
t_2 = t_1 / i
t_3 = x + ((z / y) - (a * (x / y)))
if (y <= (-170000000.0d0)) then
tmp = t_3
else if (y <= (-1.5d-116)) then
tmp = t_2
else if (y <= (-1.5d-181)) then
tmp = t_1 / (y * c)
else if (y <= 49000000000000.0d0) then
tmp = t_2
else
tmp = t_3
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 = t + (y * 230661.510616);
double t_2 = t_1 / i;
double t_3 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -170000000.0) {
tmp = t_3;
} else if (y <= -1.5e-116) {
tmp = t_2;
} else if (y <= -1.5e-181) {
tmp = t_1 / (y * c);
} else if (y <= 49000000000000.0) {
tmp = t_2;
} else {
tmp = t_3;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = t + (y * 230661.510616) t_2 = t_1 / i t_3 = x + ((z / y) - (a * (x / y))) tmp = 0 if y <= -170000000.0: tmp = t_3 elif y <= -1.5e-116: tmp = t_2 elif y <= -1.5e-181: tmp = t_1 / (y * c) elif y <= 49000000000000.0: tmp = t_2 else: tmp = t_3 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(t + Float64(y * 230661.510616)) t_2 = Float64(t_1 / i) t_3 = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))) tmp = 0.0 if (y <= -170000000.0) tmp = t_3; elseif (y <= -1.5e-116) tmp = t_2; elseif (y <= -1.5e-181) tmp = Float64(t_1 / Float64(y * c)); elseif (y <= 49000000000000.0) tmp = t_2; else tmp = t_3; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = t + (y * 230661.510616); t_2 = t_1 / i; t_3 = x + ((z / y) - (a * (x / y))); tmp = 0.0; if (y <= -170000000.0) tmp = t_3; elseif (y <= -1.5e-116) tmp = t_2; elseif (y <= -1.5e-181) tmp = t_1 / (y * c); elseif (y <= 49000000000000.0) tmp = t_2; else tmp = t_3; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 / i), $MachinePrecision]}, Block[{t$95$3 = N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -170000000.0], t$95$3, If[LessEqual[y, -1.5e-116], t$95$2, If[LessEqual[y, -1.5e-181], N[(t$95$1 / N[(y * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 49000000000000.0], t$95$2, t$95$3]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t + y \cdot 230661.510616\\
t_2 := \frac{t\_1}{i}\\
t_3 := x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -170000000:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-116}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-181}:\\
\;\;\;\;\frac{t\_1}{y \cdot c}\\
\mathbf{elif}\;y \leq 49000000000000:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_3\\
\end{array}
\end{array}
if y < -1.7e8 or 4.9e13 < y Initial program 12.0%
Taylor expanded in y around inf 55.3%
associate--l+55.3%
associate-/l*59.9%
Simplified59.9%
if -1.7e8 < y < -1.50000000000000013e-116 or -1.49999999999999987e-181 < y < 4.9e13Initial program 99.7%
Taylor expanded in i around inf 71.8%
Taylor expanded in y around 0 68.5%
if -1.50000000000000013e-116 < y < -1.49999999999999987e-181Initial program 99.5%
Taylor expanded in c around inf 74.2%
Taylor expanded in y around 0 74.2%
Final simplification64.7%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (/ (+ t (* y (+ 230661.510616 (* y 27464.7644705)))) i))
(t_2 (+ x (- (/ z y) (* a (/ x y))))))
(if (<= y -1.65e+50)
t_2
(if (<= y -1.5e-116)
t_1
(if (<= y -1.5e-181)
(/ (+ t (* y 230661.510616)) (* y c))
(if (<= y 2.3e+49) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (t + (y * (230661.510616 + (y * 27464.7644705)))) / i;
double t_2 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -1.65e+50) {
tmp = t_2;
} else if (y <= -1.5e-116) {
tmp = t_1;
} else if (y <= -1.5e-181) {
tmp = (t + (y * 230661.510616)) / (y * c);
} else if (y <= 2.3e+49) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / i
t_2 = x + ((z / y) - (a * (x / y)))
if (y <= (-1.65d+50)) then
tmp = t_2
else if (y <= (-1.5d-116)) then
tmp = t_1
else if (y <= (-1.5d-181)) then
tmp = (t + (y * 230661.510616d0)) / (y * c)
else if (y <= 2.3d+49) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = (t + (y * (230661.510616 + (y * 27464.7644705)))) / i;
double t_2 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -1.65e+50) {
tmp = t_2;
} else if (y <= -1.5e-116) {
tmp = t_1;
} else if (y <= -1.5e-181) {
tmp = (t + (y * 230661.510616)) / (y * c);
} else if (y <= 2.3e+49) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (t + (y * (230661.510616 + (y * 27464.7644705)))) / i t_2 = x + ((z / y) - (a * (x / y))) tmp = 0 if y <= -1.65e+50: tmp = t_2 elif y <= -1.5e-116: tmp = t_1 elif y <= -1.5e-181: tmp = (t + (y * 230661.510616)) / (y * c) elif y <= 2.3e+49: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * 27464.7644705)))) / i) t_2 = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))) tmp = 0.0 if (y <= -1.65e+50) tmp = t_2; elseif (y <= -1.5e-116) tmp = t_1; elseif (y <= -1.5e-181) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(y * c)); elseif (y <= 2.3e+49) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (t + (y * (230661.510616 + (y * 27464.7644705)))) / i; t_2 = x + ((z / y) - (a * (x / y))); tmp = 0.0; if (y <= -1.65e+50) tmp = t_2; elseif (y <= -1.5e-116) tmp = t_1; elseif (y <= -1.5e-181) tmp = (t + (y * 230661.510616)) / (y * c); elseif (y <= 2.3e+49) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(t + N[(y * N[(230661.510616 + N[(y * 27464.7644705), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.65e+50], t$95$2, If[LessEqual[y, -1.5e-116], t$95$1, If[LessEqual[y, -1.5e-181], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(y * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.3e+49], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{i}\\
t_2 := x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -1.65 \cdot 10^{+50}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-116}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-181}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{y \cdot c}\\
\mathbf{elif}\;y \leq 2.3 \cdot 10^{+49}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y < -1.65e50 or 2.30000000000000002e49 < y Initial program 2.4%
Taylor expanded in y around inf 64.3%
associate--l+64.3%
associate-/l*69.9%
Simplified69.9%
if -1.65e50 < y < -1.50000000000000013e-116 or -1.49999999999999987e-181 < y < 2.30000000000000002e49Initial program 94.4%
Taylor expanded in y around 0 82.3%
*-commutative82.3%
Simplified82.3%
Taylor expanded in i around inf 61.1%
if -1.50000000000000013e-116 < y < -1.49999999999999987e-181Initial program 99.5%
Taylor expanded in c around inf 74.2%
Taylor expanded in y around 0 74.2%
Final simplification65.1%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -1.12e+52) (not (<= y 4.1e+49))) (+ x (- (/ z y) (* a (/ x y)))) (/ (+ t (* y 230661.510616)) (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.12e+52) || !(y <= 4.1e+49)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + 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.12d+52)) .or. (.not. (y <= 4.1d+49))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = (t + (y * 230661.510616d0)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + 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.12e+52) || !(y <= 4.1e+49)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.12e+52) or not (y <= 4.1e+49): tmp = x + ((z / y) - (a * (x / y))) else: tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.12e+52) || !(y <= 4.1e+49)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.12e+52) || ~((y <= 4.1e+49))) tmp = x + ((z / y) - (a * (x / y))); else tmp = (t + (y * 230661.510616)) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.12e+52], N[Not[LessEqual[y, 4.1e+49]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 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]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.12 \cdot 10^{+52} \lor \neg \left(y \leq 4.1 \cdot 10^{+49}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\
\end{array}
\end{array}
if y < -1.12000000000000002e52 or 4.1e49 < y Initial program 2.4%
Taylor expanded in y around inf 64.3%
associate--l+64.3%
associate-/l*69.9%
Simplified69.9%
if -1.12000000000000002e52 < y < 4.1e49Initial program 94.7%
Taylor expanded in y around 0 80.0%
*-commutative80.0%
Simplified80.0%
Final simplification76.0%
(FPCore (x y z t a b c i)
:precision binary64
(if (or (<= y -3.9e+51) (not (<= y 2.3e+49)))
(+ x (- (/ z y) (* a (/ x y))))
(/
(+ t (* y (+ 230661.510616 (* y 27464.7644705))))
(+ 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 <= -3.9e+51) || !(y <= 2.3e+49)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (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 <= (-3.9d+51)) .or. (.not. (y <= 2.3d+49))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / (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 <= -3.9e+51) || !(y <= 2.3e+49)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * b))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -3.9e+51) or not (y <= 2.3e+49): tmp = x + ((z / y) - (a * (x / y))) else: tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * b)))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -3.9e+51) || !(y <= 2.3e+49)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * 27464.7644705)))) / 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 <= -3.9e+51) || ~((y <= 2.3e+49))) tmp = x + ((z / y) - (a * (x / y))); else tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * b)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -3.9e+51], N[Not[LessEqual[y, 2.3e+49]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 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]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.9 \cdot 10^{+51} \lor \neg \left(y \leq 2.3 \cdot 10^{+49}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{i + y \cdot \left(c + y \cdot b\right)}\\
\end{array}
\end{array}
if y < -3.89999999999999984e51 or 2.30000000000000002e49 < y Initial program 2.4%
Taylor expanded in y around inf 64.3%
associate--l+64.3%
associate-/l*69.9%
Simplified69.9%
if -3.89999999999999984e51 < y < 2.30000000000000002e49Initial program 94.7%
Taylor expanded in y around 0 83.4%
*-commutative83.4%
Simplified83.4%
Taylor expanded in y around 0 78.5%
*-commutative78.5%
Simplified78.5%
Final simplification75.1%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (/ (+ t (* y 230661.510616)) i)))
(if (<= y -15500.0)
x
(if (<= y -1.5e-116)
t_1
(if (<= y -5.4e-167)
(+ (/ (/ t y) c) (/ 230661.510616 c))
(if (<= y 7.3e-28) t_1 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)) / i;
double tmp;
if (y <= -15500.0) {
tmp = x;
} else if (y <= -1.5e-116) {
tmp = t_1;
} else if (y <= -5.4e-167) {
tmp = ((t / y) / c) + (230661.510616 / c);
} else if (y <= 7.3e-28) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = (t + (y * 230661.510616d0)) / i
if (y <= (-15500.0d0)) then
tmp = x
else if (y <= (-1.5d-116)) then
tmp = t_1
else if (y <= (-5.4d-167)) then
tmp = ((t / y) / c) + (230661.510616d0 / c)
else if (y <= 7.3d-28) then
tmp = t_1
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 t_1 = (t + (y * 230661.510616)) / i;
double tmp;
if (y <= -15500.0) {
tmp = x;
} else if (y <= -1.5e-116) {
tmp = t_1;
} else if (y <= -5.4e-167) {
tmp = ((t / y) / c) + (230661.510616 / c);
} else if (y <= 7.3e-28) {
tmp = t_1;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (t + (y * 230661.510616)) / i tmp = 0 if y <= -15500.0: tmp = x elif y <= -1.5e-116: tmp = t_1 elif y <= -5.4e-167: tmp = ((t / y) / c) + (230661.510616 / c) elif y <= 7.3e-28: tmp = t_1 else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(Float64(t + Float64(y * 230661.510616)) / i) tmp = 0.0 if (y <= -15500.0) tmp = x; elseif (y <= -1.5e-116) tmp = t_1; elseif (y <= -5.4e-167) tmp = Float64(Float64(Float64(t / y) / c) + Float64(230661.510616 / c)); elseif (y <= 7.3e-28) tmp = t_1; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = (t + (y * 230661.510616)) / i; tmp = 0.0; if (y <= -15500.0) tmp = x; elseif (y <= -1.5e-116) tmp = t_1; elseif (y <= -5.4e-167) tmp = ((t / y) / c) + (230661.510616 / c); elseif (y <= 7.3e-28) tmp = t_1; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision]}, If[LessEqual[y, -15500.0], x, If[LessEqual[y, -1.5e-116], t$95$1, If[LessEqual[y, -5.4e-167], N[(N[(N[(t / y), $MachinePrecision] / c), $MachinePrecision] + N[(230661.510616 / c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 7.3e-28], t$95$1, x]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{t + y \cdot 230661.510616}{i}\\
\mathbf{if}\;y \leq -15500:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-116}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -5.4 \cdot 10^{-167}:\\
\;\;\;\;\frac{\frac{t}{y}}{c} + \frac{230661.510616}{c}\\
\mathbf{elif}\;y \leq 7.3 \cdot 10^{-28}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -15500 or 7.2999999999999996e-28 < y Initial program 15.4%
Taylor expanded in y around inf 42.9%
if -15500 < y < -1.50000000000000013e-116 or -5.4000000000000001e-167 < y < 7.2999999999999996e-28Initial program 99.8%
Taylor expanded in i around inf 73.8%
Taylor expanded in y around 0 70.4%
if -1.50000000000000013e-116 < y < -5.4000000000000001e-167Initial program 99.6%
Taylor expanded in c around inf 76.8%
Taylor expanded in y around 0 76.5%
+-commutative76.5%
*-commutative76.5%
associate-/r*72.5%
associate-*r/72.5%
metadata-eval72.5%
Simplified72.5%
Final simplification56.8%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ t (* y 230661.510616))) (t_2 (/ t_1 i)))
(if (<= y -9500.0)
x
(if (<= y -1.5e-116)
t_2
(if (<= y -1.5e-181) (/ t_1 (* y c)) (if (<= y 6.6e-28) t_2 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);
double t_2 = t_1 / i;
double tmp;
if (y <= -9500.0) {
tmp = x;
} else if (y <= -1.5e-116) {
tmp = t_2;
} else if (y <= -1.5e-181) {
tmp = t_1 / (y * c);
} else if (y <= 6.6e-28) {
tmp = t_2;
} 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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = t + (y * 230661.510616d0)
t_2 = t_1 / i
if (y <= (-9500.0d0)) then
tmp = x
else if (y <= (-1.5d-116)) then
tmp = t_2
else if (y <= (-1.5d-181)) then
tmp = t_1 / (y * c)
else if (y <= 6.6d-28) then
tmp = t_2
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 t_1 = t + (y * 230661.510616);
double t_2 = t_1 / i;
double tmp;
if (y <= -9500.0) {
tmp = x;
} else if (y <= -1.5e-116) {
tmp = t_2;
} else if (y <= -1.5e-181) {
tmp = t_1 / (y * c);
} else if (y <= 6.6e-28) {
tmp = t_2;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = t + (y * 230661.510616) t_2 = t_1 / i tmp = 0 if y <= -9500.0: tmp = x elif y <= -1.5e-116: tmp = t_2 elif y <= -1.5e-181: tmp = t_1 / (y * c) elif y <= 6.6e-28: tmp = t_2 else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(t + Float64(y * 230661.510616)) t_2 = Float64(t_1 / i) tmp = 0.0 if (y <= -9500.0) tmp = x; elseif (y <= -1.5e-116) tmp = t_2; elseif (y <= -1.5e-181) tmp = Float64(t_1 / Float64(y * c)); elseif (y <= 6.6e-28) tmp = t_2; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = t + (y * 230661.510616); t_2 = t_1 / i; tmp = 0.0; if (y <= -9500.0) tmp = x; elseif (y <= -1.5e-116) tmp = t_2; elseif (y <= -1.5e-181) tmp = t_1 / (y * c); elseif (y <= 6.6e-28) tmp = t_2; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 / i), $MachinePrecision]}, If[LessEqual[y, -9500.0], x, If[LessEqual[y, -1.5e-116], t$95$2, If[LessEqual[y, -1.5e-181], N[(t$95$1 / N[(y * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.6e-28], t$95$2, x]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t + y \cdot 230661.510616\\
t_2 := \frac{t\_1}{i}\\
\mathbf{if}\;y \leq -9500:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-116}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq -1.5 \cdot 10^{-181}:\\
\;\;\;\;\frac{t\_1}{y \cdot c}\\
\mathbf{elif}\;y \leq 6.6 \cdot 10^{-28}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -9500 or 6.6000000000000003e-28 < y Initial program 15.4%
Taylor expanded in y around inf 42.9%
if -9500 < y < -1.50000000000000013e-116 or -1.49999999999999987e-181 < y < 6.6000000000000003e-28Initial program 99.8%
Taylor expanded in i around inf 74.7%
Taylor expanded in y around 0 71.3%
if -1.50000000000000013e-116 < y < -1.49999999999999987e-181Initial program 99.5%
Taylor expanded in c around inf 74.2%
Taylor expanded in y around 0 74.2%
Final simplification57.3%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -1.8e+50) (not (<= y 2.3e+49))) (+ x (- (/ z y) (* a (/ x y)))) (/ t (+ (* y (+ (* y (+ (* y (+ y a)) b)) c)) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.8e+50) || !(y <= 2.3e+49)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = t / ((y * ((y * ((y * (y + a)) + b)) + c)) + 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.8d+50)) .or. (.not. (y <= 2.3d+49))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = t / ((y * ((y * ((y * (y + a)) + b)) + c)) + 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.8e+50) || !(y <= 2.3e+49)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = t / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.8e+50) or not (y <= 2.3e+49): tmp = x + ((z / y) - (a * (x / y))) else: tmp = t / ((y * ((y * ((y * (y + a)) + b)) + c)) + i) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.8e+50) || !(y <= 2.3e+49)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(t / Float64(Float64(y * Float64(Float64(y * Float64(Float64(y * Float64(y + a)) + b)) + c)) + i)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.8e+50) || ~((y <= 2.3e+49))) tmp = x + ((z / y) - (a * (x / y))); else tmp = t / ((y * ((y * ((y * (y + a)) + b)) + c)) + i); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.8e+50], N[Not[LessEqual[y, 2.3e+49]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t / N[(N[(y * N[(N[(y * N[(N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision] + i), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.8 \cdot 10^{+50} \lor \neg \left(y \leq 2.3 \cdot 10^{+49}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{y \cdot \left(y \cdot \left(y \cdot \left(y + a\right) + b\right) + c\right) + i}\\
\end{array}
\end{array}
if y < -1.79999999999999993e50 or 2.30000000000000002e49 < y Initial program 2.4%
Taylor expanded in y around inf 64.3%
associate--l+64.3%
associate-/l*69.9%
Simplified69.9%
if -1.79999999999999993e50 < y < 2.30000000000000002e49Initial program 94.7%
Taylor expanded in t around inf 69.0%
Final simplification69.4%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -13600.0) x (if (<= y 7.3e-28) (/ (+ t (* y 230661.510616)) i) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -13600.0) {
tmp = x;
} else if (y <= 7.3e-28) {
tmp = (t + (y * 230661.510616)) / 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 <= (-13600.0d0)) then
tmp = x
else if (y <= 7.3d-28) then
tmp = (t + (y * 230661.510616d0)) / 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 <= -13600.0) {
tmp = x;
} else if (y <= 7.3e-28) {
tmp = (t + (y * 230661.510616)) / i;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -13600.0: tmp = x elif y <= 7.3e-28: tmp = (t + (y * 230661.510616)) / i else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -13600.0) tmp = x; elseif (y <= 7.3e-28) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / 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 <= -13600.0) tmp = x; elseif (y <= 7.3e-28) tmp = (t + (y * 230661.510616)) / i; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -13600.0], x, If[LessEqual[y, 7.3e-28], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -13600:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 7.3 \cdot 10^{-28}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -13600 or 7.2999999999999996e-28 < y Initial program 15.4%
Taylor expanded in y around inf 42.9%
if -13600 < y < 7.2999999999999996e-28Initial program 99.8%
Taylor expanded in i around inf 70.0%
Taylor expanded in y around 0 66.9%
Final simplification55.0%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -145000000000.0) x (if (<= y 18500000000000.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 <= -145000000000.0) {
tmp = x;
} else if (y <= 18500000000000.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 <= (-145000000000.0d0)) then
tmp = x
else if (y <= 18500000000000.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 <= -145000000000.0) {
tmp = x;
} else if (y <= 18500000000000.0) {
tmp = t / i;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -145000000000.0: tmp = x elif y <= 18500000000000.0: tmp = t / i else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -145000000000.0) tmp = x; elseif (y <= 18500000000000.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 <= -145000000000.0) tmp = x; elseif (y <= 18500000000000.0) tmp = t / i; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -145000000000.0], x, If[LessEqual[y, 18500000000000.0], N[(t / i), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -145000000000:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 18500000000000:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -1.45e11 or 1.85e13 < y Initial program 11.3%
Taylor expanded in y around inf 45.2%
if -1.45e11 < y < 1.85e13Initial program 99.0%
Taylor expanded in y around 0 55.1%
Final simplification50.5%
(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 57.9%
Taylor expanded in y around inf 22.9%
Final simplification22.9%
herbie shell --seed 2024053
(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)))