Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, E

Percentage Accurate: 85.3% → 89.6%
Time: 29.0s
Alternatives: 22
Speedup: 0.9×

Specification

?
\[\begin{array}{l} \\ \left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (-
  (-
   (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c))
   (* (* x 4.0) i))
  (* (* j 27.0) k)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    code = (((((((x * 18.0d0) * y) * z) * t) - ((a * 4.0d0) * t)) + (b * c)) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
def code(x, y, z, t, a, b, c, i, j, k):
	return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
function code(x, y, z, t, a, b, c, i, j, k)
	return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(Float64(a * 4.0) * t)) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k))
end
function tmp = code(x, y, z, t, a, b, c, i, j, k)
	tmp = (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(N[(a * 4.0), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 22 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 85.3% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (-
  (-
   (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c))
   (* (* x 4.0) i))
  (* (* j 27.0) k)))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    code = (((((((x * 18.0d0) * y) * z) * t) - ((a * 4.0d0) * t)) + (b * c)) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
}
def code(x, y, z, t, a, b, c, i, j, k):
	return (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
function code(x, y, z, t, a, b, c, i, j, k)
	return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(Float64(a * 4.0) * t)) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k))
end
function tmp = code(x, y, z, t, a, b, c, i, j, k)
	tmp = (((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(N[(a * 4.0), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k
\end{array}

Alternative 1: 89.6% accurate, 0.5× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \left(x \cdot 4\right) \cdot i\\ t_2 := \left(j \cdot 27\right) \cdot k\\ t_3 := t \cdot \left(a \cdot 4\right)\\ \mathbf{if}\;\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t\_3\right) + b \cdot c\right) - t\_1\right) - t\_2 \leq \infty:\\ \;\;\;\;\left(\left(b \cdot c + \left(\left(z \cdot t\right) \cdot \left(18 \cdot \left(x \cdot y\right)\right) - t\_3\right)\right) - t\_1\right) - t\_2\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* (* x 4.0) i)) (t_2 (* (* j 27.0) k)) (t_3 (* t (* a 4.0))))
   (if (<=
        (- (- (+ (- (* (* (* (* x 18.0) y) z) t) t_3) (* b c)) t_1) t_2)
        INFINITY)
     (- (- (+ (* b c) (- (* (* z t) (* 18.0 (* x y))) t_3)) t_1) t_2)
     (* x (+ (* (* 18.0 t) (* y z)) (* i -4.0))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (x * 4.0) * i;
	double t_2 = (j * 27.0) * k;
	double t_3 = t * (a * 4.0);
	double tmp;
	if (((((((((x * 18.0) * y) * z) * t) - t_3) + (b * c)) - t_1) - t_2) <= ((double) INFINITY)) {
		tmp = (((b * c) + (((z * t) * (18.0 * (x * y))) - t_3)) - t_1) - t_2;
	} else {
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	}
	return tmp;
}
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (x * 4.0) * i;
	double t_2 = (j * 27.0) * k;
	double t_3 = t * (a * 4.0);
	double tmp;
	if (((((((((x * 18.0) * y) * z) * t) - t_3) + (b * c)) - t_1) - t_2) <= Double.POSITIVE_INFINITY) {
		tmp = (((b * c) + (((z * t) * (18.0 * (x * y))) - t_3)) - t_1) - t_2;
	} else {
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (x * 4.0) * i
	t_2 = (j * 27.0) * k
	t_3 = t * (a * 4.0)
	tmp = 0
	if ((((((((x * 18.0) * y) * z) * t) - t_3) + (b * c)) - t_1) - t_2) <= math.inf:
		tmp = (((b * c) + (((z * t) * (18.0 * (x * y))) - t_3)) - t_1) - t_2
	else:
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(x * 4.0) * i)
	t_2 = Float64(Float64(j * 27.0) * k)
	t_3 = Float64(t * Float64(a * 4.0))
	tmp = 0.0
	if (Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - t_3) + Float64(b * c)) - t_1) - t_2) <= Inf)
		tmp = Float64(Float64(Float64(Float64(b * c) + Float64(Float64(Float64(z * t) * Float64(18.0 * Float64(x * y))) - t_3)) - t_1) - t_2);
	else
		tmp = Float64(x * Float64(Float64(Float64(18.0 * t) * Float64(y * z)) + Float64(i * -4.0)));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (x * 4.0) * i;
	t_2 = (j * 27.0) * k;
	t_3 = t * (a * 4.0);
	tmp = 0.0;
	if (((((((((x * 18.0) * y) * z) * t) - t_3) + (b * c)) - t_1) - t_2) <= Inf)
		tmp = (((b * c) + (((z * t) * (18.0 * (x * y))) - t_3)) - t_1) - t_2;
	else
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, Block[{t$95$3 = N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - t$95$3), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision], Infinity], N[(N[(N[(N[(b * c), $MachinePrecision] + N[(N[(N[(z * t), $MachinePrecision] * N[(18.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$3), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision], N[(x * N[(N[(N[(18.0 * t), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \left(x \cdot 4\right) \cdot i\\
t_2 := \left(j \cdot 27\right) \cdot k\\
t_3 := t \cdot \left(a \cdot 4\right)\\
\mathbf{if}\;\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t\_3\right) + b \cdot c\right) - t\_1\right) - t\_2 \leq \infty:\\
\;\;\;\;\left(\left(b \cdot c + \left(\left(z \cdot t\right) \cdot \left(18 \cdot \left(x \cdot y\right)\right) - t\_3\right)\right) - t\_1\right) - t\_2\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x 18) y) z) t) (*.f64 (*.f64 a 4) t)) (*.f64 b c)) (*.f64 (*.f64 x 4) i)) (*.f64 (*.f64 j 27) k)) < +inf.0

    1. Initial program 92.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. pow192.4%

        \[\leadsto \left(\left(\left(\color{blue}{{\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t\right)}^{1}} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      2. associate-*r*92.1%

        \[\leadsto \left(\left(\left({\left(\color{blue}{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)} \cdot t\right)}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      3. *-commutative92.1%

        \[\leadsto \left(\left(\left({\color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\right)}}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      4. associate-*r*92.4%

        \[\leadsto \left(\left(\left({\left(t \cdot \color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}\right)}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      5. *-commutative92.4%

        \[\leadsto \left(\left(\left({\left(t \cdot \color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}\right)}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      6. *-commutative92.4%

        \[\leadsto \left(\left(\left({\left(t \cdot \left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)\right)}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    4. Applied egg-rr92.4%

      \[\leadsto \left(\left(\left(\color{blue}{{\left(t \cdot \left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)\right)}^{1}} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    5. Step-by-step derivation
      1. unpow192.4%

        \[\leadsto \left(\left(\left(\color{blue}{t \cdot \left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      2. associate-*r*93.0%

        \[\leadsto \left(\left(\left(\color{blue}{\left(t \cdot z\right) \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      3. *-commutative93.0%

        \[\leadsto \left(\left(\left(\left(t \cdot z\right) \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      4. *-commutative93.0%

        \[\leadsto \left(\left(\left(\left(t \cdot z\right) \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      5. associate-*r*93.0%

        \[\leadsto \left(\left(\left(\left(t \cdot z\right) \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    6. Simplified93.0%

      \[\leadsto \left(\left(\left(\color{blue}{\left(t \cdot z\right) \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]

    if +inf.0 < (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x 18) y) z) t) (*.f64 (*.f64 a 4) t)) (*.f64 b c)) (*.f64 (*.f64 x 4) i)) (*.f64 (*.f64 j 27) k))

    1. Initial program 0.0%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified25.9%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 59.4%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Step-by-step derivation
      1. cancel-sign-sub-inv59.4%

        \[\leadsto x \cdot \color{blue}{\left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + \left(-4\right) \cdot i\right)} \]
      2. associate-*r*59.4%

        \[\leadsto x \cdot \left(\color{blue}{\left(18 \cdot t\right) \cdot \left(y \cdot z\right)} + \left(-4\right) \cdot i\right) \]
      3. *-commutative59.4%

        \[\leadsto x \cdot \left(\left(18 \cdot t\right) \cdot \color{blue}{\left(z \cdot y\right)} + \left(-4\right) \cdot i\right) \]
      4. metadata-eval59.4%

        \[\leadsto x \cdot \left(\left(18 \cdot t\right) \cdot \left(z \cdot y\right) + \color{blue}{-4} \cdot i\right) \]
    6. Applied egg-rr59.4%

      \[\leadsto x \cdot \color{blue}{\left(\left(18 \cdot t\right) \cdot \left(z \cdot y\right) + -4 \cdot i\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification89.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \leq \infty:\\ \;\;\;\;\left(\left(b \cdot c + \left(\left(z \cdot t\right) \cdot \left(18 \cdot \left(x \cdot y\right)\right) - t \cdot \left(a \cdot 4\right)\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 59.4% accurate, 0.6× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := j \cdot \left(k \cdot -27\right)\\ t_2 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\ t_3 := b \cdot c + t\_1\\ t_4 := x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \mathbf{if}\;x \leq -2.15 \cdot 10^{-7}:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;x \leq -2 \cdot 10^{-144}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;x \leq -1.15 \cdot 10^{-251}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;x \leq -3.2 \cdot 10^{-265}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;x \leq 2.95 \cdot 10^{-232}:\\ \;\;\;\;t\_1 + t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;x \leq 9.2 \cdot 10^{-88}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;x \leq 15500000:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;t\_4\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* j (* k -27.0)))
        (t_2 (+ (* b c) (* -4.0 (* t a))))
        (t_3 (+ (* b c) t_1))
        (t_4 (* x (+ (* (* 18.0 t) (* y z)) (* i -4.0)))))
   (if (<= x -2.15e-7)
     t_4
     (if (<= x -2e-144)
       t_3
       (if (<= x -1.15e-251)
         t_2
         (if (<= x -3.2e-265)
           t_3
           (if (<= x 2.95e-232)
             (+ t_1 (* t (* a -4.0)))
             (if (<= x 9.2e-88) t_2 (if (<= x 15500000.0) t_3 t_4)))))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = j * (k * -27.0);
	double t_2 = (b * c) + (-4.0 * (t * a));
	double t_3 = (b * c) + t_1;
	double t_4 = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	double tmp;
	if (x <= -2.15e-7) {
		tmp = t_4;
	} else if (x <= -2e-144) {
		tmp = t_3;
	} else if (x <= -1.15e-251) {
		tmp = t_2;
	} else if (x <= -3.2e-265) {
		tmp = t_3;
	} else if (x <= 2.95e-232) {
		tmp = t_1 + (t * (a * -4.0));
	} else if (x <= 9.2e-88) {
		tmp = t_2;
	} else if (x <= 15500000.0) {
		tmp = t_3;
	} else {
		tmp = t_4;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: t_4
    real(8) :: tmp
    t_1 = j * (k * (-27.0d0))
    t_2 = (b * c) + ((-4.0d0) * (t * a))
    t_3 = (b * c) + t_1
    t_4 = x * (((18.0d0 * t) * (y * z)) + (i * (-4.0d0)))
    if (x <= (-2.15d-7)) then
        tmp = t_4
    else if (x <= (-2d-144)) then
        tmp = t_3
    else if (x <= (-1.15d-251)) then
        tmp = t_2
    else if (x <= (-3.2d-265)) then
        tmp = t_3
    else if (x <= 2.95d-232) then
        tmp = t_1 + (t * (a * (-4.0d0)))
    else if (x <= 9.2d-88) then
        tmp = t_2
    else if (x <= 15500000.0d0) then
        tmp = t_3
    else
        tmp = t_4
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = j * (k * -27.0);
	double t_2 = (b * c) + (-4.0 * (t * a));
	double t_3 = (b * c) + t_1;
	double t_4 = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	double tmp;
	if (x <= -2.15e-7) {
		tmp = t_4;
	} else if (x <= -2e-144) {
		tmp = t_3;
	} else if (x <= -1.15e-251) {
		tmp = t_2;
	} else if (x <= -3.2e-265) {
		tmp = t_3;
	} else if (x <= 2.95e-232) {
		tmp = t_1 + (t * (a * -4.0));
	} else if (x <= 9.2e-88) {
		tmp = t_2;
	} else if (x <= 15500000.0) {
		tmp = t_3;
	} else {
		tmp = t_4;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = j * (k * -27.0)
	t_2 = (b * c) + (-4.0 * (t * a))
	t_3 = (b * c) + t_1
	t_4 = x * (((18.0 * t) * (y * z)) + (i * -4.0))
	tmp = 0
	if x <= -2.15e-7:
		tmp = t_4
	elif x <= -2e-144:
		tmp = t_3
	elif x <= -1.15e-251:
		tmp = t_2
	elif x <= -3.2e-265:
		tmp = t_3
	elif x <= 2.95e-232:
		tmp = t_1 + (t * (a * -4.0))
	elif x <= 9.2e-88:
		tmp = t_2
	elif x <= 15500000.0:
		tmp = t_3
	else:
		tmp = t_4
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(j * Float64(k * -27.0))
	t_2 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a)))
	t_3 = Float64(Float64(b * c) + t_1)
	t_4 = Float64(x * Float64(Float64(Float64(18.0 * t) * Float64(y * z)) + Float64(i * -4.0)))
	tmp = 0.0
	if (x <= -2.15e-7)
		tmp = t_4;
	elseif (x <= -2e-144)
		tmp = t_3;
	elseif (x <= -1.15e-251)
		tmp = t_2;
	elseif (x <= -3.2e-265)
		tmp = t_3;
	elseif (x <= 2.95e-232)
		tmp = Float64(t_1 + Float64(t * Float64(a * -4.0)));
	elseif (x <= 9.2e-88)
		tmp = t_2;
	elseif (x <= 15500000.0)
		tmp = t_3;
	else
		tmp = t_4;
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = j * (k * -27.0);
	t_2 = (b * c) + (-4.0 * (t * a));
	t_3 = (b * c) + t_1;
	t_4 = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	tmp = 0.0;
	if (x <= -2.15e-7)
		tmp = t_4;
	elseif (x <= -2e-144)
		tmp = t_3;
	elseif (x <= -1.15e-251)
		tmp = t_2;
	elseif (x <= -3.2e-265)
		tmp = t_3;
	elseif (x <= 2.95e-232)
		tmp = t_1 + (t * (a * -4.0));
	elseif (x <= 9.2e-88)
		tmp = t_2;
	elseif (x <= 15500000.0)
		tmp = t_3;
	else
		tmp = t_4;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(b * c), $MachinePrecision] + t$95$1), $MachinePrecision]}, Block[{t$95$4 = N[(x * N[(N[(N[(18.0 * t), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.15e-7], t$95$4, If[LessEqual[x, -2e-144], t$95$3, If[LessEqual[x, -1.15e-251], t$95$2, If[LessEqual[x, -3.2e-265], t$95$3, If[LessEqual[x, 2.95e-232], N[(t$95$1 + N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 9.2e-88], t$95$2, If[LessEqual[x, 15500000.0], t$95$3, t$95$4]]]]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
t_2 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
t_3 := b \cdot c + t\_1\\
t_4 := x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\
\mathbf{if}\;x \leq -2.15 \cdot 10^{-7}:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;x \leq -2 \cdot 10^{-144}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;x \leq -1.15 \cdot 10^{-251}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;x \leq -3.2 \cdot 10^{-265}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;x \leq 2.95 \cdot 10^{-232}:\\
\;\;\;\;t\_1 + t \cdot \left(a \cdot -4\right)\\

\mathbf{elif}\;x \leq 9.2 \cdot 10^{-88}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;x \leq 15500000:\\
\;\;\;\;t\_3\\

\mathbf{else}:\\
\;\;\;\;t\_4\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if x < -2.1500000000000001e-7 or 1.55e7 < x

    1. Initial program 71.9%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified80.3%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 70.2%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Step-by-step derivation
      1. cancel-sign-sub-inv70.2%

        \[\leadsto x \cdot \color{blue}{\left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + \left(-4\right) \cdot i\right)} \]
      2. associate-*r*70.2%

        \[\leadsto x \cdot \left(\color{blue}{\left(18 \cdot t\right) \cdot \left(y \cdot z\right)} + \left(-4\right) \cdot i\right) \]
      3. *-commutative70.2%

        \[\leadsto x \cdot \left(\left(18 \cdot t\right) \cdot \color{blue}{\left(z \cdot y\right)} + \left(-4\right) \cdot i\right) \]
      4. metadata-eval70.2%

        \[\leadsto x \cdot \left(\left(18 \cdot t\right) \cdot \left(z \cdot y\right) + \color{blue}{-4} \cdot i\right) \]
    6. Applied egg-rr70.2%

      \[\leadsto x \cdot \color{blue}{\left(\left(18 \cdot t\right) \cdot \left(z \cdot y\right) + -4 \cdot i\right)} \]

    if -2.1500000000000001e-7 < x < -1.9999999999999999e-144 or -1.15000000000000009e-251 < x < -3.2e-265 or 9.19999999999999945e-88 < x < 1.55e7

    1. Initial program 92.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified90.6%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in b around inf 76.4%

      \[\leadsto \color{blue}{b \cdot c} + j \cdot \left(k \cdot -27\right) \]

    if -1.9999999999999999e-144 < x < -1.15000000000000009e-251 or 2.95000000000000008e-232 < x < 9.19999999999999945e-88

    1. Initial program 94.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified92.3%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 78.0%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in j around 0 64.7%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + b \cdot c} \]

    if -3.2e-265 < x < 2.95000000000000008e-232

    1. Initial program 95.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified82.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 79.3%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*79.3%

        \[\leadsto \color{blue}{\left(-4 \cdot a\right) \cdot t} + j \cdot \left(k \cdot -27\right) \]
      2. *-commutative79.3%

        \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]
    6. Simplified79.3%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]
  3. Recombined 4 regimes into one program.
  4. Final simplification71.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -2.15 \cdot 10^{-7}:\\ \;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \mathbf{elif}\;x \leq -2 \cdot 10^{-144}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;x \leq -1.15 \cdot 10^{-251}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;x \leq -3.2 \cdot 10^{-265}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;x \leq 2.95 \cdot 10^{-232}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;x \leq 9.2 \cdot 10^{-88}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;x \leq 15500000:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 59.5% accurate, 0.6× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := j \cdot \left(k \cdot -27\right)\\ t_2 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\ t_3 := b \cdot c + t\_1\\ \mathbf{if}\;x \leq -1.1 \cdot 10^{-8}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\ \mathbf{elif}\;x \leq -2.02 \cdot 10^{-144}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;x \leq -1.3 \cdot 10^{-250}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;x \leq -1.8 \cdot 10^{-268}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;x \leq 8 \cdot 10^{-232}:\\ \;\;\;\;t\_1 + t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;x \leq 1.6 \cdot 10^{-88}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;x \leq 16500000:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* j (* k -27.0)))
        (t_2 (+ (* b c) (* -4.0 (* t a))))
        (t_3 (+ (* b c) t_1)))
   (if (<= x -1.1e-8)
     (* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))
     (if (<= x -2.02e-144)
       t_3
       (if (<= x -1.3e-250)
         t_2
         (if (<= x -1.8e-268)
           t_3
           (if (<= x 8e-232)
             (+ t_1 (* t (* a -4.0)))
             (if (<= x 1.6e-88)
               t_2
               (if (<= x 16500000.0)
                 t_3
                 (* x (+ (* (* 18.0 t) (* y z)) (* i -4.0))))))))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = j * (k * -27.0);
	double t_2 = (b * c) + (-4.0 * (t * a));
	double t_3 = (b * c) + t_1;
	double tmp;
	if (x <= -1.1e-8) {
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	} else if (x <= -2.02e-144) {
		tmp = t_3;
	} else if (x <= -1.3e-250) {
		tmp = t_2;
	} else if (x <= -1.8e-268) {
		tmp = t_3;
	} else if (x <= 8e-232) {
		tmp = t_1 + (t * (a * -4.0));
	} else if (x <= 1.6e-88) {
		tmp = t_2;
	} else if (x <= 16500000.0) {
		tmp = t_3;
	} else {
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = j * (k * (-27.0d0))
    t_2 = (b * c) + ((-4.0d0) * (t * a))
    t_3 = (b * c) + t_1
    if (x <= (-1.1d-8)) then
        tmp = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
    else if (x <= (-2.02d-144)) then
        tmp = t_3
    else if (x <= (-1.3d-250)) then
        tmp = t_2
    else if (x <= (-1.8d-268)) then
        tmp = t_3
    else if (x <= 8d-232) then
        tmp = t_1 + (t * (a * (-4.0d0)))
    else if (x <= 1.6d-88) then
        tmp = t_2
    else if (x <= 16500000.0d0) then
        tmp = t_3
    else
        tmp = x * (((18.0d0 * t) * (y * z)) + (i * (-4.0d0)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = j * (k * -27.0);
	double t_2 = (b * c) + (-4.0 * (t * a));
	double t_3 = (b * c) + t_1;
	double tmp;
	if (x <= -1.1e-8) {
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	} else if (x <= -2.02e-144) {
		tmp = t_3;
	} else if (x <= -1.3e-250) {
		tmp = t_2;
	} else if (x <= -1.8e-268) {
		tmp = t_3;
	} else if (x <= 8e-232) {
		tmp = t_1 + (t * (a * -4.0));
	} else if (x <= 1.6e-88) {
		tmp = t_2;
	} else if (x <= 16500000.0) {
		tmp = t_3;
	} else {
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = j * (k * -27.0)
	t_2 = (b * c) + (-4.0 * (t * a))
	t_3 = (b * c) + t_1
	tmp = 0
	if x <= -1.1e-8:
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i))
	elif x <= -2.02e-144:
		tmp = t_3
	elif x <= -1.3e-250:
		tmp = t_2
	elif x <= -1.8e-268:
		tmp = t_3
	elif x <= 8e-232:
		tmp = t_1 + (t * (a * -4.0))
	elif x <= 1.6e-88:
		tmp = t_2
	elif x <= 16500000.0:
		tmp = t_3
	else:
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(j * Float64(k * -27.0))
	t_2 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a)))
	t_3 = Float64(Float64(b * c) + t_1)
	tmp = 0.0
	if (x <= -1.1e-8)
		tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i)));
	elseif (x <= -2.02e-144)
		tmp = t_3;
	elseif (x <= -1.3e-250)
		tmp = t_2;
	elseif (x <= -1.8e-268)
		tmp = t_3;
	elseif (x <= 8e-232)
		tmp = Float64(t_1 + Float64(t * Float64(a * -4.0)));
	elseif (x <= 1.6e-88)
		tmp = t_2;
	elseif (x <= 16500000.0)
		tmp = t_3;
	else
		tmp = Float64(x * Float64(Float64(Float64(18.0 * t) * Float64(y * z)) + Float64(i * -4.0)));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = j * (k * -27.0);
	t_2 = (b * c) + (-4.0 * (t * a));
	t_3 = (b * c) + t_1;
	tmp = 0.0;
	if (x <= -1.1e-8)
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	elseif (x <= -2.02e-144)
		tmp = t_3;
	elseif (x <= -1.3e-250)
		tmp = t_2;
	elseif (x <= -1.8e-268)
		tmp = t_3;
	elseif (x <= 8e-232)
		tmp = t_1 + (t * (a * -4.0));
	elseif (x <= 1.6e-88)
		tmp = t_2;
	elseif (x <= 16500000.0)
		tmp = t_3;
	else
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(b * c), $MachinePrecision] + t$95$1), $MachinePrecision]}, If[LessEqual[x, -1.1e-8], N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -2.02e-144], t$95$3, If[LessEqual[x, -1.3e-250], t$95$2, If[LessEqual[x, -1.8e-268], t$95$3, If[LessEqual[x, 8e-232], N[(t$95$1 + N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.6e-88], t$95$2, If[LessEqual[x, 16500000.0], t$95$3, N[(x * N[(N[(N[(18.0 * t), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := j \cdot \left(k \cdot -27\right)\\
t_2 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
t_3 := b \cdot c + t\_1\\
\mathbf{if}\;x \leq -1.1 \cdot 10^{-8}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\

\mathbf{elif}\;x \leq -2.02 \cdot 10^{-144}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;x \leq -1.3 \cdot 10^{-250}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;x \leq -1.8 \cdot 10^{-268}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;x \leq 8 \cdot 10^{-232}:\\
\;\;\;\;t\_1 + t \cdot \left(a \cdot -4\right)\\

\mathbf{elif}\;x \leq 1.6 \cdot 10^{-88}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;x \leq 16500000:\\
\;\;\;\;t\_3\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if x < -1.0999999999999999e-8

    1. Initial program 73.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified80.4%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 67.3%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]

    if -1.0999999999999999e-8 < x < -2.0200000000000001e-144 or -1.30000000000000004e-250 < x < -1.8000000000000001e-268 or 1.60000000000000006e-88 < x < 1.65e7

    1. Initial program 92.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified90.6%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in b around inf 76.4%

      \[\leadsto \color{blue}{b \cdot c} + j \cdot \left(k \cdot -27\right) \]

    if -2.0200000000000001e-144 < x < -1.30000000000000004e-250 or 8.0000000000000002e-232 < x < 1.60000000000000006e-88

    1. Initial program 94.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified92.3%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 78.0%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in j around 0 64.7%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + b \cdot c} \]

    if -1.8000000000000001e-268 < x < 8.0000000000000002e-232

    1. Initial program 95.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified82.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 79.3%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*79.3%

        \[\leadsto \color{blue}{\left(-4 \cdot a\right) \cdot t} + j \cdot \left(k \cdot -27\right) \]
      2. *-commutative79.3%

        \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]
    6. Simplified79.3%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]

    if 1.65e7 < x

    1. Initial program 70.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified80.2%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 73.6%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Step-by-step derivation
      1. cancel-sign-sub-inv73.6%

        \[\leadsto x \cdot \color{blue}{\left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + \left(-4\right) \cdot i\right)} \]
      2. associate-*r*73.6%

        \[\leadsto x \cdot \left(\color{blue}{\left(18 \cdot t\right) \cdot \left(y \cdot z\right)} + \left(-4\right) \cdot i\right) \]
      3. *-commutative73.6%

        \[\leadsto x \cdot \left(\left(18 \cdot t\right) \cdot \color{blue}{\left(z \cdot y\right)} + \left(-4\right) \cdot i\right) \]
      4. metadata-eval73.6%

        \[\leadsto x \cdot \left(\left(18 \cdot t\right) \cdot \left(z \cdot y\right) + \color{blue}{-4} \cdot i\right) \]
    6. Applied egg-rr73.6%

      \[\leadsto x \cdot \color{blue}{\left(\left(18 \cdot t\right) \cdot \left(z \cdot y\right) + -4 \cdot i\right)} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification71.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -1.1 \cdot 10^{-8}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\ \mathbf{elif}\;x \leq -2.02 \cdot 10^{-144}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;x \leq -1.3 \cdot 10^{-250}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;x \leq -1.8 \cdot 10^{-268}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;x \leq 8 \cdot 10^{-232}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;x \leq 1.6 \cdot 10^{-88}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;x \leq 16500000:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 53.1% accurate, 0.6× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\ t_2 := j \cdot \left(k \cdot -27\right)\\ t_3 := t\_2 + i \cdot \left(x \cdot -4\right)\\ \mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \cdot c \leq -1 \cdot 10^{-159}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-308}:\\ \;\;\;\;t\_2 + t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 0.005:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+203}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (+ (* b c) (* -4.0 (* t a))))
        (t_2 (* j (* k -27.0)))
        (t_3 (+ t_2 (* i (* x -4.0)))))
   (if (<= (* b c) -2e+182)
     t_1
     (if (<= (* b c) -1e-159)
       t_3
       (if (<= (* b c) -5e-308)
         (+ t_2 (* t (* a -4.0)))
         (if (<= (* b c) 0.005)
           t_3
           (if (<= (* b c) 2e+203)
             (* t (- (* 18.0 (* x (* y z))) (* a 4.0)))
             t_1)))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (b * c) + (-4.0 * (t * a));
	double t_2 = j * (k * -27.0);
	double t_3 = t_2 + (i * (x * -4.0));
	double tmp;
	if ((b * c) <= -2e+182) {
		tmp = t_1;
	} else if ((b * c) <= -1e-159) {
		tmp = t_3;
	} else if ((b * c) <= -5e-308) {
		tmp = t_2 + (t * (a * -4.0));
	} else if ((b * c) <= 0.005) {
		tmp = t_3;
	} else if ((b * c) <= 2e+203) {
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = (b * c) + ((-4.0d0) * (t * a))
    t_2 = j * (k * (-27.0d0))
    t_3 = t_2 + (i * (x * (-4.0d0)))
    if ((b * c) <= (-2d+182)) then
        tmp = t_1
    else if ((b * c) <= (-1d-159)) then
        tmp = t_3
    else if ((b * c) <= (-5d-308)) then
        tmp = t_2 + (t * (a * (-4.0d0)))
    else if ((b * c) <= 0.005d0) then
        tmp = t_3
    else if ((b * c) <= 2d+203) then
        tmp = t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0))
    else
        tmp = t_1
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (b * c) + (-4.0 * (t * a));
	double t_2 = j * (k * -27.0);
	double t_3 = t_2 + (i * (x * -4.0));
	double tmp;
	if ((b * c) <= -2e+182) {
		tmp = t_1;
	} else if ((b * c) <= -1e-159) {
		tmp = t_3;
	} else if ((b * c) <= -5e-308) {
		tmp = t_2 + (t * (a * -4.0));
	} else if ((b * c) <= 0.005) {
		tmp = t_3;
	} else if ((b * c) <= 2e+203) {
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	} else {
		tmp = t_1;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (b * c) + (-4.0 * (t * a))
	t_2 = j * (k * -27.0)
	t_3 = t_2 + (i * (x * -4.0))
	tmp = 0
	if (b * c) <= -2e+182:
		tmp = t_1
	elif (b * c) <= -1e-159:
		tmp = t_3
	elif (b * c) <= -5e-308:
		tmp = t_2 + (t * (a * -4.0))
	elif (b * c) <= 0.005:
		tmp = t_3
	elif (b * c) <= 2e+203:
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0))
	else:
		tmp = t_1
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a)))
	t_2 = Float64(j * Float64(k * -27.0))
	t_3 = Float64(t_2 + Float64(i * Float64(x * -4.0)))
	tmp = 0.0
	if (Float64(b * c) <= -2e+182)
		tmp = t_1;
	elseif (Float64(b * c) <= -1e-159)
		tmp = t_3;
	elseif (Float64(b * c) <= -5e-308)
		tmp = Float64(t_2 + Float64(t * Float64(a * -4.0)));
	elseif (Float64(b * c) <= 0.005)
		tmp = t_3;
	elseif (Float64(b * c) <= 2e+203)
		tmp = Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0)));
	else
		tmp = t_1;
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (b * c) + (-4.0 * (t * a));
	t_2 = j * (k * -27.0);
	t_3 = t_2 + (i * (x * -4.0));
	tmp = 0.0;
	if ((b * c) <= -2e+182)
		tmp = t_1;
	elseif ((b * c) <= -1e-159)
		tmp = t_3;
	elseif ((b * c) <= -5e-308)
		tmp = t_2 + (t * (a * -4.0));
	elseif ((b * c) <= 0.005)
		tmp = t_3;
	elseif ((b * c) <= 2e+203)
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 + N[(i * N[(x * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -2e+182], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -1e-159], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], -5e-308], N[(t$95$2 + N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 0.005], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], 2e+203], N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
t_2 := j \cdot \left(k \cdot -27\right)\\
t_3 := t\_2 + i \cdot \left(x \cdot -4\right)\\
\mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \cdot c \leq -1 \cdot 10^{-159}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-308}:\\
\;\;\;\;t\_2 + t \cdot \left(a \cdot -4\right)\\

\mathbf{elif}\;b \cdot c \leq 0.005:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+203}:\\
\;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (*.f64 b c) < -2.0000000000000001e182 or 2e203 < (*.f64 b c)

    1. Initial program 80.7%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified79.2%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 80.8%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in j around 0 82.3%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + b \cdot c} \]

    if -2.0000000000000001e182 < (*.f64 b c) < -9.99999999999999989e-160 or -4.99999999999999955e-308 < (*.f64 b c) < 0.0050000000000000001

    1. Initial program 83.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified87.1%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in i around inf 60.8%

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*60.8%

        \[\leadsto \color{blue}{\left(-4 \cdot i\right) \cdot x} + j \cdot \left(k \cdot -27\right) \]
      2. *-commutative60.8%

        \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} + j \cdot \left(k \cdot -27\right) \]
      3. associate-*r*60.8%

        \[\leadsto \color{blue}{\left(x \cdot -4\right) \cdot i} + j \cdot \left(k \cdot -27\right) \]
      4. *-commutative60.8%

        \[\leadsto \color{blue}{\left(-4 \cdot x\right)} \cdot i + j \cdot \left(k \cdot -27\right) \]
    6. Simplified60.8%

      \[\leadsto \color{blue}{\left(-4 \cdot x\right) \cdot i} + j \cdot \left(k \cdot -27\right) \]

    if -9.99999999999999989e-160 < (*.f64 b c) < -4.99999999999999955e-308

    1. Initial program 84.5%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified94.7%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 79.3%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*79.3%

        \[\leadsto \color{blue}{\left(-4 \cdot a\right) \cdot t} + j \cdot \left(k \cdot -27\right) \]
      2. *-commutative79.3%

        \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]
    6. Simplified79.3%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]

    if 0.0050000000000000001 < (*.f64 b c) < 2e203

    1. Initial program 82.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified89.3%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. pow189.3%

        \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. associate-*r*89.4%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative89.4%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. *-commutative89.4%

        \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    5. Applied egg-rr89.4%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    6. Step-by-step derivation
      1. unpow189.4%

        \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. *-commutative89.4%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative89.4%

        \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. associate-*r*89.4%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    7. Simplified89.4%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    8. Taylor expanded in k around inf 62.0%

      \[\leadsto \color{blue}{k \cdot \left(\left(\frac{b \cdot c}{k} + \frac{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)}{k}\right) - \left(4 \cdot \frac{i \cdot x}{k} + 27 \cdot j\right)\right)} \]
    9. Taylor expanded in t around -inf 62.1%

      \[\leadsto \color{blue}{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification67.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;b \cdot c \leq -1 \cdot 10^{-159}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + i \cdot \left(x \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-308}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 0.005:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + i \cdot \left(x \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+203}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 53.8% accurate, 0.8× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\ t_2 := j \cdot \left(k \cdot -27\right)\\ t_3 := t\_2 + i \cdot \left(x \cdot -4\right)\\ \mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \cdot c \leq -1 \cdot 10^{-159}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-308}:\\ \;\;\;\;t\_2 + t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+101}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (+ (* b c) (* -4.0 (* t a))))
        (t_2 (* j (* k -27.0)))
        (t_3 (+ t_2 (* i (* x -4.0)))))
   (if (<= (* b c) -2e+182)
     t_1
     (if (<= (* b c) -1e-159)
       t_3
       (if (<= (* b c) -5e-308)
         (+ t_2 (* t (* a -4.0)))
         (if (<= (* b c) 2e+101) t_3 t_1))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (b * c) + (-4.0 * (t * a));
	double t_2 = j * (k * -27.0);
	double t_3 = t_2 + (i * (x * -4.0));
	double tmp;
	if ((b * c) <= -2e+182) {
		tmp = t_1;
	} else if ((b * c) <= -1e-159) {
		tmp = t_3;
	} else if ((b * c) <= -5e-308) {
		tmp = t_2 + (t * (a * -4.0));
	} else if ((b * c) <= 2e+101) {
		tmp = t_3;
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = (b * c) + ((-4.0d0) * (t * a))
    t_2 = j * (k * (-27.0d0))
    t_3 = t_2 + (i * (x * (-4.0d0)))
    if ((b * c) <= (-2d+182)) then
        tmp = t_1
    else if ((b * c) <= (-1d-159)) then
        tmp = t_3
    else if ((b * c) <= (-5d-308)) then
        tmp = t_2 + (t * (a * (-4.0d0)))
    else if ((b * c) <= 2d+101) then
        tmp = t_3
    else
        tmp = t_1
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (b * c) + (-4.0 * (t * a));
	double t_2 = j * (k * -27.0);
	double t_3 = t_2 + (i * (x * -4.0));
	double tmp;
	if ((b * c) <= -2e+182) {
		tmp = t_1;
	} else if ((b * c) <= -1e-159) {
		tmp = t_3;
	} else if ((b * c) <= -5e-308) {
		tmp = t_2 + (t * (a * -4.0));
	} else if ((b * c) <= 2e+101) {
		tmp = t_3;
	} else {
		tmp = t_1;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (b * c) + (-4.0 * (t * a))
	t_2 = j * (k * -27.0)
	t_3 = t_2 + (i * (x * -4.0))
	tmp = 0
	if (b * c) <= -2e+182:
		tmp = t_1
	elif (b * c) <= -1e-159:
		tmp = t_3
	elif (b * c) <= -5e-308:
		tmp = t_2 + (t * (a * -4.0))
	elif (b * c) <= 2e+101:
		tmp = t_3
	else:
		tmp = t_1
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a)))
	t_2 = Float64(j * Float64(k * -27.0))
	t_3 = Float64(t_2 + Float64(i * Float64(x * -4.0)))
	tmp = 0.0
	if (Float64(b * c) <= -2e+182)
		tmp = t_1;
	elseif (Float64(b * c) <= -1e-159)
		tmp = t_3;
	elseif (Float64(b * c) <= -5e-308)
		tmp = Float64(t_2 + Float64(t * Float64(a * -4.0)));
	elseif (Float64(b * c) <= 2e+101)
		tmp = t_3;
	else
		tmp = t_1;
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (b * c) + (-4.0 * (t * a));
	t_2 = j * (k * -27.0);
	t_3 = t_2 + (i * (x * -4.0));
	tmp = 0.0;
	if ((b * c) <= -2e+182)
		tmp = t_1;
	elseif ((b * c) <= -1e-159)
		tmp = t_3;
	elseif ((b * c) <= -5e-308)
		tmp = t_2 + (t * (a * -4.0));
	elseif ((b * c) <= 2e+101)
		tmp = t_3;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 + N[(i * N[(x * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -2e+182], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -1e-159], t$95$3, If[LessEqual[N[(b * c), $MachinePrecision], -5e-308], N[(t$95$2 + N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2e+101], t$95$3, t$95$1]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
t_2 := j \cdot \left(k \cdot -27\right)\\
t_3 := t\_2 + i \cdot \left(x \cdot -4\right)\\
\mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \cdot c \leq -1 \cdot 10^{-159}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-308}:\\
\;\;\;\;t\_2 + t \cdot \left(a \cdot -4\right)\\

\mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+101}:\\
\;\;\;\;t\_3\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 b c) < -2.0000000000000001e182 or 2e101 < (*.f64 b c)

    1. Initial program 83.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified81.9%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 76.6%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in j around 0 75.4%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + b \cdot c} \]

    if -2.0000000000000001e182 < (*.f64 b c) < -9.99999999999999989e-160 or -4.99999999999999955e-308 < (*.f64 b c) < 2e101

    1. Initial program 82.3%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified86.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in i around inf 59.0%

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*59.0%

        \[\leadsto \color{blue}{\left(-4 \cdot i\right) \cdot x} + j \cdot \left(k \cdot -27\right) \]
      2. *-commutative59.0%

        \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} + j \cdot \left(k \cdot -27\right) \]
      3. associate-*r*59.0%

        \[\leadsto \color{blue}{\left(x \cdot -4\right) \cdot i} + j \cdot \left(k \cdot -27\right) \]
      4. *-commutative59.0%

        \[\leadsto \color{blue}{\left(-4 \cdot x\right)} \cdot i + j \cdot \left(k \cdot -27\right) \]
    6. Simplified59.0%

      \[\leadsto \color{blue}{\left(-4 \cdot x\right) \cdot i} + j \cdot \left(k \cdot -27\right) \]

    if -9.99999999999999989e-160 < (*.f64 b c) < -4.99999999999999955e-308

    1. Initial program 84.5%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified94.7%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 79.3%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*79.3%

        \[\leadsto \color{blue}{\left(-4 \cdot a\right) \cdot t} + j \cdot \left(k \cdot -27\right) \]
      2. *-commutative79.3%

        \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]
    6. Simplified79.3%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification65.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;b \cdot c \leq -1 \cdot 10^{-159}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + i \cdot \left(x \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-308}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+101}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + i \cdot \left(x \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 79.0% accurate, 0.8× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\\ t_2 := 4 \cdot \left(x \cdot i\right)\\ t_3 := \left(b \cdot c + t \cdot \left(t\_1 - a \cdot 4\right)\right) - t\_2\\ \mathbf{if}\;t \leq -1.85 \cdot 10^{+68}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t \leq 5.8 \cdot 10^{-141}:\\ \;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{elif}\;t \leq 1.2 \cdot 10^{-6}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t \leq 4 \cdot 10^{+87}:\\ \;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + t\_2\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(t\_1 + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* 18.0 (* x (* y z))))
        (t_2 (* 4.0 (* x i)))
        (t_3 (- (+ (* b c) (* t (- t_1 (* a 4.0)))) t_2)))
   (if (<= t -1.85e+68)
     t_3
     (if (<= t 5.8e-141)
       (- (- (- (* b c) (* 4.0 (* t a))) (* (* x 4.0) i)) (* (* j 27.0) k))
       (if (<= t 1.2e-6)
         t_3
         (if (<= t 4e+87)
           (- (* b c) (+ (* 27.0 (* j k)) t_2))
           (+ (* t (+ t_1 (* a -4.0))) (* j (* k -27.0)))))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = 18.0 * (x * (y * z));
	double t_2 = 4.0 * (x * i);
	double t_3 = ((b * c) + (t * (t_1 - (a * 4.0)))) - t_2;
	double tmp;
	if (t <= -1.85e+68) {
		tmp = t_3;
	} else if (t <= 5.8e-141) {
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	} else if (t <= 1.2e-6) {
		tmp = t_3;
	} else if (t <= 4e+87) {
		tmp = (b * c) - ((27.0 * (j * k)) + t_2);
	} else {
		tmp = (t * (t_1 + (a * -4.0))) + (j * (k * -27.0));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = 18.0d0 * (x * (y * z))
    t_2 = 4.0d0 * (x * i)
    t_3 = ((b * c) + (t * (t_1 - (a * 4.0d0)))) - t_2
    if (t <= (-1.85d+68)) then
        tmp = t_3
    else if (t <= 5.8d-141) then
        tmp = (((b * c) - (4.0d0 * (t * a))) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
    else if (t <= 1.2d-6) then
        tmp = t_3
    else if (t <= 4d+87) then
        tmp = (b * c) - ((27.0d0 * (j * k)) + t_2)
    else
        tmp = (t * (t_1 + (a * (-4.0d0)))) + (j * (k * (-27.0d0)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = 18.0 * (x * (y * z));
	double t_2 = 4.0 * (x * i);
	double t_3 = ((b * c) + (t * (t_1 - (a * 4.0)))) - t_2;
	double tmp;
	if (t <= -1.85e+68) {
		tmp = t_3;
	} else if (t <= 5.8e-141) {
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	} else if (t <= 1.2e-6) {
		tmp = t_3;
	} else if (t <= 4e+87) {
		tmp = (b * c) - ((27.0 * (j * k)) + t_2);
	} else {
		tmp = (t * (t_1 + (a * -4.0))) + (j * (k * -27.0));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = 18.0 * (x * (y * z))
	t_2 = 4.0 * (x * i)
	t_3 = ((b * c) + (t * (t_1 - (a * 4.0)))) - t_2
	tmp = 0
	if t <= -1.85e+68:
		tmp = t_3
	elif t <= 5.8e-141:
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k)
	elif t <= 1.2e-6:
		tmp = t_3
	elif t <= 4e+87:
		tmp = (b * c) - ((27.0 * (j * k)) + t_2)
	else:
		tmp = (t * (t_1 + (a * -4.0))) + (j * (k * -27.0))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(18.0 * Float64(x * Float64(y * z)))
	t_2 = Float64(4.0 * Float64(x * i))
	t_3 = Float64(Float64(Float64(b * c) + Float64(t * Float64(t_1 - Float64(a * 4.0)))) - t_2)
	tmp = 0.0
	if (t <= -1.85e+68)
		tmp = t_3;
	elseif (t <= 5.8e-141)
		tmp = Float64(Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(t * a))) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k));
	elseif (t <= 1.2e-6)
		tmp = t_3;
	elseif (t <= 4e+87)
		tmp = Float64(Float64(b * c) - Float64(Float64(27.0 * Float64(j * k)) + t_2));
	else
		tmp = Float64(Float64(t * Float64(t_1 + Float64(a * -4.0))) + Float64(j * Float64(k * -27.0)));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = 18.0 * (x * (y * z));
	t_2 = 4.0 * (x * i);
	t_3 = ((b * c) + (t * (t_1 - (a * 4.0)))) - t_2;
	tmp = 0.0;
	if (t <= -1.85e+68)
		tmp = t_3;
	elseif (t <= 5.8e-141)
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	elseif (t <= 1.2e-6)
		tmp = t_3;
	elseif (t <= 4e+87)
		tmp = (b * c) - ((27.0 * (j * k)) + t_2);
	else
		tmp = (t * (t_1 + (a * -4.0))) + (j * (k * -27.0));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(t$95$1 - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$2), $MachinePrecision]}, If[LessEqual[t, -1.85e+68], t$95$3, If[LessEqual[t, 5.8e-141], N[(N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.2e-6], t$95$3, If[LessEqual[t, 4e+87], N[(N[(b * c), $MachinePrecision] - N[(N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision] + t$95$2), $MachinePrecision]), $MachinePrecision], N[(N[(t * N[(t$95$1 + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\\
t_2 := 4 \cdot \left(x \cdot i\right)\\
t_3 := \left(b \cdot c + t \cdot \left(t\_1 - a \cdot 4\right)\right) - t\_2\\
\mathbf{if}\;t \leq -1.85 \cdot 10^{+68}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;t \leq 5.8 \cdot 10^{-141}:\\
\;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\

\mathbf{elif}\;t \leq 1.2 \cdot 10^{-6}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;t \leq 4 \cdot 10^{+87}:\\
\;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + t\_2\right)\\

\mathbf{else}:\\
\;\;\;\;t \cdot \left(t\_1 + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -1.84999999999999999e68 or 5.7999999999999999e-141 < t < 1.1999999999999999e-6

    1. Initial program 80.8%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified88.9%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around 0 82.6%

      \[\leadsto \color{blue}{\left(b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)\right) - 4 \cdot \left(i \cdot x\right)} \]

    if -1.84999999999999999e68 < t < 5.7999999999999999e-141

    1. Initial program 83.0%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 88.8%

      \[\leadsto \left(\color{blue}{\left(b \cdot c - 4 \cdot \left(a \cdot t\right)\right)} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]

    if 1.1999999999999999e-6 < t < 3.9999999999999998e87

    1. Initial program 89.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified84.5%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 100.0%

      \[\leadsto \color{blue}{b \cdot c - \left(4 \cdot \left(i \cdot x\right) + 27 \cdot \left(j \cdot k\right)\right)} \]

    if 3.9999999999999998e87 < t

    1. Initial program 81.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified88.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 86.3%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} + j \cdot \left(k \cdot -27\right) \]
  3. Recombined 4 regimes into one program.
  4. Final simplification87.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.85 \cdot 10^{+68}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\right) - 4 \cdot \left(x \cdot i\right)\\ \mathbf{elif}\;t \leq 5.8 \cdot 10^{-141}:\\ \;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{elif}\;t \leq 1.2 \cdot 10^{-6}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\right) - 4 \cdot \left(x \cdot i\right)\\ \mathbf{elif}\;t \leq 4 \cdot 10^{+87}:\\ \;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(x \cdot i\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 78.9% accurate, 0.8× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\\ t_2 := 4 \cdot \left(x \cdot i\right)\\ t_3 := b \cdot c + t \cdot \left(t\_1 - a \cdot 4\right)\\ t_4 := 27 \cdot \left(j \cdot k\right)\\ \mathbf{if}\;t \leq -2.6 \cdot 10^{+136}:\\ \;\;\;\;t\_3 - t\_4\\ \mathbf{elif}\;t \leq 6.6 \cdot 10^{-141}:\\ \;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{elif}\;t \leq 1.35 \cdot 10^{-6}:\\ \;\;\;\;t\_3 - t\_2\\ \mathbf{elif}\;t \leq 1.3 \cdot 10^{+88}:\\ \;\;\;\;b \cdot c - \left(t\_4 + t\_2\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(t\_1 + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* 18.0 (* x (* y z))))
        (t_2 (* 4.0 (* x i)))
        (t_3 (+ (* b c) (* t (- t_1 (* a 4.0)))))
        (t_4 (* 27.0 (* j k))))
   (if (<= t -2.6e+136)
     (- t_3 t_4)
     (if (<= t 6.6e-141)
       (- (- (- (* b c) (* 4.0 (* t a))) (* (* x 4.0) i)) (* (* j 27.0) k))
       (if (<= t 1.35e-6)
         (- t_3 t_2)
         (if (<= t 1.3e+88)
           (- (* b c) (+ t_4 t_2))
           (+ (* t (+ t_1 (* a -4.0))) (* j (* k -27.0)))))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = 18.0 * (x * (y * z));
	double t_2 = 4.0 * (x * i);
	double t_3 = (b * c) + (t * (t_1 - (a * 4.0)));
	double t_4 = 27.0 * (j * k);
	double tmp;
	if (t <= -2.6e+136) {
		tmp = t_3 - t_4;
	} else if (t <= 6.6e-141) {
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	} else if (t <= 1.35e-6) {
		tmp = t_3 - t_2;
	} else if (t <= 1.3e+88) {
		tmp = (b * c) - (t_4 + t_2);
	} else {
		tmp = (t * (t_1 + (a * -4.0))) + (j * (k * -27.0));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: t_4
    real(8) :: tmp
    t_1 = 18.0d0 * (x * (y * z))
    t_2 = 4.0d0 * (x * i)
    t_3 = (b * c) + (t * (t_1 - (a * 4.0d0)))
    t_4 = 27.0d0 * (j * k)
    if (t <= (-2.6d+136)) then
        tmp = t_3 - t_4
    else if (t <= 6.6d-141) then
        tmp = (((b * c) - (4.0d0 * (t * a))) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
    else if (t <= 1.35d-6) then
        tmp = t_3 - t_2
    else if (t <= 1.3d+88) then
        tmp = (b * c) - (t_4 + t_2)
    else
        tmp = (t * (t_1 + (a * (-4.0d0)))) + (j * (k * (-27.0d0)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = 18.0 * (x * (y * z));
	double t_2 = 4.0 * (x * i);
	double t_3 = (b * c) + (t * (t_1 - (a * 4.0)));
	double t_4 = 27.0 * (j * k);
	double tmp;
	if (t <= -2.6e+136) {
		tmp = t_3 - t_4;
	} else if (t <= 6.6e-141) {
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	} else if (t <= 1.35e-6) {
		tmp = t_3 - t_2;
	} else if (t <= 1.3e+88) {
		tmp = (b * c) - (t_4 + t_2);
	} else {
		tmp = (t * (t_1 + (a * -4.0))) + (j * (k * -27.0));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = 18.0 * (x * (y * z))
	t_2 = 4.0 * (x * i)
	t_3 = (b * c) + (t * (t_1 - (a * 4.0)))
	t_4 = 27.0 * (j * k)
	tmp = 0
	if t <= -2.6e+136:
		tmp = t_3 - t_4
	elif t <= 6.6e-141:
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k)
	elif t <= 1.35e-6:
		tmp = t_3 - t_2
	elif t <= 1.3e+88:
		tmp = (b * c) - (t_4 + t_2)
	else:
		tmp = (t * (t_1 + (a * -4.0))) + (j * (k * -27.0))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(18.0 * Float64(x * Float64(y * z)))
	t_2 = Float64(4.0 * Float64(x * i))
	t_3 = Float64(Float64(b * c) + Float64(t * Float64(t_1 - Float64(a * 4.0))))
	t_4 = Float64(27.0 * Float64(j * k))
	tmp = 0.0
	if (t <= -2.6e+136)
		tmp = Float64(t_3 - t_4);
	elseif (t <= 6.6e-141)
		tmp = Float64(Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(t * a))) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k));
	elseif (t <= 1.35e-6)
		tmp = Float64(t_3 - t_2);
	elseif (t <= 1.3e+88)
		tmp = Float64(Float64(b * c) - Float64(t_4 + t_2));
	else
		tmp = Float64(Float64(t * Float64(t_1 + Float64(a * -4.0))) + Float64(j * Float64(k * -27.0)));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = 18.0 * (x * (y * z));
	t_2 = 4.0 * (x * i);
	t_3 = (b * c) + (t * (t_1 - (a * 4.0)));
	t_4 = 27.0 * (j * k);
	tmp = 0.0;
	if (t <= -2.6e+136)
		tmp = t_3 - t_4;
	elseif (t <= 6.6e-141)
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	elseif (t <= 1.35e-6)
		tmp = t_3 - t_2;
	elseif (t <= 1.3e+88)
		tmp = (b * c) - (t_4 + t_2);
	else
		tmp = (t * (t_1 + (a * -4.0))) + (j * (k * -27.0));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(b * c), $MachinePrecision] + N[(t * N[(t$95$1 - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.6e+136], N[(t$95$3 - t$95$4), $MachinePrecision], If[LessEqual[t, 6.6e-141], N[(N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.35e-6], N[(t$95$3 - t$95$2), $MachinePrecision], If[LessEqual[t, 1.3e+88], N[(N[(b * c), $MachinePrecision] - N[(t$95$4 + t$95$2), $MachinePrecision]), $MachinePrecision], N[(N[(t * N[(t$95$1 + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\\
t_2 := 4 \cdot \left(x \cdot i\right)\\
t_3 := b \cdot c + t \cdot \left(t\_1 - a \cdot 4\right)\\
t_4 := 27 \cdot \left(j \cdot k\right)\\
\mathbf{if}\;t \leq -2.6 \cdot 10^{+136}:\\
\;\;\;\;t\_3 - t\_4\\

\mathbf{elif}\;t \leq 6.6 \cdot 10^{-141}:\\
\;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\

\mathbf{elif}\;t \leq 1.35 \cdot 10^{-6}:\\
\;\;\;\;t\_3 - t\_2\\

\mathbf{elif}\;t \leq 1.3 \cdot 10^{+88}:\\
\;\;\;\;b \cdot c - \left(t\_4 + t\_2\right)\\

\mathbf{else}:\\
\;\;\;\;t \cdot \left(t\_1 + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -2.6000000000000001e136

    1. Initial program 84.3%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified93.7%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. pow193.7%

        \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. associate-*r*93.7%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative93.7%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. *-commutative93.7%

        \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    5. Applied egg-rr93.7%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    6. Step-by-step derivation
      1. unpow193.7%

        \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. *-commutative93.7%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative93.7%

        \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. associate-*r*93.7%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    7. Simplified93.7%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    8. Taylor expanded in i around 0 90.5%

      \[\leadsto \color{blue}{\left(b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)\right) - 27 \cdot \left(j \cdot k\right)} \]

    if -2.6000000000000001e136 < t < 6.59999999999999998e-141

    1. Initial program 83.5%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 88.2%

      \[\leadsto \left(\color{blue}{\left(b \cdot c - 4 \cdot \left(a \cdot t\right)\right)} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]

    if 6.59999999999999998e-141 < t < 1.34999999999999999e-6

    1. Initial program 70.7%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified80.4%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around 0 83.3%

      \[\leadsto \color{blue}{\left(b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)\right) - 4 \cdot \left(i \cdot x\right)} \]

    if 1.34999999999999999e-6 < t < 1.3e88

    1. Initial program 89.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified84.5%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 100.0%

      \[\leadsto \color{blue}{b \cdot c - \left(4 \cdot \left(i \cdot x\right) + 27 \cdot \left(j \cdot k\right)\right)} \]

    if 1.3e88 < t

    1. Initial program 81.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified88.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 86.3%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} + j \cdot \left(k \cdot -27\right) \]
  3. Recombined 5 regimes into one program.
  4. Final simplification88.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.6 \cdot 10^{+136}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\right) - 27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;t \leq 6.6 \cdot 10^{-141}:\\ \;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{elif}\;t \leq 1.35 \cdot 10^{-6}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\right) - 4 \cdot \left(x \cdot i\right)\\ \mathbf{elif}\;t \leq 1.3 \cdot 10^{+88}:\\ \;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(x \cdot i\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 36.3% accurate, 0.8× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -3.6 \cdot 10^{+177}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -6 \cdot 10^{-274}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \mathbf{elif}\;b \cdot c \leq 1.65 \cdot 10^{-115}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 1.5 \cdot 10^{+204}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= (* b c) -3.6e+177)
   (* b c)
   (if (<= (* b c) -6e-274)
     (* (* j k) -27.0)
     (if (<= (* b c) 1.65e-115)
       (* x (* i -4.0))
       (if (<= (* b c) 1.5e+204) (* x (* 18.0 (* t (* y z)))) (* b c))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((b * c) <= -3.6e+177) {
		tmp = b * c;
	} else if ((b * c) <= -6e-274) {
		tmp = (j * k) * -27.0;
	} else if ((b * c) <= 1.65e-115) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 1.5e+204) {
		tmp = x * (18.0 * (t * (y * z)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((b * c) <= (-3.6d+177)) then
        tmp = b * c
    else if ((b * c) <= (-6d-274)) then
        tmp = (j * k) * (-27.0d0)
    else if ((b * c) <= 1.65d-115) then
        tmp = x * (i * (-4.0d0))
    else if ((b * c) <= 1.5d+204) then
        tmp = x * (18.0d0 * (t * (y * z)))
    else
        tmp = b * c
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((b * c) <= -3.6e+177) {
		tmp = b * c;
	} else if ((b * c) <= -6e-274) {
		tmp = (j * k) * -27.0;
	} else if ((b * c) <= 1.65e-115) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 1.5e+204) {
		tmp = x * (18.0 * (t * (y * z)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (b * c) <= -3.6e+177:
		tmp = b * c
	elif (b * c) <= -6e-274:
		tmp = (j * k) * -27.0
	elif (b * c) <= 1.65e-115:
		tmp = x * (i * -4.0)
	elif (b * c) <= 1.5e+204:
		tmp = x * (18.0 * (t * (y * z)))
	else:
		tmp = b * c
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (Float64(b * c) <= -3.6e+177)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -6e-274)
		tmp = Float64(Float64(j * k) * -27.0);
	elseif (Float64(b * c) <= 1.65e-115)
		tmp = Float64(x * Float64(i * -4.0));
	elseif (Float64(b * c) <= 1.5e+204)
		tmp = Float64(x * Float64(18.0 * Float64(t * Float64(y * z))));
	else
		tmp = Float64(b * c);
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((b * c) <= -3.6e+177)
		tmp = b * c;
	elseif ((b * c) <= -6e-274)
		tmp = (j * k) * -27.0;
	elseif ((b * c) <= 1.65e-115)
		tmp = x * (i * -4.0);
	elseif ((b * c) <= 1.5e+204)
		tmp = x * (18.0 * (t * (y * z)));
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -3.6e+177], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -6e-274], N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.65e-115], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.5e+204], N[(x * N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -3.6 \cdot 10^{+177}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \cdot c \leq -6 \cdot 10^{-274}:\\
\;\;\;\;\left(j \cdot k\right) \cdot -27\\

\mathbf{elif}\;b \cdot c \leq 1.65 \cdot 10^{-115}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right)\\

\mathbf{elif}\;b \cdot c \leq 1.5 \cdot 10^{+204}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;b \cdot c\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (*.f64 b c) < -3.60000000000000003e177 or 1.49999999999999991e204 < (*.f64 b c)

    1. Initial program 81.0%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified79.5%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. pow179.5%

        \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. associate-*r*79.5%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative79.5%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. *-commutative79.5%

        \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    5. Applied egg-rr79.5%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    6. Step-by-step derivation
      1. unpow179.5%

        \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. *-commutative79.5%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative79.5%

        \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. associate-*r*79.5%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    7. Simplified79.5%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    8. Taylor expanded in k around inf 60.9%

      \[\leadsto \color{blue}{k \cdot \left(\left(\frac{b \cdot c}{k} + \frac{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)}{k}\right) - \left(4 \cdot \frac{i \cdot x}{k} + 27 \cdot j\right)\right)} \]
    9. Taylor expanded in b around inf 71.2%

      \[\leadsto \color{blue}{b \cdot c} \]

    if -3.60000000000000003e177 < (*.f64 b c) < -5.99999999999999954e-274

    1. Initial program 84.9%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified82.6%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around inf 35.5%

      \[\leadsto \color{blue}{-27 \cdot \left(j \cdot k\right)} \]

    if -5.99999999999999954e-274 < (*.f64 b c) < 1.64999999999999995e-115

    1. Initial program 79.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified89.7%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 62.0%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Taylor expanded in t around 0 43.6%

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
    6. Step-by-step derivation
      1. metadata-eval43.6%

        \[\leadsto \color{blue}{\left(-4\right)} \cdot \left(i \cdot x\right) \]
      2. distribute-lft-neg-in43.6%

        \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
      3. associate-*r*43.6%

        \[\leadsto -\color{blue}{\left(4 \cdot i\right) \cdot x} \]
      4. *-commutative43.6%

        \[\leadsto -\color{blue}{x \cdot \left(4 \cdot i\right)} \]
      5. distribute-rgt-neg-in43.6%

        \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]
      6. distribute-lft-neg-in43.6%

        \[\leadsto x \cdot \color{blue}{\left(\left(-4\right) \cdot i\right)} \]
      7. metadata-eval43.6%

        \[\leadsto x \cdot \left(\color{blue}{-4} \cdot i\right) \]
    7. Simplified43.6%

      \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]

    if 1.64999999999999995e-115 < (*.f64 b c) < 1.49999999999999991e204

    1. Initial program 85.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified91.8%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 42.7%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Taylor expanded in t around inf 35.7%

      \[\leadsto x \cdot \color{blue}{\left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification46.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -3.6 \cdot 10^{+177}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -6 \cdot 10^{-274}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \mathbf{elif}\;b \cdot c \leq 1.65 \cdot 10^{-115}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 1.5 \cdot 10^{+204}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 36.5% accurate, 0.8× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.2 \cdot 10^{+178}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -5.2 \cdot 10^{-293}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \mathbf{elif}\;b \cdot c \leq 3.6 \cdot 10^{-123}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 1.25 \cdot 10^{+203}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(y \cdot \left(z \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= (* b c) -1.2e+178)
   (* b c)
   (if (<= (* b c) -5.2e-293)
     (* (* j k) -27.0)
     (if (<= (* b c) 3.6e-123)
       (* x (* i -4.0))
       (if (<= (* b c) 1.25e+203) (* x (* 18.0 (* y (* z t)))) (* b c))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((b * c) <= -1.2e+178) {
		tmp = b * c;
	} else if ((b * c) <= -5.2e-293) {
		tmp = (j * k) * -27.0;
	} else if ((b * c) <= 3.6e-123) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 1.25e+203) {
		tmp = x * (18.0 * (y * (z * t)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((b * c) <= (-1.2d+178)) then
        tmp = b * c
    else if ((b * c) <= (-5.2d-293)) then
        tmp = (j * k) * (-27.0d0)
    else if ((b * c) <= 3.6d-123) then
        tmp = x * (i * (-4.0d0))
    else if ((b * c) <= 1.25d+203) then
        tmp = x * (18.0d0 * (y * (z * t)))
    else
        tmp = b * c
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((b * c) <= -1.2e+178) {
		tmp = b * c;
	} else if ((b * c) <= -5.2e-293) {
		tmp = (j * k) * -27.0;
	} else if ((b * c) <= 3.6e-123) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 1.25e+203) {
		tmp = x * (18.0 * (y * (z * t)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (b * c) <= -1.2e+178:
		tmp = b * c
	elif (b * c) <= -5.2e-293:
		tmp = (j * k) * -27.0
	elif (b * c) <= 3.6e-123:
		tmp = x * (i * -4.0)
	elif (b * c) <= 1.25e+203:
		tmp = x * (18.0 * (y * (z * t)))
	else:
		tmp = b * c
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (Float64(b * c) <= -1.2e+178)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -5.2e-293)
		tmp = Float64(Float64(j * k) * -27.0);
	elseif (Float64(b * c) <= 3.6e-123)
		tmp = Float64(x * Float64(i * -4.0));
	elseif (Float64(b * c) <= 1.25e+203)
		tmp = Float64(x * Float64(18.0 * Float64(y * Float64(z * t))));
	else
		tmp = Float64(b * c);
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((b * c) <= -1.2e+178)
		tmp = b * c;
	elseif ((b * c) <= -5.2e-293)
		tmp = (j * k) * -27.0;
	elseif ((b * c) <= 3.6e-123)
		tmp = x * (i * -4.0);
	elseif ((b * c) <= 1.25e+203)
		tmp = x * (18.0 * (y * (z * t)));
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -1.2e+178], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -5.2e-293], N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 3.6e-123], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.25e+203], N[(x * N[(18.0 * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1.2 \cdot 10^{+178}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \cdot c \leq -5.2 \cdot 10^{-293}:\\
\;\;\;\;\left(j \cdot k\right) \cdot -27\\

\mathbf{elif}\;b \cdot c \leq 3.6 \cdot 10^{-123}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right)\\

\mathbf{elif}\;b \cdot c \leq 1.25 \cdot 10^{+203}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(y \cdot \left(z \cdot t\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;b \cdot c\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (*.f64 b c) < -1.2e178 or 1.24999999999999999e203 < (*.f64 b c)

    1. Initial program 81.0%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified79.5%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. pow179.5%

        \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. associate-*r*79.5%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative79.5%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. *-commutative79.5%

        \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    5. Applied egg-rr79.5%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    6. Step-by-step derivation
      1. unpow179.5%

        \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. *-commutative79.5%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative79.5%

        \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. associate-*r*79.5%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    7. Simplified79.5%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    8. Taylor expanded in k around inf 60.9%

      \[\leadsto \color{blue}{k \cdot \left(\left(\frac{b \cdot c}{k} + \frac{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)}{k}\right) - \left(4 \cdot \frac{i \cdot x}{k} + 27 \cdot j\right)\right)} \]
    9. Taylor expanded in b around inf 71.2%

      \[\leadsto \color{blue}{b \cdot c} \]

    if -1.2e178 < (*.f64 b c) < -5.1999999999999996e-293

    1. Initial program 84.9%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified82.6%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around inf 35.5%

      \[\leadsto \color{blue}{-27 \cdot \left(j \cdot k\right)} \]

    if -5.1999999999999996e-293 < (*.f64 b c) < 3.5999999999999997e-123

    1. Initial program 79.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified89.7%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 62.0%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Taylor expanded in t around 0 43.6%

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
    6. Step-by-step derivation
      1. metadata-eval43.6%

        \[\leadsto \color{blue}{\left(-4\right)} \cdot \left(i \cdot x\right) \]
      2. distribute-lft-neg-in43.6%

        \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
      3. associate-*r*43.6%

        \[\leadsto -\color{blue}{\left(4 \cdot i\right) \cdot x} \]
      4. *-commutative43.6%

        \[\leadsto -\color{blue}{x \cdot \left(4 \cdot i\right)} \]
      5. distribute-rgt-neg-in43.6%

        \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]
      6. distribute-lft-neg-in43.6%

        \[\leadsto x \cdot \color{blue}{\left(\left(-4\right) \cdot i\right)} \]
      7. metadata-eval43.6%

        \[\leadsto x \cdot \left(\color{blue}{-4} \cdot i\right) \]
    7. Simplified43.6%

      \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]

    if 3.5999999999999997e-123 < (*.f64 b c) < 1.24999999999999999e203

    1. Initial program 85.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified91.8%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 42.7%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Taylor expanded in t around inf 35.7%

      \[\leadsto x \cdot \color{blue}{\left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right)} \]
    6. Step-by-step derivation
      1. *-commutative35.7%

        \[\leadsto x \cdot \left(18 \cdot \left(t \cdot \color{blue}{\left(z \cdot y\right)}\right)\right) \]
      2. associate-*r*35.5%

        \[\leadsto x \cdot \left(18 \cdot \color{blue}{\left(\left(t \cdot z\right) \cdot y\right)}\right) \]
    7. Simplified35.5%

      \[\leadsto x \cdot \color{blue}{\left(18 \cdot \left(\left(t \cdot z\right) \cdot y\right)\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification46.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.2 \cdot 10^{+178}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -5.2 \cdot 10^{-293}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \mathbf{elif}\;b \cdot c \leq 3.6 \cdot 10^{-123}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 1.25 \cdot 10^{+203}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(y \cdot \left(z \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 86.7% accurate, 0.9× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -4 \cdot 10^{+193}:\\ \;\;\;\;b \cdot \left(\left(c + -4 \cdot \frac{t \cdot a}{b}\right) - 27 \cdot \frac{j \cdot k}{b}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(z \cdot \left(18 \cdot \left(x \cdot y\right)\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= (* b c) -4e+193)
   (* b (- (+ c (* -4.0 (/ (* t a) b))) (* 27.0 (/ (* j k) b))))
   (-
    (+ (* b c) (* t (- (* z (* 18.0 (* x y))) (* a 4.0))))
    (+ (* x (* 4.0 i)) (* j (* 27.0 k))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((b * c) <= -4e+193) {
		tmp = b * ((c + (-4.0 * ((t * a) / b))) - (27.0 * ((j * k) / b)));
	} else {
		tmp = ((b * c) + (t * ((z * (18.0 * (x * y))) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((b * c) <= (-4d+193)) then
        tmp = b * ((c + ((-4.0d0) * ((t * a) / b))) - (27.0d0 * ((j * k) / b)))
    else
        tmp = ((b * c) + (t * ((z * (18.0d0 * (x * y))) - (a * 4.0d0)))) - ((x * (4.0d0 * i)) + (j * (27.0d0 * k)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((b * c) <= -4e+193) {
		tmp = b * ((c + (-4.0 * ((t * a) / b))) - (27.0 * ((j * k) / b)));
	} else {
		tmp = ((b * c) + (t * ((z * (18.0 * (x * y))) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (b * c) <= -4e+193:
		tmp = b * ((c + (-4.0 * ((t * a) / b))) - (27.0 * ((j * k) / b)))
	else:
		tmp = ((b * c) + (t * ((z * (18.0 * (x * y))) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (Float64(b * c) <= -4e+193)
		tmp = Float64(b * Float64(Float64(c + Float64(-4.0 * Float64(Float64(t * a) / b))) - Float64(27.0 * Float64(Float64(j * k) / b))));
	else
		tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(z * Float64(18.0 * Float64(x * y))) - Float64(a * 4.0)))) - Float64(Float64(x * Float64(4.0 * i)) + Float64(j * Float64(27.0 * k))));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((b * c) <= -4e+193)
		tmp = b * ((c + (-4.0 * ((t * a) / b))) - (27.0 * ((j * k) / b)));
	else
		tmp = ((b * c) + (t * ((z * (18.0 * (x * y))) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -4e+193], N[(b * N[(N[(c + N[(-4.0 * N[(N[(t * a), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(27.0 * N[(N[(j * k), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(z * N[(18.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(27.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -4 \cdot 10^{+193}:\\
\;\;\;\;b \cdot \left(\left(c + -4 \cdot \frac{t \cdot a}{b}\right) - 27 \cdot \frac{j \cdot k}{b}\right)\\

\mathbf{else}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(z \cdot \left(18 \cdot \left(x \cdot y\right)\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 b c) < -4.00000000000000026e193

    1. Initial program 76.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified72.7%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 89.7%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in b around inf 93.1%

      \[\leadsto \color{blue}{b \cdot \left(\left(c + -4 \cdot \frac{a \cdot t}{b}\right) - 27 \cdot \frac{j \cdot k}{b}\right)} \]

    if -4.00000000000000026e193 < (*.f64 b c)

    1. Initial program 83.5%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified86.7%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. pow186.7%

        \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. associate-*r*86.1%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative86.1%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. *-commutative86.1%

        \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    5. Applied egg-rr86.1%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    6. Step-by-step derivation
      1. unpow186.1%

        \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. *-commutative86.1%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative86.1%

        \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. associate-*r*86.1%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    7. Simplified86.1%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification86.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -4 \cdot 10^{+193}:\\ \;\;\;\;b \cdot \left(\left(c + -4 \cdot \frac{t \cdot a}{b}\right) - 27 \cdot \frac{j \cdot k}{b}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(z \cdot \left(18 \cdot \left(x \cdot y\right)\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 71.9% accurate, 0.9× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;x \leq -1.06 \cdot 10^{+52}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\ \mathbf{elif}\;x \leq -2.8 \cdot 10^{+32} \lor \neg \left(x \leq -2.15 \cdot 10^{-7}\right) \land x \leq 16500000:\\ \;\;\;\;t \cdot \left(a \cdot -4\right) + \left(b \cdot c - \left(j \cdot 27\right) \cdot k\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= x -1.06e+52)
   (* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))
   (if (or (<= x -2.8e+32) (and (not (<= x -2.15e-7)) (<= x 16500000.0)))
     (+ (* t (* a -4.0)) (- (* b c) (* (* j 27.0) k)))
     (* x (+ (* (* 18.0 t) (* y z)) (* i -4.0))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (x <= -1.06e+52) {
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	} else if ((x <= -2.8e+32) || (!(x <= -2.15e-7) && (x <= 16500000.0))) {
		tmp = (t * (a * -4.0)) + ((b * c) - ((j * 27.0) * k));
	} else {
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (x <= (-1.06d+52)) then
        tmp = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
    else if ((x <= (-2.8d+32)) .or. (.not. (x <= (-2.15d-7))) .and. (x <= 16500000.0d0)) then
        tmp = (t * (a * (-4.0d0))) + ((b * c) - ((j * 27.0d0) * k))
    else
        tmp = x * (((18.0d0 * t) * (y * z)) + (i * (-4.0d0)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (x <= -1.06e+52) {
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	} else if ((x <= -2.8e+32) || (!(x <= -2.15e-7) && (x <= 16500000.0))) {
		tmp = (t * (a * -4.0)) + ((b * c) - ((j * 27.0) * k));
	} else {
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if x <= -1.06e+52:
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i))
	elif (x <= -2.8e+32) or (not (x <= -2.15e-7) and (x <= 16500000.0)):
		tmp = (t * (a * -4.0)) + ((b * c) - ((j * 27.0) * k))
	else:
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (x <= -1.06e+52)
		tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i)));
	elseif ((x <= -2.8e+32) || (!(x <= -2.15e-7) && (x <= 16500000.0)))
		tmp = Float64(Float64(t * Float64(a * -4.0)) + Float64(Float64(b * c) - Float64(Float64(j * 27.0) * k)));
	else
		tmp = Float64(x * Float64(Float64(Float64(18.0 * t) * Float64(y * z)) + Float64(i * -4.0)));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (x <= -1.06e+52)
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	elseif ((x <= -2.8e+32) || (~((x <= -2.15e-7)) && (x <= 16500000.0)))
		tmp = (t * (a * -4.0)) + ((b * c) - ((j * 27.0) * k));
	else
		tmp = x * (((18.0 * t) * (y * z)) + (i * -4.0));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[x, -1.06e+52], N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[x, -2.8e+32], And[N[Not[LessEqual[x, -2.15e-7]], $MachinePrecision], LessEqual[x, 16500000.0]]], N[(N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(N[(b * c), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(N[(18.0 * t), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.06 \cdot 10^{+52}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\

\mathbf{elif}\;x \leq -2.8 \cdot 10^{+32} \lor \neg \left(x \leq -2.15 \cdot 10^{-7}\right) \land x \leq 16500000:\\
\;\;\;\;t \cdot \left(a \cdot -4\right) + \left(b \cdot c - \left(j \cdot 27\right) \cdot k\right)\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if x < -1.0599999999999999e52

    1. Initial program 70.7%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified77.6%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 70.1%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]

    if -1.0599999999999999e52 < x < -2.8e32 or -2.1500000000000001e-7 < x < 1.65e7

    1. Initial program 92.5%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified89.6%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 85.0%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Step-by-step derivation
      1. associate--l+85.0%

        \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + \left(b \cdot c - 27 \cdot \left(j \cdot k\right)\right)} \]
      2. associate-*r*85.0%

        \[\leadsto \color{blue}{\left(-4 \cdot a\right) \cdot t} + \left(b \cdot c - 27 \cdot \left(j \cdot k\right)\right) \]
      3. associate-*r*84.2%

        \[\leadsto \left(-4 \cdot a\right) \cdot t + \left(b \cdot c - \color{blue}{\left(27 \cdot j\right) \cdot k}\right) \]
    6. Applied egg-rr84.2%

      \[\leadsto \color{blue}{\left(-4 \cdot a\right) \cdot t + \left(b \cdot c - \left(27 \cdot j\right) \cdot k\right)} \]

    if -2.8e32 < x < -2.1500000000000001e-7 or 1.65e7 < x

    1. Initial program 73.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified82.6%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 75.3%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Step-by-step derivation
      1. cancel-sign-sub-inv75.3%

        \[\leadsto x \cdot \color{blue}{\left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) + \left(-4\right) \cdot i\right)} \]
      2. associate-*r*75.3%

        \[\leadsto x \cdot \left(\color{blue}{\left(18 \cdot t\right) \cdot \left(y \cdot z\right)} + \left(-4\right) \cdot i\right) \]
      3. *-commutative75.3%

        \[\leadsto x \cdot \left(\left(18 \cdot t\right) \cdot \color{blue}{\left(z \cdot y\right)} + \left(-4\right) \cdot i\right) \]
      4. metadata-eval75.3%

        \[\leadsto x \cdot \left(\left(18 \cdot t\right) \cdot \left(z \cdot y\right) + \color{blue}{-4} \cdot i\right) \]
    6. Applied egg-rr75.3%

      \[\leadsto x \cdot \color{blue}{\left(\left(18 \cdot t\right) \cdot \left(z \cdot y\right) + -4 \cdot i\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification78.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -1.06 \cdot 10^{+52}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\ \mathbf{elif}\;x \leq -2.8 \cdot 10^{+32} \lor \neg \left(x \leq -2.15 \cdot 10^{-7}\right) \land x \leq 16500000:\\ \;\;\;\;t \cdot \left(a \cdot -4\right) + \left(b \cdot c - \left(j \cdot 27\right) \cdot k\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\left(18 \cdot t\right) \cdot \left(y \cdot z\right) + i \cdot -4\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 85.7% accurate, 0.9× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;c \leq 1.1 \cdot 10^{+160}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= c 1.1e+160)
   (-
    (+ (* b c) (* t (- (* (* x 18.0) (* y z)) (* a 4.0))))
    (+ (* x (* 4.0 i)) (* j (* 27.0 k))))
   (- (- (- (* b c) (* 4.0 (* t a))) (* (* x 4.0) i)) (* (* j 27.0) k))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (c <= 1.1e+160) {
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	} else {
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (c <= 1.1d+160) then
        tmp = ((b * c) + (t * (((x * 18.0d0) * (y * z)) - (a * 4.0d0)))) - ((x * (4.0d0 * i)) + (j * (27.0d0 * k)))
    else
        tmp = (((b * c) - (4.0d0 * (t * a))) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (c <= 1.1e+160) {
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	} else {
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if c <= 1.1e+160:
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)))
	else:
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k)
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (c <= 1.1e+160)
		tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(x * 18.0) * Float64(y * z)) - Float64(a * 4.0)))) - Float64(Float64(x * Float64(4.0 * i)) + Float64(j * Float64(27.0 * k))));
	else
		tmp = Float64(Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(t * a))) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (c <= 1.1e+160)
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	else
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[c, 1.1e+160], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(x * 18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(27.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;c \leq 1.1 \cdot 10^{+160}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if c < 1.09999999999999996e160

    1. Initial program 83.0%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified86.2%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing

    if 1.09999999999999996e160 < c

    1. Initial program 80.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 78.2%

      \[\leadsto \left(\color{blue}{\left(b \cdot c - 4 \cdot \left(a \cdot t\right)\right)} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
  3. Recombined 2 regimes into one program.
  4. Final simplification85.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;c \leq 1.1 \cdot 10^{+160}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 36.5% accurate, 0.9× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \left(j \cdot k\right) \cdot -27\\ \mathbf{if}\;b \cdot c \leq -4.5 \cdot 10^{+176}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -8 \cdot 10^{-287}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;b \cdot c \leq 8 \cdot 10^{-121}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 3.1 \cdot 10^{+121}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* (* j k) -27.0)))
   (if (<= (* b c) -4.5e+176)
     (* b c)
     (if (<= (* b c) -8e-287)
       t_1
       (if (<= (* b c) 8e-121)
         (* x (* i -4.0))
         (if (<= (* b c) 3.1e+121) t_1 (* b c)))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (j * k) * -27.0;
	double tmp;
	if ((b * c) <= -4.5e+176) {
		tmp = b * c;
	} else if ((b * c) <= -8e-287) {
		tmp = t_1;
	} else if ((b * c) <= 8e-121) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 3.1e+121) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: tmp
    t_1 = (j * k) * (-27.0d0)
    if ((b * c) <= (-4.5d+176)) then
        tmp = b * c
    else if ((b * c) <= (-8d-287)) then
        tmp = t_1
    else if ((b * c) <= 8d-121) then
        tmp = x * (i * (-4.0d0))
    else if ((b * c) <= 3.1d+121) then
        tmp = t_1
    else
        tmp = b * c
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (j * k) * -27.0;
	double tmp;
	if ((b * c) <= -4.5e+176) {
		tmp = b * c;
	} else if ((b * c) <= -8e-287) {
		tmp = t_1;
	} else if ((b * c) <= 8e-121) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 3.1e+121) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (j * k) * -27.0
	tmp = 0
	if (b * c) <= -4.5e+176:
		tmp = b * c
	elif (b * c) <= -8e-287:
		tmp = t_1
	elif (b * c) <= 8e-121:
		tmp = x * (i * -4.0)
	elif (b * c) <= 3.1e+121:
		tmp = t_1
	else:
		tmp = b * c
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(j * k) * -27.0)
	tmp = 0.0
	if (Float64(b * c) <= -4.5e+176)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -8e-287)
		tmp = t_1;
	elseif (Float64(b * c) <= 8e-121)
		tmp = Float64(x * Float64(i * -4.0));
	elseif (Float64(b * c) <= 3.1e+121)
		tmp = t_1;
	else
		tmp = Float64(b * c);
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (j * k) * -27.0;
	tmp = 0.0;
	if ((b * c) <= -4.5e+176)
		tmp = b * c;
	elseif ((b * c) <= -8e-287)
		tmp = t_1;
	elseif ((b * c) <= 8e-121)
		tmp = x * (i * -4.0);
	elseif ((b * c) <= 3.1e+121)
		tmp = t_1;
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -4.5e+176], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -8e-287], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], 8e-121], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 3.1e+121], t$95$1, N[(b * c), $MachinePrecision]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot k\right) \cdot -27\\
\mathbf{if}\;b \cdot c \leq -4.5 \cdot 10^{+176}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \cdot c \leq -8 \cdot 10^{-287}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;b \cdot c \leq 8 \cdot 10^{-121}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right)\\

\mathbf{elif}\;b \cdot c \leq 3.1 \cdot 10^{+121}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;b \cdot c\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 b c) < -4.50000000000000003e176 or 3.10000000000000008e121 < (*.f64 b c)

    1. Initial program 82.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified81.2%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. pow181.2%

        \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. associate-*r*81.2%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative81.2%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. *-commutative81.2%

        \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    5. Applied egg-rr81.2%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    6. Step-by-step derivation
      1. unpow181.2%

        \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. *-commutative81.2%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative81.2%

        \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. associate-*r*81.2%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    7. Simplified81.2%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    8. Taylor expanded in k around inf 60.2%

      \[\leadsto \color{blue}{k \cdot \left(\left(\frac{b \cdot c}{k} + \frac{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)}{k}\right) - \left(4 \cdot \frac{i \cdot x}{k} + 27 \cdot j\right)\right)} \]
    9. Taylor expanded in b around inf 65.9%

      \[\leadsto \color{blue}{b \cdot c} \]

    if -4.50000000000000003e176 < (*.f64 b c) < -8.00000000000000017e-287 or 7.9999999999999998e-121 < (*.f64 b c) < 3.10000000000000008e121

    1. Initial program 84.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified85.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around inf 35.5%

      \[\leadsto \color{blue}{-27 \cdot \left(j \cdot k\right)} \]

    if -8.00000000000000017e-287 < (*.f64 b c) < 7.9999999999999998e-121

    1. Initial program 79.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified89.7%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 62.0%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Taylor expanded in t around 0 43.6%

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
    6. Step-by-step derivation
      1. metadata-eval43.6%

        \[\leadsto \color{blue}{\left(-4\right)} \cdot \left(i \cdot x\right) \]
      2. distribute-lft-neg-in43.6%

        \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
      3. associate-*r*43.6%

        \[\leadsto -\color{blue}{\left(4 \cdot i\right) \cdot x} \]
      4. *-commutative43.6%

        \[\leadsto -\color{blue}{x \cdot \left(4 \cdot i\right)} \]
      5. distribute-rgt-neg-in43.6%

        \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]
      6. distribute-lft-neg-in43.6%

        \[\leadsto x \cdot \color{blue}{\left(\left(-4\right) \cdot i\right)} \]
      7. metadata-eval43.6%

        \[\leadsto x \cdot \left(\color{blue}{-4} \cdot i\right) \]
    7. Simplified43.6%

      \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification46.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -4.5 \cdot 10^{+176}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -8 \cdot 10^{-287}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \mathbf{elif}\;b \cdot c \leq 8 \cdot 10^{-121}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 3.1 \cdot 10^{+121}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 81.2% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -1.05 \cdot 10^{+136} \lor \neg \left(t \leq 10^{+88}\right):\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= t -1.05e+136) (not (<= t 1e+88)))
   (+ (* t (+ (* 18.0 (* x (* y z))) (* a -4.0))) (* j (* k -27.0)))
   (- (- (- (* b c) (* 4.0 (* t a))) (* (* x 4.0) i)) (* (* j 27.0) k))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((t <= -1.05e+136) || !(t <= 1e+88)) {
		tmp = (t * ((18.0 * (x * (y * z))) + (a * -4.0))) + (j * (k * -27.0));
	} else {
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((t <= (-1.05d+136)) .or. (.not. (t <= 1d+88))) then
        tmp = (t * ((18.0d0 * (x * (y * z))) + (a * (-4.0d0)))) + (j * (k * (-27.0d0)))
    else
        tmp = (((b * c) - (4.0d0 * (t * a))) - ((x * 4.0d0) * i)) - ((j * 27.0d0) * k)
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((t <= -1.05e+136) || !(t <= 1e+88)) {
		tmp = (t * ((18.0 * (x * (y * z))) + (a * -4.0))) + (j * (k * -27.0));
	} else {
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (t <= -1.05e+136) or not (t <= 1e+88):
		tmp = (t * ((18.0 * (x * (y * z))) + (a * -4.0))) + (j * (k * -27.0))
	else:
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k)
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((t <= -1.05e+136) || !(t <= 1e+88))
		tmp = Float64(Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) + Float64(a * -4.0))) + Float64(j * Float64(k * -27.0)));
	else
		tmp = Float64(Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(t * a))) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((t <= -1.05e+136) || ~((t <= 1e+88)))
		tmp = (t * ((18.0 * (x * (y * z))) + (a * -4.0))) + (j * (k * -27.0));
	else
		tmp = (((b * c) - (4.0 * (t * a))) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[t, -1.05e+136], N[Not[LessEqual[t, 1e+88]], $MachinePrecision]], N[(N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.05 \cdot 10^{+136} \lor \neg \left(t \leq 10^{+88}\right):\\
\;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.05e136 or 9.99999999999999959e87 < t

    1. Initial program 82.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified91.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 84.2%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} + j \cdot \left(k \cdot -27\right) \]

    if -1.05e136 < t < 9.99999999999999959e87

    1. Initial program 82.7%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 86.6%

      \[\leadsto \left(\color{blue}{\left(b \cdot c - 4 \cdot \left(a \cdot t\right)\right)} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
  3. Recombined 2 regimes into one program.
  4. Final simplification85.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.05 \cdot 10^{+136} \lor \neg \left(t \leq 10^{+88}\right):\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(b \cdot c - 4 \cdot \left(t \cdot a\right)\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 45.2% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \left(j \cdot k\right) \cdot -27\\ t_2 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{if}\;j \leq -3.7 \cdot 10^{+233}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;j \leq -4.7 \cdot 10^{+210}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;j \leq -3.4 \cdot 10^{+138}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;j \leq 7.6 \cdot 10^{-125}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;j \leq 1.55 \cdot 10^{+96}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* (* j k) -27.0)) (t_2 (+ (* b c) (* -4.0 (* t a)))))
   (if (<= j -3.7e+233)
     (* k (* j -27.0))
     (if (<= j -4.7e+210)
       t_2
       (if (<= j -3.4e+138)
         t_1
         (if (<= j 7.6e-125)
           t_2
           (if (<= j 1.55e+96) (* x (* i -4.0)) t_1)))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (j * k) * -27.0;
	double t_2 = (b * c) + (-4.0 * (t * a));
	double tmp;
	if (j <= -3.7e+233) {
		tmp = k * (j * -27.0);
	} else if (j <= -4.7e+210) {
		tmp = t_2;
	} else if (j <= -3.4e+138) {
		tmp = t_1;
	} else if (j <= 7.6e-125) {
		tmp = t_2;
	} else if (j <= 1.55e+96) {
		tmp = x * (i * -4.0);
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = (j * k) * (-27.0d0)
    t_2 = (b * c) + ((-4.0d0) * (t * a))
    if (j <= (-3.7d+233)) then
        tmp = k * (j * (-27.0d0))
    else if (j <= (-4.7d+210)) then
        tmp = t_2
    else if (j <= (-3.4d+138)) then
        tmp = t_1
    else if (j <= 7.6d-125) then
        tmp = t_2
    else if (j <= 1.55d+96) then
        tmp = x * (i * (-4.0d0))
    else
        tmp = t_1
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = (j * k) * -27.0;
	double t_2 = (b * c) + (-4.0 * (t * a));
	double tmp;
	if (j <= -3.7e+233) {
		tmp = k * (j * -27.0);
	} else if (j <= -4.7e+210) {
		tmp = t_2;
	} else if (j <= -3.4e+138) {
		tmp = t_1;
	} else if (j <= 7.6e-125) {
		tmp = t_2;
	} else if (j <= 1.55e+96) {
		tmp = x * (i * -4.0);
	} else {
		tmp = t_1;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (j * k) * -27.0
	t_2 = (b * c) + (-4.0 * (t * a))
	tmp = 0
	if j <= -3.7e+233:
		tmp = k * (j * -27.0)
	elif j <= -4.7e+210:
		tmp = t_2
	elif j <= -3.4e+138:
		tmp = t_1
	elif j <= 7.6e-125:
		tmp = t_2
	elif j <= 1.55e+96:
		tmp = x * (i * -4.0)
	else:
		tmp = t_1
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(j * k) * -27.0)
	t_2 = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a)))
	tmp = 0.0
	if (j <= -3.7e+233)
		tmp = Float64(k * Float64(j * -27.0));
	elseif (j <= -4.7e+210)
		tmp = t_2;
	elseif (j <= -3.4e+138)
		tmp = t_1;
	elseif (j <= 7.6e-125)
		tmp = t_2;
	elseif (j <= 1.55e+96)
		tmp = Float64(x * Float64(i * -4.0));
	else
		tmp = t_1;
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (j * k) * -27.0;
	t_2 = (b * c) + (-4.0 * (t * a));
	tmp = 0.0;
	if (j <= -3.7e+233)
		tmp = k * (j * -27.0);
	elseif (j <= -4.7e+210)
		tmp = t_2;
	elseif (j <= -3.4e+138)
		tmp = t_1;
	elseif (j <= 7.6e-125)
		tmp = t_2;
	elseif (j <= 1.55e+96)
		tmp = x * (i * -4.0);
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -3.7e+233], N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, -4.7e+210], t$95$2, If[LessEqual[j, -3.4e+138], t$95$1, If[LessEqual[j, 7.6e-125], t$95$2, If[LessEqual[j, 1.55e+96], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
t_1 := \left(j \cdot k\right) \cdot -27\\
t_2 := b \cdot c + -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;j \leq -3.7 \cdot 10^{+233}:\\
\;\;\;\;k \cdot \left(j \cdot -27\right)\\

\mathbf{elif}\;j \leq -4.7 \cdot 10^{+210}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;j \leq -3.4 \cdot 10^{+138}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;j \leq 7.6 \cdot 10^{-125}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;j \leq 1.55 \cdot 10^{+96}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if j < -3.6999999999999998e233

    1. Initial program 76.5%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified76.9%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around inf 71.8%

      \[\leadsto \color{blue}{-27 \cdot \left(j \cdot k\right)} \]
    5. Step-by-step derivation
      1. associate-*r*71.9%

        \[\leadsto \color{blue}{\left(-27 \cdot j\right) \cdot k} \]
    6. Simplified71.9%

      \[\leadsto \color{blue}{\left(-27 \cdot j\right) \cdot k} \]

    if -3.6999999999999998e233 < j < -4.7000000000000001e210 or -3.40000000000000011e138 < j < 7.6000000000000002e-125

    1. Initial program 81.8%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified84.8%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 58.7%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in j around 0 53.1%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + b \cdot c} \]

    if -4.7000000000000001e210 < j < -3.40000000000000011e138 or 1.5499999999999999e96 < j

    1. Initial program 84.6%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified87.6%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around inf 47.5%

      \[\leadsto \color{blue}{-27 \cdot \left(j \cdot k\right)} \]

    if 7.6000000000000002e-125 < j < 1.5499999999999999e96

    1. Initial program 85.2%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified88.0%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 46.1%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Taylor expanded in t around 0 23.9%

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
    6. Step-by-step derivation
      1. metadata-eval23.9%

        \[\leadsto \color{blue}{\left(-4\right)} \cdot \left(i \cdot x\right) \]
      2. distribute-lft-neg-in23.9%

        \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
      3. associate-*r*23.9%

        \[\leadsto -\color{blue}{\left(4 \cdot i\right) \cdot x} \]
      4. *-commutative23.9%

        \[\leadsto -\color{blue}{x \cdot \left(4 \cdot i\right)} \]
      5. distribute-rgt-neg-in23.9%

        \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]
      6. distribute-lft-neg-in23.9%

        \[\leadsto x \cdot \color{blue}{\left(\left(-4\right) \cdot i\right)} \]
      7. metadata-eval23.9%

        \[\leadsto x \cdot \left(\color{blue}{-4} \cdot i\right) \]
    7. Simplified23.9%

      \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification48.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;j \leq -3.7 \cdot 10^{+233}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;j \leq -4.7 \cdot 10^{+210}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;j \leq -3.4 \cdot 10^{+138}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \mathbf{elif}\;j \leq 7.6 \cdot 10^{-125}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;j \leq 1.55 \cdot 10^{+96}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \end{array} \]
  5. Add Preprocessing

Alternative 16: 68.5% accurate, 1.1× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182} \lor \neg \left(b \cdot c \leq 5 \cdot 10^{+120}\right):\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right) + -4 \cdot \left(t \cdot a + x \cdot i\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= (* b c) -2e+182) (not (<= (* b c) 5e+120)))
   (+ (* b c) (* -4.0 (* t a)))
   (+ (* k (* j -27.0)) (* -4.0 (+ (* t a) (* x i))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (((b * c) <= -2e+182) || !((b * c) <= 5e+120)) {
		tmp = (b * c) + (-4.0 * (t * a));
	} else {
		tmp = (k * (j * -27.0)) + (-4.0 * ((t * a) + (x * i)));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (((b * c) <= (-2d+182)) .or. (.not. ((b * c) <= 5d+120))) then
        tmp = (b * c) + ((-4.0d0) * (t * a))
    else
        tmp = (k * (j * (-27.0d0))) + ((-4.0d0) * ((t * a) + (x * i)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (((b * c) <= -2e+182) || !((b * c) <= 5e+120)) {
		tmp = (b * c) + (-4.0 * (t * a));
	} else {
		tmp = (k * (j * -27.0)) + (-4.0 * ((t * a) + (x * i)));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if ((b * c) <= -2e+182) or not ((b * c) <= 5e+120):
		tmp = (b * c) + (-4.0 * (t * a))
	else:
		tmp = (k * (j * -27.0)) + (-4.0 * ((t * a) + (x * i)))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((Float64(b * c) <= -2e+182) || !(Float64(b * c) <= 5e+120))
		tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a)));
	else
		tmp = Float64(Float64(k * Float64(j * -27.0)) + Float64(-4.0 * Float64(Float64(t * a) + Float64(x * i))));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (((b * c) <= -2e+182) || ~(((b * c) <= 5e+120)))
		tmp = (b * c) + (-4.0 * (t * a));
	else
		tmp = (k * (j * -27.0)) + (-4.0 * ((t * a) + (x * i)));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -2e+182], N[Not[LessEqual[N[(b * c), $MachinePrecision], 5e+120]], $MachinePrecision]], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182} \lor \neg \left(b \cdot c \leq 5 \cdot 10^{+120}\right):\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\

\mathbf{else}:\\
\;\;\;\;k \cdot \left(j \cdot -27\right) + -4 \cdot \left(t \cdot a + x \cdot i\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 b c) < -2.0000000000000001e182 or 5.00000000000000019e120 < (*.f64 b c)

    1. Initial program 82.2%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified80.9%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 76.6%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in j around 0 76.6%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + b \cdot c} \]

    if -2.0000000000000001e182 < (*.f64 b c) < 5.00000000000000019e120

    1. Initial program 82.9%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. pow182.9%

        \[\leadsto \left(\left(\left(\color{blue}{{\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t\right)}^{1}} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      2. associate-*r*83.5%

        \[\leadsto \left(\left(\left({\left(\color{blue}{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)} \cdot t\right)}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      3. *-commutative83.5%

        \[\leadsto \left(\left(\left({\color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\right)}}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      4. associate-*r*82.9%

        \[\leadsto \left(\left(\left({\left(t \cdot \color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}\right)}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      5. *-commutative82.9%

        \[\leadsto \left(\left(\left({\left(t \cdot \color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}\right)}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      6. *-commutative82.9%

        \[\leadsto \left(\left(\left({\left(t \cdot \left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)\right)}^{1} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    4. Applied egg-rr82.9%

      \[\leadsto \left(\left(\left(\color{blue}{{\left(t \cdot \left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)\right)}^{1}} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    5. Step-by-step derivation
      1. unpow182.9%

        \[\leadsto \left(\left(\left(\color{blue}{t \cdot \left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      2. associate-*r*83.7%

        \[\leadsto \left(\left(\left(\color{blue}{\left(t \cdot z\right) \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      3. *-commutative83.7%

        \[\leadsto \left(\left(\left(\left(t \cdot z\right) \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      4. *-commutative83.7%

        \[\leadsto \left(\left(\left(\left(t \cdot z\right) \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      5. associate-*r*83.7%

        \[\leadsto \left(\left(\left(\left(t \cdot z\right) \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    6. Simplified83.7%

      \[\leadsto \left(\left(\left(\color{blue}{\left(t \cdot z\right) \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    7. Taylor expanded in a around inf 74.1%

      \[\leadsto \left(\color{blue}{-4 \cdot \left(a \cdot t\right)} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    8. Step-by-step derivation
      1. associate-*r*74.1%

        \[\leadsto \left(\color{blue}{\left(-4 \cdot a\right) \cdot t} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      2. *-commutative74.1%

        \[\leadsto \left(\color{blue}{t \cdot \left(-4 \cdot a\right)} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
      3. *-commutative74.1%

        \[\leadsto \left(t \cdot \color{blue}{\left(a \cdot -4\right)} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    9. Simplified74.1%

      \[\leadsto \left(\color{blue}{t \cdot \left(a \cdot -4\right)} - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    10. Taylor expanded in t around 0 74.7%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) - \left(4 \cdot \left(i \cdot x\right) + 27 \cdot \left(j \cdot k\right)\right)} \]
    11. Step-by-step derivation
      1. +-commutative74.7%

        \[\leadsto -4 \cdot \left(a \cdot t\right) - \color{blue}{\left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(i \cdot x\right)\right)} \]
      2. associate-*r*74.1%

        \[\leadsto -4 \cdot \left(a \cdot t\right) - \left(\color{blue}{\left(27 \cdot j\right) \cdot k} + 4 \cdot \left(i \cdot x\right)\right) \]
      3. *-commutative74.1%

        \[\leadsto -4 \cdot \left(a \cdot t\right) - \left(\color{blue}{\left(j \cdot 27\right)} \cdot k + 4 \cdot \left(i \cdot x\right)\right) \]
      4. associate-*r*74.6%

        \[\leadsto -4 \cdot \left(a \cdot t\right) - \left(\color{blue}{j \cdot \left(27 \cdot k\right)} + 4 \cdot \left(i \cdot x\right)\right) \]
      5. *-commutative74.6%

        \[\leadsto -4 \cdot \left(a \cdot t\right) - \left(j \cdot \left(27 \cdot k\right) + \color{blue}{\left(i \cdot x\right) \cdot 4}\right) \]
      6. associate-*r*74.6%

        \[\leadsto -4 \cdot \left(a \cdot t\right) - \left(j \cdot \left(27 \cdot k\right) + \color{blue}{i \cdot \left(x \cdot 4\right)}\right) \]
      7. associate--r+74.6%

        \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) - j \cdot \left(27 \cdot k\right)\right) - i \cdot \left(x \cdot 4\right)} \]
      8. associate-*r*74.1%

        \[\leadsto \left(-4 \cdot \left(a \cdot t\right) - \color{blue}{\left(j \cdot 27\right) \cdot k}\right) - i \cdot \left(x \cdot 4\right) \]
      9. *-commutative74.1%

        \[\leadsto \left(-4 \cdot \left(a \cdot t\right) - \color{blue}{\left(27 \cdot j\right)} \cdot k\right) - i \cdot \left(x \cdot 4\right) \]
      10. associate-*r*74.7%

        \[\leadsto \left(-4 \cdot \left(a \cdot t\right) - \color{blue}{27 \cdot \left(j \cdot k\right)}\right) - i \cdot \left(x \cdot 4\right) \]
      11. cancel-sign-sub-inv74.7%

        \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + \left(-27\right) \cdot \left(j \cdot k\right)\right)} - i \cdot \left(x \cdot 4\right) \]
      12. metadata-eval74.7%

        \[\leadsto \left(-4 \cdot \left(a \cdot t\right) + \color{blue}{-27} \cdot \left(j \cdot k\right)\right) - i \cdot \left(x \cdot 4\right) \]
      13. +-commutative74.7%

        \[\leadsto \color{blue}{\left(-27 \cdot \left(j \cdot k\right) + -4 \cdot \left(a \cdot t\right)\right)} - i \cdot \left(x \cdot 4\right) \]
      14. associate-*r*74.7%

        \[\leadsto \left(-27 \cdot \left(j \cdot k\right) + -4 \cdot \left(a \cdot t\right)\right) - \color{blue}{\left(i \cdot x\right) \cdot 4} \]
      15. *-commutative74.7%

        \[\leadsto \left(-27 \cdot \left(j \cdot k\right) + -4 \cdot \left(a \cdot t\right)\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
      16. associate--l+74.7%

        \[\leadsto \color{blue}{-27 \cdot \left(j \cdot k\right) + \left(-4 \cdot \left(a \cdot t\right) - 4 \cdot \left(i \cdot x\right)\right)} \]
    12. Simplified74.1%

      \[\leadsto \color{blue}{k \cdot \left(-27 \cdot j\right) + -4 \cdot \left(a \cdot t + x \cdot i\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification74.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -2 \cdot 10^{+182} \lor \neg \left(b \cdot c \leq 5 \cdot 10^{+120}\right):\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right) + -4 \cdot \left(t \cdot a + x \cdot i\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 17: 73.9% accurate, 1.1× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -6.5 \cdot 10^{+126} \lor \neg \left(t \leq 1.8 \cdot 10^{+87}\right):\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(x \cdot i\right)\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= t -6.5e+126) (not (<= t 1.8e+87)))
   (+ (* t (+ (* 18.0 (* x (* y z))) (* a -4.0))) (* j (* k -27.0)))
   (- (* b c) (+ (* 27.0 (* j k)) (* 4.0 (* x i))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((t <= -6.5e+126) || !(t <= 1.8e+87)) {
		tmp = (t * ((18.0 * (x * (y * z))) + (a * -4.0))) + (j * (k * -27.0));
	} else {
		tmp = (b * c) - ((27.0 * (j * k)) + (4.0 * (x * i)));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((t <= (-6.5d+126)) .or. (.not. (t <= 1.8d+87))) then
        tmp = (t * ((18.0d0 * (x * (y * z))) + (a * (-4.0d0)))) + (j * (k * (-27.0d0)))
    else
        tmp = (b * c) - ((27.0d0 * (j * k)) + (4.0d0 * (x * i)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((t <= -6.5e+126) || !(t <= 1.8e+87)) {
		tmp = (t * ((18.0 * (x * (y * z))) + (a * -4.0))) + (j * (k * -27.0));
	} else {
		tmp = (b * c) - ((27.0 * (j * k)) + (4.0 * (x * i)));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (t <= -6.5e+126) or not (t <= 1.8e+87):
		tmp = (t * ((18.0 * (x * (y * z))) + (a * -4.0))) + (j * (k * -27.0))
	else:
		tmp = (b * c) - ((27.0 * (j * k)) + (4.0 * (x * i)))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((t <= -6.5e+126) || !(t <= 1.8e+87))
		tmp = Float64(Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) + Float64(a * -4.0))) + Float64(j * Float64(k * -27.0)));
	else
		tmp = Float64(Float64(b * c) - Float64(Float64(27.0 * Float64(j * k)) + Float64(4.0 * Float64(x * i))));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((t <= -6.5e+126) || ~((t <= 1.8e+87)))
		tmp = (t * ((18.0 * (x * (y * z))) + (a * -4.0))) + (j * (k * -27.0));
	else
		tmp = (b * c) - ((27.0 * (j * k)) + (4.0 * (x * i)));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[t, -6.5e+126], N[Not[LessEqual[t, 1.8e+87]], $MachinePrecision]], N[(N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * c), $MachinePrecision] - N[(N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision] + N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.5 \cdot 10^{+126} \lor \neg \left(t \leq 1.8 \cdot 10^{+87}\right):\\
\;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\

\mathbf{else}:\\
\;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(x \cdot i\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -6.5000000000000005e126 or 1.79999999999999997e87 < t

    1. Initial program 83.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified92.1%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 83.4%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} + j \cdot \left(k \cdot -27\right) \]

    if -6.5000000000000005e126 < t < 1.79999999999999997e87

    1. Initial program 82.5%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified83.7%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 78.6%

      \[\leadsto \color{blue}{b \cdot c - \left(4 \cdot \left(i \cdot x\right) + 27 \cdot \left(j \cdot k\right)\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification80.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -6.5 \cdot 10^{+126} \lor \neg \left(t \leq 1.8 \cdot 10^{+87}\right):\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) + a \cdot -4\right) + j \cdot \left(k \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(x \cdot i\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 18: 54.7% accurate, 1.2× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -2.5 \cdot 10^{+176} \lor \neg \left(b \cdot c \leq 1.02 \cdot 10^{+126}\right):\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(a \cdot -4\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= (* b c) -2.5e+176) (not (<= (* b c) 1.02e+126)))
   (+ (* b c) (* -4.0 (* t a)))
   (+ (* j (* k -27.0)) (* t (* a -4.0)))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (((b * c) <= -2.5e+176) || !((b * c) <= 1.02e+126)) {
		tmp = (b * c) + (-4.0 * (t * a));
	} else {
		tmp = (j * (k * -27.0)) + (t * (a * -4.0));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (((b * c) <= (-2.5d+176)) .or. (.not. ((b * c) <= 1.02d+126))) then
        tmp = (b * c) + ((-4.0d0) * (t * a))
    else
        tmp = (j * (k * (-27.0d0))) + (t * (a * (-4.0d0)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (((b * c) <= -2.5e+176) || !((b * c) <= 1.02e+126)) {
		tmp = (b * c) + (-4.0 * (t * a));
	} else {
		tmp = (j * (k * -27.0)) + (t * (a * -4.0));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if ((b * c) <= -2.5e+176) or not ((b * c) <= 1.02e+126):
		tmp = (b * c) + (-4.0 * (t * a))
	else:
		tmp = (j * (k * -27.0)) + (t * (a * -4.0))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((Float64(b * c) <= -2.5e+176) || !(Float64(b * c) <= 1.02e+126))
		tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a)));
	else
		tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(t * Float64(a * -4.0)));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (((b * c) <= -2.5e+176) || ~(((b * c) <= 1.02e+126)))
		tmp = (b * c) + (-4.0 * (t * a));
	else
		tmp = (j * (k * -27.0)) + (t * (a * -4.0));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -2.5e+176], N[Not[LessEqual[N[(b * c), $MachinePrecision], 1.02e+126]], $MachinePrecision]], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -2.5 \cdot 10^{+176} \lor \neg \left(b \cdot c \leq 1.02 \cdot 10^{+126}\right):\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\

\mathbf{else}:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(a \cdot -4\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 b c) < -2.5e176 or 1.02e126 < (*.f64 b c)

    1. Initial program 82.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified81.2%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 75.7%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in j around 0 75.7%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + b \cdot c} \]

    if -2.5e176 < (*.f64 b c) < 1.02e126

    1. Initial program 82.8%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified88.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 50.5%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*50.5%

        \[\leadsto \color{blue}{\left(-4 \cdot a\right) \cdot t} + j \cdot \left(k \cdot -27\right) \]
      2. *-commutative50.5%

        \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]
    6. Simplified50.5%

      \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a\right)} + j \cdot \left(k \cdot -27\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification58.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -2.5 \cdot 10^{+176} \lor \neg \left(b \cdot c \leq 1.02 \cdot 10^{+126}\right):\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + t \cdot \left(a \cdot -4\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 19: 71.8% accurate, 1.2× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -5.8 \cdot 10^{+128} \lor \neg \left(t \leq 3 \cdot 10^{+87}\right):\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(x \cdot i\right)\right)\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= t -5.8e+128) (not (<= t 3e+87)))
   (* t (- (* 18.0 (* x (* y z))) (* a 4.0)))
   (- (* b c) (+ (* 27.0 (* j k)) (* 4.0 (* x i))))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((t <= -5.8e+128) || !(t <= 3e+87)) {
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	} else {
		tmp = (b * c) - ((27.0 * (j * k)) + (4.0 * (x * i)));
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((t <= (-5.8d+128)) .or. (.not. (t <= 3d+87))) then
        tmp = t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0))
    else
        tmp = (b * c) - ((27.0d0 * (j * k)) + (4.0d0 * (x * i)))
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((t <= -5.8e+128) || !(t <= 3e+87)) {
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	} else {
		tmp = (b * c) - ((27.0 * (j * k)) + (4.0 * (x * i)));
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (t <= -5.8e+128) or not (t <= 3e+87):
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0))
	else:
		tmp = (b * c) - ((27.0 * (j * k)) + (4.0 * (x * i)))
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((t <= -5.8e+128) || !(t <= 3e+87))
		tmp = Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0)));
	else
		tmp = Float64(Float64(b * c) - Float64(Float64(27.0 * Float64(j * k)) + Float64(4.0 * Float64(x * i))));
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((t <= -5.8e+128) || ~((t <= 3e+87)))
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	else
		tmp = (b * c) - ((27.0 * (j * k)) + (4.0 * (x * i)));
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[t, -5.8e+128], N[Not[LessEqual[t, 3e+87]], $MachinePrecision]], N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * c), $MachinePrecision] - N[(N[(27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision] + N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.8 \cdot 10^{+128} \lor \neg \left(t \leq 3 \cdot 10^{+87}\right):\\
\;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\

\mathbf{else}:\\
\;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(x \cdot i\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -5.8000000000000001e128 or 2.9999999999999999e87 < t

    1. Initial program 83.1%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified88.2%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. pow188.2%

        \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. associate-*r*88.3%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative88.3%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. *-commutative88.3%

        \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    5. Applied egg-rr88.3%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    6. Step-by-step derivation
      1. unpow188.3%

        \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. *-commutative88.3%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative88.3%

        \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. associate-*r*88.3%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    7. Simplified88.3%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    8. Taylor expanded in k around inf 73.1%

      \[\leadsto \color{blue}{k \cdot \left(\left(\frac{b \cdot c}{k} + \frac{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)}{k}\right) - \left(4 \cdot \frac{i \cdot x}{k} + 27 \cdot j\right)\right)} \]
    9. Taylor expanded in t around -inf 76.3%

      \[\leadsto \color{blue}{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)} \]

    if -5.8000000000000001e128 < t < 2.9999999999999999e87

    1. Initial program 82.5%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified83.7%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in t around 0 78.6%

      \[\leadsto \color{blue}{b \cdot c - \left(4 \cdot \left(i \cdot x\right) + 27 \cdot \left(j \cdot k\right)\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification77.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -5.8 \cdot 10^{+128} \lor \neg \left(t \leq 3 \cdot 10^{+87}\right):\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c - \left(27 \cdot \left(j \cdot k\right) + 4 \cdot \left(x \cdot i\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 20: 49.0% accurate, 1.5× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;j \leq -1.9 \cdot 10^{-13}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;j \leq 5.5 \cdot 10^{-125}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;j \leq 1.1 \cdot 10^{+113}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= j -1.9e-13)
   (+ (* b c) (* j (* k -27.0)))
   (if (<= j 5.5e-125)
     (+ (* b c) (* -4.0 (* t a)))
     (if (<= j 1.1e+113) (* x (* i -4.0)) (* (* j k) -27.0)))))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (j <= -1.9e-13) {
		tmp = (b * c) + (j * (k * -27.0));
	} else if (j <= 5.5e-125) {
		tmp = (b * c) + (-4.0 * (t * a));
	} else if (j <= 1.1e+113) {
		tmp = x * (i * -4.0);
	} else {
		tmp = (j * k) * -27.0;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (j <= (-1.9d-13)) then
        tmp = (b * c) + (j * (k * (-27.0d0)))
    else if (j <= 5.5d-125) then
        tmp = (b * c) + ((-4.0d0) * (t * a))
    else if (j <= 1.1d+113) then
        tmp = x * (i * (-4.0d0))
    else
        tmp = (j * k) * (-27.0d0)
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (j <= -1.9e-13) {
		tmp = (b * c) + (j * (k * -27.0));
	} else if (j <= 5.5e-125) {
		tmp = (b * c) + (-4.0 * (t * a));
	} else if (j <= 1.1e+113) {
		tmp = x * (i * -4.0);
	} else {
		tmp = (j * k) * -27.0;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if j <= -1.9e-13:
		tmp = (b * c) + (j * (k * -27.0))
	elif j <= 5.5e-125:
		tmp = (b * c) + (-4.0 * (t * a))
	elif j <= 1.1e+113:
		tmp = x * (i * -4.0)
	else:
		tmp = (j * k) * -27.0
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (j <= -1.9e-13)
		tmp = Float64(Float64(b * c) + Float64(j * Float64(k * -27.0)));
	elseif (j <= 5.5e-125)
		tmp = Float64(Float64(b * c) + Float64(-4.0 * Float64(t * a)));
	elseif (j <= 1.1e+113)
		tmp = Float64(x * Float64(i * -4.0));
	else
		tmp = Float64(Float64(j * k) * -27.0);
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (j <= -1.9e-13)
		tmp = (b * c) + (j * (k * -27.0));
	elseif (j <= 5.5e-125)
		tmp = (b * c) + (-4.0 * (t * a));
	elseif (j <= 1.1e+113)
		tmp = x * (i * -4.0);
	else
		tmp = (j * k) * -27.0;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[j, -1.9e-13], N[(N[(b * c), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 5.5e-125], N[(N[(b * c), $MachinePrecision] + N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 1.1e+113], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision]]]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;j \leq -1.9 \cdot 10^{-13}:\\
\;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\

\mathbf{elif}\;j \leq 5.5 \cdot 10^{-125}:\\
\;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\

\mathbf{elif}\;j \leq 1.1 \cdot 10^{+113}:\\
\;\;\;\;x \cdot \left(i \cdot -4\right)\\

\mathbf{else}:\\
\;\;\;\;\left(j \cdot k\right) \cdot -27\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if j < -1.9e-13

    1. Initial program 72.0%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified75.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in b around inf 61.0%

      \[\leadsto \color{blue}{b \cdot c} + j \cdot \left(k \cdot -27\right) \]

    if -1.9e-13 < j < 5.4999999999999997e-125

    1. Initial program 83.3%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified87.0%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 56.6%

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 27 \cdot \left(j \cdot k\right)} \]
    5. Taylor expanded in j around 0 54.4%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right) + b \cdot c} \]

    if 5.4999999999999997e-125 < j < 1.10000000000000005e113

    1. Initial program 84.9%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified89.6%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in x around inf 46.7%

      \[\leadsto \color{blue}{x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)} \]
    5. Taylor expanded in t around 0 27.5%

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
    6. Step-by-step derivation
      1. metadata-eval27.5%

        \[\leadsto \color{blue}{\left(-4\right)} \cdot \left(i \cdot x\right) \]
      2. distribute-lft-neg-in27.5%

        \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
      3. associate-*r*27.5%

        \[\leadsto -\color{blue}{\left(4 \cdot i\right) \cdot x} \]
      4. *-commutative27.5%

        \[\leadsto -\color{blue}{x \cdot \left(4 \cdot i\right)} \]
      5. distribute-rgt-neg-in27.5%

        \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]
      6. distribute-lft-neg-in27.5%

        \[\leadsto x \cdot \color{blue}{\left(\left(-4\right) \cdot i\right)} \]
      7. metadata-eval27.5%

        \[\leadsto x \cdot \left(\color{blue}{-4} \cdot i\right) \]
    7. Simplified27.5%

      \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i\right)} \]

    if 1.10000000000000005e113 < j

    1. Initial program 93.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified93.2%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around inf 52.2%

      \[\leadsto \color{blue}{-27 \cdot \left(j \cdot k\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification50.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;j \leq -1.9 \cdot 10^{-13}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;j \leq 5.5 \cdot 10^{-125}:\\ \;\;\;\;b \cdot c + -4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;j \leq 1.1 \cdot 10^{+113}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \end{array} \]
  5. Add Preprocessing

Alternative 21: 37.4% accurate, 1.6× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -4.9 \cdot 10^{+176} \lor \neg \left(b \cdot c \leq 2.9 \cdot 10^{+122}\right):\\ \;\;\;\;b \cdot c\\ \mathbf{else}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \end{array} \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= (* b c) -4.9e+176) (not (<= (* b c) 2.9e+122)))
   (* b c)
   (* (* j k) -27.0)))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (((b * c) <= -4.9e+176) || !((b * c) <= 2.9e+122)) {
		tmp = b * c;
	} else {
		tmp = (j * k) * -27.0;
	}
	return tmp;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (((b * c) <= (-4.9d+176)) .or. (.not. ((b * c) <= 2.9d+122))) then
        tmp = b * c
    else
        tmp = (j * k) * (-27.0d0)
    end if
    code = tmp
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (((b * c) <= -4.9e+176) || !((b * c) <= 2.9e+122)) {
		tmp = b * c;
	} else {
		tmp = (j * k) * -27.0;
	}
	return tmp;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if ((b * c) <= -4.9e+176) or not ((b * c) <= 2.9e+122):
		tmp = b * c
	else:
		tmp = (j * k) * -27.0
	return tmp
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((Float64(b * c) <= -4.9e+176) || !(Float64(b * c) <= 2.9e+122))
		tmp = Float64(b * c);
	else
		tmp = Float64(Float64(j * k) * -27.0);
	end
	return tmp
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (((b * c) <= -4.9e+176) || ~(((b * c) <= 2.9e+122)))
		tmp = b * c;
	else
		tmp = (j * k) * -27.0;
	end
	tmp_2 = tmp;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -4.9e+176], N[Not[LessEqual[N[(b * c), $MachinePrecision], 2.9e+122]], $MachinePrecision]], N[(b * c), $MachinePrecision], N[(N[(j * k), $MachinePrecision] * -27.0), $MachinePrecision]]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -4.9 \cdot 10^{+176} \lor \neg \left(b \cdot c \leq 2.9 \cdot 10^{+122}\right):\\
\;\;\;\;b \cdot c\\

\mathbf{else}:\\
\;\;\;\;\left(j \cdot k\right) \cdot -27\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 b c) < -4.9e176 or 2.9000000000000001e122 < (*.f64 b c)

    1. Initial program 82.4%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified81.2%

      \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
    3. Add Preprocessing
    4. Step-by-step derivation
      1. pow181.2%

        \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. associate-*r*81.2%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative81.2%

        \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. *-commutative81.2%

        \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    5. Applied egg-rr81.2%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    6. Step-by-step derivation
      1. unpow181.2%

        \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      2. *-commutative81.2%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. *-commutative81.2%

        \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      4. associate-*r*81.2%

        \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    7. Simplified81.2%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    8. Taylor expanded in k around inf 60.2%

      \[\leadsto \color{blue}{k \cdot \left(\left(\frac{b \cdot c}{k} + \frac{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)}{k}\right) - \left(4 \cdot \frac{i \cdot x}{k} + 27 \cdot j\right)\right)} \]
    9. Taylor expanded in b around inf 65.9%

      \[\leadsto \color{blue}{b \cdot c} \]

    if -4.9e176 < (*.f64 b c) < 2.9000000000000001e122

    1. Initial program 82.8%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Simplified88.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(t, \mathsf{fma}\left(x, 18 \cdot \left(y \cdot z\right), a \cdot -4\right), \mathsf{fma}\left(b, c, x \cdot \left(i \cdot -4\right)\right)\right) + j \cdot \left(k \cdot -27\right)} \]
    3. Add Preprocessing
    4. Taylor expanded in j around inf 32.2%

      \[\leadsto \color{blue}{-27 \cdot \left(j \cdot k\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification42.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -4.9 \cdot 10^{+176} \lor \neg \left(b \cdot c \leq 2.9 \cdot 10^{+122}\right):\\ \;\;\;\;b \cdot c\\ \mathbf{else}:\\ \;\;\;\;\left(j \cdot k\right) \cdot -27\\ \end{array} \]
  5. Add Preprocessing

Alternative 22: 24.2% accurate, 10.3× speedup?

\[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ b \cdot c \end{array} \]
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c i j k) :precision binary64 (* b c))
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	return b * c;
}
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    code = b * c
end function
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	return b * c;
}
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
[x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	return b * c
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	return Float64(b * c)
end
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
function tmp = code(x, y, z, t, a, b, c, i, j, k)
	tmp = b * c;
end
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(b * c), $MachinePrecision]
\begin{array}{l}
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
[x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
\\
b \cdot c
\end{array}
Derivation
  1. Initial program 82.7%

    \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
  2. Simplified85.1%

    \[\leadsto \color{blue}{\left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)} \]
  3. Add Preprocessing
  4. Step-by-step derivation
    1. pow185.1%

      \[\leadsto \left(t \cdot \left(\color{blue}{{\left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    2. associate-*r*84.6%

      \[\leadsto \left(t \cdot \left({\color{blue}{\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    3. *-commutative84.6%

      \[\leadsto \left(t \cdot \left({\color{blue}{\left(z \cdot \left(\left(x \cdot 18\right) \cdot y\right)\right)}}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    4. *-commutative84.6%

      \[\leadsto \left(t \cdot \left({\left(z \cdot \color{blue}{\left(y \cdot \left(x \cdot 18\right)\right)}\right)}^{1} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
  5. Applied egg-rr84.6%

    \[\leadsto \left(t \cdot \left(\color{blue}{{\left(z \cdot \left(y \cdot \left(x \cdot 18\right)\right)\right)}^{1}} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
  6. Step-by-step derivation
    1. unpow184.6%

      \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(y \cdot \left(x \cdot 18\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    2. *-commutative84.6%

      \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(\left(x \cdot 18\right) \cdot y\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    3. *-commutative84.6%

      \[\leadsto \left(t \cdot \left(z \cdot \left(\color{blue}{\left(18 \cdot x\right)} \cdot y\right) - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    4. associate-*r*84.6%

      \[\leadsto \left(t \cdot \left(z \cdot \color{blue}{\left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
  7. Simplified84.6%

    \[\leadsto \left(t \cdot \left(\color{blue}{z \cdot \left(18 \cdot \left(x \cdot y\right)\right)} - a \cdot 4\right) + b \cdot c\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
  8. Taylor expanded in k around inf 72.3%

    \[\leadsto \color{blue}{k \cdot \left(\left(\frac{b \cdot c}{k} + \frac{t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)}{k}\right) - \left(4 \cdot \frac{i \cdot x}{k} + 27 \cdot j\right)\right)} \]
  9. Taylor expanded in b around inf 24.2%

    \[\leadsto \color{blue}{b \cdot c} \]
  10. Final simplification24.2%

    \[\leadsto b \cdot c \]
  11. Add Preprocessing

Developer target: 89.4% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(a \cdot t + i \cdot x\right) \cdot 4\\ t_2 := \left(\left(18 \cdot t\right) \cdot \left(\left(x \cdot y\right) \cdot z\right) - t\_1\right) - \left(\left(k \cdot j\right) \cdot 27 - c \cdot b\right)\\ \mathbf{if}\;t < -1.6210815397541398 \cdot 10^{-69}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t < 165.68027943805222:\\ \;\;\;\;\left(\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right) - t\_1\right) + \left(c \cdot b - 27 \cdot \left(k \cdot j\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* (+ (* a t) (* i x)) 4.0))
        (t_2
         (-
          (- (* (* 18.0 t) (* (* x y) z)) t_1)
          (- (* (* k j) 27.0) (* c b)))))
   (if (< t -1.6210815397541398e-69)
     t_2
     (if (< t 165.68027943805222)
       (+ (- (* (* 18.0 y) (* x (* z t))) t_1) (- (* c b) (* 27.0 (* k j))))
       t_2))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double t_1 = ((a * t) + (i * x)) * 4.0;
	double t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b));
	double tmp;
	if (t < -1.6210815397541398e-69) {
		tmp = t_2;
	} else if (t < 165.68027943805222) {
		tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j)));
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = ((a * t) + (i * x)) * 4.0d0
    t_2 = (((18.0d0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0d0) - (c * b))
    if (t < (-1.6210815397541398d-69)) then
        tmp = t_2
    else if (t < 165.68027943805222d0) then
        tmp = (((18.0d0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0d0 * (k * j)))
    else
        tmp = 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 i, double j, double k) {
	double t_1 = ((a * t) + (i * x)) * 4.0;
	double t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b));
	double tmp;
	if (t < -1.6210815397541398e-69) {
		tmp = t_2;
	} else if (t < 165.68027943805222) {
		tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j)));
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = ((a * t) + (i * x)) * 4.0
	t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b))
	tmp = 0
	if t < -1.6210815397541398e-69:
		tmp = t_2
	elif t < 165.68027943805222:
		tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j)))
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(Float64(a * t) + Float64(i * x)) * 4.0)
	t_2 = Float64(Float64(Float64(Float64(18.0 * t) * Float64(Float64(x * y) * z)) - t_1) - Float64(Float64(Float64(k * j) * 27.0) - Float64(c * b)))
	tmp = 0.0
	if (t < -1.6210815397541398e-69)
		tmp = t_2;
	elseif (t < 165.68027943805222)
		tmp = Float64(Float64(Float64(Float64(18.0 * y) * Float64(x * Float64(z * t))) - t_1) + Float64(Float64(c * b) - Float64(27.0 * Float64(k * j))));
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = ((a * t) + (i * x)) * 4.0;
	t_2 = (((18.0 * t) * ((x * y) * z)) - t_1) - (((k * j) * 27.0) - (c * b));
	tmp = 0.0;
	if (t < -1.6210815397541398e-69)
		tmp = t_2;
	elseif (t < 165.68027943805222)
		tmp = (((18.0 * y) * (x * (z * t))) - t_1) + ((c * b) - (27.0 * (k * j)));
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(a * t), $MachinePrecision] + N[(i * x), $MachinePrecision]), $MachinePrecision] * 4.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(N[(18.0 * t), $MachinePrecision] * N[(N[(x * y), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] - N[(N[(N[(k * j), $MachinePrecision] * 27.0), $MachinePrecision] - N[(c * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -1.6210815397541398e-69], t$95$2, If[Less[t, 165.68027943805222], N[(N[(N[(N[(18.0 * y), $MachinePrecision] * N[(x * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] + N[(N[(c * b), $MachinePrecision] - N[(27.0 * N[(k * j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left(a \cdot t + i \cdot x\right) \cdot 4\\
t_2 := \left(\left(18 \cdot t\right) \cdot \left(\left(x \cdot y\right) \cdot z\right) - t\_1\right) - \left(\left(k \cdot j\right) \cdot 27 - c \cdot b\right)\\
\mathbf{if}\;t < -1.6210815397541398 \cdot 10^{-69}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t < 165.68027943805222:\\
\;\;\;\;\left(\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right) - t\_1\right) + \left(c \cdot b - 27 \cdot \left(k \cdot j\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_2\\


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2024080 
(FPCore (x y z t a b c i j k)
  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1, E"
  :precision binary64

  :alt
  (if (< t -1.6210815397541398e-69) (- (- (* (* 18.0 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4.0)) (- (* (* k j) 27.0) (* c b))) (if (< t 165.68027943805222) (+ (- (* (* 18.0 y) (* x (* z t))) (* (+ (* a t) (* i x)) 4.0)) (- (* c b) (* 27.0 (* k j)))) (- (- (* (* 18.0 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4.0)) (- (* (* k j) 27.0) (* c b)))))

  (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))