
(FPCore (x y z t a b)
:precision binary64
(+
x
(/
(*
y
(+ (* (+ (* (+ (* (+ (* z 3.13060547623) 11.1667541262) z) t) z) a) z) b))
(+
(* (+ (* (+ (* (+ z 15.234687407) z) 31.4690115749) z) 11.9400905721) z)
0.607771387771))))
double code(double x, double y, double z, double t, double a, double b) {
return x + ((y * ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771));
}
real(8) function code(x, y, z, t, a, b)
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
code = x + ((y * ((((((((z * 3.13060547623d0) + 11.1667541262d0) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407d0) * z) + 31.4690115749d0) * z) + 11.9400905721d0) * z) + 0.607771387771d0))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x + ((y * ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771));
}
def code(x, y, z, t, a, b): return x + ((y * ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771))
function code(x, y, z, t, a, b) return Float64(x + Float64(Float64(y * Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771))) end
function tmp = code(x, y, z, t, a, b) tmp = x + ((y * ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771)); end
code[x_, y_, z_, t_, a_, b_] := N[(x + N[(N[(y * N[(N[(N[(N[(N[(N[(N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision] * z), $MachinePrecision] + t), $MachinePrecision] * z), $MachinePrecision] + a), $MachinePrecision] * z), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(z + 15.234687407), $MachinePrecision] * z), $MachinePrecision] + 31.4690115749), $MachinePrecision] * z), $MachinePrecision] + 11.9400905721), $MachinePrecision] * z), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{y \cdot \left(\left(\left(\left(z \cdot 3.13060547623 + 11.1667541262\right) \cdot z + t\right) \cdot z + a\right) \cdot z + b\right)}{\left(\left(\left(z + 15.234687407\right) \cdot z + 31.4690115749\right) \cdot z + 11.9400905721\right) \cdot z + 0.607771387771}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b)
:precision binary64
(+
x
(/
(*
y
(+ (* (+ (* (+ (* (+ (* z 3.13060547623) 11.1667541262) z) t) z) a) z) b))
(+
(* (+ (* (+ (* (+ z 15.234687407) z) 31.4690115749) z) 11.9400905721) z)
0.607771387771))))
double code(double x, double y, double z, double t, double a, double b) {
return x + ((y * ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771));
}
real(8) function code(x, y, z, t, a, b)
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
code = x + ((y * ((((((((z * 3.13060547623d0) + 11.1667541262d0) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407d0) * z) + 31.4690115749d0) * z) + 11.9400905721d0) * z) + 0.607771387771d0))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x + ((y * ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771));
}
def code(x, y, z, t, a, b): return x + ((y * ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771))
function code(x, y, z, t, a, b) return Float64(x + Float64(Float64(y * Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771))) end
function tmp = code(x, y, z, t, a, b) tmp = x + ((y * ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)) / (((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771)); end
code[x_, y_, z_, t_, a_, b_] := N[(x + N[(N[(y * N[(N[(N[(N[(N[(N[(N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision] * z), $MachinePrecision] + t), $MachinePrecision] * z), $MachinePrecision] + a), $MachinePrecision] * z), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(z + 15.234687407), $MachinePrecision] * z), $MachinePrecision] + 31.4690115749), $MachinePrecision] * z), $MachinePrecision] + 11.9400905721), $MachinePrecision] * z), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{y \cdot \left(\left(\left(\left(z \cdot 3.13060547623 + 11.1667541262\right) \cdot z + t\right) \cdot z + a\right) \cdot z + b\right)}{\left(\left(\left(z + 15.234687407\right) \cdot z + 31.4690115749\right) \cdot z + 11.9400905721\right) \cdot z + 0.607771387771}
\end{array}
(FPCore (x y z t a b)
:precision binary64
(if (<=
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
(+
(*
z
(+ (* z (+ (* z (+ z 15.234687407)) 31.4690115749)) 11.9400905721))
0.607771387771))
INFINITY)
(fma
y
(/
(fma z (fma z (fma z (fma z 3.13060547623 11.1667541262) t) a) b)
(fma
z
(fma z (fma z (+ z 15.234687407) 31.4690115749) 11.9400905721)
0.607771387771))
x)
(fma
y
(+ 3.13060547623 (/ (- (/ (+ t 457.9610022158428) z) 36.52704169880642) z))
x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) <= ((double) INFINITY)) {
tmp = fma(y, (fma(z, fma(z, fma(z, fma(z, 3.13060547623, 11.1667541262), t), a), b) / fma(z, fma(z, fma(z, (z + 15.234687407), 31.4690115749), 11.9400905721), 0.607771387771)), x);
} else {
tmp = fma(y, (3.13060547623 + ((((t + 457.9610022158428) / z) - 36.52704169880642) / z)), x);
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) <= Inf) tmp = fma(y, Float64(fma(z, fma(z, fma(z, fma(z, 3.13060547623, 11.1667541262), t), a), b) / fma(z, fma(z, fma(z, Float64(z + 15.234687407), 31.4690115749), 11.9400905721), 0.607771387771)), x); else tmp = fma(y, Float64(3.13060547623 + Float64(Float64(Float64(Float64(t + 457.9610022158428) / z) - 36.52704169880642) / z)), x); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(N[(z * N[(N[(z * N[(z + 15.234687407), $MachinePrecision]), $MachinePrecision] + 31.4690115749), $MachinePrecision]), $MachinePrecision] + 11.9400905721), $MachinePrecision]), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision], Infinity], N[(y * N[(N[(z * N[(z * N[(z * N[(z * 3.13060547623 + 11.1667541262), $MachinePrecision] + t), $MachinePrecision] + a), $MachinePrecision] + b), $MachinePrecision] / N[(z * N[(z * N[(z * N[(z + 15.234687407), $MachinePrecision] + 31.4690115749), $MachinePrecision] + 11.9400905721), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(y * N[(3.13060547623 + N[(N[(N[(N[(t + 457.9610022158428), $MachinePrecision] / z), $MachinePrecision] - 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771} \leq \infty:\\
\;\;\;\;\mathsf{fma}\left(y, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, 3.13060547623, 11.1667541262\right), t\right), a\right), b\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, z + 15.234687407, 31.4690115749\right), 11.9400905721\right), 0.607771387771\right)}, x\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y, 3.13060547623 + \frac{\frac{t + 457.9610022158428}{z} - 36.52704169880642}{z}, x\right)\\
\end{array}
\end{array}
if (/.f64 (*.f64 y (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 z #s(literal 313060547623/100000000000 binary64)) #s(literal 55833770631/5000000000 binary64)) z) t) z) a) z) b)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 z #s(literal 15234687407/1000000000 binary64)) z) #s(literal 314690115749/10000000000 binary64)) z) #s(literal 119400905721/10000000000 binary64)) z) #s(literal 607771387771/1000000000000 binary64))) < +inf.0Initial program 93.8%
Simplified97.8%
if +inf.0 < (/.f64 (*.f64 y (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 z #s(literal 313060547623/100000000000 binary64)) #s(literal 55833770631/5000000000 binary64)) z) t) z) a) z) b)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 z #s(literal 15234687407/1000000000 binary64)) z) #s(literal 314690115749/10000000000 binary64)) z) #s(literal 119400905721/10000000000 binary64)) z) #s(literal 607771387771/1000000000000 binary64))) Initial program 0.0%
Simplified0.0%
Taylor expanded in z around -inf 99.0%
mul-1-neg99.0%
unsub-neg99.0%
mul-1-neg99.0%
unsub-neg99.0%
+-commutative99.0%
Simplified99.0%
Final simplification98.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1
(+
(*
z
(+ (* z (+ (* z (+ z 15.234687407)) 31.4690115749)) 11.9400905721))
0.607771387771)))
(if (<=
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
t_1)
INFINITY)
(fma
(fma z (fma z (fma z (fma z 3.13060547623 11.1667541262) t) a) b)
(/ y t_1)
x)
(fma
y
(+
3.13060547623
(/ (- (/ (+ t 457.9610022158428) z) 36.52704169880642) z))
x))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771;
double tmp;
if (((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / t_1) <= ((double) INFINITY)) {
tmp = fma(fma(z, fma(z, fma(z, fma(z, 3.13060547623, 11.1667541262), t), a), b), (y / t_1), x);
} else {
tmp = fma(y, (3.13060547623 + ((((t + 457.9610022158428) / z) - 36.52704169880642) / z)), x);
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771) tmp = 0.0 if (Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / t_1) <= Inf) tmp = fma(fma(z, fma(z, fma(z, fma(z, 3.13060547623, 11.1667541262), t), a), b), Float64(y / t_1), x); else tmp = fma(y, Float64(3.13060547623 + Float64(Float64(Float64(Float64(t + 457.9610022158428) / z) - 36.52704169880642) / z)), x); end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(z * N[(N[(z * N[(N[(z * N[(z + 15.234687407), $MachinePrecision]), $MachinePrecision] + 31.4690115749), $MachinePrecision]), $MachinePrecision] + 11.9400905721), $MachinePrecision]), $MachinePrecision] + 0.607771387771), $MachinePrecision]}, If[LessEqual[N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision], Infinity], N[(N[(z * N[(z * N[(z * N[(z * 3.13060547623 + 11.1667541262), $MachinePrecision] + t), $MachinePrecision] + a), $MachinePrecision] + b), $MachinePrecision] * N[(y / t$95$1), $MachinePrecision] + x), $MachinePrecision], N[(y * N[(3.13060547623 + N[(N[(N[(N[(t + 457.9610022158428), $MachinePrecision] / z), $MachinePrecision] - 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771\\
\mathbf{if}\;\frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{t\_1} \leq \infty:\\
\;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, \mathsf{fma}\left(z, 3.13060547623, 11.1667541262\right), t\right), a\right), b\right), \frac{y}{t\_1}, x\right)\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y, 3.13060547623 + \frac{\frac{t + 457.9610022158428}{z} - 36.52704169880642}{z}, x\right)\\
\end{array}
\end{array}
if (/.f64 (*.f64 y (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 z #s(literal 313060547623/100000000000 binary64)) #s(literal 55833770631/5000000000 binary64)) z) t) z) a) z) b)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 z #s(literal 15234687407/1000000000 binary64)) z) #s(literal 314690115749/10000000000 binary64)) z) #s(literal 119400905721/10000000000 binary64)) z) #s(literal 607771387771/1000000000000 binary64))) < +inf.0Initial program 93.8%
Simplified97.6%
Taylor expanded in y around 0 97.6%
if +inf.0 < (/.f64 (*.f64 y (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 z #s(literal 313060547623/100000000000 binary64)) #s(literal 55833770631/5000000000 binary64)) z) t) z) a) z) b)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 z #s(literal 15234687407/1000000000 binary64)) z) #s(literal 314690115749/10000000000 binary64)) z) #s(literal 119400905721/10000000000 binary64)) z) #s(literal 607771387771/1000000000000 binary64))) Initial program 0.0%
Simplified0.0%
Taylor expanded in z around -inf 99.0%
mul-1-neg99.0%
unsub-neg99.0%
mul-1-neg99.0%
unsub-neg99.0%
+-commutative99.0%
Simplified99.0%
Final simplification98.1%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -4.8e+33) (not (<= z 6.1e+29)))
(fma
y
(+ 3.13060547623 (/ (- (/ (+ t 457.9610022158428) z) 36.52704169880642) z))
x)
(+
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
(+
(* z (+ (* z (+ (* z (+ z 15.234687407)) 31.4690115749)) 11.9400905721))
0.607771387771))
x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -4.8e+33) || !(z <= 6.1e+29)) {
tmp = fma(y, (3.13060547623 + ((((t + 457.9610022158428) / z) - 36.52704169880642) / z)), x);
} else {
tmp = ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x;
}
return tmp;
}
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -4.8e+33) || !(z <= 6.1e+29)) tmp = fma(y, Float64(3.13060547623 + Float64(Float64(Float64(Float64(t + 457.9610022158428) / z) - 36.52704169880642) / z)), x); else tmp = Float64(Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x); end return tmp end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -4.8e+33], N[Not[LessEqual[z, 6.1e+29]], $MachinePrecision]], N[(y * N[(3.13060547623 + N[(N[(N[(N[(t + 457.9610022158428), $MachinePrecision] / z), $MachinePrecision] - 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(N[(z * N[(N[(z * N[(z + 15.234687407), $MachinePrecision]), $MachinePrecision] + 31.4690115749), $MachinePrecision]), $MachinePrecision] + 11.9400905721), $MachinePrecision]), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.8 \cdot 10^{+33} \lor \neg \left(z \leq 6.1 \cdot 10^{+29}\right):\\
\;\;\;\;\mathsf{fma}\left(y, 3.13060547623 + \frac{\frac{t + 457.9610022158428}{z} - 36.52704169880642}{z}, x\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771} + x\\
\end{array}
\end{array}
if z < -4.8e33 or 6.0999999999999998e29 < z Initial program 7.4%
Simplified11.4%
Taylor expanded in z around -inf 98.1%
mul-1-neg98.1%
unsub-neg98.1%
mul-1-neg98.1%
unsub-neg98.1%
+-commutative98.1%
Simplified98.1%
if -4.8e33 < z < 6.0999999999999998e29Initial program 98.3%
Final simplification98.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
(+
(*
z
(+ (* z (+ (* z (+ z 15.234687407)) 31.4690115749)) 11.9400905721))
0.607771387771))))
(if (<= t_1 INFINITY) (+ t_1 x) (+ x (* y 3.13060547623)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771);
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1 + x;
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771);
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1 + x;
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771) tmp = 0 if t_1 <= math.inf: tmp = t_1 + x else: tmp = x + (y * 3.13060547623) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) tmp = 0.0 if (t_1 <= Inf) tmp = Float64(t_1 + x); else tmp = Float64(x + Float64(y * 3.13060547623)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771); tmp = 0.0; if (t_1 <= Inf) tmp = t_1 + x; else tmp = x + (y * 3.13060547623); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(N[(z * N[(N[(z * N[(z + 15.234687407), $MachinePrecision]), $MachinePrecision] + 31.4690115749), $MachinePrecision]), $MachinePrecision] + 11.9400905721), $MachinePrecision]), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], N[(t$95$1 + x), $MachinePrecision], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771}\\
\mathbf{if}\;t\_1 \leq \infty:\\
\;\;\;\;t\_1 + x\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\end{array}
\end{array}
if (/.f64 (*.f64 y (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 z #s(literal 313060547623/100000000000 binary64)) #s(literal 55833770631/5000000000 binary64)) z) t) z) a) z) b)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 z #s(literal 15234687407/1000000000 binary64)) z) #s(literal 314690115749/10000000000 binary64)) z) #s(literal 119400905721/10000000000 binary64)) z) #s(literal 607771387771/1000000000000 binary64))) < +inf.0Initial program 93.8%
if +inf.0 < (/.f64 (*.f64 y (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 z #s(literal 313060547623/100000000000 binary64)) #s(literal 55833770631/5000000000 binary64)) z) t) z) a) z) b)) (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 (*.f64 (+.f64 z #s(literal 15234687407/1000000000 binary64)) z) #s(literal 314690115749/10000000000 binary64)) z) #s(literal 119400905721/10000000000 binary64)) z) #s(literal 607771387771/1000000000000 binary64))) Initial program 0.0%
Simplified0.0%
Taylor expanded in z around inf 96.8%
+-commutative96.8%
*-commutative96.8%
Simplified96.8%
Final simplification94.9%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ x (* y 3.13060547623))))
(if (<= z -1.5e+54)
t_1
(if (<= z 1.2e-10)
(+
x
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
(+ 0.607771387771 (* z (+ 11.9400905721 (* z 31.4690115749))))))
(if (<= z 2.6e+30)
(+
x
(/
(+ (* y b) (* z (+ (* y a) (* t (* y z)))))
(+
(*
z
(+
(* z (+ (* z (+ z 15.234687407)) 31.4690115749))
11.9400905721))
0.607771387771)))
t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x + (y * 3.13060547623);
double tmp;
if (z <= -1.5e+54) {
tmp = t_1;
} else if (z <= 1.2e-10) {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749)))));
} else if (z <= 2.6e+30) {
tmp = x + (((y * b) + (z * ((y * a) + (t * (y * z))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: t_1
real(8) :: tmp
t_1 = x + (y * 3.13060547623d0)
if (z <= (-1.5d+54)) then
tmp = t_1
else if (z <= 1.2d-10) then
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623d0) + 11.1667541262d0)) + t)) + a)) + b)) / (0.607771387771d0 + (z * (11.9400905721d0 + (z * 31.4690115749d0)))))
else if (z <= 2.6d+30) then
tmp = x + (((y * b) + (z * ((y * a) + (t * (y * z))))) / ((z * ((z * ((z * (z + 15.234687407d0)) + 31.4690115749d0)) + 11.9400905721d0)) + 0.607771387771d0))
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 t_1 = x + (y * 3.13060547623);
double tmp;
if (z <= -1.5e+54) {
tmp = t_1;
} else if (z <= 1.2e-10) {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749)))));
} else if (z <= 2.6e+30) {
tmp = x + (((y * b) + (z * ((y * a) + (t * (y * z))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x + (y * 3.13060547623) tmp = 0 if z <= -1.5e+54: tmp = t_1 elif z <= 1.2e-10: tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749))))) elif z <= 2.6e+30: tmp = x + (((y * b) + (z * ((y * a) + (t * (y * z))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x + Float64(y * 3.13060547623)) tmp = 0.0 if (z <= -1.5e+54) tmp = t_1; elseif (z <= 1.2e-10) tmp = Float64(x + Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / Float64(0.607771387771 + Float64(z * Float64(11.9400905721 + Float64(z * 31.4690115749)))))); elseif (z <= 2.6e+30) tmp = Float64(x + Float64(Float64(Float64(y * b) + Float64(z * Float64(Float64(y * a) + Float64(t * Float64(y * z))))) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x + (y * 3.13060547623); tmp = 0.0; if (z <= -1.5e+54) tmp = t_1; elseif (z <= 1.2e-10) tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749))))); elseif (z <= 2.6e+30) tmp = x + (((y * b) + (z * ((y * a) + (t * (y * z))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.5e+54], t$95$1, If[LessEqual[z, 1.2e-10], N[(x + N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(0.607771387771 + N[(z * N[(11.9400905721 + N[(z * 31.4690115749), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.6e+30], N[(x + N[(N[(N[(y * b), $MachinePrecision] + N[(z * N[(N[(y * a), $MachinePrecision] + N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(N[(z * N[(N[(z * N[(z + 15.234687407), $MachinePrecision]), $MachinePrecision] + 31.4690115749), $MachinePrecision]), $MachinePrecision] + 11.9400905721), $MachinePrecision]), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + y \cdot 3.13060547623\\
\mathbf{if}\;z \leq -1.5 \cdot 10^{+54}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 1.2 \cdot 10^{-10}:\\
\;\;\;\;x + \frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{0.607771387771 + z \cdot \left(11.9400905721 + z \cdot 31.4690115749\right)}\\
\mathbf{elif}\;z \leq 2.6 \cdot 10^{+30}:\\
\;\;\;\;x + \frac{y \cdot b + z \cdot \left(y \cdot a + t \cdot \left(y \cdot z\right)\right)}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.4999999999999999e54 or 2.59999999999999988e30 < z Initial program 4.9%
Simplified8.2%
Taylor expanded in z around inf 95.1%
+-commutative95.1%
*-commutative95.1%
Simplified95.1%
if -1.4999999999999999e54 < z < 1.2e-10Initial program 97.7%
Taylor expanded in z around 0 96.3%
*-commutative96.3%
Simplified96.3%
if 1.2e-10 < z < 2.59999999999999988e30Initial program 91.7%
Taylor expanded in z around 0 90.1%
Final simplification95.5%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ x (* y 3.13060547623))) (t_2 (* t (* y z))))
(if (<= z -0.052)
t_1
(if (<= z 2.5e-5)
(+
x
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
(+ 0.607771387771 (* z 11.9400905721))))
(if (<= z 2.9e+23)
(+
x
(/
(+ (* y b) (* z t_2))
(+
(*
z
(+
(* z (+ (* z (+ z 15.234687407)) 31.4690115749))
11.9400905721))
0.607771387771)))
(if (<= z 9.5e+29)
(+
x
(/
(+ (* y b) (* z (+ (* y a) t_2)))
(+ 0.607771387771 (* z (+ 11.9400905721 (* z 31.4690115749))))))
t_1))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x + (y * 3.13060547623);
double t_2 = t * (y * z);
double tmp;
if (z <= -0.052) {
tmp = t_1;
} else if (z <= 2.5e-5) {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721)));
} else if (z <= 2.9e+23) {
tmp = x + (((y * b) + (z * t_2)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
} else if (z <= 9.5e+29) {
tmp = x + (((y * b) + (z * ((y * a) + t_2))) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749)))));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x + (y * 3.13060547623d0)
t_2 = t * (y * z)
if (z <= (-0.052d0)) then
tmp = t_1
else if (z <= 2.5d-5) then
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623d0) + 11.1667541262d0)) + t)) + a)) + b)) / (0.607771387771d0 + (z * 11.9400905721d0)))
else if (z <= 2.9d+23) then
tmp = x + (((y * b) + (z * t_2)) / ((z * ((z * ((z * (z + 15.234687407d0)) + 31.4690115749d0)) + 11.9400905721d0)) + 0.607771387771d0))
else if (z <= 9.5d+29) then
tmp = x + (((y * b) + (z * ((y * a) + t_2))) / (0.607771387771d0 + (z * (11.9400905721d0 + (z * 31.4690115749d0)))))
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 t_1 = x + (y * 3.13060547623);
double t_2 = t * (y * z);
double tmp;
if (z <= -0.052) {
tmp = t_1;
} else if (z <= 2.5e-5) {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721)));
} else if (z <= 2.9e+23) {
tmp = x + (((y * b) + (z * t_2)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
} else if (z <= 9.5e+29) {
tmp = x + (((y * b) + (z * ((y * a) + t_2))) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749)))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x + (y * 3.13060547623) t_2 = t * (y * z) tmp = 0 if z <= -0.052: tmp = t_1 elif z <= 2.5e-5: tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721))) elif z <= 2.9e+23: tmp = x + (((y * b) + (z * t_2)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) elif z <= 9.5e+29: tmp = x + (((y * b) + (z * ((y * a) + t_2))) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749))))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x + Float64(y * 3.13060547623)) t_2 = Float64(t * Float64(y * z)) tmp = 0.0 if (z <= -0.052) tmp = t_1; elseif (z <= 2.5e-5) tmp = Float64(x + Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / Float64(0.607771387771 + Float64(z * 11.9400905721)))); elseif (z <= 2.9e+23) tmp = Float64(x + Float64(Float64(Float64(y * b) + Float64(z * t_2)) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771))); elseif (z <= 9.5e+29) tmp = Float64(x + Float64(Float64(Float64(y * b) + Float64(z * Float64(Float64(y * a) + t_2))) / Float64(0.607771387771 + Float64(z * Float64(11.9400905721 + Float64(z * 31.4690115749)))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x + (y * 3.13060547623); t_2 = t * (y * z); tmp = 0.0; if (z <= -0.052) tmp = t_1; elseif (z <= 2.5e-5) tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721))); elseif (z <= 2.9e+23) tmp = x + (((y * b) + (z * t_2)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)); elseif (z <= 9.5e+29) tmp = x + (((y * b) + (z * ((y * a) + t_2))) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749))))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -0.052], t$95$1, If[LessEqual[z, 2.5e-5], N[(x + N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(0.607771387771 + N[(z * 11.9400905721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.9e+23], N[(x + N[(N[(N[(y * b), $MachinePrecision] + N[(z * t$95$2), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(N[(z * N[(N[(z * N[(z + 15.234687407), $MachinePrecision]), $MachinePrecision] + 31.4690115749), $MachinePrecision]), $MachinePrecision] + 11.9400905721), $MachinePrecision]), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9.5e+29], N[(x + N[(N[(N[(y * b), $MachinePrecision] + N[(z * N[(N[(y * a), $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(0.607771387771 + N[(z * N[(11.9400905721 + N[(z * 31.4690115749), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + y \cdot 3.13060547623\\
t_2 := t \cdot \left(y \cdot z\right)\\
\mathbf{if}\;z \leq -0.052:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 2.5 \cdot 10^{-5}:\\
\;\;\;\;x + \frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{0.607771387771 + z \cdot 11.9400905721}\\
\mathbf{elif}\;z \leq 2.9 \cdot 10^{+23}:\\
\;\;\;\;x + \frac{y \cdot b + z \cdot t\_2}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771}\\
\mathbf{elif}\;z \leq 9.5 \cdot 10^{+29}:\\
\;\;\;\;x + \frac{y \cdot b + z \cdot \left(y \cdot a + t\_2\right)}{0.607771387771 + z \cdot \left(11.9400905721 + z \cdot 31.4690115749\right)}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -0.0519999999999999976 or 9.5000000000000003e29 < z Initial program 9.7%
Simplified14.4%
Taylor expanded in z around inf 90.7%
+-commutative90.7%
*-commutative90.7%
Simplified90.7%
if -0.0519999999999999976 < z < 2.50000000000000012e-5Initial program 99.7%
Taylor expanded in z around 0 99.5%
*-commutative73.9%
Simplified99.5%
if 2.50000000000000012e-5 < z < 2.90000000000000013e23Initial program 85.0%
Taylor expanded in z around 0 85.6%
Taylor expanded in a around 0 85.6%
*-commutative85.6%
Simplified85.6%
if 2.90000000000000013e23 < z < 9.5000000000000003e29Initial program 99.6%
Taylor expanded in z around 0 53.5%
*-commutative53.5%
Simplified53.5%
Taylor expanded in z around 0 53.5%
Final simplification94.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ x (* y 3.13060547623))))
(if (<= z -0.052)
t_1
(if (<= z 7.4e-5)
(+
x
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
(+ 0.607771387771 (* z 11.9400905721))))
(if (<= z 9.5e+23)
(+
x
(/
(+ (* y b) (* z (* t (* y z))))
(+
(*
z
(+
(* z (+ (* z (+ z 15.234687407)) 31.4690115749))
11.9400905721))
0.607771387771)))
(if (<= z 2.6e+30)
(+
x
(/
(-
(*
y
(/
(+
(+
t
(/
(-
(- a 351.40671485145015)
(+ (* t 15.234687407) -2591.7556199921937))
z))
-170.12200846348443)
z))
(* y -11.1667541262))
z))
t_1))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x + (y * 3.13060547623);
double tmp;
if (z <= -0.052) {
tmp = t_1;
} else if (z <= 7.4e-5) {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721)));
} else if (z <= 9.5e+23) {
tmp = x + (((y * b) + (z * (t * (y * z)))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
} else if (z <= 2.6e+30) {
tmp = x + (((y * (((t + (((a - 351.40671485145015) - ((t * 15.234687407) + -2591.7556199921937)) / z)) + -170.12200846348443) / z)) - (y * -11.1667541262)) / z);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: t_1
real(8) :: tmp
t_1 = x + (y * 3.13060547623d0)
if (z <= (-0.052d0)) then
tmp = t_1
else if (z <= 7.4d-5) then
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623d0) + 11.1667541262d0)) + t)) + a)) + b)) / (0.607771387771d0 + (z * 11.9400905721d0)))
else if (z <= 9.5d+23) then
tmp = x + (((y * b) + (z * (t * (y * z)))) / ((z * ((z * ((z * (z + 15.234687407d0)) + 31.4690115749d0)) + 11.9400905721d0)) + 0.607771387771d0))
else if (z <= 2.6d+30) then
tmp = x + (((y * (((t + (((a - 351.40671485145015d0) - ((t * 15.234687407d0) + (-2591.7556199921937d0))) / z)) + (-170.12200846348443d0)) / z)) - (y * (-11.1667541262d0))) / z)
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 t_1 = x + (y * 3.13060547623);
double tmp;
if (z <= -0.052) {
tmp = t_1;
} else if (z <= 7.4e-5) {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721)));
} else if (z <= 9.5e+23) {
tmp = x + (((y * b) + (z * (t * (y * z)))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
} else if (z <= 2.6e+30) {
tmp = x + (((y * (((t + (((a - 351.40671485145015) - ((t * 15.234687407) + -2591.7556199921937)) / z)) + -170.12200846348443) / z)) - (y * -11.1667541262)) / z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x + (y * 3.13060547623) tmp = 0 if z <= -0.052: tmp = t_1 elif z <= 7.4e-5: tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721))) elif z <= 9.5e+23: tmp = x + (((y * b) + (z * (t * (y * z)))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) elif z <= 2.6e+30: tmp = x + (((y * (((t + (((a - 351.40671485145015) - ((t * 15.234687407) + -2591.7556199921937)) / z)) + -170.12200846348443) / z)) - (y * -11.1667541262)) / z) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x + Float64(y * 3.13060547623)) tmp = 0.0 if (z <= -0.052) tmp = t_1; elseif (z <= 7.4e-5) tmp = Float64(x + Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / Float64(0.607771387771 + Float64(z * 11.9400905721)))); elseif (z <= 9.5e+23) tmp = Float64(x + Float64(Float64(Float64(y * b) + Float64(z * Float64(t * Float64(y * z)))) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771))); elseif (z <= 2.6e+30) tmp = Float64(x + Float64(Float64(Float64(y * Float64(Float64(Float64(t + Float64(Float64(Float64(a - 351.40671485145015) - Float64(Float64(t * 15.234687407) + -2591.7556199921937)) / z)) + -170.12200846348443) / z)) - Float64(y * -11.1667541262)) / z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x + (y * 3.13060547623); tmp = 0.0; if (z <= -0.052) tmp = t_1; elseif (z <= 7.4e-5) tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721))); elseif (z <= 9.5e+23) tmp = x + (((y * b) + (z * (t * (y * z)))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)); elseif (z <= 2.6e+30) tmp = x + (((y * (((t + (((a - 351.40671485145015) - ((t * 15.234687407) + -2591.7556199921937)) / z)) + -170.12200846348443) / z)) - (y * -11.1667541262)) / z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -0.052], t$95$1, If[LessEqual[z, 7.4e-5], N[(x + N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(0.607771387771 + N[(z * 11.9400905721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9.5e+23], N[(x + N[(N[(N[(y * b), $MachinePrecision] + N[(z * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(N[(z * N[(N[(z * N[(z + 15.234687407), $MachinePrecision]), $MachinePrecision] + 31.4690115749), $MachinePrecision]), $MachinePrecision] + 11.9400905721), $MachinePrecision]), $MachinePrecision] + 0.607771387771), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.6e+30], N[(x + N[(N[(N[(y * N[(N[(N[(t + N[(N[(N[(a - 351.40671485145015), $MachinePrecision] - N[(N[(t * 15.234687407), $MachinePrecision] + -2591.7556199921937), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] + -170.12200846348443), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] - N[(y * -11.1667541262), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + y \cdot 3.13060547623\\
\mathbf{if}\;z \leq -0.052:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 7.4 \cdot 10^{-5}:\\
\;\;\;\;x + \frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{0.607771387771 + z \cdot 11.9400905721}\\
\mathbf{elif}\;z \leq 9.5 \cdot 10^{+23}:\\
\;\;\;\;x + \frac{y \cdot b + z \cdot \left(t \cdot \left(y \cdot z\right)\right)}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771}\\
\mathbf{elif}\;z \leq 2.6 \cdot 10^{+30}:\\
\;\;\;\;x + \frac{y \cdot \frac{\left(t + \frac{\left(a - 351.40671485145015\right) - \left(t \cdot 15.234687407 + -2591.7556199921937\right)}{z}\right) + -170.12200846348443}{z} - y \cdot -11.1667541262}{z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -0.0519999999999999976 or 2.59999999999999988e30 < z Initial program 9.7%
Simplified14.4%
Taylor expanded in z around inf 90.7%
+-commutative90.7%
*-commutative90.7%
Simplified90.7%
if -0.0519999999999999976 < z < 7.39999999999999962e-5Initial program 99.7%
Taylor expanded in z around 0 99.5%
*-commutative73.9%
Simplified99.5%
if 7.39999999999999962e-5 < z < 9.50000000000000038e23Initial program 85.0%
Taylor expanded in z around 0 85.6%
Taylor expanded in a around 0 85.6%
*-commutative85.6%
Simplified85.6%
if 9.50000000000000038e23 < z < 2.59999999999999988e30Initial program 99.6%
Taylor expanded in z around 0 93.1%
Taylor expanded in z around -inf 50.2%
Taylor expanded in y around 0 75.2%
associate-/l*75.2%
Simplified75.2%
Final simplification94.6%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -1.55e+54) (not (<= z 1.85e+30)))
(+ x (* y 3.13060547623))
(+
x
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
(+ 0.607771387771 (* z (+ 11.9400905721 (* z 31.4690115749))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1.55e+54) || !(z <= 1.85e+30)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749)))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((z <= (-1.55d+54)) .or. (.not. (z <= 1.85d+30))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623d0) + 11.1667541262d0)) + t)) + a)) + b)) / (0.607771387771d0 + (z * (11.9400905721d0 + (z * 31.4690115749d0)))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1.55e+54) || !(z <= 1.85e+30)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749)))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -1.55e+54) or not (z <= 1.85e+30): tmp = x + (y * 3.13060547623) else: tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -1.55e+54) || !(z <= 1.85e+30)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(x + Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / Float64(0.607771387771 + Float64(z * Float64(11.9400905721 + Float64(z * 31.4690115749)))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -1.55e+54) || ~((z <= 1.85e+30))) tmp = x + (y * 3.13060547623); else tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * (11.9400905721 + (z * 31.4690115749))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -1.55e+54], N[Not[LessEqual[z, 1.85e+30]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(0.607771387771 + N[(z * N[(11.9400905721 + N[(z * 31.4690115749), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.55 \cdot 10^{+54} \lor \neg \left(z \leq 1.85 \cdot 10^{+30}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{0.607771387771 + z \cdot \left(11.9400905721 + z \cdot 31.4690115749\right)}\\
\end{array}
\end{array}
if z < -1.55e54 or 1.85000000000000008e30 < z Initial program 4.9%
Simplified8.2%
Taylor expanded in z around inf 95.1%
+-commutative95.1%
*-commutative95.1%
Simplified95.1%
if -1.55e54 < z < 1.85000000000000008e30Initial program 97.1%
Taylor expanded in z around 0 92.0%
*-commutative92.0%
Simplified92.0%
Final simplification93.3%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -0.052) (not (<= z 1e+30)))
(+ x (* y 3.13060547623))
(+
x
(/
(*
y
(+
(* z (+ (* z (+ (* z (+ (* z 3.13060547623) 11.1667541262)) t)) a))
b))
(+ 0.607771387771 (* z 11.9400905721))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -0.052) || !(z <= 1e+30)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((z <= (-0.052d0)) .or. (.not. (z <= 1d+30))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623d0) + 11.1667541262d0)) + t)) + a)) + b)) / (0.607771387771d0 + (z * 11.9400905721d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -0.052) || !(z <= 1e+30)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -0.052) or not (z <= 1e+30): tmp = x + (y * 3.13060547623) else: tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -0.052) || !(z <= 1e+30)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(x + Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / Float64(0.607771387771 + Float64(z * 11.9400905721)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -0.052) || ~((z <= 1e+30))) tmp = x + (y * 3.13060547623); else tmp = x + ((y * ((z * ((z * ((z * ((z * 3.13060547623) + 11.1667541262)) + t)) + a)) + b)) / (0.607771387771 + (z * 11.9400905721))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -0.052], N[Not[LessEqual[z, 1e+30]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y * N[(N[(z * N[(N[(z * N[(N[(z * N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision]), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] + a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision] / N[(0.607771387771 + N[(z * 11.9400905721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.052 \lor \neg \left(z \leq 10^{+30}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y \cdot \left(z \cdot \left(z \cdot \left(z \cdot \left(z \cdot 3.13060547623 + 11.1667541262\right) + t\right) + a\right) + b\right)}{0.607771387771 + z \cdot 11.9400905721}\\
\end{array}
\end{array}
if z < -0.0519999999999999976 or 1e30 < z Initial program 9.7%
Simplified14.4%
Taylor expanded in z around inf 90.7%
+-commutative90.7%
*-commutative90.7%
Simplified90.7%
if -0.0519999999999999976 < z < 1e30Initial program 99.0%
Taylor expanded in z around 0 94.3%
*-commutative69.7%
Simplified94.3%
Final simplification92.6%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -0.052) (not (<= z 1e+30)))
(+ x (* y 3.13060547623))
(+
x
(/
(* y (+ b (* z (+ a (* z (+ t (* z 11.1667541262)))))))
(+ 0.607771387771 (* z 11.9400905721))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -0.052) || !(z <= 1e+30)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262))))))) / (0.607771387771 + (z * 11.9400905721)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((z <= (-0.052d0)) .or. (.not. (z <= 1d+30))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262d0))))))) / (0.607771387771d0 + (z * 11.9400905721d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -0.052) || !(z <= 1e+30)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262))))))) / (0.607771387771 + (z * 11.9400905721)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -0.052) or not (z <= 1e+30): tmp = x + (y * 3.13060547623) else: tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262))))))) / (0.607771387771 + (z * 11.9400905721))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -0.052) || !(z <= 1e+30)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(x + Float64(Float64(y * Float64(b + Float64(z * Float64(a + Float64(z * Float64(t + Float64(z * 11.1667541262))))))) / Float64(0.607771387771 + Float64(z * 11.9400905721)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -0.052) || ~((z <= 1e+30))) tmp = x + (y * 3.13060547623); else tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262))))))) / (0.607771387771 + (z * 11.9400905721))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -0.052], N[Not[LessEqual[z, 1e+30]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y * N[(b + N[(z * N[(a + N[(z * N[(t + N[(z * 11.1667541262), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(0.607771387771 + N[(z * 11.9400905721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.052 \lor \neg \left(z \leq 10^{+30}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + \frac{y \cdot \left(b + z \cdot \left(a + z \cdot \left(t + z \cdot 11.1667541262\right)\right)\right)}{0.607771387771 + z \cdot 11.9400905721}\\
\end{array}
\end{array}
if z < -0.0519999999999999976 or 1e30 < z Initial program 9.7%
Simplified14.4%
Taylor expanded in z around inf 90.7%
+-commutative90.7%
*-commutative90.7%
Simplified90.7%
if -0.0519999999999999976 < z < 1e30Initial program 99.0%
Taylor expanded in z around 0 94.3%
*-commutative69.7%
Simplified94.3%
Taylor expanded in z around 0 94.1%
*-commutative94.1%
Simplified94.1%
Final simplification92.5%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -6.2e+22)
(+ x (* y 3.13060547623))
(if (<= z 0.000108)
(-
x
(*
y
(-
(* z (- (* b 32.324150453290734) (* a 1.6453555072203998)))
(* b 1.6453555072203998))))
(+ x (* y (+ 3.13060547623 (* 36.52704169880642 (/ -1.0 z))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -6.2e+22) {
tmp = x + (y * 3.13060547623);
} else if (z <= 0.000108) {
tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998)));
} else {
tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-6.2d+22)) then
tmp = x + (y * 3.13060547623d0)
else if (z <= 0.000108d0) then
tmp = x - (y * ((z * ((b * 32.324150453290734d0) - (a * 1.6453555072203998d0))) - (b * 1.6453555072203998d0)))
else
tmp = x + (y * (3.13060547623d0 + (36.52704169880642d0 * ((-1.0d0) / z))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -6.2e+22) {
tmp = x + (y * 3.13060547623);
} else if (z <= 0.000108) {
tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998)));
} else {
tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -6.2e+22: tmp = x + (y * 3.13060547623) elif z <= 0.000108: tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998))) else: tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -6.2e+22) tmp = Float64(x + Float64(y * 3.13060547623)); elseif (z <= 0.000108) tmp = Float64(x - Float64(y * Float64(Float64(z * Float64(Float64(b * 32.324150453290734) - Float64(a * 1.6453555072203998))) - Float64(b * 1.6453555072203998)))); else tmp = Float64(x + Float64(y * Float64(3.13060547623 + Float64(36.52704169880642 * Float64(-1.0 / z))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -6.2e+22) tmp = x + (y * 3.13060547623); elseif (z <= 0.000108) tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998))); else tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -6.2e+22], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 0.000108], N[(x - N[(y * N[(N[(z * N[(N[(b * 32.324150453290734), $MachinePrecision] - N[(a * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(b * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(3.13060547623 + N[(36.52704169880642 * N[(-1.0 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.2 \cdot 10^{+22}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{elif}\;z \leq 0.000108:\\
\;\;\;\;x - y \cdot \left(z \cdot \left(b \cdot 32.324150453290734 - a \cdot 1.6453555072203998\right) - b \cdot 1.6453555072203998\right)\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \left(3.13060547623 + 36.52704169880642 \cdot \frac{-1}{z}\right)\\
\end{array}
\end{array}
if z < -6.2000000000000004e22Initial program 5.7%
Simplified9.0%
Taylor expanded in z around inf 89.0%
+-commutative89.0%
*-commutative89.0%
Simplified89.0%
if -6.2000000000000004e22 < z < 1.08e-4Initial program 99.0%
Taylor expanded in z around 0 80.1%
Taylor expanded in y around 0 86.7%
if 1.08e-4 < z Initial program 22.0%
Taylor expanded in z around -inf 86.0%
+-commutative86.0%
mul-1-neg86.0%
unsub-neg86.0%
*-commutative86.0%
distribute-rgt-out--86.0%
metadata-eval86.0%
Simplified86.0%
Taylor expanded in y around 0 86.0%
Final simplification87.0%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -1.1e+22) (not (<= z 5.9e+29)))
(+ x (* y 3.13060547623))
(+
x
(+ (* (* y b) 1.6453555072203998) (* z (* a (* y 1.6453555072203998)))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1.1e+22) || !(z <= 5.9e+29)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + (((y * b) * 1.6453555072203998) + (z * (a * (y * 1.6453555072203998))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((z <= (-1.1d+22)) .or. (.not. (z <= 5.9d+29))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + (((y * b) * 1.6453555072203998d0) + (z * (a * (y * 1.6453555072203998d0))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1.1e+22) || !(z <= 5.9e+29)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + (((y * b) * 1.6453555072203998) + (z * (a * (y * 1.6453555072203998))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -1.1e+22) or not (z <= 5.9e+29): tmp = x + (y * 3.13060547623) else: tmp = x + (((y * b) * 1.6453555072203998) + (z * (a * (y * 1.6453555072203998)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -1.1e+22) || !(z <= 5.9e+29)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(x + Float64(Float64(Float64(y * b) * 1.6453555072203998) + Float64(z * Float64(a * Float64(y * 1.6453555072203998))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -1.1e+22) || ~((z <= 5.9e+29))) tmp = x + (y * 3.13060547623); else tmp = x + (((y * b) * 1.6453555072203998) + (z * (a * (y * 1.6453555072203998)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -1.1e+22], N[Not[LessEqual[z, 5.9e+29]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(N[(y * b), $MachinePrecision] * 1.6453555072203998), $MachinePrecision] + N[(z * N[(a * N[(y * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.1 \cdot 10^{+22} \lor \neg \left(z \leq 5.9 \cdot 10^{+29}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + \left(\left(y \cdot b\right) \cdot 1.6453555072203998 + z \cdot \left(a \cdot \left(y \cdot 1.6453555072203998\right)\right)\right)\\
\end{array}
\end{array}
if z < -1.1e22 or 5.8999999999999999e29 < z Initial program 8.2%
Simplified12.2%
Taylor expanded in z around inf 92.1%
+-commutative92.1%
*-commutative92.1%
Simplified92.1%
if -1.1e22 < z < 5.8999999999999999e29Initial program 98.3%
Taylor expanded in z around 0 76.6%
Taylor expanded in a around inf 78.4%
associate-*r*78.4%
*-commutative78.4%
associate-*l*78.4%
*-commutative78.4%
Simplified78.4%
Final simplification84.6%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -4.8e+18)
(+ x (* y 3.13060547623))
(if (<= z 1.22e-10)
(+ x (* (* y b) 1.6453555072203998))
(+ x (* y (+ 3.13060547623 (* 36.52704169880642 (/ -1.0 z))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -4.8e+18) {
tmp = x + (y * 3.13060547623);
} else if (z <= 1.22e-10) {
tmp = x + ((y * b) * 1.6453555072203998);
} else {
tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-4.8d+18)) then
tmp = x + (y * 3.13060547623d0)
else if (z <= 1.22d-10) then
tmp = x + ((y * b) * 1.6453555072203998d0)
else
tmp = x + (y * (3.13060547623d0 + (36.52704169880642d0 * ((-1.0d0) / z))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -4.8e+18) {
tmp = x + (y * 3.13060547623);
} else if (z <= 1.22e-10) {
tmp = x + ((y * b) * 1.6453555072203998);
} else {
tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -4.8e+18: tmp = x + (y * 3.13060547623) elif z <= 1.22e-10: tmp = x + ((y * b) * 1.6453555072203998) else: tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -4.8e+18) tmp = Float64(x + Float64(y * 3.13060547623)); elseif (z <= 1.22e-10) tmp = Float64(x + Float64(Float64(y * b) * 1.6453555072203998)); else tmp = Float64(x + Float64(y * Float64(3.13060547623 + Float64(36.52704169880642 * Float64(-1.0 / z))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -4.8e+18) tmp = x + (y * 3.13060547623); elseif (z <= 1.22e-10) tmp = x + ((y * b) * 1.6453555072203998); else tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -4.8e+18], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.22e-10], N[(x + N[(N[(y * b), $MachinePrecision] * 1.6453555072203998), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(3.13060547623 + N[(36.52704169880642 * N[(-1.0 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.8 \cdot 10^{+18}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{elif}\;z \leq 1.22 \cdot 10^{-10}:\\
\;\;\;\;x + \left(y \cdot b\right) \cdot 1.6453555072203998\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \left(3.13060547623 + 36.52704169880642 \cdot \frac{-1}{z}\right)\\
\end{array}
\end{array}
if z < -4.8e18Initial program 5.8%
Simplified10.5%
Taylor expanded in z around inf 87.5%
+-commutative87.5%
*-commutative87.5%
Simplified87.5%
if -4.8e18 < z < 1.2199999999999999e-10Initial program 99.7%
Simplified99.7%
Taylor expanded in z around 0 73.6%
+-commutative73.6%
*-commutative73.6%
Simplified73.6%
if 1.2199999999999999e-10 < z Initial program 24.2%
Taylor expanded in z around -inf 83.7%
+-commutative83.7%
mul-1-neg83.7%
unsub-neg83.7%
*-commutative83.7%
distribute-rgt-out--83.7%
metadata-eval83.7%
Simplified83.7%
Taylor expanded in y around 0 83.7%
Final simplification79.6%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -1.46e+19)
(+ x (* y 3.13060547623))
(if (<= z 1.22e-10)
(+ x (/ (* y b) (+ 0.607771387771 (* z 11.9400905721))))
(+ x (* y (+ 3.13060547623 (* 36.52704169880642 (/ -1.0 z))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.46e+19) {
tmp = x + (y * 3.13060547623);
} else if (z <= 1.22e-10) {
tmp = x + ((y * b) / (0.607771387771 + (z * 11.9400905721)));
} else {
tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if (z <= (-1.46d+19)) then
tmp = x + (y * 3.13060547623d0)
else if (z <= 1.22d-10) then
tmp = x + ((y * b) / (0.607771387771d0 + (z * 11.9400905721d0)))
else
tmp = x + (y * (3.13060547623d0 + (36.52704169880642d0 * ((-1.0d0) / z))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.46e+19) {
tmp = x + (y * 3.13060547623);
} else if (z <= 1.22e-10) {
tmp = x + ((y * b) / (0.607771387771 + (z * 11.9400905721)));
} else {
tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -1.46e+19: tmp = x + (y * 3.13060547623) elif z <= 1.22e-10: tmp = x + ((y * b) / (0.607771387771 + (z * 11.9400905721))) else: tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -1.46e+19) tmp = Float64(x + Float64(y * 3.13060547623)); elseif (z <= 1.22e-10) tmp = Float64(x + Float64(Float64(y * b) / Float64(0.607771387771 + Float64(z * 11.9400905721)))); else tmp = Float64(x + Float64(y * Float64(3.13060547623 + Float64(36.52704169880642 * Float64(-1.0 / z))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -1.46e+19) tmp = x + (y * 3.13060547623); elseif (z <= 1.22e-10) tmp = x + ((y * b) / (0.607771387771 + (z * 11.9400905721))); else tmp = x + (y * (3.13060547623 + (36.52704169880642 * (-1.0 / z)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -1.46e+19], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.22e-10], N[(x + N[(N[(y * b), $MachinePrecision] / N[(0.607771387771 + N[(z * 11.9400905721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(3.13060547623 + N[(36.52704169880642 * N[(-1.0 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.46 \cdot 10^{+19}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{elif}\;z \leq 1.22 \cdot 10^{-10}:\\
\;\;\;\;x + \frac{y \cdot b}{0.607771387771 + z \cdot 11.9400905721}\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \left(3.13060547623 + 36.52704169880642 \cdot \frac{-1}{z}\right)\\
\end{array}
\end{array}
if z < -1.46e19Initial program 5.7%
Simplified9.0%
Taylor expanded in z around inf 89.0%
+-commutative89.0%
*-commutative89.0%
Simplified89.0%
if -1.46e19 < z < 1.2199999999999999e-10Initial program 99.0%
Taylor expanded in z around 0 73.6%
*-commutative73.6%
Simplified73.6%
Taylor expanded in z around 0 73.6%
*-commutative73.6%
Simplified73.6%
if 1.2199999999999999e-10 < z Initial program 24.2%
Taylor expanded in z around -inf 83.7%
+-commutative83.7%
mul-1-neg83.7%
unsub-neg83.7%
*-commutative83.7%
distribute-rgt-out--83.7%
metadata-eval83.7%
Simplified83.7%
Taylor expanded in y around 0 83.7%
Final simplification79.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -5.6e+18) (not (<= z 6.2e+14))) (+ x (* y 3.13060547623)) (+ x (* y (* b 1.6453555072203998)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -5.6e+18) || !(z <= 6.2e+14)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + (y * (b * 1.6453555072203998));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((z <= (-5.6d+18)) .or. (.not. (z <= 6.2d+14))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + (y * (b * 1.6453555072203998d0))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -5.6e+18) || !(z <= 6.2e+14)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + (y * (b * 1.6453555072203998));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -5.6e+18) or not (z <= 6.2e+14): tmp = x + (y * 3.13060547623) else: tmp = x + (y * (b * 1.6453555072203998)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -5.6e+18) || !(z <= 6.2e+14)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(x + Float64(y * Float64(b * 1.6453555072203998))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -5.6e+18) || ~((z <= 6.2e+14))) tmp = x + (y * 3.13060547623); else tmp = x + (y * (b * 1.6453555072203998)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -5.6e+18], N[Not[LessEqual[z, 6.2e+14]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(b * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.6 \cdot 10^{+18} \lor \neg \left(z \leq 6.2 \cdot 10^{+14}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \left(b \cdot 1.6453555072203998\right)\\
\end{array}
\end{array}
if z < -5.6e18 or 6.2e14 < z Initial program 12.6%
Simplified17.8%
Taylor expanded in z around inf 87.9%
+-commutative87.9%
*-commutative87.9%
Simplified87.9%
if -5.6e18 < z < 6.2e14Initial program 99.7%
Taylor expanded in z around 0 71.7%
associate-*r*71.6%
*-commutative71.6%
Simplified71.6%
Final simplification79.5%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -7.2e+18) (not (<= z 5.5e+14))) (+ x (* y 3.13060547623)) (+ x (* (* y b) 1.6453555072203998))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -7.2e+18) || !(z <= 5.5e+14)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * b) * 1.6453555072203998);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: tmp
if ((z <= (-7.2d+18)) .or. (.not. (z <= 5.5d+14))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + ((y * b) * 1.6453555072203998d0)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -7.2e+18) || !(z <= 5.5e+14)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * b) * 1.6453555072203998);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -7.2e+18) or not (z <= 5.5e+14): tmp = x + (y * 3.13060547623) else: tmp = x + ((y * b) * 1.6453555072203998) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -7.2e+18) || !(z <= 5.5e+14)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(x + Float64(Float64(y * b) * 1.6453555072203998)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -7.2e+18) || ~((z <= 5.5e+14))) tmp = x + (y * 3.13060547623); else tmp = x + ((y * b) * 1.6453555072203998); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -7.2e+18], N[Not[LessEqual[z, 5.5e+14]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y * b), $MachinePrecision] * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.2 \cdot 10^{+18} \lor \neg \left(z \leq 5.5 \cdot 10^{+14}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + \left(y \cdot b\right) \cdot 1.6453555072203998\\
\end{array}
\end{array}
if z < -7.2e18 or 5.5e14 < z Initial program 12.6%
Simplified17.8%
Taylor expanded in z around inf 87.9%
+-commutative87.9%
*-commutative87.9%
Simplified87.9%
if -7.2e18 < z < 5.5e14Initial program 99.7%
Simplified99.7%
Taylor expanded in z around 0 71.7%
+-commutative71.7%
*-commutative71.7%
Simplified71.7%
Final simplification79.5%
(FPCore (x y z t a b) :precision binary64 (+ x (* y 3.13060547623)))
double code(double x, double y, double z, double t, double a, double b) {
return x + (y * 3.13060547623);
}
real(8) function code(x, y, z, t, a, b)
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
code = x + (y * 3.13060547623d0)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x + (y * 3.13060547623);
}
def code(x, y, z, t, a, b): return x + (y * 3.13060547623)
function code(x, y, z, t, a, b) return Float64(x + Float64(y * 3.13060547623)) end
function tmp = code(x, y, z, t, a, b) tmp = x + (y * 3.13060547623); end
code[x_, y_, z_, t_, a_, b_] := N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + y \cdot 3.13060547623
\end{array}
Initial program 57.5%
Simplified60.0%
Taylor expanded in z around inf 60.1%
+-commutative60.1%
*-commutative60.1%
Simplified60.1%
Final simplification60.1%
(FPCore (x y z t a b) :precision binary64 x)
double code(double x, double y, double z, double t, double a, double b) {
return x;
}
real(8) function code(x, y, z, t, a, b)
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
code = x
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x;
}
def code(x, y, z, t, a, b): return x
function code(x, y, z, t, a, b) return x end
function tmp = code(x, y, z, t, a, b) tmp = x; end
code[x_, y_, z_, t_, a_, b_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 57.5%
Simplified60.0%
Taylor expanded in y around 0 41.6%
Final simplification41.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1
(+
x
(*
(+ (- 3.13060547623 (/ 36.527041698806414 z)) (/ t (* z z)))
(/ y 1.0)))))
(if (< z -6.499344996252632e+53)
t_1
(if (< z 7.066965436914287e+59)
(+
x
(/
y
(/
(+
(*
(+ (* (+ (* (+ z 15.234687407) z) 31.4690115749) z) 11.9400905721)
z)
0.607771387771)
(+
(* (+ (* (+ (* (+ (* z 3.13060547623) 11.1667541262) z) t) z) a) z)
b))))
t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x + (((3.13060547623 - (36.527041698806414 / z)) + (t / (z * z))) * (y / 1.0));
double tmp;
if (z < -6.499344996252632e+53) {
tmp = t_1;
} else if (z < 7.066965436914287e+59) {
tmp = x + (y / ((((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771) / ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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) :: t_1
real(8) :: tmp
t_1 = x + (((3.13060547623d0 - (36.527041698806414d0 / z)) + (t / (z * z))) * (y / 1.0d0))
if (z < (-6.499344996252632d+53)) then
tmp = t_1
else if (z < 7.066965436914287d+59) then
tmp = x + (y / ((((((((z + 15.234687407d0) * z) + 31.4690115749d0) * z) + 11.9400905721d0) * z) + 0.607771387771d0) / ((((((((z * 3.13060547623d0) + 11.1667541262d0) * z) + t) * z) + a) * z) + 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 t_1 = x + (((3.13060547623 - (36.527041698806414 / z)) + (t / (z * z))) * (y / 1.0));
double tmp;
if (z < -6.499344996252632e+53) {
tmp = t_1;
} else if (z < 7.066965436914287e+59) {
tmp = x + (y / ((((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771) / ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x + (((3.13060547623 - (36.527041698806414 / z)) + (t / (z * z))) * (y / 1.0)) tmp = 0 if z < -6.499344996252632e+53: tmp = t_1 elif z < 7.066965436914287e+59: tmp = x + (y / ((((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771) / ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x + Float64(Float64(Float64(3.13060547623 - Float64(36.527041698806414 / z)) + Float64(t / Float64(z * z))) * Float64(y / 1.0))) tmp = 0.0 if (z < -6.499344996252632e+53) tmp = t_1; elseif (z < 7.066965436914287e+59) tmp = Float64(x + Float64(y / Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771) / Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x + (((3.13060547623 - (36.527041698806414 / z)) + (t / (z * z))) * (y / 1.0)); tmp = 0.0; if (z < -6.499344996252632e+53) tmp = t_1; elseif (z < 7.066965436914287e+59) tmp = x + (y / ((((((((z + 15.234687407) * z) + 31.4690115749) * z) + 11.9400905721) * z) + 0.607771387771) / ((((((((z * 3.13060547623) + 11.1667541262) * z) + t) * z) + a) * z) + b))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(N[(N[(3.13060547623 - N[(36.527041698806414 / z), $MachinePrecision]), $MachinePrecision] + N[(t / N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(y / 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[z, -6.499344996252632e+53], t$95$1, If[Less[z, 7.066965436914287e+59], N[(x + N[(y / N[(N[(N[(N[(N[(N[(N[(N[(z + 15.234687407), $MachinePrecision] * z), $MachinePrecision] + 31.4690115749), $MachinePrecision] * z), $MachinePrecision] + 11.9400905721), $MachinePrecision] * z), $MachinePrecision] + 0.607771387771), $MachinePrecision] / N[(N[(N[(N[(N[(N[(N[(N[(z * 3.13060547623), $MachinePrecision] + 11.1667541262), $MachinePrecision] * z), $MachinePrecision] + t), $MachinePrecision] * z), $MachinePrecision] + a), $MachinePrecision] * z), $MachinePrecision] + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(\left(3.13060547623 - \frac{36.527041698806414}{z}\right) + \frac{t}{z \cdot z}\right) \cdot \frac{y}{1}\\
\mathbf{if}\;z < -6.499344996252632 \cdot 10^{+53}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z < 7.066965436914287 \cdot 10^{+59}:\\
\;\;\;\;x + \frac{y}{\frac{\left(\left(\left(z + 15.234687407\right) \cdot z + 31.4690115749\right) \cdot z + 11.9400905721\right) \cdot z + 0.607771387771}{\left(\left(\left(z \cdot 3.13060547623 + 11.1667541262\right) \cdot z + t\right) \cdot z + a\right) \cdot z + b}}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
herbie shell --seed 2024082
(FPCore (x y z t a b)
:name "Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2, D"
:precision binary64
:alt
(if (< z -6.499344996252632e+53) (+ x (* (+ (- 3.13060547623 (/ 36.527041698806414 z)) (/ t (* z z))) (/ y 1.0))) (if (< z 7.066965436914287e+59) (+ x (/ y (/ (+ (* (+ (* (+ (* (+ z 15.234687407) z) 31.4690115749) z) 11.9400905721) z) 0.607771387771) (+ (* (+ (* (+ (* (+ (* z 3.13060547623) 11.1667541262) z) t) z) a) z) b)))) (+ x (* (+ (- 3.13060547623 (/ 36.527041698806414 z)) (/ t (* z z))) (/ y 1.0)))))
(+ x (/ (* y (+ (* (+ (* (+ (* (+ (* z 3.13060547623) 11.1667541262) z) t) z) a) z) b)) (+ (* (+ (* (+ (* (+ z 15.234687407) z) 31.4690115749) z) 11.9400905721) z) 0.607771387771))))