
(FPCore (x y z t a b c) :precision binary64 (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)))
double code(double x, double y, double z, double t, double a, double b, double c) {
return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
real(8) function code(x, y, z, t, a, b, c)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
code = ((((x * 9.0d0) * y) - (((z * 4.0d0) * t) * a)) + b) / (z * c)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
def code(x, y, z, t, a, b, c): return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c)
function code(x, y, z, t, a, b, c) return Float64(Float64(Float64(Float64(Float64(x * 9.0) * y) - Float64(Float64(Float64(z * 4.0) * t) * a)) + b) / Float64(z * c)) end
function tmp = code(x, y, z, t, a, b, c) tmp = ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c); end
code[x_, y_, z_, t_, a_, b_, c_] := N[(N[(N[(N[(N[(x * 9.0), $MachinePrecision] * y), $MachinePrecision] - N[(N[(N[(z * 4.0), $MachinePrecision] * t), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 13 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c) :precision binary64 (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)))
double code(double x, double y, double z, double t, double a, double b, double c) {
return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
real(8) function code(x, y, z, t, a, b, c)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
code = ((((x * 9.0d0) * y) - (((z * 4.0d0) * t) * a)) + b) / (z * c)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
def code(x, y, z, t, a, b, c): return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c)
function code(x, y, z, t, a, b, c) return Float64(Float64(Float64(Float64(Float64(x * 9.0) * y) - Float64(Float64(Float64(z * 4.0) * t) * a)) + b) / Float64(z * c)) end
function tmp = code(x, y, z, t, a, b, c) tmp = ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c); end
code[x_, y_, z_, t_, a_, b_, c_] := N[(N[(N[(N[(N[(x * 9.0), $MachinePrecision] * y), $MachinePrecision] - N[(N[(N[(z * 4.0), $MachinePrecision] * t), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c}
\end{array}
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (<= c_m 9.8e+129)
(/ (- (+ (* 9.0 (/ (* x y) z)) (/ b z)) (* 4.0 (* a t))) c_m)
(*
b
(+
(/ (fma -4.0 (* a (/ t c_m)) (* (* x (/ y c_m)) (/ 9.0 z))) b)
(/ (/ 1.0 c_m) z))))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if (c_m <= 9.8e+129) {
tmp = (((9.0 * ((x * y) / z)) + (b / z)) - (4.0 * (a * t))) / c_m;
} else {
tmp = b * ((fma(-4.0, (a * (t / c_m)), ((x * (y / c_m)) * (9.0 / z))) / b) + ((1.0 / c_m) / z));
}
return c_s * tmp;
}
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if (c_m <= 9.8e+129) tmp = Float64(Float64(Float64(Float64(9.0 * Float64(Float64(x * y) / z)) + Float64(b / z)) - Float64(4.0 * Float64(a * t))) / c_m); else tmp = Float64(b * Float64(Float64(fma(-4.0, Float64(a * Float64(t / c_m)), Float64(Float64(x * Float64(y / c_m)) * Float64(9.0 / z))) / b) + Float64(Float64(1.0 / c_m) / z))); end return Float64(c_s * tmp) end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[LessEqual[c$95$m, 9.8e+129], N[(N[(N[(N[(9.0 * N[(N[(x * y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] + N[(b / z), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c$95$m), $MachinePrecision], N[(b * N[(N[(N[(-4.0 * N[(a * N[(t / c$95$m), $MachinePrecision]), $MachinePrecision] + N[(N[(x * N[(y / c$95$m), $MachinePrecision]), $MachinePrecision] * N[(9.0 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision] + N[(N[(1.0 / c$95$m), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;c\_m \leq 9.8 \cdot 10^{+129}:\\
\;\;\;\;\frac{\left(9 \cdot \frac{x \cdot y}{z} + \frac{b}{z}\right) - 4 \cdot \left(a \cdot t\right)}{c\_m}\\
\mathbf{else}:\\
\;\;\;\;b \cdot \left(\frac{\mathsf{fma}\left(-4, a \cdot \frac{t}{c\_m}, \left(x \cdot \frac{y}{c\_m}\right) \cdot \frac{9}{z}\right)}{b} + \frac{\frac{1}{c\_m}}{z}\right)\\
\end{array}
\end{array}
if c < 9.8e129Initial program 84.1%
associate-+l-84.1%
*-commutative84.1%
associate-*r*81.2%
*-commutative81.2%
associate-+l-81.2%
associate-*l*81.2%
associate-*l*84.7%
*-commutative84.7%
Simplified84.7%
Taylor expanded in x around 0 81.1%
Taylor expanded in c around 0 88.8%
if 9.8e129 < c Initial program 54.7%
associate-+l-54.7%
*-commutative54.7%
associate-*r*54.8%
*-commutative54.8%
associate-+l-54.8%
Simplified54.8%
Taylor expanded in b around inf 56.9%
Simplified92.3%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(let* ((t_1 (* -4.0 (* a (/ t c_m)))))
(*
c_s
(if (<= t -4.2e+210)
t_1
(if (<= t -7.8e+186)
(/ (+ b (* y (* 9.0 x))) (* c_m z))
(if (<= t -3.6e+118)
(* -4.0 (* a (* t (/ 1.0 c_m))))
(if (<= t 2.8e-14) (/ (+ b (* x (* 9.0 y))) (* c_m z)) t_1)))))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double t_1 = -4.0 * (a * (t / c_m));
double tmp;
if (t <= -4.2e+210) {
tmp = t_1;
} else if (t <= -7.8e+186) {
tmp = (b + (y * (9.0 * x))) / (c_m * z);
} else if (t <= -3.6e+118) {
tmp = -4.0 * (a * (t * (1.0 / c_m)));
} else if (t <= 2.8e-14) {
tmp = (b + (x * (9.0 * y))) / (c_m * z);
} else {
tmp = t_1;
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: t_1
real(8) :: tmp
t_1 = (-4.0d0) * (a * (t / c_m))
if (t <= (-4.2d+210)) then
tmp = t_1
else if (t <= (-7.8d+186)) then
tmp = (b + (y * (9.0d0 * x))) / (c_m * z)
else if (t <= (-3.6d+118)) then
tmp = (-4.0d0) * (a * (t * (1.0d0 / c_m)))
else if (t <= 2.8d-14) then
tmp = (b + (x * (9.0d0 * y))) / (c_m * z)
else
tmp = t_1
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double t_1 = -4.0 * (a * (t / c_m));
double tmp;
if (t <= -4.2e+210) {
tmp = t_1;
} else if (t <= -7.8e+186) {
tmp = (b + (y * (9.0 * x))) / (c_m * z);
} else if (t <= -3.6e+118) {
tmp = -4.0 * (a * (t * (1.0 / c_m)));
} else if (t <= 2.8e-14) {
tmp = (b + (x * (9.0 * y))) / (c_m * z);
} else {
tmp = t_1;
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): t_1 = -4.0 * (a * (t / c_m)) tmp = 0 if t <= -4.2e+210: tmp = t_1 elif t <= -7.8e+186: tmp = (b + (y * (9.0 * x))) / (c_m * z) elif t <= -3.6e+118: tmp = -4.0 * (a * (t * (1.0 / c_m))) elif t <= 2.8e-14: tmp = (b + (x * (9.0 * y))) / (c_m * z) else: tmp = t_1 return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) t_1 = Float64(-4.0 * Float64(a * Float64(t / c_m))) tmp = 0.0 if (t <= -4.2e+210) tmp = t_1; elseif (t <= -7.8e+186) tmp = Float64(Float64(b + Float64(y * Float64(9.0 * x))) / Float64(c_m * z)); elseif (t <= -3.6e+118) tmp = Float64(-4.0 * Float64(a * Float64(t * Float64(1.0 / c_m)))); elseif (t <= 2.8e-14) tmp = Float64(Float64(b + Float64(x * Float64(9.0 * y))) / Float64(c_m * z)); else tmp = t_1; end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
t_1 = -4.0 * (a * (t / c_m));
tmp = 0.0;
if (t <= -4.2e+210)
tmp = t_1;
elseif (t <= -7.8e+186)
tmp = (b + (y * (9.0 * x))) / (c_m * z);
elseif (t <= -3.6e+118)
tmp = -4.0 * (a * (t * (1.0 / c_m)));
elseif (t <= 2.8e-14)
tmp = (b + (x * (9.0 * y))) / (c_m * z);
else
tmp = t_1;
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := Block[{t$95$1 = N[(-4.0 * N[(a * N[(t / c$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, N[(c$95$s * If[LessEqual[t, -4.2e+210], t$95$1, If[LessEqual[t, -7.8e+186], N[(N[(b + N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(c$95$m * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -3.6e+118], N[(-4.0 * N[(a * N[(t * N[(1.0 / c$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.8e-14], N[(N[(b + N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(c$95$m * z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]), $MachinePrecision]]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
\begin{array}{l}
t_1 := -4 \cdot \left(a \cdot \frac{t}{c\_m}\right)\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;t \leq -4.2 \cdot 10^{+210}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -7.8 \cdot 10^{+186}:\\
\;\;\;\;\frac{b + y \cdot \left(9 \cdot x\right)}{c\_m \cdot z}\\
\mathbf{elif}\;t \leq -3.6 \cdot 10^{+118}:\\
\;\;\;\;-4 \cdot \left(a \cdot \left(t \cdot \frac{1}{c\_m}\right)\right)\\
\mathbf{elif}\;t \leq 2.8 \cdot 10^{-14}:\\
\;\;\;\;\frac{b + x \cdot \left(9 \cdot y\right)}{c\_m \cdot z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
\end{array}
if t < -4.1999999999999997e210 or 2.8000000000000001e-14 < t Initial program 75.6%
associate-+l-75.6%
*-commutative75.6%
associate-*r*76.7%
*-commutative76.7%
associate-+l-76.7%
associate-*l*76.7%
associate-*l*75.7%
*-commutative75.7%
Simplified75.7%
Taylor expanded in x around 0 76.9%
Taylor expanded in z around inf 64.6%
associate-*r/70.1%
Simplified70.1%
if -4.1999999999999997e210 < t < -7.8000000000000002e186Initial program 82.6%
associate-+l-82.6%
*-commutative82.6%
associate-*r*82.6%
*-commutative82.6%
associate-+l-82.6%
Simplified82.6%
Taylor expanded in t around 0 74.3%
+-commutative74.3%
associate-*r*74.5%
*-commutative74.5%
Simplified74.5%
if -7.8000000000000002e186 < t < -3.6e118Initial program 54.8%
associate-+l-54.8%
*-commutative54.8%
associate-*r*73.4%
*-commutative73.4%
associate-+l-73.4%
associate-*l*73.4%
associate-*l*73.4%
*-commutative73.4%
Simplified73.4%
Taylor expanded in x around 0 88.4%
Taylor expanded in z around inf 71.2%
associate-*r/79.6%
Simplified79.6%
div-inv79.9%
Applied egg-rr79.9%
if -3.6e118 < t < 2.8000000000000001e-14Initial program 84.2%
associate-+l-84.2%
*-commutative84.2%
associate-*r*77.4%
*-commutative77.4%
associate-+l-77.4%
associate-*l*77.4%
associate-*l*84.5%
*-commutative84.5%
Simplified84.5%
Taylor expanded in z around inf 81.1%
Taylor expanded in z around 0 66.7%
associate-*r*66.8%
*-commutative66.8%
associate-*r*66.8%
Simplified66.8%
Final simplification68.9%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(let* ((t_1 (/ (+ b (* x (* 9.0 y))) (* c_m z)))
(t_2 (* -4.0 (* a (/ t c_m)))))
(*
c_s
(if (<= t -2.3e+210)
t_2
(if (<= t -6.2e+186)
t_1
(if (<= t -3.4e+112)
(* -4.0 (* a (* t (/ 1.0 c_m))))
(if (<= t 2.6e-13) t_1 t_2)))))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double t_1 = (b + (x * (9.0 * y))) / (c_m * z);
double t_2 = -4.0 * (a * (t / c_m));
double tmp;
if (t <= -2.3e+210) {
tmp = t_2;
} else if (t <= -6.2e+186) {
tmp = t_1;
} else if (t <= -3.4e+112) {
tmp = -4.0 * (a * (t * (1.0 / c_m)));
} else if (t <= 2.6e-13) {
tmp = t_1;
} else {
tmp = t_2;
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = (b + (x * (9.0d0 * y))) / (c_m * z)
t_2 = (-4.0d0) * (a * (t / c_m))
if (t <= (-2.3d+210)) then
tmp = t_2
else if (t <= (-6.2d+186)) then
tmp = t_1
else if (t <= (-3.4d+112)) then
tmp = (-4.0d0) * (a * (t * (1.0d0 / c_m)))
else if (t <= 2.6d-13) then
tmp = t_1
else
tmp = t_2
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double t_1 = (b + (x * (9.0 * y))) / (c_m * z);
double t_2 = -4.0 * (a * (t / c_m));
double tmp;
if (t <= -2.3e+210) {
tmp = t_2;
} else if (t <= -6.2e+186) {
tmp = t_1;
} else if (t <= -3.4e+112) {
tmp = -4.0 * (a * (t * (1.0 / c_m)));
} else if (t <= 2.6e-13) {
tmp = t_1;
} else {
tmp = t_2;
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): t_1 = (b + (x * (9.0 * y))) / (c_m * z) t_2 = -4.0 * (a * (t / c_m)) tmp = 0 if t <= -2.3e+210: tmp = t_2 elif t <= -6.2e+186: tmp = t_1 elif t <= -3.4e+112: tmp = -4.0 * (a * (t * (1.0 / c_m))) elif t <= 2.6e-13: tmp = t_1 else: tmp = t_2 return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) t_1 = Float64(Float64(b + Float64(x * Float64(9.0 * y))) / Float64(c_m * z)) t_2 = Float64(-4.0 * Float64(a * Float64(t / c_m))) tmp = 0.0 if (t <= -2.3e+210) tmp = t_2; elseif (t <= -6.2e+186) tmp = t_1; elseif (t <= -3.4e+112) tmp = Float64(-4.0 * Float64(a * Float64(t * Float64(1.0 / c_m)))); elseif (t <= 2.6e-13) tmp = t_1; else tmp = t_2; end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
t_1 = (b + (x * (9.0 * y))) / (c_m * z);
t_2 = -4.0 * (a * (t / c_m));
tmp = 0.0;
if (t <= -2.3e+210)
tmp = t_2;
elseif (t <= -6.2e+186)
tmp = t_1;
elseif (t <= -3.4e+112)
tmp = -4.0 * (a * (t * (1.0 / c_m)));
elseif (t <= 2.6e-13)
tmp = t_1;
else
tmp = t_2;
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := Block[{t$95$1 = N[(N[(b + N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(c$95$m * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(-4.0 * N[(a * N[(t / c$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, N[(c$95$s * If[LessEqual[t, -2.3e+210], t$95$2, If[LessEqual[t, -6.2e+186], t$95$1, If[LessEqual[t, -3.4e+112], N[(-4.0 * N[(a * N[(t * N[(1.0 / c$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.6e-13], t$95$1, t$95$2]]]]), $MachinePrecision]]]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
\begin{array}{l}
t_1 := \frac{b + x \cdot \left(9 \cdot y\right)}{c\_m \cdot z}\\
t_2 := -4 \cdot \left(a \cdot \frac{t}{c\_m}\right)\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;t \leq -2.3 \cdot 10^{+210}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -6.2 \cdot 10^{+186}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -3.4 \cdot 10^{+112}:\\
\;\;\;\;-4 \cdot \left(a \cdot \left(t \cdot \frac{1}{c\_m}\right)\right)\\
\mathbf{elif}\;t \leq 2.6 \cdot 10^{-13}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
\end{array}
if t < -2.2999999999999999e210 or 2.6e-13 < t Initial program 75.6%
associate-+l-75.6%
*-commutative75.6%
associate-*r*76.7%
*-commutative76.7%
associate-+l-76.7%
associate-*l*76.7%
associate-*l*75.7%
*-commutative75.7%
Simplified75.7%
Taylor expanded in x around 0 76.9%
Taylor expanded in z around inf 64.6%
associate-*r/70.1%
Simplified70.1%
if -2.2999999999999999e210 < t < -6.2000000000000002e186 or -3.39999999999999993e112 < t < 2.6e-13Initial program 84.1%
associate-+l-84.1%
*-commutative84.1%
associate-*r*77.8%
*-commutative77.8%
associate-+l-77.8%
associate-*l*77.8%
associate-*l*83.0%
*-commutative83.0%
Simplified83.0%
Taylor expanded in z around inf 79.8%
Taylor expanded in z around 0 67.3%
associate-*r*67.3%
*-commutative67.3%
associate-*r*67.3%
Simplified67.3%
if -6.2000000000000002e186 < t < -3.39999999999999993e112Initial program 54.8%
associate-+l-54.8%
*-commutative54.8%
associate-*r*73.4%
*-commutative73.4%
associate-+l-73.4%
associate-*l*73.4%
associate-*l*73.4%
*-commutative73.4%
Simplified73.4%
Taylor expanded in x around 0 88.4%
Taylor expanded in z around inf 71.2%
associate-*r/79.6%
Simplified79.6%
div-inv79.9%
Applied egg-rr79.9%
Final simplification68.9%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (or (<= z -9e+79) (not (<= z 2e-12)))
(/ (- (+ (* 9.0 (/ (* x y) z)) (/ b z)) (* 4.0 (* a t))) c_m)
(/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* c_m z)))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -9e+79) || !(z <= 2e-12)) {
tmp = (((9.0 * ((x * y) / z)) + (b / z)) - (4.0 * (a * t))) / c_m;
} else {
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (c_m * z);
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: tmp
if ((z <= (-9d+79)) .or. (.not. (z <= 2d-12))) then
tmp = (((9.0d0 * ((x * y) / z)) + (b / z)) - (4.0d0 * (a * t))) / c_m
else
tmp = (b + ((y * (9.0d0 * x)) - (a * (t * (z * 4.0d0))))) / (c_m * z)
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -9e+79) || !(z <= 2e-12)) {
tmp = (((9.0 * ((x * y) / z)) + (b / z)) - (4.0 * (a * t))) / c_m;
} else {
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (c_m * z);
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): tmp = 0 if (z <= -9e+79) or not (z <= 2e-12): tmp = (((9.0 * ((x * y) / z)) + (b / z)) - (4.0 * (a * t))) / c_m else: tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (c_m * z) return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if ((z <= -9e+79) || !(z <= 2e-12)) tmp = Float64(Float64(Float64(Float64(9.0 * Float64(Float64(x * y) / z)) + Float64(b / z)) - Float64(4.0 * Float64(a * t))) / c_m); else tmp = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(c_m * z)); end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
tmp = 0.0;
if ((z <= -9e+79) || ~((z <= 2e-12)))
tmp = (((9.0 * ((x * y) / z)) + (b / z)) - (4.0 * (a * t))) / c_m;
else
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (c_m * z);
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[Or[LessEqual[z, -9e+79], N[Not[LessEqual[z, 2e-12]], $MachinePrecision]], N[(N[(N[(N[(9.0 * N[(N[(x * y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] + N[(b / z), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c$95$m), $MachinePrecision], N[(N[(b + N[(N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * N[(t * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(c$95$m * z), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;z \leq -9 \cdot 10^{+79} \lor \neg \left(z \leq 2 \cdot 10^{-12}\right):\\
\;\;\;\;\frac{\left(9 \cdot \frac{x \cdot y}{z} + \frac{b}{z}\right) - 4 \cdot \left(a \cdot t\right)}{c\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{c\_m \cdot z}\\
\end{array}
\end{array}
if z < -8.99999999999999987e79 or 1.99999999999999996e-12 < z Initial program 59.1%
associate-+l-59.1%
*-commutative59.1%
associate-*r*53.9%
*-commutative53.9%
associate-+l-53.9%
associate-*l*53.9%
associate-*l*63.0%
*-commutative63.0%
Simplified63.0%
Taylor expanded in x around 0 77.6%
Taylor expanded in c around 0 88.0%
if -8.99999999999999987e79 < z < 1.99999999999999996e-12Initial program 94.1%
Final simplification91.6%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (or (<= z -2.3e+80) (not (<= z 1.82e+174)))
(/ (- (/ b z) (* a (* 4.0 t))) c_m)
(/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* c_m z)))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -2.3e+80) || !(z <= 1.82e+174)) {
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
} else {
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (c_m * z);
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: tmp
if ((z <= (-2.3d+80)) .or. (.not. (z <= 1.82d+174))) then
tmp = ((b / z) - (a * (4.0d0 * t))) / c_m
else
tmp = (b + ((y * (9.0d0 * x)) - (a * (t * (z * 4.0d0))))) / (c_m * z)
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -2.3e+80) || !(z <= 1.82e+174)) {
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
} else {
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (c_m * z);
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): tmp = 0 if (z <= -2.3e+80) or not (z <= 1.82e+174): tmp = ((b / z) - (a * (4.0 * t))) / c_m else: tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (c_m * z) return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if ((z <= -2.3e+80) || !(z <= 1.82e+174)) tmp = Float64(Float64(Float64(b / z) - Float64(a * Float64(4.0 * t))) / c_m); else tmp = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(c_m * z)); end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
tmp = 0.0;
if ((z <= -2.3e+80) || ~((z <= 1.82e+174)))
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
else
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (c_m * z);
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[Or[LessEqual[z, -2.3e+80], N[Not[LessEqual[z, 1.82e+174]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] - N[(a * N[(4.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c$95$m), $MachinePrecision], N[(N[(b + N[(N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * N[(t * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(c$95$m * z), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;z \leq -2.3 \cdot 10^{+80} \lor \neg \left(z \leq 1.82 \cdot 10^{+174}\right):\\
\;\;\;\;\frac{\frac{b}{z} - a \cdot \left(4 \cdot t\right)}{c\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{c\_m \cdot z}\\
\end{array}
\end{array}
if z < -2.30000000000000004e80 or 1.8199999999999999e174 < z Initial program 47.5%
associate-+l-47.5%
*-commutative47.5%
associate-*r*39.8%
*-commutative39.8%
associate-+l-39.8%
associate-*l*39.8%
associate-*l*53.1%
*-commutative53.1%
Simplified53.1%
Taylor expanded in x around 0 76.8%
Taylor expanded in c around 0 86.6%
Taylor expanded in x around 0 80.8%
associate-*r*80.8%
*-commutative80.8%
associate-*r*80.8%
Simplified80.8%
if -2.30000000000000004e80 < z < 1.8199999999999999e174Initial program 92.5%
Final simplification89.1%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (or (<= z -5.8e+127) (not (<= z 2.95e+174)))
(/ (- (/ b z) (* a (* 4.0 t))) c_m)
(/ (+ b (- (* x (* 9.0 y)) (* (* a t) (* z 4.0)))) (* c_m z)))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -5.8e+127) || !(z <= 2.95e+174)) {
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
} else {
tmp = (b + ((x * (9.0 * y)) - ((a * t) * (z * 4.0)))) / (c_m * z);
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: tmp
if ((z <= (-5.8d+127)) .or. (.not. (z <= 2.95d+174))) then
tmp = ((b / z) - (a * (4.0d0 * t))) / c_m
else
tmp = (b + ((x * (9.0d0 * y)) - ((a * t) * (z * 4.0d0)))) / (c_m * z)
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -5.8e+127) || !(z <= 2.95e+174)) {
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
} else {
tmp = (b + ((x * (9.0 * y)) - ((a * t) * (z * 4.0)))) / (c_m * z);
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): tmp = 0 if (z <= -5.8e+127) or not (z <= 2.95e+174): tmp = ((b / z) - (a * (4.0 * t))) / c_m else: tmp = (b + ((x * (9.0 * y)) - ((a * t) * (z * 4.0)))) / (c_m * z) return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if ((z <= -5.8e+127) || !(z <= 2.95e+174)) tmp = Float64(Float64(Float64(b / z) - Float64(a * Float64(4.0 * t))) / c_m); else tmp = Float64(Float64(b + Float64(Float64(x * Float64(9.0 * y)) - Float64(Float64(a * t) * Float64(z * 4.0)))) / Float64(c_m * z)); end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
tmp = 0.0;
if ((z <= -5.8e+127) || ~((z <= 2.95e+174)))
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
else
tmp = (b + ((x * (9.0 * y)) - ((a * t) * (z * 4.0)))) / (c_m * z);
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[Or[LessEqual[z, -5.8e+127], N[Not[LessEqual[z, 2.95e+174]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] - N[(a * N[(4.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c$95$m), $MachinePrecision], N[(N[(b + N[(N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision] - N[(N[(a * t), $MachinePrecision] * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(c$95$m * z), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;z \leq -5.8 \cdot 10^{+127} \lor \neg \left(z \leq 2.95 \cdot 10^{+174}\right):\\
\;\;\;\;\frac{\frac{b}{z} - a \cdot \left(4 \cdot t\right)}{c\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(a \cdot t\right) \cdot \left(z \cdot 4\right)\right)}{c\_m \cdot z}\\
\end{array}
\end{array}
if z < -5.8000000000000004e127 or 2.95e174 < z Initial program 46.8%
associate-+l-46.8%
*-commutative46.8%
associate-*r*39.6%
*-commutative39.6%
associate-+l-39.6%
associate-*l*39.6%
associate-*l*53.1%
*-commutative53.1%
Simplified53.1%
Taylor expanded in x around 0 78.3%
Taylor expanded in c around 0 87.8%
Taylor expanded in x around 0 84.5%
associate-*r*84.5%
*-commutative84.5%
associate-*r*84.5%
Simplified84.5%
if -5.8000000000000004e127 < z < 2.95e174Initial program 90.8%
associate-+l-90.8%
*-commutative90.8%
associate-*r*90.0%
*-commutative90.0%
associate-+l-90.0%
associate-*l*90.0%
associate-*l*88.9%
*-commutative88.9%
Simplified88.9%
Final simplification87.8%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (or (<= z -1.85e-140) (not (<= z 4e-63)))
(/ (- (/ b z) (* a (* 4.0 t))) c_m)
(/ (+ (* 9.0 (/ (* x y) c_m)) (/ b c_m)) z))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -1.85e-140) || !(z <= 4e-63)) {
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
} else {
tmp = ((9.0 * ((x * y) / c_m)) + (b / c_m)) / z;
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: tmp
if ((z <= (-1.85d-140)) .or. (.not. (z <= 4d-63))) then
tmp = ((b / z) - (a * (4.0d0 * t))) / c_m
else
tmp = ((9.0d0 * ((x * y) / c_m)) + (b / c_m)) / z
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -1.85e-140) || !(z <= 4e-63)) {
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
} else {
tmp = ((9.0 * ((x * y) / c_m)) + (b / c_m)) / z;
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): tmp = 0 if (z <= -1.85e-140) or not (z <= 4e-63): tmp = ((b / z) - (a * (4.0 * t))) / c_m else: tmp = ((9.0 * ((x * y) / c_m)) + (b / c_m)) / z return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if ((z <= -1.85e-140) || !(z <= 4e-63)) tmp = Float64(Float64(Float64(b / z) - Float64(a * Float64(4.0 * t))) / c_m); else tmp = Float64(Float64(Float64(9.0 * Float64(Float64(x * y) / c_m)) + Float64(b / c_m)) / z); end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
tmp = 0.0;
if ((z <= -1.85e-140) || ~((z <= 4e-63)))
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
else
tmp = ((9.0 * ((x * y) / c_m)) + (b / c_m)) / z;
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[Or[LessEqual[z, -1.85e-140], N[Not[LessEqual[z, 4e-63]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] - N[(a * N[(4.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c$95$m), $MachinePrecision], N[(N[(N[(9.0 * N[(N[(x * y), $MachinePrecision] / c$95$m), $MachinePrecision]), $MachinePrecision] + N[(b / c$95$m), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;z \leq -1.85 \cdot 10^{-140} \lor \neg \left(z \leq 4 \cdot 10^{-63}\right):\\
\;\;\;\;\frac{\frac{b}{z} - a \cdot \left(4 \cdot t\right)}{c\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{9 \cdot \frac{x \cdot y}{c\_m} + \frac{b}{c\_m}}{z}\\
\end{array}
\end{array}
if z < -1.84999999999999989e-140 or 4.00000000000000027e-63 < z Initial program 70.9%
associate-+l-70.9%
*-commutative70.9%
associate-*r*67.5%
*-commutative67.5%
associate-+l-67.5%
associate-*l*67.5%
associate-*l*73.4%
*-commutative73.4%
Simplified73.4%
Taylor expanded in x around 0 76.7%
Taylor expanded in c around 0 87.7%
Taylor expanded in x around 0 76.8%
associate-*r*76.8%
*-commutative76.8%
associate-*r*76.8%
Simplified76.8%
if -1.84999999999999989e-140 < z < 4.00000000000000027e-63Initial program 95.4%
associate-+l-95.4%
*-commutative95.4%
associate-*r*94.7%
*-commutative94.7%
associate-+l-94.7%
associate-*l*94.8%
associate-*l*91.5%
*-commutative91.5%
Simplified91.5%
Taylor expanded in x around 0 81.3%
Taylor expanded in z around 0 83.8%
Final simplification79.3%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (or (<= z -4.8e-141) (not (<= z 4e+14)))
(/ (- (/ b z) (* a (* 4.0 t))) c_m)
(/ (+ b (* x (* 9.0 y))) (* c_m z)))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -4.8e-141) || !(z <= 4e+14)) {
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
} else {
tmp = (b + (x * (9.0 * y))) / (c_m * z);
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: tmp
if ((z <= (-4.8d-141)) .or. (.not. (z <= 4d+14))) then
tmp = ((b / z) - (a * (4.0d0 * t))) / c_m
else
tmp = (b + (x * (9.0d0 * y))) / (c_m * z)
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((z <= -4.8e-141) || !(z <= 4e+14)) {
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
} else {
tmp = (b + (x * (9.0 * y))) / (c_m * z);
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): tmp = 0 if (z <= -4.8e-141) or not (z <= 4e+14): tmp = ((b / z) - (a * (4.0 * t))) / c_m else: tmp = (b + (x * (9.0 * y))) / (c_m * z) return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if ((z <= -4.8e-141) || !(z <= 4e+14)) tmp = Float64(Float64(Float64(b / z) - Float64(a * Float64(4.0 * t))) / c_m); else tmp = Float64(Float64(b + Float64(x * Float64(9.0 * y))) / Float64(c_m * z)); end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
tmp = 0.0;
if ((z <= -4.8e-141) || ~((z <= 4e+14)))
tmp = ((b / z) - (a * (4.0 * t))) / c_m;
else
tmp = (b + (x * (9.0 * y))) / (c_m * z);
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[Or[LessEqual[z, -4.8e-141], N[Not[LessEqual[z, 4e+14]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] - N[(a * N[(4.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c$95$m), $MachinePrecision], N[(N[(b + N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(c$95$m * z), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;z \leq -4.8 \cdot 10^{-141} \lor \neg \left(z \leq 4 \cdot 10^{+14}\right):\\
\;\;\;\;\frac{\frac{b}{z} - a \cdot \left(4 \cdot t\right)}{c\_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{b + x \cdot \left(9 \cdot y\right)}{c\_m \cdot z}\\
\end{array}
\end{array}
if z < -4.8000000000000002e-141 or 4e14 < z Initial program 66.6%
associate-+l-66.6%
*-commutative66.6%
associate-*r*62.6%
*-commutative62.6%
associate-+l-62.6%
associate-*l*62.6%
associate-*l*69.5%
*-commutative69.5%
Simplified69.5%
Taylor expanded in x around 0 77.7%
Taylor expanded in c around 0 87.6%
Taylor expanded in x around 0 77.8%
associate-*r*77.8%
*-commutative77.8%
associate-*r*77.8%
Simplified77.8%
if -4.8000000000000002e-141 < z < 4e14Initial program 95.6%
associate-+l-95.6%
*-commutative95.6%
associate-*r*95.0%
*-commutative95.0%
associate-+l-95.0%
associate-*l*95.0%
associate-*l*92.5%
*-commutative92.5%
Simplified92.5%
Taylor expanded in z around inf 86.6%
Taylor expanded in z around 0 80.7%
associate-*r*80.7%
*-commutative80.7%
associate-*r*80.7%
Simplified80.7%
Final simplification79.1%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (or (<= b -7e+84) (not (<= b 2.5e-35)))
(* (/ b c_m) (/ 1.0 z))
(* (* a t) (/ -4.0 c_m)))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((b <= -7e+84) || !(b <= 2.5e-35)) {
tmp = (b / c_m) * (1.0 / z);
} else {
tmp = (a * t) * (-4.0 / c_m);
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: tmp
if ((b <= (-7d+84)) .or. (.not. (b <= 2.5d-35))) then
tmp = (b / c_m) * (1.0d0 / z)
else
tmp = (a * t) * ((-4.0d0) / c_m)
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((b <= -7e+84) || !(b <= 2.5e-35)) {
tmp = (b / c_m) * (1.0 / z);
} else {
tmp = (a * t) * (-4.0 / c_m);
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): tmp = 0 if (b <= -7e+84) or not (b <= 2.5e-35): tmp = (b / c_m) * (1.0 / z) else: tmp = (a * t) * (-4.0 / c_m) return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if ((b <= -7e+84) || !(b <= 2.5e-35)) tmp = Float64(Float64(b / c_m) * Float64(1.0 / z)); else tmp = Float64(Float64(a * t) * Float64(-4.0 / c_m)); end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
tmp = 0.0;
if ((b <= -7e+84) || ~((b <= 2.5e-35)))
tmp = (b / c_m) * (1.0 / z);
else
tmp = (a * t) * (-4.0 / c_m);
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[Or[LessEqual[b, -7e+84], N[Not[LessEqual[b, 2.5e-35]], $MachinePrecision]], N[(N[(b / c$95$m), $MachinePrecision] * N[(1.0 / z), $MachinePrecision]), $MachinePrecision], N[(N[(a * t), $MachinePrecision] * N[(-4.0 / c$95$m), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;b \leq -7 \cdot 10^{+84} \lor \neg \left(b \leq 2.5 \cdot 10^{-35}\right):\\
\;\;\;\;\frac{b}{c\_m} \cdot \frac{1}{z}\\
\mathbf{else}:\\
\;\;\;\;\left(a \cdot t\right) \cdot \frac{-4}{c\_m}\\
\end{array}
\end{array}
if b < -6.9999999999999998e84 or 2.49999999999999982e-35 < b Initial program 85.6%
associate-+l-85.6%
*-commutative85.6%
associate-*r*83.3%
*-commutative83.3%
associate-+l-83.3%
Simplified83.2%
Taylor expanded in t around 0 71.3%
+-commutative71.3%
associate-*r*71.3%
*-commutative71.3%
Simplified71.3%
Taylor expanded in x around 0 58.3%
associate-/r*62.9%
Simplified62.9%
div-inv62.9%
Applied egg-rr62.9%
if -6.9999999999999998e84 < b < 2.49999999999999982e-35Initial program 74.1%
associate-+l-74.1%
*-commutative74.1%
associate-*r*71.6%
*-commutative71.6%
associate-+l-71.6%
Simplified71.6%
Taylor expanded in t around inf 59.0%
associate-*r/58.3%
*-commutative58.3%
associate-/l*58.9%
Simplified58.9%
Final simplification60.8%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (or (<= b -1.2e+85) (not (<= b 2.5e-35)))
(/ (/ b c_m) z)
(* (* a t) (/ -4.0 c_m)))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((b <= -1.2e+85) || !(b <= 2.5e-35)) {
tmp = (b / c_m) / z;
} else {
tmp = (a * t) * (-4.0 / c_m);
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: tmp
if ((b <= (-1.2d+85)) .or. (.not. (b <= 2.5d-35))) then
tmp = (b / c_m) / z
else
tmp = (a * t) * ((-4.0d0) / c_m)
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((b <= -1.2e+85) || !(b <= 2.5e-35)) {
tmp = (b / c_m) / z;
} else {
tmp = (a * t) * (-4.0 / c_m);
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): tmp = 0 if (b <= -1.2e+85) or not (b <= 2.5e-35): tmp = (b / c_m) / z else: tmp = (a * t) * (-4.0 / c_m) return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if ((b <= -1.2e+85) || !(b <= 2.5e-35)) tmp = Float64(Float64(b / c_m) / z); else tmp = Float64(Float64(a * t) * Float64(-4.0 / c_m)); end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
tmp = 0.0;
if ((b <= -1.2e+85) || ~((b <= 2.5e-35)))
tmp = (b / c_m) / z;
else
tmp = (a * t) * (-4.0 / c_m);
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[Or[LessEqual[b, -1.2e+85], N[Not[LessEqual[b, 2.5e-35]], $MachinePrecision]], N[(N[(b / c$95$m), $MachinePrecision] / z), $MachinePrecision], N[(N[(a * t), $MachinePrecision] * N[(-4.0 / c$95$m), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;b \leq -1.2 \cdot 10^{+85} \lor \neg \left(b \leq 2.5 \cdot 10^{-35}\right):\\
\;\;\;\;\frac{\frac{b}{c\_m}}{z}\\
\mathbf{else}:\\
\;\;\;\;\left(a \cdot t\right) \cdot \frac{-4}{c\_m}\\
\end{array}
\end{array}
if b < -1.19999999999999998e85 or 2.49999999999999982e-35 < b Initial program 85.6%
associate-+l-85.6%
*-commutative85.6%
associate-*r*83.3%
*-commutative83.3%
associate-+l-83.3%
Simplified83.2%
Taylor expanded in t around 0 71.3%
+-commutative71.3%
associate-*r*71.3%
*-commutative71.3%
Simplified71.3%
Taylor expanded in x around 0 58.3%
associate-/r*62.9%
Simplified62.9%
if -1.19999999999999998e85 < b < 2.49999999999999982e-35Initial program 74.1%
associate-+l-74.1%
*-commutative74.1%
associate-*r*71.6%
*-commutative71.6%
associate-+l-71.6%
Simplified71.6%
Taylor expanded in t around inf 59.0%
associate-*r/58.3%
*-commutative58.3%
associate-/l*58.9%
Simplified58.9%
Final simplification60.8%
c\_m = (fabs.f64 c)
c\_s = (copysign.f64 #s(literal 1 binary64) c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
(FPCore (c_s x y z t a b c_m)
:precision binary64
(*
c_s
(if (or (<= b -1.06e+85) (not (<= b 2.35e-35)))
(/ (/ b c_m) z)
(* -4.0 (* a (/ t c_m))))))c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((b <= -1.06e+85) || !(b <= 2.35e-35)) {
tmp = (b / c_m) / z;
} else {
tmp = -4.0 * (a * (t / c_m));
}
return c_s * tmp;
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
real(8) :: tmp
if ((b <= (-1.06d+85)) .or. (.not. (b <= 2.35d-35))) then
tmp = (b / c_m) / z
else
tmp = (-4.0d0) * (a * (t / c_m))
end if
code = c_s * tmp
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
double tmp;
if ((b <= -1.06e+85) || !(b <= 2.35e-35)) {
tmp = (b / c_m) / z;
} else {
tmp = -4.0 * (a * (t / c_m));
}
return c_s * tmp;
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): tmp = 0 if (b <= -1.06e+85) or not (b <= 2.35e-35): tmp = (b / c_m) / z else: tmp = -4.0 * (a * (t / c_m)) return c_s * tmp
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) tmp = 0.0 if ((b <= -1.06e+85) || !(b <= 2.35e-35)) tmp = Float64(Float64(b / c_m) / z); else tmp = Float64(-4.0 * Float64(a * Float64(t / c_m))); end return Float64(c_s * tmp) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp_2 = code(c_s, x, y, z, t, a, b, c_m)
tmp = 0.0;
if ((b <= -1.06e+85) || ~((b <= 2.35e-35)))
tmp = (b / c_m) / z;
else
tmp = -4.0 * (a * (t / c_m));
end
tmp_2 = c_s * tmp;
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * If[Or[LessEqual[b, -1.06e+85], N[Not[LessEqual[b, 2.35e-35]], $MachinePrecision]], N[(N[(b / c$95$m), $MachinePrecision] / z), $MachinePrecision], N[(-4.0 * N[(a * N[(t / c$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \begin{array}{l}
\mathbf{if}\;b \leq -1.06 \cdot 10^{+85} \lor \neg \left(b \leq 2.35 \cdot 10^{-35}\right):\\
\;\;\;\;\frac{\frac{b}{c\_m}}{z}\\
\mathbf{else}:\\
\;\;\;\;-4 \cdot \left(a \cdot \frac{t}{c\_m}\right)\\
\end{array}
\end{array}
if b < -1.0600000000000001e85 or 2.35e-35 < b Initial program 85.6%
associate-+l-85.6%
*-commutative85.6%
associate-*r*83.3%
*-commutative83.3%
associate-+l-83.3%
Simplified83.2%
Taylor expanded in t around 0 71.3%
+-commutative71.3%
associate-*r*71.3%
*-commutative71.3%
Simplified71.3%
Taylor expanded in x around 0 58.3%
associate-/r*62.9%
Simplified62.9%
if -1.0600000000000001e85 < b < 2.35e-35Initial program 74.1%
associate-+l-74.1%
*-commutative74.1%
associate-*r*71.6%
*-commutative71.6%
associate-+l-71.6%
associate-*l*71.6%
associate-*l*75.2%
*-commutative75.2%
Simplified75.2%
Taylor expanded in x around 0 78.8%
Taylor expanded in z around inf 59.0%
associate-*r/59.0%
Simplified59.0%
Final simplification60.8%
c\_m = (fabs.f64 c) c\_s = (copysign.f64 #s(literal 1 binary64) c) NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function. (FPCore (c_s x y z t a b c_m) :precision binary64 (* c_s (/ (/ b c_m) z)))
c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
return c_s * ((b / c_m) / z);
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
code = c_s * ((b / c_m) / z)
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
return c_s * ((b / c_m) / z);
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): return c_s * ((b / c_m) / z)
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) return Float64(c_s * Float64(Float64(b / c_m) / z)) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp = code(c_s, x, y, z, t, a, b, c_m)
tmp = c_s * ((b / c_m) / z);
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * N[(N[(b / c$95$m), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \frac{\frac{b}{c\_m}}{z}
\end{array}
Initial program 79.6%
associate-+l-79.6%
*-commutative79.6%
associate-*r*77.2%
*-commutative77.2%
associate-+l-77.2%
Simplified77.2%
Taylor expanded in t around 0 54.0%
+-commutative54.0%
associate-*r*54.0%
*-commutative54.0%
Simplified54.0%
Taylor expanded in x around 0 35.5%
associate-/r*36.6%
Simplified36.6%
c\_m = (fabs.f64 c) c\_s = (copysign.f64 #s(literal 1 binary64) c) NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function. (FPCore (c_s x y z t a b c_m) :precision binary64 (* c_s (/ b (* c_m z))))
c\_m = fabs(c);
c\_s = copysign(1.0, c);
assert(x < y && y < z && z < t && t < a && a < b && b < c_m);
double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
return c_s * (b / (c_m * z));
}
c\_m = abs(c)
c\_s = copysign(1.0d0, c)
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
real(8) function code(c_s, x, y, z, t, a, b, c_m)
real(8), intent (in) :: c_s
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c_m
code = c_s * (b / (c_m * z))
end function
c\_m = Math.abs(c);
c\_s = Math.copySign(1.0, c);
assert x < y && y < z && z < t && t < a && a < b && b < c_m;
public static double code(double c_s, double x, double y, double z, double t, double a, double b, double c_m) {
return c_s * (b / (c_m * z));
}
c\_m = math.fabs(c) c\_s = math.copysign(1.0, c) [x, y, z, t, a, b, c_m] = sort([x, y, z, t, a, b, c_m]) def code(c_s, x, y, z, t, a, b, c_m): return c_s * (b / (c_m * z))
c\_m = abs(c) c\_s = copysign(1.0, c) x, y, z, t, a, b, c_m = sort([x, y, z, t, a, b, c_m]) function code(c_s, x, y, z, t, a, b, c_m) return Float64(c_s * Float64(b / Float64(c_m * z))) end
c\_m = abs(c);
c\_s = sign(c) * abs(1.0);
x, y, z, t, a, b, c_m = num2cell(sort([x, y, z, t, a, b, c_m])){:}
function tmp = code(c_s, x, y, z, t, a, b, c_m)
tmp = c_s * (b / (c_m * z));
end
c\_m = N[Abs[c], $MachinePrecision]
c\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[c]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
NOTE: x, y, z, t, a, b, and c_m should be sorted in increasing order before calling this function.
code[c$95$s_, x_, y_, z_, t_, a_, b_, c$95$m_] := N[(c$95$s * N[(b / N[(c$95$m * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
c\_m = \left|c\right|
\\
c\_s = \mathsf{copysign}\left(1, c\right)
\\
[x, y, z, t, a, b, c_m] = \mathsf{sort}([x, y, z, t, a, b, c_m])\\
\\
c\_s \cdot \frac{b}{c\_m \cdot z}
\end{array}
Initial program 79.6%
associate-+l-79.6%
*-commutative79.6%
associate-*r*77.2%
*-commutative77.2%
associate-+l-77.2%
Simplified77.2%
Taylor expanded in b around inf 35.5%
*-commutative35.5%
Simplified35.5%
Final simplification35.5%
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (/ b (* c z)))
(t_2 (* 4.0 (/ (* a t) c)))
(t_3 (* (* x 9.0) y))
(t_4 (+ (- t_3 (* (* (* z 4.0) t) a)) b))
(t_5 (/ t_4 (* z c)))
(t_6 (/ (+ (- t_3 (* (* z 4.0) (* t a))) b) (* z c))))
(if (< t_5 -1.100156740804105e-171)
t_6
(if (< t_5 0.0)
(/ (/ t_4 z) c)
(if (< t_5 1.1708877911747488e-53)
t_6
(if (< t_5 2.876823679546137e+130)
(- (+ (* (* 9.0 (/ y c)) (/ x z)) t_1) t_2)
(if (< t_5 1.3838515042456319e+158)
t_6
(- (+ (* 9.0 (* (/ y (* c z)) x)) t_1) t_2))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = b / (c * z);
double t_2 = 4.0 * ((a * t) / c);
double t_3 = (x * 9.0) * y;
double t_4 = (t_3 - (((z * 4.0) * t) * a)) + b;
double t_5 = t_4 / (z * c);
double t_6 = ((t_3 - ((z * 4.0) * (t * a))) + b) / (z * c);
double tmp;
if (t_5 < -1.100156740804105e-171) {
tmp = t_6;
} else if (t_5 < 0.0) {
tmp = (t_4 / z) / c;
} else if (t_5 < 1.1708877911747488e-53) {
tmp = t_6;
} else if (t_5 < 2.876823679546137e+130) {
tmp = (((9.0 * (y / c)) * (x / z)) + t_1) - t_2;
} else if (t_5 < 1.3838515042456319e+158) {
tmp = t_6;
} else {
tmp = ((9.0 * ((y / (c * z)) * x)) + t_1) - t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: t_5
real(8) :: t_6
real(8) :: tmp
t_1 = b / (c * z)
t_2 = 4.0d0 * ((a * t) / c)
t_3 = (x * 9.0d0) * y
t_4 = (t_3 - (((z * 4.0d0) * t) * a)) + b
t_5 = t_4 / (z * c)
t_6 = ((t_3 - ((z * 4.0d0) * (t * a))) + b) / (z * c)
if (t_5 < (-1.100156740804105d-171)) then
tmp = t_6
else if (t_5 < 0.0d0) then
tmp = (t_4 / z) / c
else if (t_5 < 1.1708877911747488d-53) then
tmp = t_6
else if (t_5 < 2.876823679546137d+130) then
tmp = (((9.0d0 * (y / c)) * (x / z)) + t_1) - t_2
else if (t_5 < 1.3838515042456319d+158) then
tmp = t_6
else
tmp = ((9.0d0 * ((y / (c * z)) * x)) + t_1) - t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = b / (c * z);
double t_2 = 4.0 * ((a * t) / c);
double t_3 = (x * 9.0) * y;
double t_4 = (t_3 - (((z * 4.0) * t) * a)) + b;
double t_5 = t_4 / (z * c);
double t_6 = ((t_3 - ((z * 4.0) * (t * a))) + b) / (z * c);
double tmp;
if (t_5 < -1.100156740804105e-171) {
tmp = t_6;
} else if (t_5 < 0.0) {
tmp = (t_4 / z) / c;
} else if (t_5 < 1.1708877911747488e-53) {
tmp = t_6;
} else if (t_5 < 2.876823679546137e+130) {
tmp = (((9.0 * (y / c)) * (x / z)) + t_1) - t_2;
} else if (t_5 < 1.3838515042456319e+158) {
tmp = t_6;
} else {
tmp = ((9.0 * ((y / (c * z)) * x)) + t_1) - t_2;
}
return tmp;
}
def code(x, y, z, t, a, b, c): t_1 = b / (c * z) t_2 = 4.0 * ((a * t) / c) t_3 = (x * 9.0) * y t_4 = (t_3 - (((z * 4.0) * t) * a)) + b t_5 = t_4 / (z * c) t_6 = ((t_3 - ((z * 4.0) * (t * a))) + b) / (z * c) tmp = 0 if t_5 < -1.100156740804105e-171: tmp = t_6 elif t_5 < 0.0: tmp = (t_4 / z) / c elif t_5 < 1.1708877911747488e-53: tmp = t_6 elif t_5 < 2.876823679546137e+130: tmp = (((9.0 * (y / c)) * (x / z)) + t_1) - t_2 elif t_5 < 1.3838515042456319e+158: tmp = t_6 else: tmp = ((9.0 * ((y / (c * z)) * x)) + t_1) - t_2 return tmp
function code(x, y, z, t, a, b, c) t_1 = Float64(b / Float64(c * z)) t_2 = Float64(4.0 * Float64(Float64(a * t) / c)) t_3 = Float64(Float64(x * 9.0) * y) t_4 = Float64(Float64(t_3 - Float64(Float64(Float64(z * 4.0) * t) * a)) + b) t_5 = Float64(t_4 / Float64(z * c)) t_6 = Float64(Float64(Float64(t_3 - Float64(Float64(z * 4.0) * Float64(t * a))) + b) / Float64(z * c)) tmp = 0.0 if (t_5 < -1.100156740804105e-171) tmp = t_6; elseif (t_5 < 0.0) tmp = Float64(Float64(t_4 / z) / c); elseif (t_5 < 1.1708877911747488e-53) tmp = t_6; elseif (t_5 < 2.876823679546137e+130) tmp = Float64(Float64(Float64(Float64(9.0 * Float64(y / c)) * Float64(x / z)) + t_1) - t_2); elseif (t_5 < 1.3838515042456319e+158) tmp = t_6; else tmp = Float64(Float64(Float64(9.0 * Float64(Float64(y / Float64(c * z)) * x)) + t_1) - t_2); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) t_1 = b / (c * z); t_2 = 4.0 * ((a * t) / c); t_3 = (x * 9.0) * y; t_4 = (t_3 - (((z * 4.0) * t) * a)) + b; t_5 = t_4 / (z * c); t_6 = ((t_3 - ((z * 4.0) * (t * a))) + b) / (z * c); tmp = 0.0; if (t_5 < -1.100156740804105e-171) tmp = t_6; elseif (t_5 < 0.0) tmp = (t_4 / z) / c; elseif (t_5 < 1.1708877911747488e-53) tmp = t_6; elseif (t_5 < 2.876823679546137e+130) tmp = (((9.0 * (y / c)) * (x / z)) + t_1) - t_2; elseif (t_5 < 1.3838515042456319e+158) tmp = t_6; else tmp = ((9.0 * ((y / (c * z)) * x)) + t_1) - t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(b / N[(c * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(x * 9.0), $MachinePrecision] * y), $MachinePrecision]}, Block[{t$95$4 = N[(N[(t$95$3 - N[(N[(N[(z * 4.0), $MachinePrecision] * t), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]}, Block[{t$95$5 = N[(t$95$4 / N[(z * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(N[(N[(t$95$3 - N[(N[(z * 4.0), $MachinePrecision] * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]}, If[Less[t$95$5, -1.100156740804105e-171], t$95$6, If[Less[t$95$5, 0.0], N[(N[(t$95$4 / z), $MachinePrecision] / c), $MachinePrecision], If[Less[t$95$5, 1.1708877911747488e-53], t$95$6, If[Less[t$95$5, 2.876823679546137e+130], N[(N[(N[(N[(9.0 * N[(y / c), $MachinePrecision]), $MachinePrecision] * N[(x / z), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision], If[Less[t$95$5, 1.3838515042456319e+158], t$95$6, N[(N[(N[(9.0 * N[(N[(y / N[(c * z), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{b}{c \cdot z}\\
t_2 := 4 \cdot \frac{a \cdot t}{c}\\
t_3 := \left(x \cdot 9\right) \cdot y\\
t_4 := \left(t\_3 - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b\\
t_5 := \frac{t\_4}{z \cdot c}\\
t_6 := \frac{\left(t\_3 - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{z \cdot c}\\
\mathbf{if}\;t\_5 < -1.100156740804105 \cdot 10^{-171}:\\
\;\;\;\;t\_6\\
\mathbf{elif}\;t\_5 < 0:\\
\;\;\;\;\frac{\frac{t\_4}{z}}{c}\\
\mathbf{elif}\;t\_5 < 1.1708877911747488 \cdot 10^{-53}:\\
\;\;\;\;t\_6\\
\mathbf{elif}\;t\_5 < 2.876823679546137 \cdot 10^{+130}:\\
\;\;\;\;\left(\left(9 \cdot \frac{y}{c}\right) \cdot \frac{x}{z} + t\_1\right) - t\_2\\
\mathbf{elif}\;t\_5 < 1.3838515042456319 \cdot 10^{+158}:\\
\;\;\;\;t\_6\\
\mathbf{else}:\\
\;\;\;\;\left(9 \cdot \left(\frac{y}{c \cdot z} \cdot x\right) + t\_1\right) - t\_2\\
\end{array}
\end{array}
herbie shell --seed 2024163
(FPCore (x y z t a b c)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, J"
:precision binary64
:alt
(! :herbie-platform default (if (< (/ (+ (- (* (* x 9) y) (* (* (* z 4) t) a)) b) (* z c)) -220031348160821/200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (/ (+ (- (* (* x 9) y) (* (* z 4) (* t a))) b) (* z c)) (if (< (/ (+ (- (* (* x 9) y) (* (* (* z 4) t) a)) b) (* z c)) 0) (/ (/ (+ (- (* (* x 9) y) (* (* (* z 4) t) a)) b) z) c) (if (< (/ (+ (- (* (* x 9) y) (* (* (* z 4) t) a)) b) (* z c)) 365902434742109/31250000000000000000000000000000000000000000000000000000000000000000) (/ (+ (- (* (* x 9) y) (* (* z 4) (* t a))) b) (* z c)) (if (< (/ (+ (- (* (* x 9) y) (* (* (* z 4) t) a)) b) (* z c)) 28768236795461370000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- (+ (* (* 9 (/ y c)) (/ x z)) (/ b (* c z))) (* 4 (/ (* a t) c))) (if (< (/ (+ (- (* (* x 9) y) (* (* (* z 4) t) a)) b) (* z c)) 138385150424563190000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (/ (+ (- (* (* x 9) y) (* (* z 4) (* t a))) b) (* z c)) (- (+ (* 9 (* (/ y (* c z)) x)) (/ b (* c z))) (* 4 (/ (* a t) c)))))))))
(/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)))