
(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 16 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}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. (FPCore (x y z t a b c) :precision binary64 (if (or (<= z -1.9e+122) (not (<= z 5.5e-68))) (* (fma -4.0 (* a t) (fma 9.0 (/ x (/ z y)) (/ b z))) (/ 1.0 c)) (* (+ b (fma x (* 9.0 y) (* a (* z (* -4.0 t))))) (/ 1.0 (* z c)))))
assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((z <= -1.9e+122) || !(z <= 5.5e-68)) {
tmp = fma(-4.0, (a * t), fma(9.0, (x / (z / y)), (b / z))) * (1.0 / c);
} else {
tmp = (b + fma(x, (9.0 * y), (a * (z * (-4.0 * t))))) * (1.0 / (z * c));
}
return tmp;
}
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) tmp = 0.0 if ((z <= -1.9e+122) || !(z <= 5.5e-68)) tmp = Float64(fma(-4.0, Float64(a * t), fma(9.0, Float64(x / Float64(z / y)), Float64(b / z))) * Float64(1.0 / c)); else tmp = Float64(Float64(b + fma(x, Float64(9.0 * y), Float64(a * Float64(z * Float64(-4.0 * t))))) * Float64(1.0 / Float64(z * c))); end return tmp end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -1.9e+122], N[Not[LessEqual[z, 5.5e-68]], $MachinePrecision]], N[(N[(-4.0 * N[(a * t), $MachinePrecision] + N[(9.0 * N[(x / N[(z / y), $MachinePrecision]), $MachinePrecision] + N[(b / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 / c), $MachinePrecision]), $MachinePrecision], N[(N[(b + N[(x * N[(9.0 * y), $MachinePrecision] + N[(a * N[(z * N[(-4.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{+122} \lor \neg \left(z \leq 5.5 \cdot 10^{-68}\right):\\
\;\;\;\;\mathsf{fma}\left(-4, a \cdot t, \mathsf{fma}\left(9, \frac{x}{\frac{z}{y}}, \frac{b}{z}\right)\right) \cdot \frac{1}{c}\\
\mathbf{else}:\\
\;\;\;\;\left(b + \mathsf{fma}\left(x, 9 \cdot y, a \cdot \left(z \cdot \left(-4 \cdot t\right)\right)\right)\right) \cdot \frac{1}{z \cdot c}\\
\end{array}
\end{array}
if z < -1.8999999999999999e122 or 5.5000000000000003e-68 < z Initial program 62.2%
associate-+l-62.2%
*-commutative62.2%
associate-*r*60.6%
*-commutative60.6%
associate-+l-60.6%
*-commutative60.6%
associate-*r*62.2%
*-commutative62.2%
associate-*l*62.2%
associate-*l*66.4%
Simplified66.4%
Applied egg-rr73.3%
Taylor expanded in x around 0 88.1%
fma-def88.1%
fma-def88.1%
associate-/l*92.3%
Simplified92.3%
if -1.8999999999999999e122 < z < 5.5000000000000003e-68Initial program 94.4%
associate-+l-94.4%
*-commutative94.4%
associate-*r*95.1%
*-commutative95.1%
associate-+l-95.1%
*-commutative95.1%
associate-*r*94.4%
*-commutative94.4%
associate-*l*94.4%
associate-*l*90.9%
Simplified90.9%
div-inv90.8%
associate-*r*94.3%
cancel-sign-sub-inv94.3%
fma-def94.4%
distribute-lft-neg-in94.4%
*-commutative94.4%
distribute-rgt-neg-in94.4%
distribute-lft-neg-in94.4%
distribute-rgt-neg-in94.4%
metadata-eval94.4%
associate-*r*94.4%
*-commutative94.4%
Applied egg-rr94.4%
Final simplification93.5%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c)))
(t_2 (+ b (fma x (* 9.0 y) (* a (* z (* -4.0 t)))))))
(if (<= t_1 (- INFINITY))
(* (/ 1.0 c) (/ (+ b (+ (* x (* 9.0 y)) (* (* -4.0 t) (* z a)))) z))
(if (<= t_1 -5e-181)
(* t_2 (/ 1.0 (* z c)))
(if (<= t_1 INFINITY)
(* (/ 1.0 z) (/ t_2 c))
(* -4.0 (* t (/ a c))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
double t_2 = b + fma(x, (9.0 * y), (a * (z * (-4.0 * t))));
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = (1.0 / c) * ((b + ((x * (9.0 * y)) + ((-4.0 * t) * (z * a)))) / z);
} else if (t_1 <= -5e-181) {
tmp = t_2 * (1.0 / (z * c));
} else if (t_1 <= ((double) INFINITY)) {
tmp = (1.0 / z) * (t_2 / c);
} else {
tmp = -4.0 * (t * (a / c));
}
return tmp;
}
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) t_1 = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c)) t_2 = Float64(b + fma(x, Float64(9.0 * y), Float64(a * Float64(z * Float64(-4.0 * t))))) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = Float64(Float64(1.0 / c) * Float64(Float64(b + Float64(Float64(x * Float64(9.0 * y)) + Float64(Float64(-4.0 * t) * Float64(z * a)))) / z)); elseif (t_1 <= -5e-181) tmp = Float64(t_2 * Float64(1.0 / Float64(z * c))); elseif (t_1 <= Inf) tmp = Float64(Float64(1.0 / z) * Float64(t_2 / c)); else tmp = Float64(-4.0 * Float64(t * Float64(a / c))); end return tmp end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = 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[(z * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(b + N[(x * N[(9.0 * y), $MachinePrecision] + N[(a * N[(z * N[(-4.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(1.0 / c), $MachinePrecision] * N[(N[(b + N[(N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision] + N[(N[(-4.0 * t), $MachinePrecision] * N[(z * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, -5e-181], N[(t$95$2 * N[(1.0 / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, Infinity], N[(N[(1.0 / z), $MachinePrecision] * N[(t$95$2 / c), $MachinePrecision]), $MachinePrecision], N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
t_1 := \frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\
t_2 := b + \mathsf{fma}\left(x, 9 \cdot y, a \cdot \left(z \cdot \left(-4 \cdot t\right)\right)\right)\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;\frac{1}{c} \cdot \frac{b + \left(x \cdot \left(9 \cdot y\right) + \left(-4 \cdot t\right) \cdot \left(z \cdot a\right)\right)}{z}\\
\mathbf{elif}\;t\_1 \leq -5 \cdot 10^{-181}:\\
\;\;\;\;t\_2 \cdot \frac{1}{z \cdot c}\\
\mathbf{elif}\;t\_1 \leq \infty:\\
\;\;\;\;\frac{1}{z} \cdot \frac{t\_2}{c}\\
\mathbf{else}:\\
\;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\
\end{array}
\end{array}
if (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < -inf.0Initial program 86.8%
associate-+l-86.8%
*-commutative86.8%
associate-*r*91.3%
*-commutative91.3%
associate-+l-91.3%
*-commutative91.3%
associate-*r*86.8%
*-commutative86.8%
associate-*l*86.8%
associate-*l*88.2%
Simplified88.2%
Applied egg-rr86.8%
fma-udef86.8%
associate-*r*89.9%
Applied egg-rr89.9%
if -inf.0 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < -5.0000000000000001e-181Initial program 99.4%
associate-+l-99.4%
*-commutative99.4%
associate-*r*93.9%
*-commutative93.9%
associate-+l-93.9%
*-commutative93.9%
associate-*r*99.4%
*-commutative99.4%
associate-*l*99.3%
associate-*l*97.6%
Simplified97.6%
div-inv97.4%
associate-*r*99.2%
cancel-sign-sub-inv99.2%
fma-def99.2%
distribute-lft-neg-in99.2%
*-commutative99.2%
distribute-rgt-neg-in99.2%
distribute-lft-neg-in99.2%
distribute-rgt-neg-in99.2%
metadata-eval99.2%
associate-*r*99.2%
*-commutative99.2%
Applied egg-rr99.2%
if -5.0000000000000001e-181 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < +inf.0Initial program 80.1%
associate-+l-80.1%
*-commutative80.1%
associate-*r*78.5%
*-commutative78.5%
associate-+l-78.5%
*-commutative78.5%
associate-*r*80.1%
*-commutative80.1%
associate-*l*80.1%
associate-*l*79.3%
Simplified79.3%
Applied egg-rr85.4%
if +inf.0 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) Initial program 0.0%
associate-+l-0.0%
*-commutative0.0%
associate-*r*5.4%
*-commutative5.4%
associate-+l-5.4%
*-commutative5.4%
associate-*r*0.0%
*-commutative0.0%
associate-*l*0.0%
associate-*l*5.4%
Simplified5.4%
Applied egg-rr8.6%
Taylor expanded in x around 0 58.6%
fma-def58.6%
fma-def58.6%
associate-/l*79.6%
Simplified79.6%
Taylor expanded in x around 0 69.8%
Taylor expanded in a around inf 64.7%
associate-*l/79.4%
*-commutative79.4%
Simplified79.4%
Final simplification89.0%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (* x (* 9.0 y)))
(t_2 (/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c)))
(t_3 (+ b (fma x (* 9.0 y) (* a (* z (* -4.0 t)))))))
(if (<= t_2 (- INFINITY))
(* (/ 1.0 c) (/ (+ b (+ t_1 (* (* -4.0 t) (* z a)))) z))
(if (<= t_2 -2e-28)
(* t_3 (/ 1.0 (* z c)))
(if (<= t_2 1e-108)
(* (/ 1.0 c) (/ t_3 z))
(if (<= t_2 INFINITY)
(/ (+ b (- t_1 (* (* a t) (* z 4.0)))) (* z c))
(* -4.0 (* t (/ a c)))))))))assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = x * (9.0 * y);
double t_2 = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
double t_3 = b + fma(x, (9.0 * y), (a * (z * (-4.0 * t))));
double tmp;
if (t_2 <= -((double) INFINITY)) {
tmp = (1.0 / c) * ((b + (t_1 + ((-4.0 * t) * (z * a)))) / z);
} else if (t_2 <= -2e-28) {
tmp = t_3 * (1.0 / (z * c));
} else if (t_2 <= 1e-108) {
tmp = (1.0 / c) * (t_3 / z);
} else if (t_2 <= ((double) INFINITY)) {
tmp = (b + (t_1 - ((a * t) * (z * 4.0)))) / (z * c);
} else {
tmp = -4.0 * (t * (a / c));
}
return tmp;
}
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) t_1 = Float64(x * Float64(9.0 * y)) t_2 = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c)) t_3 = Float64(b + fma(x, Float64(9.0 * y), Float64(a * Float64(z * Float64(-4.0 * t))))) tmp = 0.0 if (t_2 <= Float64(-Inf)) tmp = Float64(Float64(1.0 / c) * Float64(Float64(b + Float64(t_1 + Float64(Float64(-4.0 * t) * Float64(z * a)))) / z)); elseif (t_2 <= -2e-28) tmp = Float64(t_3 * Float64(1.0 / Float64(z * c))); elseif (t_2 <= 1e-108) tmp = Float64(Float64(1.0 / c) * Float64(t_3 / z)); elseif (t_2 <= Inf) tmp = Float64(Float64(b + Float64(t_1 - Float64(Float64(a * t) * Float64(z * 4.0)))) / Float64(z * c)); else tmp = Float64(-4.0 * Float64(t * Float64(a / c))); end return tmp end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = 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[(z * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(b + N[(x * N[(9.0 * y), $MachinePrecision] + N[(a * N[(z * N[(-4.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], N[(N[(1.0 / c), $MachinePrecision] * N[(N[(b + N[(t$95$1 + N[(N[(-4.0 * t), $MachinePrecision] * N[(z * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, -2e-28], N[(t$95$3 * N[(1.0 / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 1e-108], N[(N[(1.0 / c), $MachinePrecision] * N[(t$95$3 / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, Infinity], N[(N[(b + N[(t$95$1 - N[(N[(a * t), $MachinePrecision] * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision], N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
t_1 := x \cdot \left(9 \cdot y\right)\\
t_2 := \frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\
t_3 := b + \mathsf{fma}\left(x, 9 \cdot y, a \cdot \left(z \cdot \left(-4 \cdot t\right)\right)\right)\\
\mathbf{if}\;t\_2 \leq -\infty:\\
\;\;\;\;\frac{1}{c} \cdot \frac{b + \left(t\_1 + \left(-4 \cdot t\right) \cdot \left(z \cdot a\right)\right)}{z}\\
\mathbf{elif}\;t\_2 \leq -2 \cdot 10^{-28}:\\
\;\;\;\;t\_3 \cdot \frac{1}{z \cdot c}\\
\mathbf{elif}\;t\_2 \leq 10^{-108}:\\
\;\;\;\;\frac{1}{c} \cdot \frac{t\_3}{z}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\frac{b + \left(t\_1 - \left(a \cdot t\right) \cdot \left(z \cdot 4\right)\right)}{z \cdot c}\\
\mathbf{else}:\\
\;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\
\end{array}
\end{array}
if (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < -inf.0Initial program 86.8%
associate-+l-86.8%
*-commutative86.8%
associate-*r*91.3%
*-commutative91.3%
associate-+l-91.3%
*-commutative91.3%
associate-*r*86.8%
*-commutative86.8%
associate-*l*86.8%
associate-*l*88.2%
Simplified88.2%
Applied egg-rr86.8%
fma-udef86.8%
associate-*r*89.9%
Applied egg-rr89.9%
if -inf.0 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < -1.99999999999999994e-28Initial program 99.2%
associate-+l-99.2%
*-commutative99.2%
associate-*r*90.6%
*-commutative90.6%
associate-+l-90.6%
*-commutative90.6%
associate-*r*99.2%
*-commutative99.2%
associate-*l*99.2%
associate-*l*96.4%
Simplified96.4%
div-inv96.3%
associate-*r*99.2%
cancel-sign-sub-inv99.2%
fma-def99.2%
distribute-lft-neg-in99.2%
*-commutative99.2%
distribute-rgt-neg-in99.2%
distribute-lft-neg-in99.2%
distribute-rgt-neg-in99.2%
metadata-eval99.2%
associate-*r*99.2%
*-commutative99.2%
Applied egg-rr99.2%
if -1.99999999999999994e-28 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < 1.00000000000000004e-108Initial program 74.3%
associate-+l-74.3%
*-commutative74.3%
associate-*r*72.2%
*-commutative72.2%
associate-+l-72.2%
*-commutative72.2%
associate-*r*74.3%
*-commutative74.3%
associate-*l*74.3%
associate-*l*74.2%
Simplified74.2%
Applied egg-rr99.6%
if 1.00000000000000004e-108 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < +inf.0Initial program 86.9%
associate-+l-86.9%
*-commutative86.9%
associate-*r*85.9%
*-commutative85.9%
associate-+l-85.9%
*-commutative85.9%
associate-*r*86.9%
*-commutative86.9%
associate-*l*86.9%
associate-*l*85.9%
Simplified85.9%
if +inf.0 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) Initial program 0.0%
associate-+l-0.0%
*-commutative0.0%
associate-*r*5.4%
*-commutative5.4%
associate-+l-5.4%
*-commutative5.4%
associate-*r*0.0%
*-commutative0.0%
associate-*l*0.0%
associate-*l*5.4%
Simplified5.4%
Applied egg-rr8.6%
Taylor expanded in x around 0 58.6%
fma-def58.6%
fma-def58.6%
associate-/l*79.6%
Simplified79.6%
Taylor expanded in x around 0 69.8%
Taylor expanded in a around inf 64.7%
associate-*l/79.4%
*-commutative79.4%
Simplified79.4%
Final simplification90.5%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (/ (+ (/ b z) (* -4.0 (* a t))) c)))
(if (<= z -1.95e+122)
t_1
(if (<= z 2.25e-20)
(* (+ b (fma x (* 9.0 y) (* a (* z (* -4.0 t))))) (/ 1.0 (* z c)))
(if (<= z 4.5e+207)
(* (/ 1.0 c) (/ (+ b (+ (* x (* 9.0 y)) (* (* -4.0 t) (* z a)))) z))
t_1)))))assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = ((b / z) + (-4.0 * (a * t))) / c;
double tmp;
if (z <= -1.95e+122) {
tmp = t_1;
} else if (z <= 2.25e-20) {
tmp = (b + fma(x, (9.0 * y), (a * (z * (-4.0 * t))))) * (1.0 / (z * c));
} else if (z <= 4.5e+207) {
tmp = (1.0 / c) * ((b + ((x * (9.0 * y)) + ((-4.0 * t) * (z * a)))) / z);
} else {
tmp = t_1;
}
return tmp;
}
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) t_1 = Float64(Float64(Float64(b / z) + Float64(-4.0 * Float64(a * t))) / c) tmp = 0.0 if (z <= -1.95e+122) tmp = t_1; elseif (z <= 2.25e-20) tmp = Float64(Float64(b + fma(x, Float64(9.0 * y), Float64(a * Float64(z * Float64(-4.0 * t))))) * Float64(1.0 / Float64(z * c))); elseif (z <= 4.5e+207) tmp = Float64(Float64(1.0 / c) * Float64(Float64(b + Float64(Float64(x * Float64(9.0 * y)) + Float64(Float64(-4.0 * t) * Float64(z * a)))) / z)); else tmp = t_1; end return tmp end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(N[(N[(b / z), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]}, If[LessEqual[z, -1.95e+122], t$95$1, If[LessEqual[z, 2.25e-20], N[(N[(b + N[(x * N[(9.0 * y), $MachinePrecision] + N[(a * N[(z * N[(-4.0 * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e+207], N[(N[(1.0 / c), $MachinePrecision] * N[(N[(b + N[(N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision] + N[(N[(-4.0 * t), $MachinePrecision] * N[(z * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
t_1 := \frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\
\mathbf{if}\;z \leq -1.95 \cdot 10^{+122}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 2.25 \cdot 10^{-20}:\\
\;\;\;\;\left(b + \mathsf{fma}\left(x, 9 \cdot y, a \cdot \left(z \cdot \left(-4 \cdot t\right)\right)\right)\right) \cdot \frac{1}{z \cdot c}\\
\mathbf{elif}\;z \leq 4.5 \cdot 10^{+207}:\\
\;\;\;\;\frac{1}{c} \cdot \frac{b + \left(x \cdot \left(9 \cdot y\right) + \left(-4 \cdot t\right) \cdot \left(z \cdot a\right)\right)}{z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.95e122 or 4.50000000000000003e207 < z Initial program 47.8%
associate-+l-47.8%
*-commutative47.8%
associate-*r*49.6%
*-commutative49.6%
associate-+l-49.6%
*-commutative49.6%
associate-*r*47.8%
*-commutative47.8%
associate-*l*47.8%
associate-*l*56.5%
Simplified56.5%
Applied egg-rr58.7%
Taylor expanded in x around 0 87.5%
fma-def87.5%
fma-def87.5%
associate-/l*94.5%
Simplified94.5%
Taylor expanded in x around 0 83.1%
if -1.95e122 < z < 2.2500000000000001e-20Initial program 94.1%
associate-+l-94.1%
*-commutative94.1%
associate-*r*94.7%
*-commutative94.7%
associate-+l-94.7%
*-commutative94.7%
associate-*r*94.1%
*-commutative94.1%
associate-*l*94.0%
associate-*l*90.8%
Simplified90.8%
div-inv90.7%
associate-*r*94.0%
cancel-sign-sub-inv94.0%
fma-def94.1%
distribute-lft-neg-in94.1%
*-commutative94.1%
distribute-rgt-neg-in94.1%
distribute-lft-neg-in94.1%
distribute-rgt-neg-in94.1%
metadata-eval94.1%
associate-*r*94.1%
*-commutative94.1%
Applied egg-rr94.1%
if 2.2500000000000001e-20 < z < 4.50000000000000003e207Initial program 73.3%
associate-+l-73.3%
*-commutative73.3%
associate-*r*67.8%
*-commutative67.8%
associate-+l-67.8%
*-commutative67.8%
associate-*r*73.3%
*-commutative73.3%
associate-*l*73.3%
associate-*l*73.4%
Simplified73.4%
Applied egg-rr86.6%
fma-udef86.6%
associate-*r*82.8%
Applied egg-rr82.8%
Final simplification89.4%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (/ (+ (/ b z) (* -4.0 (* a t))) c)))
(if (<= z -1.9e+122)
t_1
(if (<= z 2.35e-20)
(/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c))
(if (<= z 9.2e+207)
(* (/ 1.0 c) (/ (+ b (+ (* x (* 9.0 y)) (* (* -4.0 t) (* z a)))) z))
t_1)))))assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = ((b / z) + (-4.0 * (a * t))) / c;
double tmp;
if (z <= -1.9e+122) {
tmp = t_1;
} else if (z <= 2.35e-20) {
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
} else if (z <= 9.2e+207) {
tmp = (1.0 / c) * ((b + ((x * (9.0 * y)) + ((-4.0 * t) * (z * a)))) / z);
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
t_1 = ((b / z) + ((-4.0d0) * (a * t))) / c
if (z <= (-1.9d+122)) then
tmp = t_1
else if (z <= 2.35d-20) then
tmp = (b + ((y * (9.0d0 * x)) - (a * (t * (z * 4.0d0))))) / (z * c)
else if (z <= 9.2d+207) then
tmp = (1.0d0 / c) * ((b + ((x * (9.0d0 * y)) + (((-4.0d0) * t) * (z * a)))) / z)
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = ((b / z) + (-4.0 * (a * t))) / c;
double tmp;
if (z <= -1.9e+122) {
tmp = t_1;
} else if (z <= 2.35e-20) {
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
} else if (z <= 9.2e+207) {
tmp = (1.0 / c) * ((b + ((x * (9.0 * y)) + ((-4.0 * t) * (z * a)))) / z);
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): t_1 = ((b / z) + (-4.0 * (a * t))) / c tmp = 0 if z <= -1.9e+122: tmp = t_1 elif z <= 2.35e-20: tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c) elif z <= 9.2e+207: tmp = (1.0 / c) * ((b + ((x * (9.0 * y)) + ((-4.0 * t) * (z * a)))) / z) else: tmp = t_1 return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) t_1 = Float64(Float64(Float64(b / z) + Float64(-4.0 * Float64(a * t))) / c) tmp = 0.0 if (z <= -1.9e+122) tmp = t_1; elseif (z <= 2.35e-20) tmp = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c)); elseif (z <= 9.2e+207) tmp = Float64(Float64(1.0 / c) * Float64(Float64(b + Float64(Float64(x * Float64(9.0 * y)) + Float64(Float64(-4.0 * t) * Float64(z * a)))) / z)); else tmp = t_1; end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
t_1 = ((b / z) + (-4.0 * (a * t))) / c;
tmp = 0.0;
if (z <= -1.9e+122)
tmp = t_1;
elseif (z <= 2.35e-20)
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
elseif (z <= 9.2e+207)
tmp = (1.0 / c) * ((b + ((x * (9.0 * y)) + ((-4.0 * t) * (z * a)))) / z);
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(N[(N[(b / z), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]}, If[LessEqual[z, -1.9e+122], t$95$1, If[LessEqual[z, 2.35e-20], 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[(z * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9.2e+207], N[(N[(1.0 / c), $MachinePrecision] * N[(N[(b + N[(N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision] + N[(N[(-4.0 * t), $MachinePrecision] * N[(z * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
t_1 := \frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\
\mathbf{if}\;z \leq -1.9 \cdot 10^{+122}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 2.35 \cdot 10^{-20}:\\
\;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\
\mathbf{elif}\;z \leq 9.2 \cdot 10^{+207}:\\
\;\;\;\;\frac{1}{c} \cdot \frac{b + \left(x \cdot \left(9 \cdot y\right) + \left(-4 \cdot t\right) \cdot \left(z \cdot a\right)\right)}{z}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.8999999999999999e122 or 9.19999999999999979e207 < z Initial program 47.8%
associate-+l-47.8%
*-commutative47.8%
associate-*r*49.6%
*-commutative49.6%
associate-+l-49.6%
*-commutative49.6%
associate-*r*47.8%
*-commutative47.8%
associate-*l*47.8%
associate-*l*56.5%
Simplified56.5%
Applied egg-rr58.7%
Taylor expanded in x around 0 87.5%
fma-def87.5%
fma-def87.5%
associate-/l*94.5%
Simplified94.5%
Taylor expanded in x around 0 83.1%
if -1.8999999999999999e122 < z < 2.35000000000000007e-20Initial program 94.1%
if 2.35000000000000007e-20 < z < 9.19999999999999979e207Initial program 73.3%
associate-+l-73.3%
*-commutative73.3%
associate-*r*67.8%
*-commutative67.8%
associate-+l-67.8%
*-commutative67.8%
associate-*r*73.3%
*-commutative73.3%
associate-*l*73.3%
associate-*l*73.4%
Simplified73.4%
Applied egg-rr86.6%
fma-udef86.6%
associate-*r*82.8%
Applied egg-rr82.8%
Final simplification89.4%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (* 9.0 (* x (/ (/ y z) c)))) (t_2 (* -4.0 (* t (/ a c)))))
(if (<= x -1.95e+58)
t_1
(if (<= x -4.5e-81)
(* (/ 1.0 z) (/ b c))
(if (<= x -5.4e-137)
t_2
(if (<= x -7.2e-276) (/ (/ b z) c) (if (<= x 9e-105) t_2 t_1)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = 9.0 * (x * ((y / z) / c));
double t_2 = -4.0 * (t * (a / c));
double tmp;
if (x <= -1.95e+58) {
tmp = t_1;
} else if (x <= -4.5e-81) {
tmp = (1.0 / z) * (b / c);
} else if (x <= -5.4e-137) {
tmp = t_2;
} else if (x <= -7.2e-276) {
tmp = (b / z) / c;
} else if (x <= 9e-105) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
t_1 = 9.0d0 * (x * ((y / z) / c))
t_2 = (-4.0d0) * (t * (a / c))
if (x <= (-1.95d+58)) then
tmp = t_1
else if (x <= (-4.5d-81)) then
tmp = (1.0d0 / z) * (b / c)
else if (x <= (-5.4d-137)) then
tmp = t_2
else if (x <= (-7.2d-276)) then
tmp = (b / z) / c
else if (x <= 9d-105) then
tmp = t_2
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = 9.0 * (x * ((y / z) / c));
double t_2 = -4.0 * (t * (a / c));
double tmp;
if (x <= -1.95e+58) {
tmp = t_1;
} else if (x <= -4.5e-81) {
tmp = (1.0 / z) * (b / c);
} else if (x <= -5.4e-137) {
tmp = t_2;
} else if (x <= -7.2e-276) {
tmp = (b / z) / c;
} else if (x <= 9e-105) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): t_1 = 9.0 * (x * ((y / z) / c)) t_2 = -4.0 * (t * (a / c)) tmp = 0 if x <= -1.95e+58: tmp = t_1 elif x <= -4.5e-81: tmp = (1.0 / z) * (b / c) elif x <= -5.4e-137: tmp = t_2 elif x <= -7.2e-276: tmp = (b / z) / c elif x <= 9e-105: tmp = t_2 else: tmp = t_1 return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) t_1 = Float64(9.0 * Float64(x * Float64(Float64(y / z) / c))) t_2 = Float64(-4.0 * Float64(t * Float64(a / c))) tmp = 0.0 if (x <= -1.95e+58) tmp = t_1; elseif (x <= -4.5e-81) tmp = Float64(Float64(1.0 / z) * Float64(b / c)); elseif (x <= -5.4e-137) tmp = t_2; elseif (x <= -7.2e-276) tmp = Float64(Float64(b / z) / c); elseif (x <= 9e-105) tmp = t_2; else tmp = t_1; end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
t_1 = 9.0 * (x * ((y / z) / c));
t_2 = -4.0 * (t * (a / c));
tmp = 0.0;
if (x <= -1.95e+58)
tmp = t_1;
elseif (x <= -4.5e-81)
tmp = (1.0 / z) * (b / c);
elseif (x <= -5.4e-137)
tmp = t_2;
elseif (x <= -7.2e-276)
tmp = (b / z) / c;
elseif (x <= 9e-105)
tmp = t_2;
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(9.0 * N[(x * N[(N[(y / z), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.95e+58], t$95$1, If[LessEqual[x, -4.5e-81], N[(N[(1.0 / z), $MachinePrecision] * N[(b / c), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -5.4e-137], t$95$2, If[LessEqual[x, -7.2e-276], N[(N[(b / z), $MachinePrecision] / c), $MachinePrecision], If[LessEqual[x, 9e-105], t$95$2, t$95$1]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
t_1 := 9 \cdot \left(x \cdot \frac{\frac{y}{z}}{c}\right)\\
t_2 := -4 \cdot \left(t \cdot \frac{a}{c}\right)\\
\mathbf{if}\;x \leq -1.95 \cdot 10^{+58}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq -4.5 \cdot 10^{-81}:\\
\;\;\;\;\frac{1}{z} \cdot \frac{b}{c}\\
\mathbf{elif}\;x \leq -5.4 \cdot 10^{-137}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq -7.2 \cdot 10^{-276}:\\
\;\;\;\;\frac{\frac{b}{z}}{c}\\
\mathbf{elif}\;x \leq 9 \cdot 10^{-105}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -1.95000000000000005e58 or 8.9999999999999995e-105 < x Initial program 78.9%
associate-+l-78.9%
*-commutative78.9%
associate-*r*78.3%
*-commutative78.3%
associate-+l-78.3%
*-commutative78.3%
associate-*r*78.9%
*-commutative78.9%
associate-*l*78.9%
associate-*l*76.9%
Simplified76.9%
Applied egg-rr83.4%
Taylor expanded in x around 0 84.6%
fma-def84.6%
fma-def84.6%
associate-/l*87.5%
Simplified87.5%
Taylor expanded in x around inf 51.8%
associate-*r/51.8%
*-commutative51.8%
associate-*r/51.8%
associate-*r/52.2%
associate-/r*53.4%
Simplified53.4%
if -1.95000000000000005e58 < x < -4.5e-81Initial program 84.0%
associate-+l-84.0%
*-commutative84.0%
associate-*r*84.0%
*-commutative84.0%
associate-+l-84.0%
*-commutative84.0%
associate-*r*84.0%
*-commutative84.0%
associate-*l*83.9%
associate-*l*83.8%
Simplified83.8%
Applied egg-rr90.4%
Taylor expanded in b around inf 54.6%
if -4.5e-81 < x < -5.39999999999999986e-137 or -7.19999999999999988e-276 < x < 8.9999999999999995e-105Initial program 78.5%
associate-+l-78.5%
*-commutative78.5%
associate-*r*80.0%
*-commutative80.0%
associate-+l-80.0%
*-commutative80.0%
associate-*r*78.5%
*-commutative78.5%
associate-*l*78.5%
associate-*l*83.1%
Simplified83.1%
Applied egg-rr77.3%
Taylor expanded in x around 0 89.3%
fma-def89.3%
fma-def89.3%
associate-/l*87.7%
Simplified87.7%
Taylor expanded in x around 0 82.9%
Taylor expanded in a around inf 47.4%
associate-*l/49.0%
*-commutative49.0%
Simplified49.0%
if -5.39999999999999986e-137 < x < -7.19999999999999988e-276Initial program 83.5%
associate-+l-83.5%
*-commutative83.5%
associate-*r*79.5%
*-commutative79.5%
associate-+l-79.5%
*-commutative79.5%
associate-*r*83.5%
*-commutative83.5%
associate-*l*83.5%
associate-*l*83.5%
Simplified83.5%
Applied egg-rr83.6%
Taylor expanded in b around inf 61.4%
*-commutative61.4%
associate-/r*65.6%
Simplified65.6%
Final simplification53.6%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (* 9.0 (* (/ y z) (/ x c)))) (t_2 (* -4.0 (* t (/ a c)))))
(if (<= x -1.45e+57)
t_1
(if (<= x -7e-81)
(* (/ 1.0 z) (/ b c))
(if (<= x -1.06e-135)
t_2
(if (<= x -6.9e-274) (/ (/ b z) c) (if (<= x 4.1e-119) t_2 t_1)))))))assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = 9.0 * ((y / z) * (x / c));
double t_2 = -4.0 * (t * (a / c));
double tmp;
if (x <= -1.45e+57) {
tmp = t_1;
} else if (x <= -7e-81) {
tmp = (1.0 / z) * (b / c);
} else if (x <= -1.06e-135) {
tmp = t_2;
} else if (x <= -6.9e-274) {
tmp = (b / z) / c;
} else if (x <= 4.1e-119) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
t_1 = 9.0d0 * ((y / z) * (x / c))
t_2 = (-4.0d0) * (t * (a / c))
if (x <= (-1.45d+57)) then
tmp = t_1
else if (x <= (-7d-81)) then
tmp = (1.0d0 / z) * (b / c)
else if (x <= (-1.06d-135)) then
tmp = t_2
else if (x <= (-6.9d-274)) then
tmp = (b / z) / c
else if (x <= 4.1d-119) then
tmp = t_2
else
tmp = t_1
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = 9.0 * ((y / z) * (x / c));
double t_2 = -4.0 * (t * (a / c));
double tmp;
if (x <= -1.45e+57) {
tmp = t_1;
} else if (x <= -7e-81) {
tmp = (1.0 / z) * (b / c);
} else if (x <= -1.06e-135) {
tmp = t_2;
} else if (x <= -6.9e-274) {
tmp = (b / z) / c;
} else if (x <= 4.1e-119) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): t_1 = 9.0 * ((y / z) * (x / c)) t_2 = -4.0 * (t * (a / c)) tmp = 0 if x <= -1.45e+57: tmp = t_1 elif x <= -7e-81: tmp = (1.0 / z) * (b / c) elif x <= -1.06e-135: tmp = t_2 elif x <= -6.9e-274: tmp = (b / z) / c elif x <= 4.1e-119: tmp = t_2 else: tmp = t_1 return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) t_1 = Float64(9.0 * Float64(Float64(y / z) * Float64(x / c))) t_2 = Float64(-4.0 * Float64(t * Float64(a / c))) tmp = 0.0 if (x <= -1.45e+57) tmp = t_1; elseif (x <= -7e-81) tmp = Float64(Float64(1.0 / z) * Float64(b / c)); elseif (x <= -1.06e-135) tmp = t_2; elseif (x <= -6.9e-274) tmp = Float64(Float64(b / z) / c); elseif (x <= 4.1e-119) tmp = t_2; else tmp = t_1; end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
t_1 = 9.0 * ((y / z) * (x / c));
t_2 = -4.0 * (t * (a / c));
tmp = 0.0;
if (x <= -1.45e+57)
tmp = t_1;
elseif (x <= -7e-81)
tmp = (1.0 / z) * (b / c);
elseif (x <= -1.06e-135)
tmp = t_2;
elseif (x <= -6.9e-274)
tmp = (b / z) / c;
elseif (x <= 4.1e-119)
tmp = t_2;
else
tmp = t_1;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(9.0 * N[(N[(y / z), $MachinePrecision] * N[(x / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.45e+57], t$95$1, If[LessEqual[x, -7e-81], N[(N[(1.0 / z), $MachinePrecision] * N[(b / c), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -1.06e-135], t$95$2, If[LessEqual[x, -6.9e-274], N[(N[(b / z), $MachinePrecision] / c), $MachinePrecision], If[LessEqual[x, 4.1e-119], t$95$2, t$95$1]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
t_1 := 9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\
t_2 := -4 \cdot \left(t \cdot \frac{a}{c}\right)\\
\mathbf{if}\;x \leq -1.45 \cdot 10^{+57}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq -7 \cdot 10^{-81}:\\
\;\;\;\;\frac{1}{z} \cdot \frac{b}{c}\\
\mathbf{elif}\;x \leq -1.06 \cdot 10^{-135}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;x \leq -6.9 \cdot 10^{-274}:\\
\;\;\;\;\frac{\frac{b}{z}}{c}\\
\mathbf{elif}\;x \leq 4.1 \cdot 10^{-119}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -1.4500000000000001e57 or 4.1000000000000002e-119 < x Initial program 78.6%
associate-+l-78.6%
*-commutative78.6%
associate-*r*77.9%
*-commutative77.9%
associate-+l-77.9%
*-commutative77.9%
associate-*r*78.6%
*-commutative78.6%
associate-*l*78.5%
associate-*l*76.5%
Simplified76.5%
Taylor expanded in x around inf 51.8%
associate-*r/51.8%
*-commutative51.8%
*-commutative51.8%
associate-/l*51.8%
associate-/r/51.8%
*-commutative51.8%
Simplified51.8%
Taylor expanded in z around 0 51.8%
associate-/l/51.7%
Simplified51.7%
Taylor expanded in z around 0 51.8%
times-frac54.8%
Simplified54.8%
if -1.4500000000000001e57 < x < -6.99999999999999973e-81Initial program 84.0%
associate-+l-84.0%
*-commutative84.0%
associate-*r*84.0%
*-commutative84.0%
associate-+l-84.0%
*-commutative84.0%
associate-*r*84.0%
*-commutative84.0%
associate-*l*83.9%
associate-*l*83.8%
Simplified83.8%
Applied egg-rr90.4%
Taylor expanded in b around inf 54.6%
if -6.99999999999999973e-81 < x < -1.06000000000000004e-135 or -6.89999999999999963e-274 < x < 4.1000000000000002e-119Initial program 79.3%
associate-+l-79.3%
*-commutative79.3%
associate-*r*80.9%
*-commutative80.9%
associate-+l-80.9%
*-commutative80.9%
associate-*r*79.3%
*-commutative79.3%
associate-*l*79.3%
associate-*l*84.1%
Simplified84.1%
Applied egg-rr78.1%
Taylor expanded in x around 0 89.0%
fma-def89.0%
fma-def89.0%
associate-/l*88.9%
Simplified88.9%
Taylor expanded in x around 0 84.0%
Taylor expanded in a around inf 47.3%
associate-*l/50.4%
*-commutative50.4%
Simplified50.4%
if -1.06000000000000004e-135 < x < -6.89999999999999963e-274Initial program 83.5%
associate-+l-83.5%
*-commutative83.5%
associate-*r*79.5%
*-commutative79.5%
associate-+l-79.5%
*-commutative79.5%
associate-*r*83.5%
*-commutative83.5%
associate-*l*83.5%
associate-*l*83.5%
Simplified83.5%
Applied egg-rr83.6%
Taylor expanded in b around inf 61.4%
*-commutative61.4%
associate-/r*65.6%
Simplified65.6%
Final simplification54.7%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. (FPCore (x y z t a b c) :precision binary64 (if (or (<= z -1.95e+122) (not (<= z 7.2e+127))) (/ (+ (/ b z) (* -4.0 (* a t))) c) (/ (+ b (- (* x (* 9.0 y)) (* (* a t) (* z 4.0)))) (* z c))))
assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((z <= -1.95e+122) || !(z <= 7.2e+127)) {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
} else {
tmp = (b + ((x * (9.0 * y)) - ((a * t) * (z * 4.0)))) / (z * c);
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
if ((z <= (-1.95d+122)) .or. (.not. (z <= 7.2d+127))) then
tmp = ((b / z) + ((-4.0d0) * (a * t))) / c
else
tmp = (b + ((x * (9.0d0 * y)) - ((a * t) * (z * 4.0d0)))) / (z * c)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((z <= -1.95e+122) || !(z <= 7.2e+127)) {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
} else {
tmp = (b + ((x * (9.0 * y)) - ((a * t) * (z * 4.0)))) / (z * c);
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): tmp = 0 if (z <= -1.95e+122) or not (z <= 7.2e+127): tmp = ((b / z) + (-4.0 * (a * t))) / c else: tmp = (b + ((x * (9.0 * y)) - ((a * t) * (z * 4.0)))) / (z * c) return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) tmp = 0.0 if ((z <= -1.95e+122) || !(z <= 7.2e+127)) tmp = Float64(Float64(Float64(b / z) + Float64(-4.0 * Float64(a * t))) / c); else tmp = Float64(Float64(b + Float64(Float64(x * Float64(9.0 * y)) - Float64(Float64(a * t) * Float64(z * 4.0)))) / Float64(z * c)); end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
tmp = 0.0;
if ((z <= -1.95e+122) || ~((z <= 7.2e+127)))
tmp = ((b / z) + (-4.0 * (a * t))) / c;
else
tmp = (b + ((x * (9.0 * y)) - ((a * t) * (z * 4.0)))) / (z * c);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -1.95e+122], N[Not[LessEqual[z, 7.2e+127]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $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[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.95 \cdot 10^{+122} \lor \neg \left(z \leq 7.2 \cdot 10^{+127}\right):\\
\;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\
\mathbf{else}:\\
\;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(a \cdot t\right) \cdot \left(z \cdot 4\right)\right)}{z \cdot c}\\
\end{array}
\end{array}
if z < -1.95e122 or 7.19999999999999958e127 < z Initial program 53.1%
associate-+l-53.1%
*-commutative53.1%
associate-*r*50.8%
*-commutative50.8%
associate-+l-50.8%
*-commutative50.8%
associate-*r*53.1%
*-commutative53.1%
associate-*l*53.1%
associate-*l*59.5%
Simplified59.5%
Applied egg-rr66.1%
Taylor expanded in x around 0 88.3%
fma-def88.3%
fma-def88.3%
associate-/l*94.7%
Simplified94.7%
Taylor expanded in x around 0 81.4%
if -1.95e122 < z < 7.19999999999999958e127Initial program 91.3%
associate-+l-91.3%
*-commutative91.3%
associate-*r*91.8%
*-commutative91.8%
associate-+l-91.8%
*-commutative91.8%
associate-*r*91.3%
*-commutative91.3%
associate-*l*91.3%
associate-*l*88.5%
Simplified88.5%
Final simplification86.4%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. (FPCore (x y z t a b c) :precision binary64 (if (or (<= z -1.9e+122) (not (<= z 1.06e+127))) (/ (+ (/ b z) (* -4.0 (* a t))) c) (/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c))))
assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((z <= -1.9e+122) || !(z <= 1.06e+127)) {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
} else {
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
if ((z <= (-1.9d+122)) .or. (.not. (z <= 1.06d+127))) then
tmp = ((b / z) + ((-4.0d0) * (a * t))) / c
else
tmp = (b + ((y * (9.0d0 * x)) - (a * (t * (z * 4.0d0))))) / (z * c)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((z <= -1.9e+122) || !(z <= 1.06e+127)) {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
} else {
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): tmp = 0 if (z <= -1.9e+122) or not (z <= 1.06e+127): tmp = ((b / z) + (-4.0 * (a * t))) / c else: tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c) return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) tmp = 0.0 if ((z <= -1.9e+122) || !(z <= 1.06e+127)) tmp = Float64(Float64(Float64(b / z) + Float64(-4.0 * Float64(a * t))) / c); else tmp = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c)); end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
tmp = 0.0;
if ((z <= -1.9e+122) || ~((z <= 1.06e+127)))
tmp = ((b / z) + (-4.0 * (a * t))) / c;
else
tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -1.9e+122], N[Not[LessEqual[z, 1.06e+127]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $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[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{+122} \lor \neg \left(z \leq 1.06 \cdot 10^{+127}\right):\\
\;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\
\mathbf{else}:\\
\;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\
\end{array}
\end{array}
if z < -1.8999999999999999e122 or 1.06000000000000006e127 < z Initial program 53.1%
associate-+l-53.1%
*-commutative53.1%
associate-*r*50.8%
*-commutative50.8%
associate-+l-50.8%
*-commutative50.8%
associate-*r*53.1%
*-commutative53.1%
associate-*l*53.1%
associate-*l*59.5%
Simplified59.5%
Applied egg-rr66.1%
Taylor expanded in x around 0 88.3%
fma-def88.3%
fma-def88.3%
associate-/l*94.7%
Simplified94.7%
Taylor expanded in x around 0 81.4%
if -1.8999999999999999e122 < z < 1.06000000000000006e127Initial program 91.3%
Final simplification88.3%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. (FPCore (x y z t a b c) :precision binary64 (if (or (<= x -1.85e+59) (not (<= x 3e-141))) (+ (* -4.0 (/ (* a t) c)) (* 9.0 (* (/ y z) (/ x c)))) (/ (+ (/ b z) (* -4.0 (* a t))) c)))
assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((x <= -1.85e+59) || !(x <= 3e-141)) {
tmp = (-4.0 * ((a * t) / c)) + (9.0 * ((y / z) * (x / c)));
} else {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
if ((x <= (-1.85d+59)) .or. (.not. (x <= 3d-141))) then
tmp = ((-4.0d0) * ((a * t) / c)) + (9.0d0 * ((y / z) * (x / c)))
else
tmp = ((b / z) + ((-4.0d0) * (a * t))) / c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((x <= -1.85e+59) || !(x <= 3e-141)) {
tmp = (-4.0 * ((a * t) / c)) + (9.0 * ((y / z) * (x / c)));
} else {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): tmp = 0 if (x <= -1.85e+59) or not (x <= 3e-141): tmp = (-4.0 * ((a * t) / c)) + (9.0 * ((y / z) * (x / c))) else: tmp = ((b / z) + (-4.0 * (a * t))) / c return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) tmp = 0.0 if ((x <= -1.85e+59) || !(x <= 3e-141)) tmp = Float64(Float64(-4.0 * Float64(Float64(a * t) / c)) + Float64(9.0 * Float64(Float64(y / z) * Float64(x / c)))); else tmp = Float64(Float64(Float64(b / z) + Float64(-4.0 * Float64(a * t))) / c); end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
tmp = 0.0;
if ((x <= -1.85e+59) || ~((x <= 3e-141)))
tmp = (-4.0 * ((a * t) / c)) + (9.0 * ((y / z) * (x / c)));
else
tmp = ((b / z) + (-4.0 * (a * t))) / c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[x, -1.85e+59], N[Not[LessEqual[x, 3e-141]], $MachinePrecision]], N[(N[(-4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision] + N[(9.0 * N[(N[(y / z), $MachinePrecision] * N[(x / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b / z), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.85 \cdot 10^{+59} \lor \neg \left(x \leq 3 \cdot 10^{-141}\right):\\
\;\;\;\;-4 \cdot \frac{a \cdot t}{c} + 9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\
\end{array}
\end{array}
if x < -1.84999999999999999e59 or 2.99999999999999983e-141 < x Initial program 78.5%
associate-+l-78.5%
*-commutative78.5%
associate-*r*77.9%
*-commutative77.9%
associate-+l-77.9%
*-commutative77.9%
associate-*r*78.5%
*-commutative78.5%
associate-*l*78.5%
associate-*l*76.5%
Simplified76.5%
Taylor expanded in b around 0 65.0%
Taylor expanded in x around 0 65.0%
*-commutative65.0%
*-commutative65.0%
times-frac69.8%
Applied egg-rr69.8%
if -1.84999999999999999e59 < x < 2.99999999999999983e-141Initial program 81.6%
associate-+l-81.6%
*-commutative81.6%
associate-*r*81.6%
*-commutative81.6%
associate-+l-81.6%
*-commutative81.6%
associate-*r*81.6%
*-commutative81.6%
associate-*l*81.6%
associate-*l*84.2%
Simplified84.2%
Applied egg-rr81.7%
Taylor expanded in x around 0 90.2%
fma-def90.2%
fma-def90.2%
associate-/l*89.3%
Simplified89.3%
Taylor expanded in x around 0 80.4%
Final simplification74.4%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (* -4.0 (* a t))))
(if (or (<= b -5.2e+22) (not (<= b 1.25e-36)))
(/ (+ (/ b z) t_1) c)
(/ (+ t_1 (* 9.0 (/ (* x y) z))) c))))assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = -4.0 * (a * t);
double tmp;
if ((b <= -5.2e+22) || !(b <= 1.25e-36)) {
tmp = ((b / z) + t_1) / c;
} else {
tmp = (t_1 + (9.0 * ((x * y) / z))) / c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
t_1 = (-4.0d0) * (a * t)
if ((b <= (-5.2d+22)) .or. (.not. (b <= 1.25d-36))) then
tmp = ((b / z) + t_1) / c
else
tmp = (t_1 + (9.0d0 * ((x * y) / z))) / c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = -4.0 * (a * t);
double tmp;
if ((b <= -5.2e+22) || !(b <= 1.25e-36)) {
tmp = ((b / z) + t_1) / c;
} else {
tmp = (t_1 + (9.0 * ((x * y) / z))) / c;
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): t_1 = -4.0 * (a * t) tmp = 0 if (b <= -5.2e+22) or not (b <= 1.25e-36): tmp = ((b / z) + t_1) / c else: tmp = (t_1 + (9.0 * ((x * y) / z))) / c return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) t_1 = Float64(-4.0 * Float64(a * t)) tmp = 0.0 if ((b <= -5.2e+22) || !(b <= 1.25e-36)) tmp = Float64(Float64(Float64(b / z) + t_1) / c); else tmp = Float64(Float64(t_1 + Float64(9.0 * Float64(Float64(x * y) / z))) / c); end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
t_1 = -4.0 * (a * t);
tmp = 0.0;
if ((b <= -5.2e+22) || ~((b <= 1.25e-36)))
tmp = ((b / z) + t_1) / c;
else
tmp = (t_1 + (9.0 * ((x * y) / z))) / c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[b, -5.2e+22], N[Not[LessEqual[b, 1.25e-36]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] + t$95$1), $MachinePrecision] / c), $MachinePrecision], N[(N[(t$95$1 + N[(9.0 * N[(N[(x * y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
t_1 := -4 \cdot \left(a \cdot t\right)\\
\mathbf{if}\;b \leq -5.2 \cdot 10^{+22} \lor \neg \left(b \leq 1.25 \cdot 10^{-36}\right):\\
\;\;\;\;\frac{\frac{b}{z} + t\_1}{c}\\
\mathbf{else}:\\
\;\;\;\;\frac{t\_1 + 9 \cdot \frac{x \cdot y}{z}}{c}\\
\end{array}
\end{array}
if b < -5.2e22 or 1.25000000000000001e-36 < b Initial program 77.4%
associate-+l-77.4%
*-commutative77.4%
associate-*r*79.6%
*-commutative79.6%
associate-+l-79.6%
*-commutative79.6%
associate-*r*77.4%
*-commutative77.4%
associate-*l*77.4%
associate-*l*78.8%
Simplified78.8%
Applied egg-rr81.9%
Taylor expanded in x around 0 86.1%
fma-def86.1%
fma-def86.1%
associate-/l*89.8%
Simplified89.8%
Taylor expanded in x around 0 78.4%
if -5.2e22 < b < 1.25000000000000001e-36Initial program 82.5%
associate-+l-82.5%
*-commutative82.5%
associate-*r*79.4%
*-commutative79.4%
associate-+l-79.4%
*-commutative79.4%
associate-*r*82.5%
*-commutative82.5%
associate-*l*82.4%
associate-*l*80.9%
Simplified80.9%
Applied egg-rr83.5%
Taylor expanded in x around 0 88.8%
fma-def88.8%
fma-def88.8%
associate-/l*86.5%
Simplified86.5%
Taylor expanded in b around 0 81.0%
Final simplification79.6%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. (FPCore (x y z t a b c) :precision binary64 (if (or (<= z -3.5e+16) (not (<= z 4.9e+86))) (/ (+ (/ b z) (* -4.0 (* a t))) c) (/ (+ b (* 9.0 (* x y))) (* z c))))
assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((z <= -3.5e+16) || !(z <= 4.9e+86)) {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
} else {
tmp = (b + (9.0 * (x * y))) / (z * c);
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
if ((z <= (-3.5d+16)) .or. (.not. (z <= 4.9d+86))) then
tmp = ((b / z) + ((-4.0d0) * (a * t))) / c
else
tmp = (b + (9.0d0 * (x * y))) / (z * c)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((z <= -3.5e+16) || !(z <= 4.9e+86)) {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
} else {
tmp = (b + (9.0 * (x * y))) / (z * c);
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): tmp = 0 if (z <= -3.5e+16) or not (z <= 4.9e+86): tmp = ((b / z) + (-4.0 * (a * t))) / c else: tmp = (b + (9.0 * (x * y))) / (z * c) return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) tmp = 0.0 if ((z <= -3.5e+16) || !(z <= 4.9e+86)) tmp = Float64(Float64(Float64(b / z) + Float64(-4.0 * Float64(a * t))) / c); else tmp = Float64(Float64(b + Float64(9.0 * Float64(x * y))) / Float64(z * c)); end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
tmp = 0.0;
if ((z <= -3.5e+16) || ~((z <= 4.9e+86)))
tmp = ((b / z) + (-4.0 * (a * t))) / c;
else
tmp = (b + (9.0 * (x * y))) / (z * c);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -3.5e+16], N[Not[LessEqual[z, 4.9e+86]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision], N[(N[(b + N[(9.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.5 \cdot 10^{+16} \lor \neg \left(z \leq 4.9 \cdot 10^{+86}\right):\\
\;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\
\mathbf{else}:\\
\;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\
\end{array}
\end{array}
if z < -3.5e16 or 4.8999999999999999e86 < z Initial program 61.7%
associate-+l-61.7%
*-commutative61.7%
associate-*r*60.9%
*-commutative60.9%
associate-+l-60.9%
*-commutative60.9%
associate-*r*61.7%
*-commutative61.7%
associate-*l*61.7%
associate-*l*67.2%
Simplified67.2%
Applied egg-rr72.1%
Taylor expanded in x around 0 88.8%
fma-def88.8%
fma-def88.8%
associate-/l*92.5%
Simplified92.5%
Taylor expanded in x around 0 76.4%
if -3.5e16 < z < 4.8999999999999999e86Initial program 92.8%
associate-+l-92.8%
*-commutative92.8%
associate-*r*92.8%
*-commutative92.8%
associate-+l-92.8%
*-commutative92.8%
associate-*r*92.8%
*-commutative92.8%
associate-*l*92.8%
associate-*l*88.9%
Simplified88.9%
Taylor expanded in x around inf 80.6%
Final simplification78.8%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
:precision binary64
(if (<= x -3.5e+129)
(* 9.0 (* (/ y z) (/ x c)))
(if (<= x 480000000.0)
(/ (+ (/ b z) (* -4.0 (* a t))) c)
(/ x (/ (* c (* z 0.1111111111111111)) y)))))assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (x <= -3.5e+129) {
tmp = 9.0 * ((y / z) * (x / c));
} else if (x <= 480000000.0) {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
} else {
tmp = x / ((c * (z * 0.1111111111111111)) / y);
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
if (x <= (-3.5d+129)) then
tmp = 9.0d0 * ((y / z) * (x / c))
else if (x <= 480000000.0d0) then
tmp = ((b / z) + ((-4.0d0) * (a * t))) / c
else
tmp = x / ((c * (z * 0.1111111111111111d0)) / y)
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (x <= -3.5e+129) {
tmp = 9.0 * ((y / z) * (x / c));
} else if (x <= 480000000.0) {
tmp = ((b / z) + (-4.0 * (a * t))) / c;
} else {
tmp = x / ((c * (z * 0.1111111111111111)) / y);
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): tmp = 0 if x <= -3.5e+129: tmp = 9.0 * ((y / z) * (x / c)) elif x <= 480000000.0: tmp = ((b / z) + (-4.0 * (a * t))) / c else: tmp = x / ((c * (z * 0.1111111111111111)) / y) return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) tmp = 0.0 if (x <= -3.5e+129) tmp = Float64(9.0 * Float64(Float64(y / z) * Float64(x / c))); elseif (x <= 480000000.0) tmp = Float64(Float64(Float64(b / z) + Float64(-4.0 * Float64(a * t))) / c); else tmp = Float64(x / Float64(Float64(c * Float64(z * 0.1111111111111111)) / y)); end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
tmp = 0.0;
if (x <= -3.5e+129)
tmp = 9.0 * ((y / z) * (x / c));
elseif (x <= 480000000.0)
tmp = ((b / z) + (-4.0 * (a * t))) / c;
else
tmp = x / ((c * (z * 0.1111111111111111)) / y);
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[x, -3.5e+129], N[(9.0 * N[(N[(y / z), $MachinePrecision] * N[(x / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 480000000.0], N[(N[(N[(b / z), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision], N[(x / N[(N[(c * N[(z * 0.1111111111111111), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3.5 \cdot 10^{+129}:\\
\;\;\;\;9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\
\mathbf{elif}\;x \leq 480000000:\\
\;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{\frac{c \cdot \left(z \cdot 0.1111111111111111\right)}{y}}\\
\end{array}
\end{array}
if x < -3.4999999999999998e129Initial program 74.8%
associate-+l-74.8%
*-commutative74.8%
associate-*r*74.8%
*-commutative74.8%
associate-+l-74.8%
*-commutative74.8%
associate-*r*74.8%
*-commutative74.8%
associate-*l*74.7%
associate-*l*70.1%
Simplified70.1%
Taylor expanded in x around inf 68.1%
associate-*r/68.0%
*-commutative68.0%
*-commutative68.0%
associate-/l*68.1%
associate-/r/68.0%
*-commutative68.0%
Simplified68.0%
Taylor expanded in z around 0 68.0%
associate-/l/67.9%
Simplified67.9%
Taylor expanded in z around 0 68.1%
times-frac72.9%
Simplified72.9%
if -3.4999999999999998e129 < x < 4.8e8Initial program 80.4%
associate-+l-80.4%
*-commutative80.4%
associate-*r*79.8%
*-commutative79.8%
associate-+l-79.8%
*-commutative79.8%
associate-*r*80.4%
*-commutative80.4%
associate-*l*80.3%
associate-*l*82.2%
Simplified82.2%
Applied egg-rr83.6%
Taylor expanded in x around 0 91.3%
fma-def91.3%
fma-def91.3%
associate-/l*90.7%
Simplified90.7%
Taylor expanded in x around 0 76.6%
if 4.8e8 < x Initial program 82.2%
associate-+l-82.2%
*-commutative82.2%
associate-*r*82.3%
*-commutative82.3%
associate-+l-82.3%
*-commutative82.3%
associate-*r*82.2%
*-commutative82.2%
associate-*l*82.2%
associate-*l*80.6%
Simplified80.6%
Taylor expanded in x around inf 49.1%
associate-*r/49.1%
*-commutative49.1%
*-commutative49.1%
associate-/l*49.1%
associate-/r/49.1%
*-commutative49.1%
Simplified49.1%
Taylor expanded in z around 0 49.1%
associate-/l/49.1%
Simplified49.1%
expm1-log1p-u32.0%
expm1-udef23.2%
*-commutative23.2%
clear-num23.2%
un-div-inv23.2%
div-inv23.2%
clear-num23.2%
div-inv23.2%
metadata-eval23.2%
Applied egg-rr23.2%
expm1-def31.9%
expm1-log1p49.1%
associate-/l*52.5%
Simplified52.5%
Final simplification70.8%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. (FPCore (x y z t a b c) :precision binary64 (if (or (<= a -6.2e-52) (not (<= a 3.3e-19))) (* -4.0 (* t (/ a c))) (/ (/ b z) c)))
assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((a <= -6.2e-52) || !(a <= 3.3e-19)) {
tmp = -4.0 * (t * (a / c));
} else {
tmp = (b / z) / c;
}
return tmp;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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) :: tmp
if ((a <= (-6.2d-52)) .or. (.not. (a <= 3.3d-19))) then
tmp = (-4.0d0) * (t * (a / c))
else
tmp = (b / z) / c
end if
code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((a <= -6.2e-52) || !(a <= 3.3e-19)) {
tmp = -4.0 * (t * (a / c));
} else {
tmp = (b / z) / c;
}
return tmp;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): tmp = 0 if (a <= -6.2e-52) or not (a <= 3.3e-19): tmp = -4.0 * (t * (a / c)) else: tmp = (b / z) / c return tmp
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) tmp = 0.0 if ((a <= -6.2e-52) || !(a <= 3.3e-19)) tmp = Float64(-4.0 * Float64(t * Float64(a / c))); else tmp = Float64(Float64(b / z) / c); end return tmp end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
tmp = 0.0;
if ((a <= -6.2e-52) || ~((a <= 3.3e-19)))
tmp = -4.0 * (t * (a / c));
else
tmp = (b / z) / c;
end
tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[a, -6.2e-52], N[Not[LessEqual[a, 3.3e-19]], $MachinePrecision]], N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b / z), $MachinePrecision] / c), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\begin{array}{l}
\mathbf{if}\;a \leq -6.2 \cdot 10^{-52} \lor \neg \left(a \leq 3.3 \cdot 10^{-19}\right):\\
\;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{b}{z}}{c}\\
\end{array}
\end{array}
if a < -6.1999999999999998e-52 or 3.2999999999999998e-19 < a Initial program 79.7%
associate-+l-79.7%
*-commutative79.7%
associate-*r*75.4%
*-commutative75.4%
associate-+l-75.4%
*-commutative75.4%
associate-*r*79.7%
*-commutative79.7%
associate-*l*79.7%
associate-*l*76.1%
Simplified76.1%
Applied egg-rr80.9%
Taylor expanded in x around 0 83.9%
fma-def83.9%
fma-def83.9%
associate-/l*85.5%
Simplified85.5%
Taylor expanded in x around 0 73.5%
Taylor expanded in a around inf 49.2%
associate-*l/54.7%
*-commutative54.7%
Simplified54.7%
if -6.1999999999999998e-52 < a < 3.2999999999999998e-19Initial program 80.0%
associate-+l-80.0%
*-commutative80.0%
associate-*r*84.0%
*-commutative84.0%
associate-+l-84.0%
*-commutative84.0%
associate-*r*80.0%
*-commutative80.0%
associate-*l*79.9%
associate-*l*84.0%
Simplified84.0%
Applied egg-rr84.8%
Taylor expanded in b around inf 39.2%
*-commutative39.2%
associate-/r*43.2%
Simplified43.2%
Final simplification49.2%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. (FPCore (x y z t a b c) :precision binary64 (/ b (* z c)))
assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
return b / (z * c);
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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 = b / (z * c)
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
return b / (z * c);
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): return b / (z * c)
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) return Float64(b / Float64(z * c)) end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp = code(x, y, z, t, a, b, c)
tmp = b / (z * c);
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\frac{b}{z \cdot c}
\end{array}
Initial program 79.8%
associate-+l-79.8%
*-commutative79.8%
associate-*r*79.5%
*-commutative79.5%
associate-+l-79.5%
*-commutative79.5%
associate-*r*79.8%
*-commutative79.8%
associate-*l*79.8%
associate-*l*79.8%
Simplified79.8%
Taylor expanded in b around inf 35.8%
*-commutative35.8%
Simplified35.8%
Final simplification35.8%
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. (FPCore (x y z t a b c) :precision binary64 (/ (/ b z) c))
assert(x < y && y < z && z < t && t < a && a < b && b < c);
assert(x < y && y < z && z < t && t < a && a < b && b < c);
double code(double x, double y, double z, double t, double a, double b, double c) {
return (b / z) / c;
}
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function.
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 = (b / z) / c
end function
assert x < y && y < z && z < t && t < a && a < b && b < c;
assert x < y && y < z && z < t && t < a && a < b && b < c;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
return (b / z) / c;
}
[x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) [x, y, z, t, a, b, c] = sort([x, y, z, t, a, b, c]) def code(x, y, z, t, a, b, c): return (b / z) / c
x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) x, y, z, t, a, b, c = sort([x, y, z, t, a, b, c]) function code(x, y, z, t, a, b, c) return Float64(Float64(b / z) / c) end
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
x, y, z, t, a, b, c = num2cell(sort([x, y, z, t, a, b, c])){:}
function tmp = code(x, y, z, t, a, b, c)
tmp = (b / z) / c;
end
NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. NOTE: x, y, z, t, a, b, and c should be sorted in increasing order before calling this function. code[x_, y_, z_, t_, a_, b_, c_] := N[(N[(b / z), $MachinePrecision] / c), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\\\
[x, y, z, t, a, b, c] = \mathsf{sort}([x, y, z, t, a, b, c])\\
\\
\frac{\frac{b}{z}}{c}
\end{array}
Initial program 79.8%
associate-+l-79.8%
*-commutative79.8%
associate-*r*79.5%
*-commutative79.5%
associate-+l-79.5%
*-commutative79.5%
associate-*r*79.8%
*-commutative79.8%
associate-*l*79.8%
associate-*l*79.8%
Simplified79.8%
Applied egg-rr82.7%
Taylor expanded in b around inf 35.8%
*-commutative35.8%
associate-/r*37.6%
Simplified37.6%
Final simplification37.6%
(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 2024031
(FPCore (x y z t a b c)
:name "Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, J"
:precision binary64
:herbie-target
(if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) -1.100156740804105e-171) (/ (+ (- (* (* x 9.0) y) (* (* z 4.0) (* t a))) b) (* z c)) (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) 0.0) (/ (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) z) c) (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) 1.1708877911747488e-53) (/ (+ (- (* (* x 9.0) y) (* (* z 4.0) (* t a))) b) (* z c)) (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) 2.876823679546137e+130) (- (+ (* (* 9.0 (/ y c)) (/ x z)) (/ b (* c z))) (* 4.0 (/ (* a t) c))) (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) 1.3838515042456319e+158) (/ (+ (- (* (* x 9.0) y) (* (* z 4.0) (* t a))) b) (* z c)) (- (+ (* 9.0 (* (/ y (* c z)) x)) (/ b (* c z))) (* 4.0 (/ (* a t) c))))))))
(/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)))