
(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 16 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 (or (<= y -2e+37) (not (<= y 6.2e+34)))
(+ x (- (/ z y) (* a (/ x y))))
(/
(+ (* y (+ (* y (+ (* y (+ (* x y) z)) 27464.7644705)) 230661.510616)) t)
(+ i (* y (+ c (* y (+ b (* y a)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -2e+37) || !(y <= 6.2e+34)) {
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 + (y * a))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((y <= (-2d+37)) .or. (.not. (y <= 6.2d+34))) 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 + (y * a))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -2e+37) || !(y <= 6.2e+34)) {
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 + (y * a))))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -2e+37) or not (y <= 6.2e+34): 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 + (y * a)))))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -2e+37) || !(y <= 6.2e+34)) 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 * Float64(b + Float64(y * a))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -2e+37) || ~((y <= 6.2e+34))) 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 + (y * a)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -2e+37], N[Not[LessEqual[y, 6.2e+34]], $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 * N[(b + N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2 \cdot 10^{+37} \lor \neg \left(y \leq 6.2 \cdot 10^{+34}\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 \left(b + y \cdot a\right)\right)}\\
\end{array}
\end{array}
if y < -1.99999999999999991e37 or 6.19999999999999955e34 < y Initial program 4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
Simplified4.1%
Taylor expanded in y around inf 68.4%
associate--l+68.4%
associate-/l*71.7%
Simplified71.7%
if -1.99999999999999991e37 < y < 6.19999999999999955e34Initial program 95.6%
Taylor expanded in y around 0 95.6%
Final simplification84.9%
(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) 5e+292)
(+ (/ 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) <= 5e+292) {
tmp = (t / t_1) + (t_2 / 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) :: t_2
real(8) :: tmp
t_1 = (y * ((y * ((y * (y + a)) + b)) + c)) + i
t_2 = y * ((y * ((y * ((x * y) + z)) + 27464.7644705d0)) + 230661.510616d0)
if (((t_2 + t) / t_1) <= 5d+292) then
tmp = (t / t_1) + (t_2 / 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 * ((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) <= 5e+292) {
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) <= 5e+292: 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) <= 5e+292) 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) <= 5e+292) 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], 5e+292], 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 5 \cdot 10^{+292}:\\
\;\;\;\;\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) #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)) < 4.9999999999999996e292Initial program 90.3%
fma-define90.3%
fma-define90.3%
fma-define90.3%
fma-define90.3%
fma-define90.3%
fma-define90.3%
fma-define90.3%
Simplified90.3%
Taylor expanded in t around 0 90.3%
if 4.9999999999999996e292 < (/.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x y) z) y) #s(literal 54929528941/2000000 binary64)) y) #s(literal 28832688827/125000 binary64)) y) t) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 y a) y) b) y) c) y) i)) Initial program 2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
Simplified2.2%
Taylor expanded in y around inf 71.3%
associate--l+71.3%
associate-/l*75.0%
Simplified75.0%
Final simplification84.1%
(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 5e+292) 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 <= 5e+292) {
tmp = 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 * ((y * ((y * ((x * y) + z)) + 27464.7644705d0)) + 230661.510616d0)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i)
if (t_1 <= 5d+292) then
tmp = 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 * ((y * ((y * ((x * y) + z)) + 27464.7644705)) + 230661.510616)) + t) / ((y * ((y * ((y * (y + a)) + b)) + c)) + i);
double tmp;
if (t_1 <= 5e+292) {
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 <= 5e+292: 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 <= 5e+292) 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 <= 5e+292) 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, 5e+292], 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 5 \cdot 10^{+292}:\\
\;\;\;\;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)) < 4.9999999999999996e292Initial program 90.3%
if 4.9999999999999996e292 < (/.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 x y) z) y) #s(literal 54929528941/2000000 binary64)) y) #s(literal 28832688827/125000 binary64)) y) t) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 y a) y) b) y) c) y) i)) Initial program 2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
fma-define2.2%
Simplified2.2%
Taylor expanded in y around inf 71.3%
associate--l+71.3%
associate-/l*75.0%
Simplified75.0%
Final simplification84.1%
(FPCore (x y z t a b c i)
:precision binary64
(if (or (<= y -6.2e+36) (not (<= y 1.7e+34)))
(+ x (- (/ z y) (* a (/ x y))))
(/
(+ t (* y (+ 230661.510616 (* y (+ 27464.7644705 (* y z))))))
(+ i (* y (+ c (* y (+ b (* y a)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -6.2e+36) || !(y <= 1.7e+34)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * (c + (y * (b + (y * a))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((y <= (-6.2d+36)) .or. (.not. (y <= 1.7d+34))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = (t + (y * (230661.510616d0 + (y * (27464.7644705d0 + (y * z)))))) / (i + (y * (c + (y * (b + (y * a))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -6.2e+36) || !(y <= 1.7e+34)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * (c + (y * (b + (y * a))))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -6.2e+36) or not (y <= 1.7e+34): tmp = x + ((z / y) - (a * (x / y))) else: tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * (c + (y * (b + (y * a)))))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -6.2e+36) || !(y <= 1.7e+34)) 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(i + Float64(y * Float64(c + Float64(y * Float64(b + Float64(y * a))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -6.2e+36) || ~((y <= 1.7e+34))) tmp = x + ((z / y) - (a * (x / y))); else tmp = (t + (y * (230661.510616 + (y * (27464.7644705 + (y * z)))))) / (i + (y * (c + (y * (b + (y * a)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -6.2e+36], N[Not[LessEqual[y, 1.7e+34]], $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[(i + N[(y * N[(c + N[(y * N[(b + N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.2 \cdot 10^{+36} \lor \neg \left(y \leq 1.7 \cdot 10^{+34}\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)}{i + y \cdot \left(c + y \cdot \left(b + y \cdot a\right)\right)}\\
\end{array}
\end{array}
if y < -6.1999999999999999e36 or 1.7e34 < y Initial program 4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
Simplified4.1%
Taylor expanded in y around inf 68.4%
associate--l+68.4%
associate-/l*71.7%
Simplified71.7%
if -6.1999999999999999e36 < y < 1.7e34Initial program 95.6%
Taylor expanded in y around 0 95.6%
Taylor expanded in x around 0 90.9%
Final simplification82.3%
(FPCore (x y z t a b c i)
:precision binary64
(if (or (<= y -3.1e+35) (not (<= y 1.55e+35)))
(+ 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 <= -3.1e+35) || !(y <= 1.55e+35)) {
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 <= (-3.1d+35)) .or. (.not. (y <= 1.55d+35))) 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 <= -3.1e+35) || !(y <= 1.55e+35)) {
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 <= -3.1e+35) or not (y <= 1.55e+35): 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 <= -3.1e+35) || !(y <= 1.55e+35)) 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 <= -3.1e+35) || ~((y <= 1.55e+35))) 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, -3.1e+35], N[Not[LessEqual[y, 1.55e+35]], $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 -3.1 \cdot 10^{+35} \lor \neg \left(y \leq 1.55 \cdot 10^{+35}\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 < -3.09999999999999987e35 or 1.54999999999999993e35 < y Initial program 4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
Simplified4.1%
Taylor expanded in y around inf 68.4%
associate--l+68.4%
associate-/l*71.7%
Simplified71.7%
if -3.09999999999999987e35 < y < 1.54999999999999993e35Initial program 95.6%
Taylor expanded in y around 0 81.5%
*-commutative81.5%
Simplified81.5%
Final simplification77.1%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ x (- (/ z y) (* a (/ x y))))))
(if (<= y -7.8e+77)
t_1
(if (<= y -0.32)
(/ (* y (+ x (/ z y))) a)
(if (<= y 9.5e-24)
(/ (+ t (* y 230661.510616)) (+ i (* y c)))
(if (<= y 2.75e+20) (/ t (* y (+ c (* y (+ b (* y a)))))) t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -7.8e+77) {
tmp = t_1;
} else if (y <= -0.32) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 9.5e-24) {
tmp = (t + (y * 230661.510616)) / (i + (y * c));
} else if (y <= 2.75e+20) {
tmp = t / (y * (c + (y * (b + (y * a)))));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = x + ((z / y) - (a * (x / y)))
if (y <= (-7.8d+77)) then
tmp = t_1
else if (y <= (-0.32d0)) then
tmp = (y * (x + (z / y))) / a
else if (y <= 9.5d-24) then
tmp = (t + (y * 230661.510616d0)) / (i + (y * c))
else if (y <= 2.75d+20) then
tmp = t / (y * (c + (y * (b + (y * a)))))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -7.8e+77) {
tmp = t_1;
} else if (y <= -0.32) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 9.5e-24) {
tmp = (t + (y * 230661.510616)) / (i + (y * c));
} else if (y <= 2.75e+20) {
tmp = t / (y * (c + (y * (b + (y * a)))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = x + ((z / y) - (a * (x / y))) tmp = 0 if y <= -7.8e+77: tmp = t_1 elif y <= -0.32: tmp = (y * (x + (z / y))) / a elif y <= 9.5e-24: tmp = (t + (y * 230661.510616)) / (i + (y * c)) elif y <= 2.75e+20: tmp = t / (y * (c + (y * (b + (y * a))))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))) tmp = 0.0 if (y <= -7.8e+77) tmp = t_1; elseif (y <= -0.32) tmp = Float64(Float64(y * Float64(x + Float64(z / y))) / a); elseif (y <= 9.5e-24) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * c))); elseif (y <= 2.75e+20) tmp = Float64(t / Float64(y * Float64(c + Float64(y * Float64(b + Float64(y * a)))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = x + ((z / y) - (a * (x / y))); tmp = 0.0; if (y <= -7.8e+77) tmp = t_1; elseif (y <= -0.32) tmp = (y * (x + (z / y))) / a; elseif (y <= 9.5e-24) tmp = (t + (y * 230661.510616)) / (i + (y * c)); elseif (y <= 2.75e+20) tmp = t / (y * (c + (y * (b + (y * a))))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -7.8e+77], t$95$1, If[LessEqual[y, -0.32], N[(N[(y * N[(x + N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, 9.5e-24], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.75e+20], N[(t / N[(y * N[(c + N[(y * N[(b + N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -7.8 \cdot 10^{+77}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -0.32:\\
\;\;\;\;\frac{y \cdot \left(x + \frac{z}{y}\right)}{a}\\
\mathbf{elif}\;y \leq 9.5 \cdot 10^{-24}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot c}\\
\mathbf{elif}\;y \leq 2.75 \cdot 10^{+20}:\\
\;\;\;\;\frac{t}{y \cdot \left(c + y \cdot \left(b + y \cdot a\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -7.7999999999999995e77 or 2.75e20 < y Initial program 1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
Simplified1.4%
Taylor expanded in y around inf 71.9%
associate--l+71.9%
associate-/l*75.5%
Simplified75.5%
if -7.7999999999999995e77 < y < -0.320000000000000007Initial program 44.6%
Taylor expanded in y around 0 34.8%
Taylor expanded in y around -inf 38.6%
mul-1-neg38.6%
distribute-lft-out38.6%
Simplified38.6%
Taylor expanded in a around inf 46.5%
associate-*r/46.5%
associate-*r*46.5%
mul-1-neg46.5%
Simplified46.5%
if -0.320000000000000007 < y < 9.50000000000000029e-24Initial program 99.6%
Taylor expanded in y around 0 99.6%
Taylor expanded in y around 0 88.5%
*-commutative88.5%
Simplified88.5%
Taylor expanded in y around 0 84.6%
if 9.50000000000000029e-24 < y < 2.75e20Initial program 85.0%
Taylor expanded in y around 0 85.0%
Taylor expanded in i around 0 62.9%
Taylor expanded in t around inf 41.4%
Final simplification75.8%
(FPCore (x y z t a b c i)
:precision binary64
(if (or (<= y -1.9e+35) (not (<= y 1.1e+31)))
(+ x (- (/ z y) (* a (/ x y))))
(/
(+ t (* y (+ 230661.510616 (* y 27464.7644705))))
(+ i (* y (+ c (* y (+ b (* y a)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.9e+35) || !(y <= 1.1e+31)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * (b + (y * a))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((y <= (-1.9d+35)) .or. (.not. (y <= 1.1d+31))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = (t + (y * (230661.510616d0 + (y * 27464.7644705d0)))) / (i + (y * (c + (y * (b + (y * a))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.9e+35) || !(y <= 1.1e+31)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * (b + (y * a))))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.9e+35) or not (y <= 1.1e+31): tmp = x + ((z / y) - (a * (x / y))) else: tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * (b + (y * a)))))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.9e+35) || !(y <= 1.1e+31)) 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 * Float64(b + Float64(y * a))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.9e+35) || ~((y <= 1.1e+31))) tmp = x + ((z / y) - (a * (x / y))); else tmp = (t + (y * (230661.510616 + (y * 27464.7644705)))) / (i + (y * (c + (y * (b + (y * a)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.9e+35], N[Not[LessEqual[y, 1.1e+31]], $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 * N[(b + N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.9 \cdot 10^{+35} \lor \neg \left(y \leq 1.1 \cdot 10^{+31}\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 \left(b + y \cdot a\right)\right)}\\
\end{array}
\end{array}
if y < -1.9e35 or 1.10000000000000005e31 < y Initial program 4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
Simplified4.1%
Taylor expanded in y around inf 68.4%
associate--l+68.4%
associate-/l*71.7%
Simplified71.7%
if -1.9e35 < y < 1.10000000000000005e31Initial program 95.6%
Taylor expanded in y around 0 95.6%
Taylor expanded in y around 0 81.5%
*-commutative81.5%
Simplified81.5%
Final simplification77.1%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ x (- (/ z y) (* a (/ x y))))))
(if (<= y -6.5e+75)
t_1
(if (<= y -2100.0)
(/ (* y (+ x (/ z y))) a)
(if (<= y 1e+29)
(/ (+ t (* y 230661.510616)) (+ i (* y (+ c (* y b)))))
t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -6.5e+75) {
tmp = t_1;
} else if (y <= -2100.0) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 1e+29) {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b))));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = x + ((z / y) - (a * (x / y)))
if (y <= (-6.5d+75)) then
tmp = t_1
else if (y <= (-2100.0d0)) then
tmp = (y * (x + (z / y))) / a
else if (y <= 1d+29) then
tmp = (t + (y * 230661.510616d0)) / (i + (y * (c + (y * b))))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -6.5e+75) {
tmp = t_1;
} else if (y <= -2100.0) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 1e+29) {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = x + ((z / y) - (a * (x / y))) tmp = 0 if y <= -6.5e+75: tmp = t_1 elif y <= -2100.0: tmp = (y * (x + (z / y))) / a elif y <= 1e+29: tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b)))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))) tmp = 0.0 if (y <= -6.5e+75) tmp = t_1; elseif (y <= -2100.0) tmp = Float64(Float64(y * Float64(x + Float64(z / y))) / a); elseif (y <= 1e+29) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * Float64(c + Float64(y * b))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = x + ((z / y) - (a * (x / y))); tmp = 0.0; if (y <= -6.5e+75) tmp = t_1; elseif (y <= -2100.0) tmp = (y * (x + (z / y))) / a; elseif (y <= 1e+29) tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * b)))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6.5e+75], t$95$1, If[LessEqual[y, -2100.0], N[(N[(y * N[(x + N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, 1e+29], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * N[(c + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -6.5 \cdot 10^{+75}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -2100:\\
\;\;\;\;\frac{y \cdot \left(x + \frac{z}{y}\right)}{a}\\
\mathbf{elif}\;y \leq 10^{+29}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot b\right)}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -6.4999999999999998e75 or 9.99999999999999914e28 < y Initial program 1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
Simplified1.4%
Taylor expanded in y around inf 71.9%
associate--l+71.9%
associate-/l*75.5%
Simplified75.5%
if -6.4999999999999998e75 < y < -2100Initial program 41.6%
Taylor expanded in y around 0 31.3%
Taylor expanded in y around -inf 40.6%
mul-1-neg40.6%
distribute-lft-out40.6%
Simplified40.6%
Taylor expanded in a around inf 48.7%
associate-*r/48.7%
associate-*r*48.7%
mul-1-neg48.7%
Simplified48.7%
if -2100 < y < 9.99999999999999914e28Initial program 98.2%
Taylor expanded in y around 0 98.2%
Taylor expanded in y around 0 83.9%
*-commutative83.9%
Simplified83.9%
Taylor expanded in a around 0 79.9%
Final simplification75.9%
(FPCore (x y z t a b c i) :precision binary64 (if (or (<= y -1.4e+34) (not (<= y 7.2e+28))) (+ x (- (/ z y) (* a (/ x y)))) (/ (+ t (* y 230661.510616)) (+ i (* y (+ c (* y (+ b (* y a)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.4e+34) || !(y <= 7.2e+28)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * (b + (y * a))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: tmp
if ((y <= (-1.4d+34)) .or. (.not. (y <= 7.2d+28))) then
tmp = x + ((z / y) - (a * (x / y)))
else
tmp = (t + (y * 230661.510616d0)) / (i + (y * (c + (y * (b + (y * a))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if ((y <= -1.4e+34) || !(y <= 7.2e+28)) {
tmp = x + ((z / y) - (a * (x / y)));
} else {
tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * (b + (y * a))))));
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if (y <= -1.4e+34) or not (y <= 7.2e+28): tmp = x + ((z / y) - (a * (x / y))) else: tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * (b + (y * a)))))) return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if ((y <= -1.4e+34) || !(y <= 7.2e+28)) tmp = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))); else tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * Float64(c + Float64(y * Float64(b + Float64(y * a))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) tmp = 0.0; if ((y <= -1.4e+34) || ~((y <= 7.2e+28))) tmp = x + ((z / y) - (a * (x / y))); else tmp = (t + (y * 230661.510616)) / (i + (y * (c + (y * (b + (y * a)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[y, -1.4e+34], N[Not[LessEqual[y, 7.2e+28]], $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[(i + N[(y * N[(c + N[(y * N[(b + N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.4 \cdot 10^{+34} \lor \neg \left(y \leq 7.2 \cdot 10^{+28}\right):\\
\;\;\;\;x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot \left(c + y \cdot \left(b + y \cdot a\right)\right)}\\
\end{array}
\end{array}
if y < -1.40000000000000004e34 or 7.1999999999999999e28 < y Initial program 4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
fma-define4.1%
Simplified4.1%
Taylor expanded in y around inf 68.4%
associate--l+68.4%
associate-/l*71.7%
Simplified71.7%
if -1.40000000000000004e34 < y < 7.1999999999999999e28Initial program 95.6%
Taylor expanded in y around 0 95.6%
Taylor expanded in y around 0 80.7%
*-commutative80.7%
Simplified80.7%
Final simplification76.7%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ x (- (/ z y) (* a (/ x y))))))
(if (<= y -1.75e+78)
t_1
(if (<= y -0.35)
(/ (* y (+ x (/ z y))) a)
(if (<= y 6.8e+27) (/ (+ t (* y 230661.510616)) (+ i (* y c))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -1.75e+78) {
tmp = t_1;
} else if (y <= -0.35) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 6.8e+27) {
tmp = (t + (y * 230661.510616)) / (i + (y * c));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = x + ((z / y) - (a * (x / y)))
if (y <= (-1.75d+78)) then
tmp = t_1
else if (y <= (-0.35d0)) then
tmp = (y * (x + (z / y))) / a
else if (y <= 6.8d+27) then
tmp = (t + (y * 230661.510616d0)) / (i + (y * c))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -1.75e+78) {
tmp = t_1;
} else if (y <= -0.35) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 6.8e+27) {
tmp = (t + (y * 230661.510616)) / (i + (y * c));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = x + ((z / y) - (a * (x / y))) tmp = 0 if y <= -1.75e+78: tmp = t_1 elif y <= -0.35: tmp = (y * (x + (z / y))) / a elif y <= 6.8e+27: tmp = (t + (y * 230661.510616)) / (i + (y * c)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))) tmp = 0.0 if (y <= -1.75e+78) tmp = t_1; elseif (y <= -0.35) tmp = Float64(Float64(y * Float64(x + Float64(z / y))) / a); elseif (y <= 6.8e+27) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / Float64(i + Float64(y * c))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = x + ((z / y) - (a * (x / y))); tmp = 0.0; if (y <= -1.75e+78) tmp = t_1; elseif (y <= -0.35) tmp = (y * (x + (z / y))) / a; elseif (y <= 6.8e+27) tmp = (t + (y * 230661.510616)) / (i + (y * c)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.75e+78], t$95$1, If[LessEqual[y, -0.35], N[(N[(y * N[(x + N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, 6.8e+27], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / N[(i + N[(y * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -1.75 \cdot 10^{+78}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -0.35:\\
\;\;\;\;\frac{y \cdot \left(x + \frac{z}{y}\right)}{a}\\
\mathbf{elif}\;y \leq 6.8 \cdot 10^{+27}:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i + y \cdot c}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -1.7500000000000001e78 or 6.8e27 < y Initial program 1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
fma-define1.4%
Simplified1.4%
Taylor expanded in y around inf 71.9%
associate--l+71.9%
associate-/l*75.5%
Simplified75.5%
if -1.7500000000000001e78 < y < -0.34999999999999998Initial program 44.6%
Taylor expanded in y around 0 34.8%
Taylor expanded in y around -inf 38.6%
mul-1-neg38.6%
distribute-lft-out38.6%
Simplified38.6%
Taylor expanded in a around inf 46.5%
associate-*r/46.5%
associate-*r*46.5%
mul-1-neg46.5%
Simplified46.5%
if -0.34999999999999998 < y < 6.8e27Initial program 98.2%
Taylor expanded in y around 0 98.2%
Taylor expanded in y around 0 83.8%
*-commutative83.8%
Simplified83.8%
Taylor expanded in y around 0 76.9%
Final simplification74.1%
(FPCore (x y z t a b c i)
:precision binary64
(let* ((t_1 (+ x (- (/ z y) (* a (/ x y))))))
(if (<= y -6.2e+76)
t_1
(if (<= y -1.95e-33)
(/ (* y (+ x (/ z y))) a)
(if (<= y 1250000.0) (/ (+ t (* y 230661.510616)) i) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -6.2e+76) {
tmp = t_1;
} else if (y <= -1.95e-33) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 1250000.0) {
tmp = (t + (y * 230661.510616)) / i;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: i
real(8) :: t_1
real(8) :: tmp
t_1 = x + ((z / y) - (a * (x / y)))
if (y <= (-6.2d+76)) then
tmp = t_1
else if (y <= (-1.95d-33)) then
tmp = (y * (x + (z / y))) / a
else if (y <= 1250000.0d0) then
tmp = (t + (y * 230661.510616d0)) / i
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double t_1 = x + ((z / y) - (a * (x / y)));
double tmp;
if (y <= -6.2e+76) {
tmp = t_1;
} else if (y <= -1.95e-33) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 1250000.0) {
tmp = (t + (y * 230661.510616)) / i;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): t_1 = x + ((z / y) - (a * (x / y))) tmp = 0 if y <= -6.2e+76: tmp = t_1 elif y <= -1.95e-33: tmp = (y * (x + (z / y))) / a elif y <= 1250000.0: tmp = (t + (y * 230661.510616)) / i else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c, i) t_1 = Float64(x + Float64(Float64(z / y) - Float64(a * Float64(x / y)))) tmp = 0.0 if (y <= -6.2e+76) tmp = t_1; elseif (y <= -1.95e-33) tmp = Float64(Float64(y * Float64(x + Float64(z / y))) / a); elseif (y <= 1250000.0) tmp = Float64(Float64(t + Float64(y * 230661.510616)) / i); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c, i) t_1 = x + ((z / y) - (a * (x / y))); tmp = 0.0; if (y <= -6.2e+76) tmp = t_1; elseif (y <= -1.95e-33) tmp = (y * (x + (z / y))) / a; elseif (y <= 1250000.0) tmp = (t + (y * 230661.510616)) / i; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(x + N[(N[(z / y), $MachinePrecision] - N[(a * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6.2e+76], t$95$1, If[LessEqual[y, -1.95e-33], N[(N[(y * N[(x + N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, 1250000.0], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(\frac{z}{y} - a \cdot \frac{x}{y}\right)\\
\mathbf{if}\;y \leq -6.2 \cdot 10^{+76}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -1.95 \cdot 10^{-33}:\\
\;\;\;\;\frac{y \cdot \left(x + \frac{z}{y}\right)}{a}\\
\mathbf{elif}\;y \leq 1250000:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -6.20000000000000023e76 or 1.25e6 < y Initial program 2.4%
fma-define2.4%
fma-define2.4%
fma-define2.4%
fma-define2.4%
fma-define2.4%
fma-define2.4%
fma-define2.4%
Simplified2.4%
Taylor expanded in y around inf 69.9%
associate--l+69.9%
associate-/l*73.5%
Simplified73.5%
if -6.20000000000000023e76 < y < -1.94999999999999987e-33Initial program 57.7%
Taylor expanded in y around 0 50.2%
Taylor expanded in y around -inf 34.0%
mul-1-neg34.0%
distribute-lft-out34.0%
Simplified34.0%
Taylor expanded in a around inf 40.3%
associate-*r/40.3%
associate-*r*40.3%
mul-1-neg40.3%
Simplified40.3%
if -1.94999999999999987e-33 < y < 1.25e6Initial program 99.7%
Taylor expanded in y around 0 99.7%
Taylor expanded in y around 0 86.7%
*-commutative86.7%
Simplified86.7%
Taylor expanded in i around inf 61.2%
Final simplification64.3%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -2.85e+107)
x
(if (<= y -1.9e-33)
(/ (* y (+ x (/ z y))) a)
(if (<= y 3.6) (/ (+ 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 <= -2.85e+107) {
tmp = x;
} else if (y <= -1.9e-33) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 3.6) {
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 <= (-2.85d+107)) then
tmp = x
else if (y <= (-1.9d-33)) then
tmp = (y * (x + (z / y))) / a
else if (y <= 3.6d0) 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 <= -2.85e+107) {
tmp = x;
} else if (y <= -1.9e-33) {
tmp = (y * (x + (z / y))) / a;
} else if (y <= 3.6) {
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 <= -2.85e+107: tmp = x elif y <= -1.9e-33: tmp = (y * (x + (z / y))) / a elif y <= 3.6: 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 <= -2.85e+107) tmp = x; elseif (y <= -1.9e-33) tmp = Float64(Float64(y * Float64(x + Float64(z / y))) / a); elseif (y <= 3.6) 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 <= -2.85e+107) tmp = x; elseif (y <= -1.9e-33) tmp = (y * (x + (z / y))) / a; elseif (y <= 3.6) 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, -2.85e+107], x, If[LessEqual[y, -1.9e-33], N[(N[(y * N[(x + N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, 3.6], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision], x]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.85 \cdot 10^{+107}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -1.9 \cdot 10^{-33}:\\
\;\;\;\;\frac{y \cdot \left(x + \frac{z}{y}\right)}{a}\\
\mathbf{elif}\;y \leq 3.6:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -2.84999999999999986e107 or 3.60000000000000009 < y Initial program 4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
Simplified4.2%
Taylor expanded in y around inf 60.1%
if -2.84999999999999986e107 < y < -1.89999999999999997e-33Initial program 49.9%
Taylor expanded in y around 0 43.6%
Taylor expanded in y around -inf 32.8%
mul-1-neg32.8%
distribute-lft-out32.8%
Simplified32.8%
Taylor expanded in a around inf 38.4%
associate-*r/38.4%
associate-*r*38.4%
mul-1-neg38.4%
Simplified38.4%
if -1.89999999999999997e-33 < y < 3.60000000000000009Initial program 99.7%
Taylor expanded in y around 0 99.7%
Taylor expanded in y around 0 88.0%
*-commutative88.0%
Simplified88.0%
Taylor expanded in i around inf 62.2%
Final simplification58.6%
(FPCore (x y z t a b c i)
:precision binary64
(if (<= y -2e+105)
x
(if (<= y -7.6e-34)
(* y (/ (+ x (/ z y)) a))
(if (<= y 0.095) (/ (+ 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 <= -2e+105) {
tmp = x;
} else if (y <= -7.6e-34) {
tmp = y * ((x + (z / y)) / a);
} else if (y <= 0.095) {
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 <= (-2d+105)) then
tmp = x
else if (y <= (-7.6d-34)) then
tmp = y * ((x + (z / y)) / a)
else if (y <= 0.095d0) 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 <= -2e+105) {
tmp = x;
} else if (y <= -7.6e-34) {
tmp = y * ((x + (z / y)) / a);
} else if (y <= 0.095) {
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 <= -2e+105: tmp = x elif y <= -7.6e-34: tmp = y * ((x + (z / y)) / a) elif y <= 0.095: 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 <= -2e+105) tmp = x; elseif (y <= -7.6e-34) tmp = Float64(y * Float64(Float64(x + Float64(z / y)) / a)); elseif (y <= 0.095) 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 <= -2e+105) tmp = x; elseif (y <= -7.6e-34) tmp = y * ((x + (z / y)) / a); elseif (y <= 0.095) 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, -2e+105], x, If[LessEqual[y, -7.6e-34], N[(y * N[(N[(x + N[(z / y), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 0.095], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision], x]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2 \cdot 10^{+105}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq -7.6 \cdot 10^{-34}:\\
\;\;\;\;y \cdot \frac{x + \frac{z}{y}}{a}\\
\mathbf{elif}\;y \leq 0.095:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -1.9999999999999999e105 or 0.095000000000000001 < y Initial program 4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
fma-define4.2%
Simplified4.2%
Taylor expanded in y around inf 60.1%
if -1.9999999999999999e105 < y < -7.6000000000000002e-34Initial program 49.9%
Taylor expanded in y around 0 43.6%
Taylor expanded in y around -inf 32.8%
mul-1-neg32.8%
distribute-lft-out32.8%
Simplified32.8%
Taylor expanded in a around -inf 38.4%
associate-/l*35.3%
distribute-lft-in35.3%
mul-1-neg35.3%
Simplified35.3%
if -7.6000000000000002e-34 < y < 0.095000000000000001Initial program 99.7%
Taylor expanded in y around 0 99.7%
Taylor expanded in y around 0 88.0%
*-commutative88.0%
Simplified88.0%
Taylor expanded in i around inf 62.2%
Final simplification58.3%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -1.15e-9) x (if (<= y 0.44) (/ (+ 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 <= -1.15e-9) {
tmp = x;
} else if (y <= 0.44) {
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 <= (-1.15d-9)) then
tmp = x
else if (y <= 0.44d0) 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 <= -1.15e-9) {
tmp = x;
} else if (y <= 0.44) {
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 <= -1.15e-9: tmp = x elif y <= 0.44: 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 <= -1.15e-9) tmp = x; elseif (y <= 0.44) 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 <= -1.15e-9) tmp = x; elseif (y <= 0.44) 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, -1.15e-9], x, If[LessEqual[y, 0.44], N[(N[(t + N[(y * 230661.510616), $MachinePrecision]), $MachinePrecision] / i), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.15 \cdot 10^{-9}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 0.44:\\
\;\;\;\;\frac{t + y \cdot 230661.510616}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -1.15e-9 or 0.440000000000000002 < y Initial program 12.1%
fma-define12.1%
fma-define12.1%
fma-define12.1%
fma-define12.1%
fma-define12.1%
fma-define12.1%
fma-define12.1%
Simplified12.1%
Taylor expanded in y around inf 51.2%
if -1.15e-9 < y < 0.440000000000000002Initial program 99.7%
Taylor expanded in y around 0 99.7%
Taylor expanded in y around 0 87.4%
*-commutative87.4%
Simplified87.4%
Taylor expanded in i around inf 60.8%
Final simplification55.8%
(FPCore (x y z t a b c i) :precision binary64 (if (<= y -1.12e-7) x (if (<= y 0.195) (/ t i) x)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
double tmp;
if (y <= -1.12e-7) {
tmp = x;
} else if (y <= 0.195) {
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 <= (-1.12d-7)) then
tmp = x
else if (y <= 0.195d0) 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 <= -1.12e-7) {
tmp = x;
} else if (y <= 0.195) {
tmp = t / i;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b, c, i): tmp = 0 if y <= -1.12e-7: tmp = x elif y <= 0.195: tmp = t / i else: tmp = x return tmp
function code(x, y, z, t, a, b, c, i) tmp = 0.0 if (y <= -1.12e-7) tmp = x; elseif (y <= 0.195) 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 <= -1.12e-7) tmp = x; elseif (y <= 0.195) tmp = t / i; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[y, -1.12e-7], x, If[LessEqual[y, 0.195], N[(t / i), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.12 \cdot 10^{-7}:\\
\;\;\;\;x\\
\mathbf{elif}\;y \leq 0.195:\\
\;\;\;\;\frac{t}{i}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -1.12e-7 or 0.19500000000000001 < y Initial program 11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
fma-define11.5%
Simplified11.5%
Taylor expanded in y around inf 51.6%
if -1.12e-7 < y < 0.19500000000000001Initial program 99.6%
fma-define99.6%
fma-define99.6%
fma-define99.6%
fma-define99.6%
fma-define99.6%
fma-define99.6%
fma-define99.6%
Simplified99.6%
Taylor expanded in y around 0 56.0%
(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 54.5%
fma-define54.5%
fma-define54.5%
fma-define54.5%
fma-define54.5%
fma-define54.5%
fma-define54.5%
fma-define54.5%
Simplified54.5%
Taylor expanded in y around inf 28.0%
herbie shell --seed 2024136
(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)))