
(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 14 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 (+ b (* y (+ y a))))
(t_2 (/ (pow y 2.0) t_1))
(t_3 (* x t_1))
(t_4 (/ 1.0 t_3))
(t_5 (/ t (* x (* t_1 (pow y 2.0)))))
(t_6 (* y t_1))
(t_7 (+ i (* y (+ t_6 c))))
(t_8 (/ 1.0 (* x t_6))))
(if (<= y -1.65e+124)
(- x (/ (* z (+ -1.0 (/ a y))) y))
(if (<= y -1.6e+17)
(*
x
(+
(* 230661.510616 t_8)
(+ (* 27464.7644705 t_4) (+ t_5 (+ (/ (* y z) t_3) t_2)))))
(if (<= y 4.8e+15)
(+
(/ t t_7)
(+
(/ (* x (pow y 4.0)) t_7)
(/ (* y (+ 230661.510616 (* y (+ 27464.7644705 (* y z))))) t_7)))
(if (<= y 6.5e+139)
(*
x
(fma
230661.510616
t_8
(fma 27464.7644705 t_4 (+ t_5 (+ t_2 (* (/ y x) (/ z 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 = b + (y * (y + a));
double t_2 = pow(y, 2.0) / t_1;
double t_3 = x * t_1;
double t_4 = 1.0 / t_3;
double t_5 = t / (x * (t_1 * pow(y, 2.0)));
double t_6 = y * t_1;
double t_7 = i + (y * (t_6 + c));
double t_8 = 1.0 / (x * t_6);
double tmp;
if (y <= -1.65e+124) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -1.6e+17) {
tmp = x * ((230661.510616 * t_8) + ((27464.7644705 * t_4) + (t_5 + (((y * z) / t_3) + t_2))));
} else if (y <= 4.8e+15) {
tmp = (t / t_7) + (((x * pow(y, 4.0)) / t_7) + ((y * (230661.510616 + (y * (27464.7644705 + (y * z))))) / t_7));
} else if (y <= 6.5e+139) {
tmp = x * fma(230661.510616, t_8, fma(27464.7644705, t_4, (t_5 + (t_2 + ((y / x) * (z / 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(b + Float64(y * Float64(y + a))) t_2 = Float64((y ^ 2.0) / t_1) t_3 = Float64(x * t_1) t_4 = Float64(1.0 / t_3) t_5 = Float64(t / Float64(x * Float64(t_1 * (y ^ 2.0)))) t_6 = Float64(y * t_1) t_7 = Float64(i + Float64(y * Float64(t_6 + c))) t_8 = Float64(1.0 / Float64(x * t_6)) tmp = 0.0 if (y <= -1.65e+124) tmp = Float64(x - Float64(Float64(z * Float64(-1.0 + Float64(a / y))) / y)); elseif (y <= -1.6e+17) tmp = Float64(x * Float64(Float64(230661.510616 * t_8) + Float64(Float64(27464.7644705 * t_4) + Float64(t_5 + Float64(Float64(Float64(y * z) / t_3) + t_2))))); elseif (y <= 4.8e+15) tmp = Float64(Float64(t / t_7) + Float64(Float64(Float64(x * (y ^ 4.0)) / t_7) + Float64(Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * z))))) / t_7))); elseif (y <= 6.5e+139) tmp = Float64(x * fma(230661.510616, t_8, fma(27464.7644705, t_4, Float64(t_5 + Float64(t_2 + Float64(Float64(y / x) * Float64(z / t_1))))))); 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_] := Block[{t$95$1 = N[(b + N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[Power[y, 2.0], $MachinePrecision] / t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(x * t$95$1), $MachinePrecision]}, Block[{t$95$4 = N[(1.0 / t$95$3), $MachinePrecision]}, Block[{t$95$5 = N[(t / N[(x * N[(t$95$1 * N[Power[y, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(y * t$95$1), $MachinePrecision]}, Block[{t$95$7 = N[(i + N[(y * N[(t$95$6 + c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$8 = N[(1.0 / N[(x * t$95$6), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.65e+124], N[(x - N[(N[(z * N[(-1.0 + N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.6e+17], N[(x * N[(N[(230661.510616 * t$95$8), $MachinePrecision] + N[(N[(27464.7644705 * t$95$4), $MachinePrecision] + N[(t$95$5 + N[(N[(N[(y * z), $MachinePrecision] / t$95$3), $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.8e+15], N[(N[(t / t$95$7), $MachinePrecision] + N[(N[(N[(x * N[Power[y, 4.0], $MachinePrecision]), $MachinePrecision] / t$95$7), $MachinePrecision] + N[(N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$7), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.5e+139], N[(x * N[(230661.510616 * t$95$8 + N[(27464.7644705 * t$95$4 + N[(t$95$5 + N[(t$95$2 + N[(N[(y / x), $MachinePrecision] * N[(z / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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 := b + y \cdot \left(y + a\right)\\
t_2 := \frac{{y}^{2}}{t\_1}\\
t_3 := x \cdot t\_1\\
t_4 := \frac{1}{t\_3}\\
t_5 := \frac{t}{x \cdot \left(t\_1 \cdot {y}^{2}\right)}\\
t_6 := y \cdot t\_1\\
t_7 := i + y \cdot \left(t\_6 + c\right)\\
t_8 := \frac{1}{x \cdot t\_6}\\
\mathbf{if}\;y \leq -1.65 \cdot 10^{+124}:\\
\;\;\;\;x - \frac{z \cdot \left(-1 + \frac{a}{y}\right)}{y}\\
\mathbf{elif}\;y \leq -1.6 \cdot 10^{+17}:\\
\;\;\;\;x \cdot \left(230661.510616 \cdot t\_8 + \left(27464.7644705 \cdot t\_4 + \left(t\_5 + \left(\frac{y \cdot z}{t\_3} + t\_2\right)\right)\right)\right)\\
\mathbf{elif}\;y \leq 4.8 \cdot 10^{+15}:\\
\;\;\;\;\frac{t}{t\_7} + \left(\frac{x \cdot {y}^{4}}{t\_7} + \frac{y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot z\right)\right)}{t\_7}\right)\\
\mathbf{elif}\;y \leq 6.5 \cdot 10^{+139}:\\
\;\;\;\;x \cdot \mathsf{fma}\left(230661.510616, t\_8, \mathsf{fma}\left(27464.7644705, t\_4, t\_5 + \left(t\_2 + \frac{y}{x} \cdot \frac{z}{t\_1}\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\end{array}
\end{array}
if y < -1.65000000000000007e124Initial program 0.0%
Taylor expanded in y around -inf 60.8%
Taylor expanded in z around inf 87.6%
if -1.65000000000000007e124 < y < -1.6e17Initial program 45.1%
Taylor expanded in x around inf 53.0%
Taylor expanded in i around 0 63.3%
Taylor expanded in c around 0 71.8%
if -1.6e17 < y < 4.8e15Initial program 99.7%
Taylor expanded in x around 0 99.7%
if 4.8e15 < y < 6.5000000000000003e139Initial program 17.0%
Taylor expanded in x around inf 23.1%
Taylor expanded in i around 0 30.9%
Taylor expanded in c around 0 73.3%
fma-define73.3%
fma-define73.3%
Simplified73.8%
if 6.5000000000000003e139 < y Initial program 0.0%
Taylor expanded in y around inf 89.3%
associate--l+89.3%
associate-/l*92.6%
Simplified92.6%
Final simplification91.6%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ b (* y (+ y a))))
(t_2 (* y t_1))
(t_3 (+ i (* y (+ t_2 c))))
(t_4 (* x t_1))
(t_5
(*
x
(+
(* 230661.510616 (/ 1.0 (* x t_2)))
(+
(* 27464.7644705 (/ 1.0 t_4))
(+
(/ t (* x (* t_1 (pow y 2.0))))
(+ (/ (* y z) t_4) (/ (pow y 2.0) t_1))))))))
(if (<= y -6.4e+123)
(- x (/ (* z (+ -1.0 (/ a y))) y))
(if (<= y -1.6e+17)
t_5
(if (<= y 8.5e+18)
(+
(/ t t_3)
(+
(/ (* x (pow y 4.0)) t_3)
(/ (* y (+ 230661.510616 (* y (+ 27464.7644705 (* y z))))) t_3)))
(if (<= y 9e+139) t_5 (+ 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 = b + (y * (y + a));
double t_2 = y * t_1;
double t_3 = i + (y * (t_2 + c));
double t_4 = x * t_1;
double t_5 = x * ((230661.510616 * (1.0 / (x * t_2))) + ((27464.7644705 * (1.0 / t_4)) + ((t / (x * (t_1 * pow(y, 2.0)))) + (((y * z) / t_4) + (pow(y, 2.0) / t_1)))));
double tmp;
if (y <= -6.4e+123) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -1.6e+17) {
tmp = t_5;
} else if (y <= 8.5e+18) {
tmp = (t / t_3) + (((x * pow(y, 4.0)) / t_3) + ((y * (230661.510616 + (y * (27464.7644705 + (y * z))))) / t_3));
} else if (y <= 9e+139) {
tmp = t_5;
} else {
tmp = x + ((z / y) - (a * (x / 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) :: t_3
real(8) :: t_4
real(8) :: t_5
real(8) :: tmp
t_1 = b + (y * (y + a))
t_2 = y * t_1
t_3 = i + (y * (t_2 + c))
t_4 = x * t_1
t_5 = x * ((230661.510616d0 * (1.0d0 / (x * t_2))) + ((27464.7644705d0 * (1.0d0 / t_4)) + ((t / (x * (t_1 * (y ** 2.0d0)))) + (((y * z) / t_4) + ((y ** 2.0d0) / t_1)))))
if (y <= (-6.4d+123)) then
tmp = x - ((z * ((-1.0d0) + (a / y))) / y)
else if (y <= (-1.6d+17)) then
tmp = t_5
else if (y <= 8.5d+18) then
tmp = (t / t_3) + (((x * (y ** 4.0d0)) / t_3) + ((y * (230661.510616d0 + (y * (27464.7644705d0 + (y * z))))) / t_3))
else if (y <= 9d+139) then
tmp = t_5
else
tmp = x + ((z / y) - (a * (x / 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 = b + (y * (y + a));
double t_2 = y * t_1;
double t_3 = i + (y * (t_2 + c));
double t_4 = x * t_1;
double t_5 = x * ((230661.510616 * (1.0 / (x * t_2))) + ((27464.7644705 * (1.0 / t_4)) + ((t / (x * (t_1 * Math.pow(y, 2.0)))) + (((y * z) / t_4) + (Math.pow(y, 2.0) / t_1)))));
double tmp;
if (y <= -6.4e+123) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -1.6e+17) {
tmp = t_5;
} else if (y <= 8.5e+18) {
tmp = (t / t_3) + (((x * Math.pow(y, 4.0)) / t_3) + ((y * (230661.510616 + (y * (27464.7644705 + (y * z))))) / t_3));
} else if (y <= 9e+139) {
tmp = t_5;
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = b + (y * (y + a)) t_2 = y * t_1 t_3 = i + (y * (t_2 + c)) t_4 = x * t_1 t_5 = x * ((230661.510616 * (1.0 / (x * t_2))) + ((27464.7644705 * (1.0 / t_4)) + ((t / (x * (t_1 * math.pow(y, 2.0)))) + (((y * z) / t_4) + (math.pow(y, 2.0) / t_1))))) tmp = 0 if y <= -6.4e+123: tmp = x - ((z * (-1.0 + (a / y))) / y) elif y <= -1.6e+17: tmp = t_5 elif y <= 8.5e+18: tmp = (t / t_3) + (((x * math.pow(y, 4.0)) / t_3) + ((y * (230661.510616 + (y * (27464.7644705 + (y * z))))) / t_3)) elif y <= 9e+139: tmp = t_5 else: tmp = x + ((z / y) - (a * (x / y))) return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(b + Float64(y * Float64(y + a))) t_2 = Float64(y * t_1) t_3 = Float64(i + Float64(y * Float64(t_2 + c))) t_4 = Float64(x * t_1) t_5 = Float64(x * Float64(Float64(230661.510616 * Float64(1.0 / Float64(x * t_2))) + Float64(Float64(27464.7644705 * Float64(1.0 / t_4)) + Float64(Float64(t / Float64(x * Float64(t_1 * (y ^ 2.0)))) + Float64(Float64(Float64(y * z) / t_4) + Float64((y ^ 2.0) / t_1)))))) tmp = 0.0 if (y <= -6.4e+123) tmp = Float64(x - Float64(Float64(z * Float64(-1.0 + Float64(a / y))) / y)); elseif (y <= -1.6e+17) tmp = t_5; elseif (y <= 8.5e+18) tmp = Float64(Float64(t / t_3) + Float64(Float64(Float64(x * (y ^ 4.0)) / t_3) + Float64(Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * z))))) / t_3))); elseif (y <= 9e+139) tmp = t_5; 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 = b + (y * (y + a)); t_2 = y * t_1; t_3 = i + (y * (t_2 + c)); t_4 = x * t_1; t_5 = x * ((230661.510616 * (1.0 / (x * t_2))) + ((27464.7644705 * (1.0 / t_4)) + ((t / (x * (t_1 * (y ^ 2.0)))) + (((y * z) / t_4) + ((y ^ 2.0) / t_1))))); tmp = 0.0; if (y <= -6.4e+123) tmp = x - ((z * (-1.0 + (a / y))) / y); elseif (y <= -1.6e+17) tmp = t_5; elseif (y <= 8.5e+18) tmp = (t / t_3) + (((x * (y ^ 4.0)) / t_3) + ((y * (230661.510616 + (y * (27464.7644705 + (y * z))))) / t_3)); elseif (y <= 9e+139) tmp = t_5; 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[(b + N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(i + N[(y * N[(t$95$2 + c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(x * t$95$1), $MachinePrecision]}, Block[{t$95$5 = N[(x * N[(N[(230661.510616 * N[(1.0 / N[(x * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(27464.7644705 * N[(1.0 / t$95$4), $MachinePrecision]), $MachinePrecision] + N[(N[(t / N[(x * N[(t$95$1 * N[Power[y, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y * z), $MachinePrecision] / t$95$4), $MachinePrecision] + N[(N[Power[y, 2.0], $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6.4e+123], N[(x - N[(N[(z * N[(-1.0 + N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.6e+17], t$95$5, If[LessEqual[y, 8.5e+18], N[(N[(t / t$95$3), $MachinePrecision] + N[(N[(N[(x * N[Power[y, 4.0], $MachinePrecision]), $MachinePrecision] / t$95$3), $MachinePrecision] + N[(N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9e+139], t$95$5, N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := b + y \cdot \left(y + a\right)\\
t_2 := y \cdot t\_1\\
t_3 := i + y \cdot \left(t\_2 + c\right)\\
t_4 := x \cdot t\_1\\
t_5 := x \cdot \left(230661.510616 \cdot \frac{1}{x \cdot t\_2} + \left(27464.7644705 \cdot \frac{1}{t\_4} + \left(\frac{t}{x \cdot \left(t\_1 \cdot {y}^{2}\right)} + \left(\frac{y \cdot z}{t\_4} + \frac{{y}^{2}}{t\_1}\right)\right)\right)\right)\\
\mathbf{if}\;y \leq -6.4 \cdot 10^{+123}:\\
\;\;\;\;x - \frac{z \cdot \left(-1 + \frac{a}{y}\right)}{y}\\
\mathbf{elif}\;y \leq -1.6 \cdot 10^{+17}:\\
\;\;\;\;t\_5\\
\mathbf{elif}\;y \leq 8.5 \cdot 10^{+18}:\\
\;\;\;\;\frac{t}{t\_3} + \left(\frac{x \cdot {y}^{4}}{t\_3} + \frac{y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot z\right)\right)}{t\_3}\right)\\
\mathbf{elif}\;y \leq 9 \cdot 10^{+139}:\\
\;\;\;\;t\_5\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\end{array}
\end{array}
if y < -6.40000000000000009e123Initial program 0.0%
Taylor expanded in y around -inf 60.8%
Taylor expanded in z around inf 87.6%
if -6.40000000000000009e123 < y < -1.6e17 or 8.5e18 < y < 8.9999999999999999e139Initial program 29.7%
Taylor expanded in x around inf 36.6%
Taylor expanded in i around 0 45.6%
Taylor expanded in c around 0 72.6%
if -1.6e17 < y < 8.5e18Initial program 99.7%
Taylor expanded in x around 0 99.7%
if 8.9999999999999999e139 < y Initial program 0.0%
Taylor expanded in y around inf 89.3%
associate--l+89.3%
associate-/l*92.6%
Simplified92.6%
Final simplification91.6%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1
(/
(+
t
(* y (+ 230661.510616 (* y (+ 27464.7644705 (* y (+ z (* y x))))))))
(+ i (* y (+ (* y (+ b (* y (+ y a)))) c))))))
(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 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))))) / (i + (y * ((y * (b + (y * (y + a)))) + c)));
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 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))))) / (i + (y * ((y * (b + (y * (y + a)))) + c)));
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 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))))) / (i + (y * ((y * (b + (y * (y + a)))) + c))) 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(t + Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * Float64(z + Float64(y * x)))))))) / Float64(i + Float64(y * Float64(Float64(y * Float64(b + Float64(y * Float64(y + a)))) + c)))) 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 = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))))) / (i + (y * ((y * (b + (y * (y + a)))) + c))); 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[(t + N[(y * N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * N[(z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(N[(y * N[(b + N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision]), $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{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot \left(z + y \cdot x\right)\right)\right)}{i + y \cdot \left(y \cdot \left(b + y \cdot \left(y + a\right)\right) + c\right)}\\
\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) #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)) < +inf.0Initial program 88.6%
if +inf.0 < (/.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 0.0%
Taylor expanded in y around inf 75.8%
associate--l+75.8%
associate-/l*82.6%
Simplified82.6%
Final simplification86.5%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y (+ b (* y (+ y a)))) c))
(t_2
(/
(+ 230661.510616 (* y (+ 27464.7644705 (* y (+ z (* y x))))))
t_1)))
(if (<= y -4.6e+71)
(- x (/ (* z (+ -1.0 (/ a y))) y))
(if (<= y -1.7e+16)
t_2
(if (<= y 1.12e-17)
(/ (+ t (* y (+ 230661.510616 (* y 27464.7644705)))) (+ i (* y t_1)))
(if (<= y 1.15e+64) t_2 (+ 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 * (b + (y * (y + a)))) + c;
double t_2 = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1;
double tmp;
if (y <= -4.6e+71) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -1.7e+16) {
tmp = t_2;
} else if (y <= 1.12e-17) {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * t_1));
} else if (y <= 1.15e+64) {
tmp = t_2;
} else {
tmp = x + ((z / y) - (a * (x / 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 * (b + (y * (y + a)))) + c
t_2 = (230661.510616d0 + (y * (27464.7644705d0 + (y * (z + (y * x)))))) / t_1
if (y <= (-4.6d+71)) then
tmp = x - ((z * ((-1.0d0) + (a / y))) / y)
else if (y <= (-1.7d+16)) then
tmp = t_2
else if (y <= 1.12d-17) then
tmp = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / (i + (y * t_1))
else if (y <= 1.15d+64) then
tmp = t_2
else
tmp = x + ((z / y) - (a * (x / 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 * (b + (y * (y + a)))) + c;
double t_2 = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1;
double tmp;
if (y <= -4.6e+71) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -1.7e+16) {
tmp = t_2;
} else if (y <= 1.12e-17) {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * t_1));
} else if (y <= 1.15e+64) {
tmp = t_2;
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * (b + (y * (y + a)))) + c t_2 = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1 tmp = 0 if y <= -4.6e+71: tmp = x - ((z * (-1.0 + (a / y))) / y) elif y <= -1.7e+16: tmp = t_2 elif y <= 1.12e-17: tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * t_1)) elif y <= 1.15e+64: tmp = t_2 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(b + Float64(y * Float64(y + a)))) + c) t_2 = Float64(Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * Float64(z + Float64(y * x)))))) / t_1) tmp = 0.0 if (y <= -4.6e+71) tmp = Float64(x - Float64(Float64(z * Float64(-1.0 + Float64(a / y))) / y)); elseif (y <= -1.7e+16) tmp = t_2; elseif (y <= 1.12e-17) tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * 27464.7644705)))) / Float64(i + Float64(y * t_1))); elseif (y <= 1.15e+64) tmp = t_2; 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 * (b + (y * (y + a)))) + c; t_2 = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1; tmp = 0.0; if (y <= -4.6e+71) tmp = x - ((z * (-1.0 + (a / y))) / y); elseif (y <= -1.7e+16) tmp = t_2; elseif (y <= 1.12e-17) tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * t_1)); elseif (y <= 1.15e+64) tmp = t_2; 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[(b + N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]}, Block[{t$95$2 = N[(N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * N[(z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]}, If[LessEqual[y, -4.6e+71], N[(x - N[(N[(z * N[(-1.0 + N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.7e+16], t$95$2, If[LessEqual[y, 1.12e-17], N[(N[(t + N[(y * N[(230661.510616 + N[(y * 27464.7644705), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.15e+64], t$95$2, 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(b + y \cdot \left(y + a\right)\right) + c\\
t_2 := \frac{230661.510616 + y \cdot \left(27464.7644705 + y \cdot \left(z + y \cdot x\right)\right)}{t\_1}\\
\mathbf{if}\;y \leq -4.6 \cdot 10^{+71}:\\
\;\;\;\;x - \frac{z \cdot \left(-1 + \frac{a}{y}\right)}{y}\\
\mathbf{elif}\;y \leq -1.7 \cdot 10^{+16}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq 1.12 \cdot 10^{-17}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot 27464.7644705\right)}{i + y \cdot t\_1}\\
\mathbf{elif}\;y \leq 1.15 \cdot 10^{+64}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\end{array}
\end{array}
if y < -4.6000000000000005e71Initial program 4.4%
Taylor expanded in y around -inf 58.8%
Taylor expanded in z around inf 80.4%
if -4.6000000000000005e71 < y < -1.7e16 or 1.12000000000000005e-17 < y < 1.15e64Initial program 56.9%
Taylor expanded in t around 0 53.9%
Simplified56.7%
Taylor expanded in i around 0 64.9%
if -1.7e16 < y < 1.12000000000000005e-17Initial program 99.7%
Taylor expanded in y around 0 90.2%
*-commutative90.2%
Simplified90.2%
if 1.15e64 < y Initial program 2.6%
Taylor expanded in y around inf 76.4%
associate--l+76.4%
associate-/l*78.5%
Simplified78.5%
Final simplification83.0%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y (+ b (* y (+ y a)))) c))
(t_2
(/
(+ 230661.510616 (* y (+ 27464.7644705 (* y (+ z (* y x))))))
t_1)))
(if (<= y -3.6e+70)
(- x (/ (* z (+ -1.0 (/ a y))) y))
(if (<= y -1.45e+16)
t_2
(if (<= y 2e-19)
(/ (+ t (* y 230661.510616)) (+ i (* y t_1)))
(if (<= y 2.6e+63) t_2 (+ 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 * (b + (y * (y + a)))) + c;
double t_2 = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1;
double tmp;
if (y <= -3.6e+70) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -1.45e+16) {
tmp = t_2;
} else if (y <= 2e-19) {
tmp = (t + (y * 230661.510616)) / (i + (y * t_1));
} else if (y <= 2.6e+63) {
tmp = t_2;
} else {
tmp = x + ((z / y) - (a * (x / 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 * (b + (y * (y + a)))) + c
t_2 = (230661.510616d0 + (y * (27464.7644705d0 + (y * (z + (y * x)))))) / t_1
if (y <= (-3.6d+70)) then
tmp = x - ((z * ((-1.0d0) + (a / y))) / y)
else if (y <= (-1.45d+16)) then
tmp = t_2
else if (y <= 2d-19) then
tmp = (t + (y * 230661.510616d0)) / (i + (y * t_1))
else if (y <= 2.6d+63) then
tmp = t_2
else
tmp = x + ((z / y) - (a * (x / 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 * (b + (y * (y + a)))) + c;
double t_2 = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1;
double tmp;
if (y <= -3.6e+70) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -1.45e+16) {
tmp = t_2;
} else if (y <= 2e-19) {
tmp = (t + (y * 230661.510616)) / (i + (y * t_1));
} else if (y <= 2.6e+63) {
tmp = t_2;
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = (y * (b + (y * (y + a)))) + c t_2 = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1 tmp = 0 if y <= -3.6e+70: tmp = x - ((z * (-1.0 + (a / y))) / y) elif y <= -1.45e+16: tmp = t_2 elif y <= 2e-19: tmp = (t + (y * 230661.510616)) / (i + (y * t_1)) elif y <= 2.6e+63: tmp = t_2 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(b + Float64(y * Float64(y + a)))) + c) t_2 = Float64(Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * Float64(z + Float64(y * x)))))) / t_1) tmp = 0.0 if (y <= -3.6e+70) tmp = Float64(x - Float64(Float64(z * Float64(-1.0 + Float64(a / y))) / y)); elseif (y <= -1.45e+16) tmp = t_2; elseif (y <= 2e-19) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * t_1))); elseif (y <= 2.6e+63) tmp = t_2; 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 * (b + (y * (y + a)))) + c; t_2 = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1; tmp = 0.0; if (y <= -3.6e+70) tmp = x - ((z * (-1.0 + (a / y))) / y); elseif (y <= -1.45e+16) tmp = t_2; elseif (y <= 2e-19) tmp = (t + (y * 230661.510616)) / (i + (y * t_1)); elseif (y <= 2.6e+63) tmp = t_2; 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[(b + N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]}, Block[{t$95$2 = N[(N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * N[(z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]}, If[LessEqual[y, -3.6e+70], N[(x - N[(N[(z * N[(-1.0 + N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1.45e+16], t$95$2, If[LessEqual[y, 2e-19], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.6e+63], t$95$2, 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(b + y \cdot \left(y + a\right)\right) + c\\
t_2 := \frac{230661.510616 + y \cdot \left(27464.7644705 + y \cdot \left(z + y \cdot x\right)\right)}{t\_1}\\
\mathbf{if}\;y \leq -3.6 \cdot 10^{+70}:\\
\;\;\;\;x - \frac{z \cdot \left(-1 + \frac{a}{y}\right)}{y}\\
\mathbf{elif}\;y \leq -1.45 \cdot 10^{+16}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq 2 \cdot 10^{-19}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot t\_1}\\
\mathbf{elif}\;y \leq 2.6 \cdot 10^{+63}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\end{array}
\end{array}
if y < -3.6e70Initial program 4.4%
Taylor expanded in y around -inf 58.8%
Taylor expanded in z around inf 80.4%
if -3.6e70 < y < -1.45e16 or 2e-19 < y < 2.6000000000000001e63Initial program 56.9%
Taylor expanded in t around 0 53.9%
Simplified56.7%
Taylor expanded in i around 0 64.9%
if -1.45e16 < y < 2e-19Initial program 99.7%
Taylor expanded in y around 0 89.6%
*-commutative89.6%
Simplified89.6%
if 2.6000000000000001e63 < y Initial program 2.6%
Taylor expanded in y around inf 76.4%
associate--l+76.4%
associate-/l*78.5%
Simplified78.5%
Final simplification82.7%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ (* y (+ b (* y (+ y a)))) c)))
(if (<= y -2.8e+70)
(- x (/ (* z (+ -1.0 (/ a y))) y))
(if (<= y -2.9e+16)
(/ (+ 230661.510616 (* y (+ 27464.7644705 (* y (+ z (* y x)))))) t_1)
(if (<= y 4e+27)
(/
(+ t (* y (+ 230661.510616 (* y (+ 27464.7644705 (* y z))))))
(+ i (* y 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 * (b + (y * (y + a)))) + c;
double tmp;
if (y <= -2.8e+70) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -2.9e+16) {
tmp = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1;
} else if (y <= 4e+27) {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * t_1));
} else {
tmp = x + ((z / y) - (a * (x / 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 * (b + (y * (y + a)))) + c
if (y <= (-2.8d+70)) then
tmp = x - ((z * ((-1.0d0) + (a / y))) / y)
else if (y <= (-2.9d+16)) then
tmp = (230661.510616d0 + (y * (27464.7644705d0 + (y * (z + (y * x)))))) / t_1
else if (y <= 4d+27) then
tmp = (t + (y * (230661.510616d0 + (y * (27464.7644705d0 + (y * z)))))) / (i + (y * t_1))
else
tmp = x + ((z / y) - (a * (x / 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 * (b + (y * (y + a)))) + c;
double tmp;
if (y <= -2.8e+70) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= -2.9e+16) {
tmp = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1;
} else if (y <= 4e+27) {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * 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 * (b + (y * (y + a)))) + c tmp = 0 if y <= -2.8e+70: tmp = x - ((z * (-1.0 + (a / y))) / y) elif y <= -2.9e+16: tmp = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1 elif y <= 4e+27: tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * 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(b + Float64(y * Float64(y + a)))) + c) tmp = 0.0 if (y <= -2.8e+70) tmp = Float64(x - Float64(Float64(z * Float64(-1.0 + Float64(a / y))) / y)); elseif (y <= -2.9e+16) tmp = Float64(Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * Float64(z + Float64(y * x)))))) / t_1); elseif (y <= 4e+27) tmp = Float64(Float64(t + Float64(y * Float64(230661.510616 + Float64(y * Float64(27464.7644705 + Float64(y * z)))))) / Float64(i + Float64(y * 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 * (b + (y * (y + a)))) + c; tmp = 0.0; if (y <= -2.8e+70) tmp = x - ((z * (-1.0 + (a / y))) / y); elseif (y <= -2.9e+16) tmp = (230661.510616 + (y * (27464.7644705 + (y * (z + (y * x)))))) / t_1; elseif (y <= 4e+27) tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * 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[(b + N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]}, If[LessEqual[y, -2.8e+70], N[(x - N[(N[(z * N[(-1.0 + N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.9e+16], N[(N[(230661.510616 + N[(y * N[(27464.7644705 + N[(y * N[(z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision], If[LessEqual[y, 4e+27], 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 * t$95$1), $MachinePrecision]), $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(b + y \cdot \left(y + a\right)\right) + c\\
\mathbf{if}\;y \leq -2.8 \cdot 10^{+70}:\\
\;\;\;\;x - \frac{z \cdot \left(-1 + \frac{a}{y}\right)}{y}\\
\mathbf{elif}\;y \leq -2.9 \cdot 10^{+16}:\\
\;\;\;\;\frac{230661.510616 + y \cdot \left(27464.7644705 + y \cdot \left(z + y \cdot x\right)\right)}{t\_1}\\
\mathbf{elif}\;y \leq 4 \cdot 10^{+27}:\\
\;\;\;\;\frac{t + y \cdot \left(230661.510616 + y \cdot \left(27464.7644705 + y \cdot z\right)\right)}{i + y \cdot t\_1}\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\end{array}
\end{array}
if y < -2.7999999999999999e70Initial program 4.4%
Taylor expanded in y around -inf 58.8%
Taylor expanded in z around inf 80.4%
if -2.7999999999999999e70 < y < -2.9e16Initial program 57.8%
Taylor expanded in t around 0 57.8%
Simplified63.6%
Taylor expanded in i around 0 74.2%
if -2.9e16 < y < 4.0000000000000001e27Initial program 99.1%
Taylor expanded in x around 0 94.2%
if 4.0000000000000001e27 < y Initial program 8.0%
Taylor expanded in y around inf 68.6%
associate--l+68.6%
associate-/l*70.3%
Simplified70.3%
Final simplification85.1%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -3.7e+26)
(- x (/ (* z (+ -1.0 (/ a y))) y))
(if (<= y 4e+27)
(/ (+ t (* y 230661.510616)) (+ i (* y (+ (* y (+ b (* y (+ y a)))) c))))
(+ 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 <= -3.7e+26) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= 4e+27) {
tmp = (t + (y * 230661.510616)) / (i + (y * ((y * (b + (y * (y + a)))) + c)));
} else {
tmp = x + ((z / y) - (a * (x / 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.7d+26)) then
tmp = x - ((z * ((-1.0d0) + (a / y))) / y)
else if (y <= 4d+27) then
tmp = (t + (y * 230661.510616d0)) / (i + (y * ((y * (b + (y * (y + a)))) + c)))
else
tmp = x + ((z / y) - (a * (x / 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.7e+26) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= 4e+27) {
tmp = (t + (y * 230661.510616)) / (i + (y * ((y * (b + (y * (y + a)))) + c)));
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -3.7e+26: tmp = x - ((z * (-1.0 + (a / y))) / y) elif y <= 4e+27: tmp = (t + (y * 230661.510616)) / (i + (y * ((y * (b + (y * (y + a)))) + c))) else: tmp = x + ((z / y) - (a * (x / y))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -3.7e+26) tmp = Float64(x - Float64(Float64(z * Float64(-1.0 + Float64(a / y))) / y)); elseif (y <= 4e+27) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * Float64(Float64(y * Float64(b + Float64(y * Float64(y + a)))) + c)))); 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) tmp = 0.0; if (y <= -3.7e+26) tmp = x - ((z * (-1.0 + (a / y))) / y); elseif (y <= 4e+27) tmp = (t + (y * 230661.510616)) / (i + (y * ((y * (b + (y * (y + a)))) + c))); else tmp = x + ((z / y) - (a * (x / y))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -3.7e+26], N[(x - N[(N[(z * N[(-1.0 + N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4e+27], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(N[(y * N[(b + N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision]), $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}\;y \leq -3.7 \cdot 10^{+26}:\\
\;\;\;\;x - \frac{z \cdot \left(-1 + \frac{a}{y}\right)}{y}\\
\mathbf{elif}\;y \leq 4 \cdot 10^{+27}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(y \cdot \left(b + y \cdot \left(y + a\right)\right) + c\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\end{array}
\end{array}
if y < -3.69999999999999988e26Initial program 15.5%
Taylor expanded in y around -inf 56.0%
Taylor expanded in z around inf 73.0%
if -3.69999999999999988e26 < y < 4.0000000000000001e27Initial program 97.7%
Taylor expanded in y around 0 83.7%
*-commutative83.7%
Simplified83.7%
if 4.0000000000000001e27 < y Initial program 8.0%
Taylor expanded in y around inf 68.6%
associate--l+68.6%
associate-/l*70.3%
Simplified70.3%
Final simplification78.2%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -1.8e+25)
(- x (/ (* z (+ -1.0 (/ a y))) y))
(if (<= y 1.7e+23)
(/ t (+ i (* y (+ (* y (+ b (* y (+ y a)))) c))))
(+ 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 <= -1.8e+25) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= 1.7e+23) {
tmp = t / (i + (y * ((y * (b + (y * (y + a)))) + c)));
} else {
tmp = x + ((z / y) - (a * (x / 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.8d+25)) then
tmp = x - ((z * ((-1.0d0) + (a / y))) / y)
else if (y <= 1.7d+23) then
tmp = t / (i + (y * ((y * (b + (y * (y + a)))) + c)))
else
tmp = x + ((z / y) - (a * (x / 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.8e+25) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= 1.7e+23) {
tmp = t / (i + (y * ((y * (b + (y * (y + a)))) + c)));
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -1.8e+25: tmp = x - ((z * (-1.0 + (a / y))) / y) elif y <= 1.7e+23: tmp = t / (i + (y * ((y * (b + (y * (y + a)))) + c))) else: tmp = x + ((z / y) - (a * (x / y))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -1.8e+25) tmp = Float64(x - Float64(Float64(z * Float64(-1.0 + Float64(a / y))) / y)); elseif (y <= 1.7e+23) tmp = Float64(t / Float64(i + Float64(y * Float64(Float64(y * Float64(b + Float64(y * Float64(y + a)))) + c)))); 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) tmp = 0.0; if (y <= -1.8e+25) tmp = x - ((z * (-1.0 + (a / y))) / y); elseif (y <= 1.7e+23) tmp = t / (i + (y * ((y * (b + (y * (y + a)))) + c))); else tmp = x + ((z / y) - (a * (x / y))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -1.8e+25], N[(x - N[(N[(z * N[(-1.0 + N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.7e+23], N[(t / N[(i + N[(y * N[(N[(y * N[(b + N[(y * N[(y + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + c), $MachinePrecision]), $MachinePrecision]), $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}\;y \leq -1.8 \cdot 10^{+25}:\\
\;\;\;\;x - \frac{z \cdot \left(-1 + \frac{a}{y}\right)}{y}\\
\mathbf{elif}\;y \leq 1.7 \cdot 10^{+23}:\\
\;\;\;\;\frac{t}{i + y \cdot \left(y \cdot \left(b + y \cdot \left(y + a\right)\right) + c\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\end{array}
\end{array}
if y < -1.80000000000000008e25Initial program 15.5%
Taylor expanded in y around -inf 56.0%
Taylor expanded in z around inf 73.0%
if -1.80000000000000008e25 < y < 1.69999999999999996e23Initial program 97.7%
Taylor expanded in t around inf 72.2%
if 1.69999999999999996e23 < y Initial program 8.0%
Taylor expanded in y around inf 68.6%
associate--l+68.6%
associate-/l*70.3%
Simplified70.3%
Final simplification71.9%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -3.9e+29) (not (<= y 1.36e+23))) (+ 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 <= -3.9e+29) || !(y <= 1.36e+23)) {
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 <= (-3.9d+29)) .or. (.not. (y <= 1.36d+23))) 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 <= -3.9e+29) || !(y <= 1.36e+23)) {
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 <= -3.9e+29) or not (y <= 1.36e+23): 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 <= -3.9e+29) || !(y <= 1.36e+23)) 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 <= -3.9e+29) || ~((y <= 1.36e+23))) 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, -3.9e+29], N[Not[LessEqual[y, 1.36e+23]], $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 -3.9 \cdot 10^{+29} \lor \neg \left(y \leq 1.36 \cdot 10^{+23}\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 < -3.89999999999999968e29 or 1.36e23 < y Initial program 11.9%
Taylor expanded in y around inf 67.1%
associate--l+67.1%
associate-/l*72.2%
Simplified72.2%
if -3.89999999999999968e29 < y < 1.36e23Initial program 97.1%
Taylor expanded in t around inf 71.7%
Taylor expanded in b around inf 70.3%
Final simplification71.2%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -1.45e+27) (not (<= y 1.15e+27))) (+ x (- (/ z y) (* a (/ x y)))) (/ t (+ i (* y c)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.45e+27) || !(y <= 1.15e+27)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = t / (i + (y * c));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((y <= (-1.45d+27)) .or. (.not. (y <= 1.15d+27))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = t / (i + (y * c))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.45e+27) || !(y <= 1.15e+27)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = t / (i + (y * c));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.45e+27) or not (y <= 1.15e+27): tmp = x + ((z / y) - (a * (x / y))) else: tmp = t / (i + (y * c)) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.45e+27) || !(y <= 1.15e+27)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(t / Float64(i + Float64(y * c))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.45e+27) || ~((y <= 1.15e+27))) tmp = x + ((z / y) - (a * (x / y))); else tmp = t / (i + (y * c)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.45e+27], N[Not[LessEqual[y, 1.15e+27]], $MachinePrecision]], N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t / N[(i + N[(y * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.45 \cdot 10^{+27} \lor \neg \left(y \leq 1.15 \cdot 10^{+27}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{i + y \cdot c}\\
\end{array}
\end{array}
if y < -1.4500000000000001e27 or 1.15e27 < y Initial program 11.9%
Taylor expanded in y around inf 67.1%
associate--l+67.1%
associate-/l*72.2%
Simplified72.2%
if -1.4500000000000001e27 < y < 1.15e27Initial program 97.1%
Taylor expanded in t around inf 71.7%
Taylor expanded in y around 0 66.2%
Final simplification68.9%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -4.75e+24)
(- x (/ (* z (+ -1.0 (/ a y))) y))
(if (<= y 5.4e+22)
(/ t (+ i (* y (+ c (* y b)))))
(+ 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 <= -4.75e+24) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= 5.4e+22) {
tmp = t / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z / y) - (a * (x / 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 <= (-4.75d+24)) then
tmp = x - ((z * ((-1.0d0) + (a / y))) / y)
else if (y <= 5.4d+22) then
tmp = t / (i + (y * (c + (y * b))))
else
tmp = x + ((z / y) - (a * (x / 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 <= -4.75e+24) {
tmp = x - ((z * (-1.0 + (a / y))) / y);
} else if (y <= 5.4e+22) {
tmp = t / (i + (y * (c + (y * b))));
} else {
tmp = x + ((z / y) - (a * (x / y)));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -4.75e+24: tmp = x - ((z * (-1.0 + (a / y))) / y) elif y <= 5.4e+22: tmp = t / (i + (y * (c + (y * b)))) else: tmp = x + ((z / y) - (a * (x / y))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -4.75e+24) tmp = Float64(x - Float64(Float64(z * Float64(-1.0 + Float64(a / y))) / y)); elseif (y <= 5.4e+22) tmp = Float64(t / Float64(i + Float64(y * Float64(c + Float64(y * b))))); 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) tmp = 0.0; if (y <= -4.75e+24) tmp = x - ((z * (-1.0 + (a / y))) / y); elseif (y <= 5.4e+22) tmp = t / (i + (y * (c + (y * b)))); else tmp = x + ((z / y) - (a * (x / y))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -4.75e+24], N[(x - N[(N[(z * N[(-1.0 + N[(a / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.4e+22], N[(t / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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}\;y \leq -4.75 \cdot 10^{+24}:\\
\;\;\;\;x - \frac{z \cdot \left(-1 + \frac{a}{y}\right)}{y}\\
\mathbf{elif}\;y \leq 5.4 \cdot 10^{+22}:\\
\;\;\;\;\frac{t}{i + y \cdot \left(c + y \cdot b\right)}\\
\mathbf{else}:\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\end{array}
\end{array}
if y < -4.7500000000000001e24Initial program 15.5%
Taylor expanded in y around -inf 56.0%
Taylor expanded in z around inf 73.0%
if -4.7500000000000001e24 < y < 5.4000000000000004e22Initial program 97.7%
Taylor expanded in t around inf 72.2%
Taylor expanded in b around inf 70.8%
if 5.4000000000000004e22 < y Initial program 8.0%
Taylor expanded in y around inf 68.6%
associate--l+68.6%
associate-/l*70.3%
Simplified70.3%
Final simplification71.2%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -4.8e+26) x (if (<= y 2.9e+26) (/ t (+ i (* y c))) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -4.8e+26) {
tmp = x;
} else if (y <= 2.9e+26) {
tmp = t / (i + (y * c));
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if (y <= (-4.8d+26)) then
tmp = x
else if (y <= 2.9d+26) then
tmp = t / (i + (y * c))
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -4.8e+26) {
tmp = x;
} else if (y <= 2.9e+26) {
tmp = t / (i + (y * c));
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -4.8e+26: tmp = x elif y <= 2.9e+26: tmp = t / (i + (y * c)) else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -4.8e+26) tmp = x; elseif (y <= 2.9e+26) tmp = Float64(t / Float64(i + Float64(y * c))); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -4.8e+26) tmp = x; elseif (y <= 2.9e+26) tmp = t / (i + (y * c)); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -4.8e+26], x, If[LessEqual[y, 2.9e+26], N[(t / N[(i + N[(y * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.8 \cdot 10^{+26}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 2.9 \cdot 10^{+26}:\\
\;\;\;\;\frac{t}{i + y \cdot c}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -4.80000000000000009e26 or 2.9e26 < y Initial program 11.9%
Taylor expanded in y around inf 54.3%
if -4.80000000000000009e26 < y < 2.9e26Initial program 97.1%
Taylor expanded in t around inf 71.7%
Taylor expanded in y around 0 66.2%
Final simplification60.8%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -4.9e+28) x (if (<= y 2.3e+24) (/ t i) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -4.9e+28) {
tmp = x;
} else if (y <= 2.3e+24) {
tmp = t / i;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if (y <= (-4.9d+28)) then
tmp = x
else if (y <= 2.3d+24) then
tmp = t / i
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -4.9e+28) {
tmp = x;
} else if (y <= 2.3e+24) {
tmp = t / i;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -4.9e+28: tmp = x elif y <= 2.3e+24: tmp = t / i else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -4.9e+28) tmp = x; elseif (y <= 2.3e+24) tmp = Float64(t / i); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if (y <= -4.9e+28) tmp = x; elseif (y <= 2.3e+24) tmp = t / i; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -4.9e+28], x, If[LessEqual[y, 2.3e+24], N[(t / i), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.9 \cdot 10^{+28}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 2.3 \cdot 10^{+24}:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -4.8999999999999996e28 or 2.2999999999999999e24 < y Initial program 11.9%
Taylor expanded in y around inf 54.3%
if -4.8999999999999996e28 < y < 2.2999999999999999e24Initial program 97.1%
Taylor expanded in y around 0 50.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 58.5%
Taylor expanded in y around inf 26.7%
herbie shell --seed 2024091
(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)))