
(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 20 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 (or (<= z -1.05e+15) (not (<= z 14500000.0)))
(fma
y
(+
3.13060547623
(/
(-
(/
(+
457.9610022158428
(+ t (/ (+ a (+ -5864.8025282699045 (* t -15.234687407))) z)))
z)
36.52704169880642)
z))
x)
(+
(/
(*
y
(+
b
(* z (+ a (* z (+ t (* z (+ 11.1667541262 (* z 3.13060547623)))))))))
(+
(* 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 <= -1.05e+15) || !(z <= 14500000.0)) {
tmp = fma(y, (3.13060547623 + ((((457.9610022158428 + (t + ((a + (-5864.8025282699045 + (t * -15.234687407))) / z))) / z) - 36.52704169880642) / z)), x);
} else {
tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((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 <= -1.05e+15) || !(z <= 14500000.0)) tmp = fma(y, Float64(3.13060547623 + Float64(Float64(Float64(Float64(457.9610022158428 + Float64(t + Float64(Float64(a + Float64(-5864.8025282699045 + Float64(t * -15.234687407))) / z))) / z) - 36.52704169880642) / z)), x); else tmp = Float64(Float64(Float64(y * Float64(b + Float64(z * Float64(a + Float64(z * Float64(t + Float64(z * Float64(11.1667541262 + Float64(z * 3.13060547623))))))))) / 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, -1.05e+15], N[Not[LessEqual[z, 14500000.0]], $MachinePrecision]], N[(y * N[(3.13060547623 + N[(N[(N[(N[(457.9610022158428 + N[(t + N[(N[(a + N[(-5864.8025282699045 + N[(t * -15.234687407), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] - 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(N[(N[(y * N[(b + N[(z * N[(a + N[(z * N[(t + N[(z * N[(11.1667541262 + N[(z * 3.13060547623), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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] + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.05 \cdot 10^{+15} \lor \neg \left(z \leq 14500000\right):\\
\;\;\;\;\mathsf{fma}\left(y, 3.13060547623 + \frac{\frac{457.9610022158428 + \left(t + \frac{a + \left(-5864.8025282699045 + t \cdot -15.234687407\right)}{z}\right)}{z} - 36.52704169880642}{z}, x\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{y \cdot \left(b + z \cdot \left(a + z \cdot \left(t + z \cdot \left(11.1667541262 + z \cdot 3.13060547623\right)\right)\right)\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 < -1.05e15 or 1.45e7 < z Initial program 13.6%
Simplified21.9%
Taylor expanded in z around -inf 99.1%
Simplified99.1%
if -1.05e15 < z < 1.45e7Initial program 99.6%
Final simplification99.4%
(FPCore (x y z t a b)
:precision binary64
(if (<=
(/
(*
y
(+
b
(* z (+ a (* z (+ t (* z (+ 11.1667541262 (* z 3.13060547623)))))))))
(+
(*
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 * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((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(b + Float64(z * Float64(a + Float64(z * Float64(t + Float64(z * Float64(11.1667541262 + Float64(z * 3.13060547623))))))))) / 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[(b + N[(z * N[(a + N[(z * N[(t + N[(z * N[(11.1667541262 + N[(z * 3.13060547623), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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], 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(b + z \cdot \left(a + z \cdot \left(t + z \cdot \left(11.1667541262 + z \cdot 3.13060547623\right)\right)\right)\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 91.0%
Simplified97.3%
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.9%
mul-1-neg99.9%
unsub-neg99.9%
mul-1-neg99.9%
unsub-neg99.9%
+-commutative99.9%
Simplified99.9%
Final simplification98.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1
(+
(*
z
(+ (* z (+ (* z (+ z 15.234687407)) 31.4690115749)) 11.9400905721))
0.607771387771))
(t_2
(+
b
(* z (+ a (* z (+ t (* z (+ 11.1667541262 (* z 3.13060547623)))))))))
(t_3 (/ (* y t_2) t_1)))
(if (<= t_3 -5e+275)
(* y (+ (/ x y) (/ t_2 t_1)))
(if (<= t_3 INFINITY) (+ t_3 x) (fma y 3.13060547623 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 t_2 = b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623)))))));
double t_3 = (y * t_2) / t_1;
double tmp;
if (t_3 <= -5e+275) {
tmp = y * ((x / y) + (t_2 / t_1));
} else if (t_3 <= ((double) INFINITY)) {
tmp = t_3 + x;
} else {
tmp = fma(y, 3.13060547623, 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) t_2 = Float64(b + Float64(z * Float64(a + Float64(z * Float64(t + Float64(z * Float64(11.1667541262 + Float64(z * 3.13060547623)))))))) t_3 = Float64(Float64(y * t_2) / t_1) tmp = 0.0 if (t_3 <= -5e+275) tmp = Float64(y * Float64(Float64(x / y) + Float64(t_2 / t_1))); elseif (t_3 <= Inf) tmp = Float64(t_3 + x); else tmp = fma(y, 3.13060547623, 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]}, Block[{t$95$2 = N[(b + N[(z * N[(a + N[(z * N[(t + N[(z * N[(11.1667541262 + N[(z * 3.13060547623), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(y * t$95$2), $MachinePrecision] / t$95$1), $MachinePrecision]}, If[LessEqual[t$95$3, -5e+275], N[(y * N[(N[(x / y), $MachinePrecision] + N[(t$95$2 / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, Infinity], N[(t$95$3 + x), $MachinePrecision], N[(y * 3.13060547623 + 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\\
t_2 := b + z \cdot \left(a + z \cdot \left(t + z \cdot \left(11.1667541262 + z \cdot 3.13060547623\right)\right)\right)\\
t_3 := \frac{y \cdot t\_2}{t\_1}\\
\mathbf{if}\;t\_3 \leq -5 \cdot 10^{+275}:\\
\;\;\;\;y \cdot \left(\frac{x}{y} + \frac{t\_2}{t\_1}\right)\\
\mathbf{elif}\;t\_3 \leq \infty:\\
\;\;\;\;t\_3 + x\\
\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(y, 3.13060547623, 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))) < -5.0000000000000003e275Initial program 67.5%
Simplified92.1%
Taylor expanded in y around -inf 92.1%
if -5.0000000000000003e275 < (/.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 95.4%
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 94.5%
Final simplification94.8%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -3.2e+24) (not (<= z 2.75e+29)))
(fma
y
(+ 3.13060547623 (/ (- (/ (+ t 457.9610022158428) z) 36.52704169880642) z))
x)
(+
(/
(*
y
(+
b
(* z (+ a (* z (+ t (* z (+ 11.1667541262 (* z 3.13060547623)))))))))
(+
(* 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 <= -3.2e+24) || !(z <= 2.75e+29)) {
tmp = fma(y, (3.13060547623 + ((((t + 457.9610022158428) / z) - 36.52704169880642) / z)), x);
} else {
tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((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 <= -3.2e+24) || !(z <= 2.75e+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(b + Float64(z * Float64(a + Float64(z * Float64(t + Float64(z * Float64(11.1667541262 + Float64(z * 3.13060547623))))))))) / 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, -3.2e+24], N[Not[LessEqual[z, 2.75e+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[(b + N[(z * N[(a + N[(z * N[(t + N[(z * N[(11.1667541262 + N[(z * 3.13060547623), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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] + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.2 \cdot 10^{+24} \lor \neg \left(z \leq 2.75 \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(b + z \cdot \left(a + z \cdot \left(t + z \cdot \left(11.1667541262 + z \cdot 3.13060547623\right)\right)\right)\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 < -3.1999999999999997e24 or 2.75e29 < z Initial program 8.5%
Simplified16.6%
Taylor expanded in z around -inf 97.5%
mul-1-neg97.5%
unsub-neg97.5%
mul-1-neg97.5%
unsub-neg97.5%
+-commutative97.5%
Simplified97.5%
if -3.1999999999999997e24 < z < 2.75e29Initial program 99.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))
(t_2
(+
b
(* z (+ a (* z (+ t (* z (+ 11.1667541262 (* z 3.13060547623)))))))))
(t_3 (/ (* y t_2) t_1)))
(if (<= t_3 -5e+275)
(* y (+ (/ x y) (/ t_2 t_1)))
(if (<= t_3 INFINITY) (+ t_3 x) (+ x (* y 3.13060547623))))))
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 t_2 = b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623)))))));
double t_3 = (y * t_2) / t_1;
double tmp;
if (t_3 <= -5e+275) {
tmp = y * ((x / y) + (t_2 / t_1));
} else if (t_3 <= ((double) INFINITY)) {
tmp = t_3 + 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 = (z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771;
double t_2 = b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623)))))));
double t_3 = (y * t_2) / t_1;
double tmp;
if (t_3 <= -5e+275) {
tmp = y * ((x / y) + (t_2 / t_1));
} else if (t_3 <= Double.POSITIVE_INFINITY) {
tmp = t_3 + x;
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771 t_2 = b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))) t_3 = (y * t_2) / t_1 tmp = 0 if t_3 <= -5e+275: tmp = y * ((x / y) + (t_2 / t_1)) elif t_3 <= math.inf: tmp = t_3 + x else: tmp = x + (y * 3.13060547623) 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) t_2 = Float64(b + Float64(z * Float64(a + Float64(z * Float64(t + Float64(z * Float64(11.1667541262 + Float64(z * 3.13060547623)))))))) t_3 = Float64(Float64(y * t_2) / t_1) tmp = 0.0 if (t_3 <= -5e+275) tmp = Float64(y * Float64(Float64(x / y) + Float64(t_2 / t_1))); elseif (t_3 <= Inf) tmp = Float64(t_3 + 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 = (z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771; t_2 = b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))); t_3 = (y * t_2) / t_1; tmp = 0.0; if (t_3 <= -5e+275) tmp = y * ((x / y) + (t_2 / t_1)); elseif (t_3 <= Inf) tmp = t_3 + 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[(z * N[(N[(z * N[(N[(z * N[(z + 15.234687407), $MachinePrecision]), $MachinePrecision] + 31.4690115749), $MachinePrecision]), $MachinePrecision] + 11.9400905721), $MachinePrecision]), $MachinePrecision] + 0.607771387771), $MachinePrecision]}, Block[{t$95$2 = N[(b + N[(z * N[(a + N[(z * N[(t + N[(z * N[(11.1667541262 + N[(z * 3.13060547623), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(y * t$95$2), $MachinePrecision] / t$95$1), $MachinePrecision]}, If[LessEqual[t$95$3, -5e+275], N[(y * N[(N[(x / y), $MachinePrecision] + N[(t$95$2 / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, Infinity], N[(t$95$3 + x), $MachinePrecision], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $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\\
t_2 := b + z \cdot \left(a + z \cdot \left(t + z \cdot \left(11.1667541262 + z \cdot 3.13060547623\right)\right)\right)\\
t_3 := \frac{y \cdot t\_2}{t\_1}\\
\mathbf{if}\;t\_3 \leq -5 \cdot 10^{+275}:\\
\;\;\;\;y \cdot \left(\frac{x}{y} + \frac{t\_2}{t\_1}\right)\\
\mathbf{elif}\;t\_3 \leq \infty:\\
\;\;\;\;t\_3 + 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))) < -5.0000000000000003e275Initial program 67.5%
Simplified92.1%
Taylor expanded in y around -inf 92.1%
if -5.0000000000000003e275 < (/.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 95.4%
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 94.5%
+-commutative94.5%
*-commutative94.5%
Simplified94.5%
Final simplification94.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ x (* y 3.13060547623))))
(if (<= z -2e+113)
t_1
(if (<= z -1.3e+26)
(+
x
(+
(* y 3.13060547623)
(/
(-
(* y -47.69379582500642)
(+
(* y -11.1667541262)
(/
(-
(-
(* y 98.5170599679272)
(*
-15.234687407
(- (* y -47.69379582500642) (* y -11.1667541262))))
(* y t))
z)))
z)))
(if (<= z 9.5e+50)
(+
(/
(*
y
(+
b
(*
z
(+ a (* z (+ t (* z (+ 11.1667541262 (* z 3.13060547623)))))))))
(+
(*
z
(+
(* z (+ (* z (+ z 15.234687407)) 31.4690115749))
11.9400905721))
0.607771387771))
x)
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 <= -2e+113) {
tmp = t_1;
} else if (z <= -1.3e+26) {
tmp = x + ((y * 3.13060547623) + (((y * -47.69379582500642) - ((y * -11.1667541262) + ((((y * 98.5170599679272) - (-15.234687407 * ((y * -47.69379582500642) - (y * -11.1667541262)))) - (y * t)) / z))) / z));
} else if (z <= 9.5e+50) {
tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x;
} 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 <= (-2d+113)) then
tmp = t_1
else if (z <= (-1.3d+26)) then
tmp = x + ((y * 3.13060547623d0) + (((y * (-47.69379582500642d0)) - ((y * (-11.1667541262d0)) + ((((y * 98.5170599679272d0) - ((-15.234687407d0) * ((y * (-47.69379582500642d0)) - (y * (-11.1667541262d0))))) - (y * t)) / z))) / z))
else if (z <= 9.5d+50) then
tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262d0 + (z * 3.13060547623d0))))))))) / ((z * ((z * ((z * (z + 15.234687407d0)) + 31.4690115749d0)) + 11.9400905721d0)) + 0.607771387771d0)) + x
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 <= -2e+113) {
tmp = t_1;
} else if (z <= -1.3e+26) {
tmp = x + ((y * 3.13060547623) + (((y * -47.69379582500642) - ((y * -11.1667541262) + ((((y * 98.5170599679272) - (-15.234687407 * ((y * -47.69379582500642) - (y * -11.1667541262)))) - (y * t)) / z))) / z));
} else if (z <= 9.5e+50) {
tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x + (y * 3.13060547623) tmp = 0 if z <= -2e+113: tmp = t_1 elif z <= -1.3e+26: tmp = x + ((y * 3.13060547623) + (((y * -47.69379582500642) - ((y * -11.1667541262) + ((((y * 98.5170599679272) - (-15.234687407 * ((y * -47.69379582500642) - (y * -11.1667541262)))) - (y * t)) / z))) / z)) elif z <= 9.5e+50: tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x 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 <= -2e+113) tmp = t_1; elseif (z <= -1.3e+26) tmp = Float64(x + Float64(Float64(y * 3.13060547623) + Float64(Float64(Float64(y * -47.69379582500642) - Float64(Float64(y * -11.1667541262) + Float64(Float64(Float64(Float64(y * 98.5170599679272) - Float64(-15.234687407 * Float64(Float64(y * -47.69379582500642) - Float64(y * -11.1667541262)))) - Float64(y * t)) / z))) / z))); elseif (z <= 9.5e+50) tmp = Float64(Float64(Float64(y * Float64(b + Float64(z * Float64(a + Float64(z * Float64(t + Float64(z * Float64(11.1667541262 + Float64(z * 3.13060547623))))))))) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x); 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 <= -2e+113) tmp = t_1; elseif (z <= -1.3e+26) tmp = x + ((y * 3.13060547623) + (((y * -47.69379582500642) - ((y * -11.1667541262) + ((((y * 98.5170599679272) - (-15.234687407 * ((y * -47.69379582500642) - (y * -11.1667541262)))) - (y * t)) / z))) / z)); elseif (z <= 9.5e+50) tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x; 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, -2e+113], t$95$1, If[LessEqual[z, -1.3e+26], N[(x + N[(N[(y * 3.13060547623), $MachinePrecision] + N[(N[(N[(y * -47.69379582500642), $MachinePrecision] - N[(N[(y * -11.1667541262), $MachinePrecision] + N[(N[(N[(N[(y * 98.5170599679272), $MachinePrecision] - N[(-15.234687407 * N[(N[(y * -47.69379582500642), $MachinePrecision] - N[(y * -11.1667541262), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y * t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9.5e+50], N[(N[(N[(y * N[(b + N[(z * N[(a + N[(z * N[(t + N[(z * N[(11.1667541262 + N[(z * 3.13060547623), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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] + x), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + y \cdot 3.13060547623\\
\mathbf{if}\;z \leq -2 \cdot 10^{+113}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -1.3 \cdot 10^{+26}:\\
\;\;\;\;x + \left(y \cdot 3.13060547623 + \frac{y \cdot -47.69379582500642 - \left(y \cdot -11.1667541262 + \frac{\left(y \cdot 98.5170599679272 - -15.234687407 \cdot \left(y \cdot -47.69379582500642 - y \cdot -11.1667541262\right)\right) - y \cdot t}{z}\right)}{z}\right)\\
\mathbf{elif}\;z \leq 9.5 \cdot 10^{+50}:\\
\;\;\;\;\frac{y \cdot \left(b + z \cdot \left(a + z \cdot \left(t + z \cdot \left(11.1667541262 + z \cdot 3.13060547623\right)\right)\right)\right)}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771} + x\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -2e113 or 9.4999999999999993e50 < z Initial program 3.5%
Simplified5.5%
Taylor expanded in z around inf 95.7%
+-commutative95.7%
*-commutative95.7%
Simplified95.7%
if -2e113 < z < -1.30000000000000001e26Initial program 18.1%
Taylor expanded in z around -inf 90.1%
if -1.30000000000000001e26 < z < 9.4999999999999993e50Initial program 97.1%
Final simplification96.1%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -4.1e+26) (not (<= z 4.8e+48)))
(+ x (* y 3.13060547623))
(+
(/
(*
y
(+
b
(* z (+ a (* z (+ t (* z (+ 11.1667541262 (* z 3.13060547623)))))))))
(+
(* 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.1e+26) || !(z <= 4.8e+48)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x;
}
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.1d+26)) .or. (.not. (z <= 4.8d+48))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262d0 + (z * 3.13060547623d0))))))))) / ((z * ((z * ((z * (z + 15.234687407d0)) + 31.4690115749d0)) + 11.9400905721d0)) + 0.607771387771d0)) + x
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.1e+26) || !(z <= 4.8e+48)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -4.1e+26) or not (z <= 4.8e+48): tmp = x + (y * 3.13060547623) else: tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((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.1e+26) || !(z <= 4.8e+48)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(Float64(Float64(y * Float64(b + Float64(z * Float64(a + Float64(z * Float64(t + Float64(z * Float64(11.1667541262 + Float64(z * 3.13060547623))))))))) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -4.1e+26) || ~((z <= 4.8e+48))) tmp = x + (y * 3.13060547623); else tmp = ((y * (b + (z * (a + (z * (t + (z * (11.1667541262 + (z * 3.13060547623))))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) + x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -4.1e+26], N[Not[LessEqual[z, 4.8e+48]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(N[(N[(y * N[(b + N[(z * N[(a + N[(z * N[(t + N[(z * N[(11.1667541262 + N[(z * 3.13060547623), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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] + x), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.1 \cdot 10^{+26} \lor \neg \left(z \leq 4.8 \cdot 10^{+48}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;\frac{y \cdot \left(b + z \cdot \left(a + z \cdot \left(t + z \cdot \left(11.1667541262 + z \cdot 3.13060547623\right)\right)\right)\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.09999999999999983e26 or 4.8000000000000002e48 < z Initial program 6.0%
Simplified12.9%
Taylor expanded in z around inf 90.0%
+-commutative90.0%
*-commutative90.0%
Simplified90.0%
if -4.09999999999999983e26 < z < 4.8000000000000002e48Initial program 97.1%
Final simplification94.1%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -4.1e+26) (not (<= z 5.5e+49)))
(+ x (* y 3.13060547623))
(+
x
(/
(* y (+ b (* z (+ a (* z (+ t (* z 11.1667541262)))))))
(+
(* z (+ (* z (+ (* z (+ z 15.234687407)) 31.4690115749)) 11.9400905721))
0.607771387771)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -4.1e+26) || !(z <= 5.5e+49)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
}
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.1d+26)) .or. (.not. (z <= 5.5d+49))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262d0))))))) / ((z * ((z * ((z * (z + 15.234687407d0)) + 31.4690115749d0)) + 11.9400905721d0)) + 0.607771387771d0))
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.1e+26) || !(z <= 5.5e+49)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -4.1e+26) or not (z <= 5.5e+49): tmp = x + (y * 3.13060547623) else: tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -4.1e+26) || !(z <= 5.5e+49)) 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(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -4.1e+26) || ~((z <= 5.5e+49))) tmp = x + (y * 3.13060547623); else tmp = x + ((y * (b + (z * (a + (z * (t + (z * 11.1667541262))))))) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -4.1e+26], N[Not[LessEqual[z, 5.5e+49]], $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[(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]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.1 \cdot 10^{+26} \lor \neg \left(z \leq 5.5 \cdot 10^{+49}\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)}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771}\\
\end{array}
\end{array}
if z < -4.09999999999999983e26 or 5.50000000000000042e49 < z Initial program 6.0%
Simplified12.9%
Taylor expanded in z around inf 90.0%
+-commutative90.0%
*-commutative90.0%
Simplified90.0%
if -4.09999999999999983e26 < z < 5.50000000000000042e49Initial program 97.1%
Taylor expanded in z around 0 96.4%
*-commutative96.4%
Simplified96.4%
Final simplification93.7%
(FPCore (x y z t a b)
:precision binary64
(if (or (<= z -3.6e+26) (not (<= z 4.4e+43)))
(+ x (* y 3.13060547623))
(+
x
(/
(+ (* a (* y z)) (* y b))
(+
(* z (+ (* z (+ (* z (+ z 15.234687407)) 31.4690115749)) 11.9400905721))
0.607771387771)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -3.6e+26) || !(z <= 4.4e+43)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + (((a * (y * z)) + (y * b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
}
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 <= (-3.6d+26)) .or. (.not. (z <= 4.4d+43))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + (((a * (y * z)) + (y * b)) / ((z * ((z * ((z * (z + 15.234687407d0)) + 31.4690115749d0)) + 11.9400905721d0)) + 0.607771387771d0))
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 <= -3.6e+26) || !(z <= 4.4e+43)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + (((a * (y * z)) + (y * b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -3.6e+26) or not (z <= 4.4e+43): tmp = x + (y * 3.13060547623) else: tmp = x + (((a * (y * z)) + (y * b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -3.6e+26) || !(z <= 4.4e+43)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(x + Float64(Float64(Float64(a * Float64(y * z)) + Float64(y * b)) / Float64(Float64(z * Float64(Float64(z * Float64(Float64(z * Float64(z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -3.6e+26) || ~((z <= 4.4e+43))) tmp = x + (y * 3.13060547623); else tmp = x + (((a * (y * z)) + (y * b)) / ((z * ((z * ((z * (z + 15.234687407)) + 31.4690115749)) + 11.9400905721)) + 0.607771387771)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -3.6e+26], N[Not[LessEqual[z, 4.4e+43]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(N[(a * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(y * 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]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.6 \cdot 10^{+26} \lor \neg \left(z \leq 4.4 \cdot 10^{+43}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + \frac{a \cdot \left(y \cdot z\right) + y \cdot b}{z \cdot \left(z \cdot \left(z \cdot \left(z + 15.234687407\right) + 31.4690115749\right) + 11.9400905721\right) + 0.607771387771}\\
\end{array}
\end{array}
if z < -3.60000000000000024e26 or 4.40000000000000001e43 < z Initial program 6.9%
Simplified13.7%
Taylor expanded in z around inf 89.2%
+-commutative89.2%
*-commutative89.2%
Simplified89.2%
if -3.60000000000000024e26 < z < 4.40000000000000001e43Initial program 97.1%
Taylor expanded in z around 0 92.3%
Final simplification91.0%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -140000000.0)
(-
(+ x (+ (* y 3.13060547623) (* 11.1667541262 (/ y z))))
(* (/ y z) 47.69379582500642))
(if (<= z 6.4e+28)
(+
x
(+
(* (* a (* y z)) 1.6453555072203998)
(* b (+ (* (* y z) -32.324150453290734) (* y 1.6453555072203998)))))
(+ x (* y 3.13060547623)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -140000000.0) {
tmp = (x + ((y * 3.13060547623) + (11.1667541262 * (y / z)))) - ((y / z) * 47.69379582500642);
} else if (z <= 6.4e+28) {
tmp = x + (((a * (y * z)) * 1.6453555072203998) + (b * (((y * z) * -32.324150453290734) + (y * 1.6453555072203998))));
} else {
tmp = x + (y * 3.13060547623);
}
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 <= (-140000000.0d0)) then
tmp = (x + ((y * 3.13060547623d0) + (11.1667541262d0 * (y / z)))) - ((y / z) * 47.69379582500642d0)
else if (z <= 6.4d+28) then
tmp = x + (((a * (y * z)) * 1.6453555072203998d0) + (b * (((y * z) * (-32.324150453290734d0)) + (y * 1.6453555072203998d0))))
else
tmp = x + (y * 3.13060547623d0)
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 <= -140000000.0) {
tmp = (x + ((y * 3.13060547623) + (11.1667541262 * (y / z)))) - ((y / z) * 47.69379582500642);
} else if (z <= 6.4e+28) {
tmp = x + (((a * (y * z)) * 1.6453555072203998) + (b * (((y * z) * -32.324150453290734) + (y * 1.6453555072203998))));
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -140000000.0: tmp = (x + ((y * 3.13060547623) + (11.1667541262 * (y / z)))) - ((y / z) * 47.69379582500642) elif z <= 6.4e+28: tmp = x + (((a * (y * z)) * 1.6453555072203998) + (b * (((y * z) * -32.324150453290734) + (y * 1.6453555072203998)))) else: tmp = x + (y * 3.13060547623) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -140000000.0) tmp = Float64(Float64(x + Float64(Float64(y * 3.13060547623) + Float64(11.1667541262 * Float64(y / z)))) - Float64(Float64(y / z) * 47.69379582500642)); elseif (z <= 6.4e+28) tmp = Float64(x + Float64(Float64(Float64(a * Float64(y * z)) * 1.6453555072203998) + Float64(b * Float64(Float64(Float64(y * z) * -32.324150453290734) + Float64(y * 1.6453555072203998))))); else tmp = Float64(x + Float64(y * 3.13060547623)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -140000000.0) tmp = (x + ((y * 3.13060547623) + (11.1667541262 * (y / z)))) - ((y / z) * 47.69379582500642); elseif (z <= 6.4e+28) tmp = x + (((a * (y * z)) * 1.6453555072203998) + (b * (((y * z) * -32.324150453290734) + (y * 1.6453555072203998)))); else tmp = x + (y * 3.13060547623); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -140000000.0], N[(N[(x + N[(N[(y * 3.13060547623), $MachinePrecision] + N[(11.1667541262 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y / z), $MachinePrecision] * 47.69379582500642), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 6.4e+28], N[(x + N[(N[(N[(a * N[(y * z), $MachinePrecision]), $MachinePrecision] * 1.6453555072203998), $MachinePrecision] + N[(b * N[(N[(N[(y * z), $MachinePrecision] * -32.324150453290734), $MachinePrecision] + N[(y * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -140000000:\\
\;\;\;\;\left(x + \left(y \cdot 3.13060547623 + 11.1667541262 \cdot \frac{y}{z}\right)\right) - \frac{y}{z} \cdot 47.69379582500642\\
\mathbf{elif}\;z \leq 6.4 \cdot 10^{+28}:\\
\;\;\;\;x + \left(\left(a \cdot \left(y \cdot z\right)\right) \cdot 1.6453555072203998 + b \cdot \left(\left(y \cdot z\right) \cdot -32.324150453290734 + y \cdot 1.6453555072203998\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\end{array}
\end{array}
if z < -1.4e8Initial program 11.7%
Simplified21.9%
Taylor expanded in z around inf 82.9%
if -1.4e8 < z < 6.4000000000000001e28Initial program 99.0%
Taylor expanded in z around 0 83.5%
Taylor expanded in b around 0 94.6%
if 6.4000000000000001e28 < z Initial program 11.3%
Simplified16.3%
Taylor expanded in z around inf 87.8%
+-commutative87.8%
*-commutative87.8%
Simplified87.8%
Final simplification90.2%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -270000.0)
(+ x (- (* y 3.13060547623) (/ (* y 36.52704169880642) z)))
(if (<= z 4.2e+28)
(-
x
(*
y
(-
(* z (- (* b 32.324150453290734) (* a 1.6453555072203998)))
(* b 1.6453555072203998))))
(+ x (* y 3.13060547623)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -270000.0) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 4.2e+28) {
tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998)));
} else {
tmp = x + (y * 3.13060547623);
}
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 <= (-270000.0d0)) then
tmp = x + ((y * 3.13060547623d0) - ((y * 36.52704169880642d0) / z))
else if (z <= 4.2d+28) then
tmp = x - (y * ((z * ((b * 32.324150453290734d0) - (a * 1.6453555072203998d0))) - (b * 1.6453555072203998d0)))
else
tmp = x + (y * 3.13060547623d0)
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 <= -270000.0) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 4.2e+28) {
tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998)));
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -270000.0: tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)) elif z <= 4.2e+28: tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998))) else: tmp = x + (y * 3.13060547623) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -270000.0) tmp = Float64(x + Float64(Float64(y * 3.13060547623) - Float64(Float64(y * 36.52704169880642) / z))); elseif (z <= 4.2e+28) 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 * 3.13060547623)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -270000.0) tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)); elseif (z <= 4.2e+28) tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998))); else tmp = x + (y * 3.13060547623); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -270000.0], N[(x + N[(N[(y * 3.13060547623), $MachinePrecision] - N[(N[(y * 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.2e+28], 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 * 3.13060547623), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -270000:\\
\;\;\;\;x + \left(y \cdot 3.13060547623 - \frac{y \cdot 36.52704169880642}{z}\right)\\
\mathbf{elif}\;z \leq 4.2 \cdot 10^{+28}:\\
\;\;\;\;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 3.13060547623\\
\end{array}
\end{array}
if z < -2.7e5Initial program 11.7%
Taylor expanded in z around -inf 82.9%
+-commutative82.9%
mul-1-neg82.9%
unsub-neg82.9%
*-commutative82.9%
distribute-rgt-out--82.9%
metadata-eval82.9%
Simplified82.9%
if -2.7e5 < z < 4.19999999999999978e28Initial program 99.0%
Taylor expanded in z around 0 83.5%
Taylor expanded in y around 0 94.6%
if 4.19999999999999978e28 < z Initial program 11.3%
Simplified16.3%
Taylor expanded in z around inf 87.8%
+-commutative87.8%
*-commutative87.8%
Simplified87.8%
Final simplification90.2%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -56000000.0)
(-
(+ x (+ (* y 3.13060547623) (* 11.1667541262 (/ y z))))
(* (/ y z) 47.69379582500642))
(if (<= z 4.2e+28)
(-
x
(*
y
(-
(* z (- (* b 32.324150453290734) (* a 1.6453555072203998)))
(* b 1.6453555072203998))))
(+ x (* y 3.13060547623)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -56000000.0) {
tmp = (x + ((y * 3.13060547623) + (11.1667541262 * (y / z)))) - ((y / z) * 47.69379582500642);
} else if (z <= 4.2e+28) {
tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998)));
} else {
tmp = x + (y * 3.13060547623);
}
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 <= (-56000000.0d0)) then
tmp = (x + ((y * 3.13060547623d0) + (11.1667541262d0 * (y / z)))) - ((y / z) * 47.69379582500642d0)
else if (z <= 4.2d+28) then
tmp = x - (y * ((z * ((b * 32.324150453290734d0) - (a * 1.6453555072203998d0))) - (b * 1.6453555072203998d0)))
else
tmp = x + (y * 3.13060547623d0)
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 <= -56000000.0) {
tmp = (x + ((y * 3.13060547623) + (11.1667541262 * (y / z)))) - ((y / z) * 47.69379582500642);
} else if (z <= 4.2e+28) {
tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998)));
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -56000000.0: tmp = (x + ((y * 3.13060547623) + (11.1667541262 * (y / z)))) - ((y / z) * 47.69379582500642) elif z <= 4.2e+28: tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998))) else: tmp = x + (y * 3.13060547623) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -56000000.0) tmp = Float64(Float64(x + Float64(Float64(y * 3.13060547623) + Float64(11.1667541262 * Float64(y / z)))) - Float64(Float64(y / z) * 47.69379582500642)); elseif (z <= 4.2e+28) 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 * 3.13060547623)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -56000000.0) tmp = (x + ((y * 3.13060547623) + (11.1667541262 * (y / z)))) - ((y / z) * 47.69379582500642); elseif (z <= 4.2e+28) tmp = x - (y * ((z * ((b * 32.324150453290734) - (a * 1.6453555072203998))) - (b * 1.6453555072203998))); else tmp = x + (y * 3.13060547623); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -56000000.0], N[(N[(x + N[(N[(y * 3.13060547623), $MachinePrecision] + N[(11.1667541262 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y / z), $MachinePrecision] * 47.69379582500642), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.2e+28], 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 * 3.13060547623), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -56000000:\\
\;\;\;\;\left(x + \left(y \cdot 3.13060547623 + 11.1667541262 \cdot \frac{y}{z}\right)\right) - \frac{y}{z} \cdot 47.69379582500642\\
\mathbf{elif}\;z \leq 4.2 \cdot 10^{+28}:\\
\;\;\;\;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 3.13060547623\\
\end{array}
\end{array}
if z < -5.6e7Initial program 11.7%
Simplified21.9%
Taylor expanded in z around inf 82.9%
if -5.6e7 < z < 4.19999999999999978e28Initial program 99.0%
Taylor expanded in z around 0 83.5%
Taylor expanded in y around 0 94.6%
if 4.19999999999999978e28 < z Initial program 11.3%
Simplified16.3%
Taylor expanded in z around inf 87.8%
+-commutative87.8%
*-commutative87.8%
Simplified87.8%
Final simplification90.2%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -120000.0)
(+ x (- (* y 3.13060547623) (/ (* y 36.52704169880642) z)))
(if (<= z 3.4e+29)
(+
x
(+ (* (* y b) 1.6453555072203998) (* z (* 1.6453555072203998 (* y a)))))
(+ x (* y 3.13060547623)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -120000.0) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 3.4e+29) {
tmp = x + (((y * b) * 1.6453555072203998) + (z * (1.6453555072203998 * (y * a))));
} else {
tmp = x + (y * 3.13060547623);
}
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 <= (-120000.0d0)) then
tmp = x + ((y * 3.13060547623d0) - ((y * 36.52704169880642d0) / z))
else if (z <= 3.4d+29) then
tmp = x + (((y * b) * 1.6453555072203998d0) + (z * (1.6453555072203998d0 * (y * a))))
else
tmp = x + (y * 3.13060547623d0)
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 <= -120000.0) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 3.4e+29) {
tmp = x + (((y * b) * 1.6453555072203998) + (z * (1.6453555072203998 * (y * a))));
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -120000.0: tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)) elif z <= 3.4e+29: tmp = x + (((y * b) * 1.6453555072203998) + (z * (1.6453555072203998 * (y * a)))) else: tmp = x + (y * 3.13060547623) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -120000.0) tmp = Float64(x + Float64(Float64(y * 3.13060547623) - Float64(Float64(y * 36.52704169880642) / z))); elseif (z <= 3.4e+29) tmp = Float64(x + Float64(Float64(Float64(y * b) * 1.6453555072203998) + Float64(z * Float64(1.6453555072203998 * Float64(y * a))))); else tmp = Float64(x + Float64(y * 3.13060547623)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -120000.0) tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)); elseif (z <= 3.4e+29) tmp = x + (((y * b) * 1.6453555072203998) + (z * (1.6453555072203998 * (y * a)))); else tmp = x + (y * 3.13060547623); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -120000.0], N[(x + N[(N[(y * 3.13060547623), $MachinePrecision] - N[(N[(y * 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.4e+29], N[(x + N[(N[(N[(y * b), $MachinePrecision] * 1.6453555072203998), $MachinePrecision] + N[(z * N[(1.6453555072203998 * N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -120000:\\
\;\;\;\;x + \left(y \cdot 3.13060547623 - \frac{y \cdot 36.52704169880642}{z}\right)\\
\mathbf{elif}\;z \leq 3.4 \cdot 10^{+29}:\\
\;\;\;\;x + \left(\left(y \cdot b\right) \cdot 1.6453555072203998 + z \cdot \left(1.6453555072203998 \cdot \left(y \cdot a\right)\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\end{array}
\end{array}
if z < -1.2e5Initial program 11.7%
Taylor expanded in z around -inf 82.9%
+-commutative82.9%
mul-1-neg82.9%
unsub-neg82.9%
*-commutative82.9%
distribute-rgt-out--82.9%
metadata-eval82.9%
Simplified82.9%
if -1.2e5 < z < 3.39999999999999981e29Initial program 99.0%
Taylor expanded in z around 0 83.5%
Taylor expanded in a around inf 86.3%
if 3.39999999999999981e29 < z Initial program 11.3%
Simplified16.3%
Taylor expanded in z around inf 87.8%
+-commutative87.8%
*-commutative87.8%
Simplified87.8%
Final simplification85.8%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -75000.0)
(+ x (- (* y 3.13060547623) (/ (* y 36.52704169880642) z)))
(if (<= z 4.8e+30)
(+
x
(+ (* (* a (* y z)) 1.6453555072203998) (* (* y b) 1.6453555072203998)))
(+ x (* y 3.13060547623)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -75000.0) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 4.8e+30) {
tmp = x + (((a * (y * z)) * 1.6453555072203998) + ((y * b) * 1.6453555072203998));
} else {
tmp = x + (y * 3.13060547623);
}
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 <= (-75000.0d0)) then
tmp = x + ((y * 3.13060547623d0) - ((y * 36.52704169880642d0) / z))
else if (z <= 4.8d+30) then
tmp = x + (((a * (y * z)) * 1.6453555072203998d0) + ((y * b) * 1.6453555072203998d0))
else
tmp = x + (y * 3.13060547623d0)
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 <= -75000.0) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 4.8e+30) {
tmp = x + (((a * (y * z)) * 1.6453555072203998) + ((y * b) * 1.6453555072203998));
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -75000.0: tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)) elif z <= 4.8e+30: tmp = x + (((a * (y * z)) * 1.6453555072203998) + ((y * b) * 1.6453555072203998)) else: tmp = x + (y * 3.13060547623) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -75000.0) tmp = Float64(x + Float64(Float64(y * 3.13060547623) - Float64(Float64(y * 36.52704169880642) / z))); elseif (z <= 4.8e+30) tmp = Float64(x + Float64(Float64(Float64(a * Float64(y * z)) * 1.6453555072203998) + Float64(Float64(y * b) * 1.6453555072203998))); else tmp = Float64(x + Float64(y * 3.13060547623)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -75000.0) tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)); elseif (z <= 4.8e+30) tmp = x + (((a * (y * z)) * 1.6453555072203998) + ((y * b) * 1.6453555072203998)); else tmp = x + (y * 3.13060547623); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -75000.0], N[(x + N[(N[(y * 3.13060547623), $MachinePrecision] - N[(N[(y * 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.8e+30], N[(x + N[(N[(N[(a * N[(y * z), $MachinePrecision]), $MachinePrecision] * 1.6453555072203998), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -75000:\\
\;\;\;\;x + \left(y \cdot 3.13060547623 - \frac{y \cdot 36.52704169880642}{z}\right)\\
\mathbf{elif}\;z \leq 4.8 \cdot 10^{+30}:\\
\;\;\;\;x + \left(\left(a \cdot \left(y \cdot z\right)\right) \cdot 1.6453555072203998 + \left(y \cdot b\right) \cdot 1.6453555072203998\right)\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\end{array}
\end{array}
if z < -75000Initial program 11.7%
Taylor expanded in z around -inf 82.9%
+-commutative82.9%
mul-1-neg82.9%
unsub-neg82.9%
*-commutative82.9%
distribute-rgt-out--82.9%
metadata-eval82.9%
Simplified82.9%
if -75000 < z < 4.7999999999999999e30Initial program 99.0%
Taylor expanded in z around 0 83.5%
Taylor expanded in a around inf 94.6%
*-commutative94.6%
Simplified94.6%
if 4.7999999999999999e30 < z Initial program 11.3%
Simplified16.3%
Taylor expanded in z around inf 87.8%
+-commutative87.8%
*-commutative87.8%
Simplified87.8%
Final simplification90.2%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -1.96)
(+ x (- (* y 3.13060547623) (/ (* y 36.52704169880642) z)))
(if (<= z 9.5e-15)
(+ x (* b (+ (* (* y z) -32.324150453290734) (* y 1.6453555072203998))))
(+ x (* y 3.13060547623)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.96) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 9.5e-15) {
tmp = x + (b * (((y * z) * -32.324150453290734) + (y * 1.6453555072203998)));
} else {
tmp = x + (y * 3.13060547623);
}
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.96d0)) then
tmp = x + ((y * 3.13060547623d0) - ((y * 36.52704169880642d0) / z))
else if (z <= 9.5d-15) then
tmp = x + (b * (((y * z) * (-32.324150453290734d0)) + (y * 1.6453555072203998d0)))
else
tmp = x + (y * 3.13060547623d0)
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.96) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 9.5e-15) {
tmp = x + (b * (((y * z) * -32.324150453290734) + (y * 1.6453555072203998)));
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -1.96: tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)) elif z <= 9.5e-15: tmp = x + (b * (((y * z) * -32.324150453290734) + (y * 1.6453555072203998))) else: tmp = x + (y * 3.13060547623) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -1.96) tmp = Float64(x + Float64(Float64(y * 3.13060547623) - Float64(Float64(y * 36.52704169880642) / z))); elseif (z <= 9.5e-15) tmp = Float64(x + Float64(b * Float64(Float64(Float64(y * z) * -32.324150453290734) + Float64(y * 1.6453555072203998)))); else tmp = Float64(x + Float64(y * 3.13060547623)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -1.96) tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)); elseif (z <= 9.5e-15) tmp = x + (b * (((y * z) * -32.324150453290734) + (y * 1.6453555072203998))); else tmp = x + (y * 3.13060547623); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -1.96], N[(x + N[(N[(y * 3.13060547623), $MachinePrecision] - N[(N[(y * 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9.5e-15], N[(x + N[(b * N[(N[(N[(y * z), $MachinePrecision] * -32.324150453290734), $MachinePrecision] + N[(y * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.96:\\
\;\;\;\;x + \left(y \cdot 3.13060547623 - \frac{y \cdot 36.52704169880642}{z}\right)\\
\mathbf{elif}\;z \leq 9.5 \cdot 10^{-15}:\\
\;\;\;\;x + b \cdot \left(\left(y \cdot z\right) \cdot -32.324150453290734 + y \cdot 1.6453555072203998\right)\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\end{array}
\end{array}
if z < -1.96Initial program 11.7%
Taylor expanded in z around -inf 82.9%
+-commutative82.9%
mul-1-neg82.9%
unsub-neg82.9%
*-commutative82.9%
distribute-rgt-out--82.9%
metadata-eval82.9%
Simplified82.9%
if -1.96 < z < 9.5000000000000005e-15Initial program 99.6%
Taylor expanded in z around 0 84.8%
Taylor expanded in b around inf 86.5%
if 9.5000000000000005e-15 < z Initial program 19.8%
Simplified25.7%
Taylor expanded in z around inf 84.5%
+-commutative84.5%
*-commutative84.5%
Simplified84.5%
Final simplification85.1%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -6000000.0) (not (<= z 2.8e+18))) (+ x (* y 3.13060547623)) (+ x (* b (* y 1.6453555072203998)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -6000000.0) || !(z <= 2.8e+18)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + (b * (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 <= (-6000000.0d0)) .or. (.not. (z <= 2.8d+18))) then
tmp = x + (y * 3.13060547623d0)
else
tmp = x + (b * (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 <= -6000000.0) || !(z <= 2.8e+18)) {
tmp = x + (y * 3.13060547623);
} else {
tmp = x + (b * (y * 1.6453555072203998));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -6000000.0) or not (z <= 2.8e+18): tmp = x + (y * 3.13060547623) else: tmp = x + (b * (y * 1.6453555072203998)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -6000000.0) || !(z <= 2.8e+18)) tmp = Float64(x + Float64(y * 3.13060547623)); else tmp = Float64(x + Float64(b * Float64(y * 1.6453555072203998))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -6000000.0) || ~((z <= 2.8e+18))) tmp = x + (y * 3.13060547623); else tmp = x + (b * (y * 1.6453555072203998)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -6000000.0], N[Not[LessEqual[z, 2.8e+18]], $MachinePrecision]], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision], N[(x + N[(b * N[(y * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6000000 \lor \neg \left(z \leq 2.8 \cdot 10^{+18}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + b \cdot \left(y \cdot 1.6453555072203998\right)\\
\end{array}
\end{array}
if z < -6e6 or 2.8e18 < z Initial program 12.9%
Simplified20.7%
Taylor expanded in z around inf 84.3%
+-commutative84.3%
*-commutative84.3%
Simplified84.3%
if -6e6 < z < 2.8e18Initial program 99.0%
Taylor expanded in z around 0 95.2%
Taylor expanded in z around 0 85.5%
*-commutative85.5%
*-commutative85.5%
*-commutative85.5%
associate-*r*85.6%
Simplified85.6%
Final simplification85.0%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -64000.0) (not (<= z 3.3e+18))) (+ 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 <= -64000.0) || !(z <= 3.3e+18)) {
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 <= (-64000.0d0)) .or. (.not. (z <= 3.3d+18))) 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 <= -64000.0) || !(z <= 3.3e+18)) {
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 <= -64000.0) or not (z <= 3.3e+18): 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 <= -64000.0) || !(z <= 3.3e+18)) 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 <= -64000.0) || ~((z <= 3.3e+18))) 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, -64000.0], N[Not[LessEqual[z, 3.3e+18]], $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 -64000 \lor \neg \left(z \leq 3.3 \cdot 10^{+18}\right):\\
\;\;\;\;x + y \cdot 3.13060547623\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \left(b \cdot 1.6453555072203998\right)\\
\end{array}
\end{array}
if z < -64000 or 3.3e18 < z Initial program 12.9%
Simplified20.7%
Taylor expanded in z around inf 84.3%
+-commutative84.3%
*-commutative84.3%
Simplified84.3%
if -64000 < z < 3.3e18Initial program 99.0%
Taylor expanded in z around 0 85.5%
associate-*r*85.6%
*-commutative85.6%
Simplified85.6%
Final simplification85.0%
(FPCore (x y z t a b)
:precision binary64
(if (<= z -6.8)
(+ x (- (* y 3.13060547623) (/ (* y 36.52704169880642) z)))
(if (<= z 2.8e+18)
(+ x (* y (* b 1.6453555072203998)))
(+ x (* y 3.13060547623)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -6.8) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 2.8e+18) {
tmp = x + (y * (b * 1.6453555072203998));
} else {
tmp = x + (y * 3.13060547623);
}
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.8d0)) then
tmp = x + ((y * 3.13060547623d0) - ((y * 36.52704169880642d0) / z))
else if (z <= 2.8d+18) then
tmp = x + (y * (b * 1.6453555072203998d0))
else
tmp = x + (y * 3.13060547623d0)
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.8) {
tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z));
} else if (z <= 2.8e+18) {
tmp = x + (y * (b * 1.6453555072203998));
} else {
tmp = x + (y * 3.13060547623);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -6.8: tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)) elif z <= 2.8e+18: tmp = x + (y * (b * 1.6453555072203998)) else: tmp = x + (y * 3.13060547623) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -6.8) tmp = Float64(x + Float64(Float64(y * 3.13060547623) - Float64(Float64(y * 36.52704169880642) / z))); elseif (z <= 2.8e+18) tmp = Float64(x + Float64(y * Float64(b * 1.6453555072203998))); else tmp = Float64(x + Float64(y * 3.13060547623)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -6.8) tmp = x + ((y * 3.13060547623) - ((y * 36.52704169880642) / z)); elseif (z <= 2.8e+18) tmp = x + (y * (b * 1.6453555072203998)); else tmp = x + (y * 3.13060547623); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -6.8], N[(x + N[(N[(y * 3.13060547623), $MachinePrecision] - N[(N[(y * 36.52704169880642), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.8e+18], N[(x + N[(y * N[(b * 1.6453555072203998), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * 3.13060547623), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.8:\\
\;\;\;\;x + \left(y \cdot 3.13060547623 - \frac{y \cdot 36.52704169880642}{z}\right)\\
\mathbf{elif}\;z \leq 2.8 \cdot 10^{+18}:\\
\;\;\;\;x + y \cdot \left(b \cdot 1.6453555072203998\right)\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot 3.13060547623\\
\end{array}
\end{array}
if z < -6.79999999999999982Initial program 11.7%
Taylor expanded in z around -inf 82.9%
+-commutative82.9%
mul-1-neg82.9%
unsub-neg82.9%
*-commutative82.9%
distribute-rgt-out--82.9%
metadata-eval82.9%
Simplified82.9%
if -6.79999999999999982 < z < 2.8e18Initial program 99.0%
Taylor expanded in z around 0 85.5%
associate-*r*85.6%
*-commutative85.6%
Simplified85.6%
if 2.8e18 < z Initial program 14.4%
Simplified19.2%
Taylor expanded in z around inf 86.5%
+-commutative86.5%
*-commutative86.5%
Simplified86.5%
Final simplification85.1%
(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 58.3%
Simplified62.3%
Taylor expanded in z around inf 61.4%
+-commutative61.4%
*-commutative61.4%
Simplified61.4%
Final simplification61.4%
(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 58.3%
Simplified62.3%
Taylor expanded in y around 0 45.6%
Final simplification45.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 2024079
(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))))