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

Percentage Accurate: 85.5% → 90.6%
Time: 25.1s
Alternatives: 15
Speedup: 1.0×

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 15 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.5% 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: 90.6% accurate, 0.5× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} t_1 := \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\\ \mathbf{if}\;t_1 \leq \infty:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 18.0) y) z) t) (* t (* a 4.0))) (* b c))
           (* (* x 4.0) i))
          (* (* j 27.0) k))))
   (if (<= t_1 INFINITY)
     t_1
     (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0)))))))
assert(y < z);
assert(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 * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	double tmp;
	if (t_1 <= ((double) INFINITY)) {
		tmp = t_1;
	} else {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	}
	return tmp;
}
assert y < z;
assert 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 * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	double tmp;
	if (t_1 <= Double.POSITIVE_INFINITY) {
		tmp = t_1;
	} else {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)
	tmp = 0
	if t_1 <= math.inf:
		tmp = t_1
	else:
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(t * Float64(a * 4.0))) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k))
	tmp = 0.0
	if (t_1 <= Inf)
		tmp = t_1;
	else
		tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))));
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k);
	tmp = 0.0;
	if (t_1 <= Inf)
		tmp = t_1;
	else
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $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]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
t_1 := \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\\
\mathbf{if}\;t_1 \leq \infty:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \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 93.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 \]

    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. Simplified21.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. Taylor expanded in x around inf 44.7%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*44.7%

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

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

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

      \[\leadsto \color{blue}{b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - 4 \cdot a\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification88.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(\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\\ \mathbf{else}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \end{array} \]

Alternative 2: 37.1% accurate, 0.9× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} t_1 := 18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{if}\;b \cdot c \leq -1.18 \cdot 10^{+162}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -820:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-66}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;b \cdot c \leq 8.2 \cdot 10^{-195}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq 9.8 \cdot 10^{-101}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;b \cdot c \leq 2.9 \cdot 10^{+131}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 (* t (* z (* x y))))))
   (if (<= (* b c) -1.18e+162)
     (* b c)
     (if (<= (* b c) -820.0)
       t_1
       (if (<= (* b c) -5e-66)
         (* k (* j -27.0))
         (if (<= (* b c) 8.2e-195)
           t_1
           (if (<= (* b c) 9.8e-101)
             (* -27.0 (* j k))
             (if (<= (* b c) 2.9e+131) t_1 (* b c)))))))))
assert(y < z);
assert(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 * (t * (z * (x * y)));
	double tmp;
	if ((b * c) <= -1.18e+162) {
		tmp = b * c;
	} else if ((b * c) <= -820.0) {
		tmp = t_1;
	} else if ((b * c) <= -5e-66) {
		tmp = k * (j * -27.0);
	} else if ((b * c) <= 8.2e-195) {
		tmp = t_1;
	} else if ((b * c) <= 9.8e-101) {
		tmp = -27.0 * (j * k);
	} else if ((b * c) <= 2.9e+131) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 = 18.0d0 * (t * (z * (x * y)))
    if ((b * c) <= (-1.18d+162)) then
        tmp = b * c
    else if ((b * c) <= (-820.0d0)) then
        tmp = t_1
    else if ((b * c) <= (-5d-66)) then
        tmp = k * (j * (-27.0d0))
    else if ((b * c) <= 8.2d-195) then
        tmp = t_1
    else if ((b * c) <= 9.8d-101) then
        tmp = (-27.0d0) * (j * k)
    else if ((b * c) <= 2.9d+131) then
        tmp = t_1
    else
        tmp = b * c
    end if
    code = tmp
end function
assert y < z;
assert 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 * (t * (z * (x * y)));
	double tmp;
	if ((b * c) <= -1.18e+162) {
		tmp = b * c;
	} else if ((b * c) <= -820.0) {
		tmp = t_1;
	} else if ((b * c) <= -5e-66) {
		tmp = k * (j * -27.0);
	} else if ((b * c) <= 8.2e-195) {
		tmp = t_1;
	} else if ((b * c) <= 9.8e-101) {
		tmp = -27.0 * (j * k);
	} else if ((b * c) <= 2.9e+131) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = 18.0 * (t * (z * (x * y)))
	tmp = 0
	if (b * c) <= -1.18e+162:
		tmp = b * c
	elif (b * c) <= -820.0:
		tmp = t_1
	elif (b * c) <= -5e-66:
		tmp = k * (j * -27.0)
	elif (b * c) <= 8.2e-195:
		tmp = t_1
	elif (b * c) <= 9.8e-101:
		tmp = -27.0 * (j * k)
	elif (b * c) <= 2.9e+131:
		tmp = t_1
	else:
		tmp = b * c
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(18.0 * Float64(t * Float64(z * Float64(x * y))))
	tmp = 0.0
	if (Float64(b * c) <= -1.18e+162)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -820.0)
		tmp = t_1;
	elseif (Float64(b * c) <= -5e-66)
		tmp = Float64(k * Float64(j * -27.0));
	elseif (Float64(b * c) <= 8.2e-195)
		tmp = t_1;
	elseif (Float64(b * c) <= 9.8e-101)
		tmp = Float64(-27.0 * Float64(j * k));
	elseif (Float64(b * c) <= 2.9e+131)
		tmp = t_1;
	else
		tmp = Float64(b * c);
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = 18.0 * (t * (z * (x * y)));
	tmp = 0.0;
	if ((b * c) <= -1.18e+162)
		tmp = b * c;
	elseif ((b * c) <= -820.0)
		tmp = t_1;
	elseif ((b * c) <= -5e-66)
		tmp = k * (j * -27.0);
	elseif ((b * c) <= 8.2e-195)
		tmp = t_1;
	elseif ((b * c) <= 9.8e-101)
		tmp = -27.0 * (j * k);
	elseif ((b * c) <= 2.9e+131)
		tmp = t_1;
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[(t * N[(z * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -1.18e+162], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -820.0], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -5e-66], N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 8.2e-195], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], 9.8e-101], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2.9e+131], t$95$1, N[(b * c), $MachinePrecision]]]]]]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\
\mathbf{if}\;b \cdot c \leq -1.18 \cdot 10^{+162}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \cdot c \leq -820:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;b \cdot c \leq 8.2 \cdot 10^{-195}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;b \cdot c \leq 2.9 \cdot 10^{+131}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (*.f64 b c) < -1.1800000000000001e162 or 2.9000000000000001e131 < (*.f64 b c)

    1. Initial program 79.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.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. Taylor expanded in b around inf 68.6%

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

    if -1.1800000000000001e162 < (*.f64 b c) < -820 or -4.99999999999999962e-66 < (*.f64 b c) < 8.20000000000000024e-195 or 9.8000000000000001e-101 < (*.f64 b c) < 2.9000000000000001e131

    1. Initial program 79.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.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. Taylor expanded in y around inf 43.2%

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

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

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

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

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

        \[\leadsto 18 \cdot \left(x \cdot \left(\color{blue}{\left(z \cdot y\right)} \cdot t\right)\right) \]
      6. associate-*l*43.3%

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

      \[\leadsto \color{blue}{18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)} \]
    6. Taylor expanded in x around 0 43.2%

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

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

        \[\leadsto 18 \cdot \left(t \cdot \color{blue}{\left(\left(z \cdot y\right) \cdot x\right)}\right) \]
      3. associate-*l*42.5%

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

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

    if -820 < (*.f64 b c) < -4.99999999999999962e-66

    1. Initial program 75.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. Simplified69.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. Taylor expanded in j around inf 57.5%

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

        \[\leadsto \color{blue}{\left(-27 \cdot j\right) \cdot k} \]
    5. Simplified57.4%

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

    if 8.20000000000000024e-195 < (*.f64 b c) < 9.8000000000000001e-101

    1. Initial program 87.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. Simplified93.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. Taylor expanded in j around inf 51.2%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.18 \cdot 10^{+162}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -820:\\ \;\;\;\;18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq -5 \cdot 10^{-66}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;b \cdot c \leq 8.2 \cdot 10^{-195}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 9.8 \cdot 10^{-101}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;b \cdot c \leq 2.9 \cdot 10^{+131}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]

Alternative 3: 37.0% accurate, 0.9× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} t_1 := 18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{if}\;b \cdot c \leq -3.1 \cdot 10^{+169}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -26:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq -2.9 \cdot 10^{-70}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;b \cdot c \leq 1.15 \cdot 10^{-194}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq 1.22 \cdot 10^{-98}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;b \cdot c \leq 1.08 \cdot 10^{+129}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(y \cdot \left(z \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 (* t (* z (* x y))))))
   (if (<= (* b c) -3.1e+169)
     (* b c)
     (if (<= (* b c) -26.0)
       t_1
       (if (<= (* b c) -2.9e-70)
         (* k (* j -27.0))
         (if (<= (* b c) 1.15e-194)
           t_1
           (if (<= (* b c) 1.22e-98)
             (* -27.0 (* j k))
             (if (<= (* b c) 1.08e+129)
               (* 18.0 (* x (* y (* z t))))
               (* b c)))))))))
assert(y < z);
assert(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 * (t * (z * (x * y)));
	double tmp;
	if ((b * c) <= -3.1e+169) {
		tmp = b * c;
	} else if ((b * c) <= -26.0) {
		tmp = t_1;
	} else if ((b * c) <= -2.9e-70) {
		tmp = k * (j * -27.0);
	} else if ((b * c) <= 1.15e-194) {
		tmp = t_1;
	} else if ((b * c) <= 1.22e-98) {
		tmp = -27.0 * (j * k);
	} else if ((b * c) <= 1.08e+129) {
		tmp = 18.0 * (x * (y * (z * t)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 = 18.0d0 * (t * (z * (x * y)))
    if ((b * c) <= (-3.1d+169)) then
        tmp = b * c
    else if ((b * c) <= (-26.0d0)) then
        tmp = t_1
    else if ((b * c) <= (-2.9d-70)) then
        tmp = k * (j * (-27.0d0))
    else if ((b * c) <= 1.15d-194) then
        tmp = t_1
    else if ((b * c) <= 1.22d-98) then
        tmp = (-27.0d0) * (j * k)
    else if ((b * c) <= 1.08d+129) then
        tmp = 18.0d0 * (x * (y * (z * t)))
    else
        tmp = b * c
    end if
    code = tmp
end function
assert y < z;
assert 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 * (t * (z * (x * y)));
	double tmp;
	if ((b * c) <= -3.1e+169) {
		tmp = b * c;
	} else if ((b * c) <= -26.0) {
		tmp = t_1;
	} else if ((b * c) <= -2.9e-70) {
		tmp = k * (j * -27.0);
	} else if ((b * c) <= 1.15e-194) {
		tmp = t_1;
	} else if ((b * c) <= 1.22e-98) {
		tmp = -27.0 * (j * k);
	} else if ((b * c) <= 1.08e+129) {
		tmp = 18.0 * (x * (y * (z * t)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = 18.0 * (t * (z * (x * y)))
	tmp = 0
	if (b * c) <= -3.1e+169:
		tmp = b * c
	elif (b * c) <= -26.0:
		tmp = t_1
	elif (b * c) <= -2.9e-70:
		tmp = k * (j * -27.0)
	elif (b * c) <= 1.15e-194:
		tmp = t_1
	elif (b * c) <= 1.22e-98:
		tmp = -27.0 * (j * k)
	elif (b * c) <= 1.08e+129:
		tmp = 18.0 * (x * (y * (z * t)))
	else:
		tmp = b * c
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(18.0 * Float64(t * Float64(z * Float64(x * y))))
	tmp = 0.0
	if (Float64(b * c) <= -3.1e+169)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -26.0)
		tmp = t_1;
	elseif (Float64(b * c) <= -2.9e-70)
		tmp = Float64(k * Float64(j * -27.0));
	elseif (Float64(b * c) <= 1.15e-194)
		tmp = t_1;
	elseif (Float64(b * c) <= 1.22e-98)
		tmp = Float64(-27.0 * Float64(j * k));
	elseif (Float64(b * c) <= 1.08e+129)
		tmp = Float64(18.0 * Float64(x * Float64(y * Float64(z * t))));
	else
		tmp = Float64(b * c);
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = 18.0 * (t * (z * (x * y)));
	tmp = 0.0;
	if ((b * c) <= -3.1e+169)
		tmp = b * c;
	elseif ((b * c) <= -26.0)
		tmp = t_1;
	elseif ((b * c) <= -2.9e-70)
		tmp = k * (j * -27.0);
	elseif ((b * c) <= 1.15e-194)
		tmp = t_1;
	elseif ((b * c) <= 1.22e-98)
		tmp = -27.0 * (j * k);
	elseif ((b * c) <= 1.08e+129)
		tmp = 18.0 * (x * (y * (z * t)));
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[(t * N[(z * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -3.1e+169], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -26.0], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -2.9e-70], N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.15e-194], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], 1.22e-98], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.08e+129], N[(18.0 * N[(x * N[(y * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]]]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\
\mathbf{if}\;b \cdot c \leq -3.1 \cdot 10^{+169}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \cdot c \leq -26:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;b \cdot c \leq 1.15 \cdot 10^{-194}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;b \cdot c \leq 1.08 \cdot 10^{+129}:\\
\;\;\;\;18 \cdot \left(x \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 5 regimes
  2. if (*.f64 b c) < -3.1e169 or 1.08e129 < (*.f64 b c)

    1. Initial program 79.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.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. Taylor expanded in b around inf 68.6%

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

    if -3.1e169 < (*.f64 b c) < -26 or -2.89999999999999971e-70 < (*.f64 b c) < 1.15000000000000001e-194

    1. Initial program 78.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. Simplified85.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. Taylor expanded in y around inf 47.0%

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

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

        \[\leadsto 18 \cdot \color{blue}{\left(x \cdot \left(\left(y \cdot z\right) \cdot t\right)\right)} \]
      3. *-commutative47.0%

        \[\leadsto 18 \cdot \left(x \cdot \color{blue}{\left(t \cdot \left(y \cdot z\right)\right)}\right) \]
      4. *-commutative47.0%

        \[\leadsto 18 \cdot \left(x \cdot \color{blue}{\left(\left(y \cdot z\right) \cdot t\right)}\right) \]
      5. *-commutative47.0%

        \[\leadsto 18 \cdot \left(x \cdot \left(\color{blue}{\left(z \cdot y\right)} \cdot t\right)\right) \]
      6. associate-*l*46.3%

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

      \[\leadsto \color{blue}{18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)} \]
    6. Taylor expanded in x around 0 47.0%

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

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

        \[\leadsto 18 \cdot \left(t \cdot \color{blue}{\left(\left(z \cdot y\right) \cdot x\right)}\right) \]
      3. associate-*l*47.0%

        \[\leadsto 18 \cdot \left(t \cdot \color{blue}{\left(z \cdot \left(y \cdot x\right)\right)}\right) \]
    8. Simplified47.0%

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

    if -26 < (*.f64 b c) < -2.89999999999999971e-70

    1. Initial program 75.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. Simplified69.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. Taylor expanded in j around inf 57.5%

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

        \[\leadsto \color{blue}{\left(-27 \cdot j\right) \cdot k} \]
    5. Simplified57.4%

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

    if 1.15000000000000001e-194 < (*.f64 b c) < 1.2200000000000001e-98

    1. Initial program 87.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. Simplified93.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. Taylor expanded in j around inf 51.2%

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

    if 1.2200000000000001e-98 < (*.f64 b c) < 1.08e129

    1. Initial program 82.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. Simplified84.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. Taylor expanded in y around inf 34.2%

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

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

        \[\leadsto 18 \cdot \color{blue}{\left(x \cdot \left(\left(y \cdot z\right) \cdot t\right)\right)} \]
      3. *-commutative34.0%

        \[\leadsto 18 \cdot \left(x \cdot \color{blue}{\left(t \cdot \left(y \cdot z\right)\right)}\right) \]
      4. *-commutative34.0%

        \[\leadsto 18 \cdot \left(x \cdot \color{blue}{\left(\left(y \cdot z\right) \cdot t\right)}\right) \]
      5. associate-*l*38.5%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -3.1 \cdot 10^{+169}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -26:\\ \;\;\;\;18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq -2.9 \cdot 10^{-70}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;b \cdot c \leq 1.15 \cdot 10^{-194}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 1.22 \cdot 10^{-98}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;b \cdot c \leq 1.08 \cdot 10^{+129}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(y \cdot \left(z \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]

Alternative 4: 37.0% accurate, 0.9× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} t_1 := 18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ t_2 := -27 \cdot \left(j \cdot k\right)\\ \mathbf{if}\;b \cdot c \leq -1.78 \cdot 10^{+162}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -8.2 \cdot 10^{-12}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq -3.2 \cdot 10^{-67}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \cdot c \leq 3.9 \cdot 10^{-199}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 3.8 \cdot 10^{-97}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \cdot c \leq 1.02 \cdot 10^{+131}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 (* z (* y t))))) (t_2 (* -27.0 (* j k))))
   (if (<= (* b c) -1.78e+162)
     (* b c)
     (if (<= (* b c) -8.2e-12)
       t_1
       (if (<= (* b c) -3.2e-67)
         t_2
         (if (<= (* b c) 3.9e-199)
           (* 18.0 (* t (* z (* x y))))
           (if (<= (* b c) 3.8e-97)
             t_2
             (if (<= (* b c) 1.02e+131) t_1 (* b c)))))))))
assert(y < z);
assert(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 * (z * (y * t)));
	double t_2 = -27.0 * (j * k);
	double tmp;
	if ((b * c) <= -1.78e+162) {
		tmp = b * c;
	} else if ((b * c) <= -8.2e-12) {
		tmp = t_1;
	} else if ((b * c) <= -3.2e-67) {
		tmp = t_2;
	} else if ((b * c) <= 3.9e-199) {
		tmp = 18.0 * (t * (z * (x * y)));
	} else if ((b * c) <= 3.8e-97) {
		tmp = t_2;
	} else if ((b * c) <= 1.02e+131) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 = 18.0d0 * (x * (z * (y * t)))
    t_2 = (-27.0d0) * (j * k)
    if ((b * c) <= (-1.78d+162)) then
        tmp = b * c
    else if ((b * c) <= (-8.2d-12)) then
        tmp = t_1
    else if ((b * c) <= (-3.2d-67)) then
        tmp = t_2
    else if ((b * c) <= 3.9d-199) then
        tmp = 18.0d0 * (t * (z * (x * y)))
    else if ((b * c) <= 3.8d-97) then
        tmp = t_2
    else if ((b * c) <= 1.02d+131) then
        tmp = t_1
    else
        tmp = b * c
    end if
    code = tmp
end function
assert y < z;
assert 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 * (z * (y * t)));
	double t_2 = -27.0 * (j * k);
	double tmp;
	if ((b * c) <= -1.78e+162) {
		tmp = b * c;
	} else if ((b * c) <= -8.2e-12) {
		tmp = t_1;
	} else if ((b * c) <= -3.2e-67) {
		tmp = t_2;
	} else if ((b * c) <= 3.9e-199) {
		tmp = 18.0 * (t * (z * (x * y)));
	} else if ((b * c) <= 3.8e-97) {
		tmp = t_2;
	} else if ((b * c) <= 1.02e+131) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = 18.0 * (x * (z * (y * t)))
	t_2 = -27.0 * (j * k)
	tmp = 0
	if (b * c) <= -1.78e+162:
		tmp = b * c
	elif (b * c) <= -8.2e-12:
		tmp = t_1
	elif (b * c) <= -3.2e-67:
		tmp = t_2
	elif (b * c) <= 3.9e-199:
		tmp = 18.0 * (t * (z * (x * y)))
	elif (b * c) <= 3.8e-97:
		tmp = t_2
	elif (b * c) <= 1.02e+131:
		tmp = t_1
	else:
		tmp = b * c
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(18.0 * Float64(x * Float64(z * Float64(y * t))))
	t_2 = Float64(-27.0 * Float64(j * k))
	tmp = 0.0
	if (Float64(b * c) <= -1.78e+162)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -8.2e-12)
		tmp = t_1;
	elseif (Float64(b * c) <= -3.2e-67)
		tmp = t_2;
	elseif (Float64(b * c) <= 3.9e-199)
		tmp = Float64(18.0 * Float64(t * Float64(z * Float64(x * y))));
	elseif (Float64(b * c) <= 3.8e-97)
		tmp = t_2;
	elseif (Float64(b * c) <= 1.02e+131)
		tmp = t_1;
	else
		tmp = Float64(b * c);
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = 18.0 * (x * (z * (y * t)));
	t_2 = -27.0 * (j * k);
	tmp = 0.0;
	if ((b * c) <= -1.78e+162)
		tmp = b * c;
	elseif ((b * c) <= -8.2e-12)
		tmp = t_1;
	elseif ((b * c) <= -3.2e-67)
		tmp = t_2;
	elseif ((b * c) <= 3.9e-199)
		tmp = 18.0 * (t * (z * (x * y)));
	elseif ((b * c) <= 3.8e-97)
		tmp = t_2;
	elseif ((b * c) <= 1.02e+131)
		tmp = t_1;
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -1.78e+162], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -8.2e-12], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -3.2e-67], t$95$2, If[LessEqual[N[(b * c), $MachinePrecision], 3.9e-199], N[(18.0 * N[(t * N[(z * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 3.8e-97], t$95$2, If[LessEqual[N[(b * c), $MachinePrecision], 1.02e+131], t$95$1, N[(b * c), $MachinePrecision]]]]]]]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
t_1 := 18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\
t_2 := -27 \cdot \left(j \cdot k\right)\\
\mathbf{if}\;b \cdot c \leq -1.78 \cdot 10^{+162}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \cdot c \leq -8.2 \cdot 10^{-12}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;b \cdot c \leq -3.2 \cdot 10^{-67}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;b \cdot c \leq 3.9 \cdot 10^{-199}:\\
\;\;\;\;18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\

\mathbf{elif}\;b \cdot c \leq 3.8 \cdot 10^{-97}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;b \cdot c \leq 1.02 \cdot 10^{+131}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (*.f64 b c) < -1.77999999999999998e162 or 1.0199999999999999e131 < (*.f64 b c)

    1. Initial program 79.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.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. Taylor expanded in b around inf 68.6%

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

    if -1.77999999999999998e162 < (*.f64 b c) < -8.19999999999999979e-12 or 3.8000000000000001e-97 < (*.f64 b c) < 1.0199999999999999e131

    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. Simplified82.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. Taylor expanded in y around inf 39.1%

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

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

        \[\leadsto 18 \cdot \color{blue}{\left(x \cdot \left(\left(y \cdot z\right) \cdot t\right)\right)} \]
      3. *-commutative39.0%

        \[\leadsto 18 \cdot \left(x \cdot \color{blue}{\left(t \cdot \left(y \cdot z\right)\right)}\right) \]
      4. *-commutative39.0%

        \[\leadsto 18 \cdot \left(x \cdot \color{blue}{\left(\left(y \cdot z\right) \cdot t\right)}\right) \]
      5. *-commutative39.0%

        \[\leadsto 18 \cdot \left(x \cdot \left(\color{blue}{\left(z \cdot y\right)} \cdot t\right)\right) \]
      6. associate-*l*40.6%

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

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

    if -8.19999999999999979e-12 < (*.f64 b c) < -3.20000000000000021e-67 or 3.9000000000000001e-199 < (*.f64 b c) < 3.8000000000000001e-97

    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. Simplified83.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. Taylor expanded in j around inf 54.6%

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

    if -3.20000000000000021e-67 < (*.f64 b c) < 3.9000000000000001e-199

    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. Simplified86.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. Taylor expanded in y around inf 45.7%

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

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

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

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

        \[\leadsto 18 \cdot \left(x \cdot \color{blue}{\left(\left(y \cdot z\right) \cdot t\right)}\right) \]
      5. *-commutative45.6%

        \[\leadsto 18 \cdot \left(x \cdot \left(\color{blue}{\left(z \cdot y\right)} \cdot t\right)\right) \]
      6. associate-*l*45.6%

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

      \[\leadsto \color{blue}{18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)} \]
    6. Taylor expanded in x around 0 45.7%

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

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

        \[\leadsto 18 \cdot \left(t \cdot \color{blue}{\left(\left(z \cdot y\right) \cdot x\right)}\right) \]
      3. associate-*l*46.6%

        \[\leadsto 18 \cdot \left(t \cdot \color{blue}{\left(z \cdot \left(y \cdot x\right)\right)}\right) \]
    8. Simplified46.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.78 \cdot 10^{+162}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -8.2 \cdot 10^{-12}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq -3.2 \cdot 10^{-67}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;b \cdot c \leq 3.9 \cdot 10^{-199}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(z \cdot \left(x \cdot y\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 3.8 \cdot 10^{-97}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;b \cdot c \leq 1.02 \cdot 10^{+131}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]

Alternative 5: 84.3% accurate, 0.9× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} \mathbf{if}\;x \leq -2.5 \cdot 10^{+219}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{elif}\;x \leq 4.5 \cdot 10^{+188}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot y\right) \cdot \left(18 \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}:\\ \;\;\;\;b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 -2.5e+219)
   (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))
   (if (<= x 4.5e+188)
     (-
      (+ (* b c) (* t (- (* (* x y) (* 18.0 z)) (* a 4.0))))
      (+ (* x (* 4.0 i)) (* j (* 27.0 k))))
     (+ (* b c) (* t (* (* x 18.0) (* y z)))))))
assert(y < z);
assert(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 <= -2.5e+219) {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	} else if (x <= 4.5e+188) {
		tmp = ((b * c) + (t * (((x * y) * (18.0 * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	} else {
		tmp = (b * c) + (t * ((x * 18.0) * (y * z)));
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 <= (-2.5d+219)) then
        tmp = (b * c) + (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0)))
    else if (x <= 4.5d+188) then
        tmp = ((b * c) + (t * (((x * y) * (18.0d0 * z)) - (a * 4.0d0)))) - ((x * (4.0d0 * i)) + (j * (27.0d0 * k)))
    else
        tmp = (b * c) + (t * ((x * 18.0d0) * (y * z)))
    end if
    code = tmp
end function
assert y < z;
assert 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 <= -2.5e+219) {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	} else if (x <= 4.5e+188) {
		tmp = ((b * c) + (t * (((x * y) * (18.0 * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	} else {
		tmp = (b * c) + (t * ((x * 18.0) * (y * z)));
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if x <= -2.5e+219:
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))
	elif x <= 4.5e+188:
		tmp = ((b * c) + (t * (((x * y) * (18.0 * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)))
	else:
		tmp = (b * c) + (t * ((x * 18.0) * (y * z)))
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (x <= -2.5e+219)
		tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))));
	elseif (x <= 4.5e+188)
		tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(x * y) * Float64(18.0 * z)) - Float64(a * 4.0)))) - Float64(Float64(x * Float64(4.0 * i)) + Float64(j * Float64(27.0 * k))));
	else
		tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(x * 18.0) * Float64(y * z))));
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (x <= -2.5e+219)
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	elseif (x <= 4.5e+188)
		tmp = ((b * c) + (t * (((x * y) * (18.0 * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	else
		tmp = (b * c) + (t * ((x * 18.0) * (y * z)));
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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, -2.5e+219], N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 4.5e+188], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(x * y), $MachinePrecision] * N[(18.0 * 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[(b * c), $MachinePrecision] + N[(t * N[(N[(x * 18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -2.5 \cdot 10^{+219}:\\
\;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\

\mathbf{elif}\;x \leq 4.5 \cdot 10^{+188}:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot y\right) \cdot \left(18 \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}:\\
\;\;\;\;b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\


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

    1. Initial program 40.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. Simplified52.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. Taylor expanded in x around inf 61.1%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*61.1%

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

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

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

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

    if -2.5e219 < x < 4.5000000000000001e188

    1. Initial program 87.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. Simplified90.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. Taylor expanded in x around 0 90.5%

      \[\leadsto \left(t \cdot \left(\color{blue}{18 \cdot \left(x \cdot \left(y \cdot z\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) \]
    4. Step-by-step derivation
      1. *-commutative90.5%

        \[\leadsto \left(t \cdot \left(\color{blue}{\left(x \cdot \left(y \cdot z\right)\right) \cdot 18} - 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*90.5%

        \[\leadsto \left(t \cdot \left(\color{blue}{\left(\left(x \cdot y\right) \cdot z\right)} \cdot 18 - 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. associate-*l*90.5%

        \[\leadsto \left(t \cdot \left(\color{blue}{\left(x \cdot y\right) \cdot \left(z \cdot 18\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) \]
    5. Simplified90.5%

      \[\leadsto \left(t \cdot \left(\color{blue}{\left(x \cdot y\right) \cdot \left(z \cdot 18\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) \]

    if 4.5000000000000001e188 < x

    1. Initial program 52.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. Simplified56.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. Taylor expanded in x around inf 64.6%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*64.6%

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

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

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

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

      \[\leadsto b \cdot c + t \cdot \color{blue}{\left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r*68.6%

        \[\leadsto b \cdot c + t \cdot \color{blue}{\left(\left(18 \cdot x\right) \cdot \left(y \cdot z\right)\right)} \]
      2. *-commutative68.6%

        \[\leadsto b \cdot c + t \cdot \left(\color{blue}{\left(x \cdot 18\right)} \cdot \left(y \cdot z\right)\right) \]
    9. Simplified68.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -2.5 \cdot 10^{+219}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{elif}\;x \leq 4.5 \cdot 10^{+188}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot y\right) \cdot \left(18 \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}:\\ \;\;\;\;b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\ \end{array} \]

Alternative 6: 85.6% accurate, 1.0× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} \mathbf{if}\;x \leq -1.2 \cdot 10^{+231}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;\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)\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.2e+231)
   (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))
   (-
    (+ (* b c) (* t (- (* (* x 18.0) (* y z)) (* a 4.0))))
    (+ (* x (* 4.0 i)) (* j (* 27.0 k))))))
assert(y < z);
assert(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.2e+231) {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	} else {
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.2d+231)) then
        tmp = (b * c) + (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0)))
    else
        tmp = ((b * c) + (t * (((x * 18.0d0) * (y * z)) - (a * 4.0d0)))) - ((x * (4.0d0 * i)) + (j * (27.0d0 * k)))
    end if
    code = tmp
end function
assert y < z;
assert 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.2e+231) {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	} else {
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if x <= -1.2e+231:
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))
	else:
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)))
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (x <= -1.2e+231)
		tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))));
	else
		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))));
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (x <= -1.2e+231)
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	else
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.2e+231], N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 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]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.2 \cdot 10^{+231}:\\
\;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\

\mathbf{else}:\\
\;\;\;\;\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)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < -1.20000000000000003e231

    1. Initial program 39.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. Simplified52.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. Taylor expanded in x around inf 61.8%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*61.8%

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

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

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

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

    if -1.20000000000000003e231 < x

    1. Initial program 83.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. Simplified86.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. Recombined 2 regimes into one program.
  4. Final simplification86.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -1.2 \cdot 10^{+231}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;\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)\\ \end{array} \]

Alternative 7: 36.3% accurate, 1.1× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} t_1 := -27 \cdot \left(j \cdot k\right)\\ t_2 := t \cdot \left(a \cdot -4\right)\\ \mathbf{if}\;b \cdot c \leq -1.75 \cdot 10^{+199}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -1.6 \cdot 10^{-231}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq -1.1 \cdot 10^{-301}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \cdot c \leq 6.2 \cdot 10^{-101}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq 1.6 \cdot 10^{+42}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \cdot c \leq 10^{+92}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 (* -27.0 (* j k))) (t_2 (* t (* a -4.0))))
   (if (<= (* b c) -1.75e+199)
     (* b c)
     (if (<= (* b c) -1.6e-231)
       t_1
       (if (<= (* b c) -1.1e-301)
         t_2
         (if (<= (* b c) 6.2e-101)
           t_1
           (if (<= (* b c) 1.6e+42)
             t_2
             (if (<= (* b c) 1e+92) t_1 (* b c)))))))))
assert(y < z);
assert(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 = -27.0 * (j * k);
	double t_2 = t * (a * -4.0);
	double tmp;
	if ((b * c) <= -1.75e+199) {
		tmp = b * c;
	} else if ((b * c) <= -1.6e-231) {
		tmp = t_1;
	} else if ((b * c) <= -1.1e-301) {
		tmp = t_2;
	} else if ((b * c) <= 6.2e-101) {
		tmp = t_1;
	} else if ((b * c) <= 1.6e+42) {
		tmp = t_2;
	} else if ((b * c) <= 1e+92) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 = (-27.0d0) * (j * k)
    t_2 = t * (a * (-4.0d0))
    if ((b * c) <= (-1.75d+199)) then
        tmp = b * c
    else if ((b * c) <= (-1.6d-231)) then
        tmp = t_1
    else if ((b * c) <= (-1.1d-301)) then
        tmp = t_2
    else if ((b * c) <= 6.2d-101) then
        tmp = t_1
    else if ((b * c) <= 1.6d+42) then
        tmp = t_2
    else if ((b * c) <= 1d+92) then
        tmp = t_1
    else
        tmp = b * c
    end if
    code = tmp
end function
assert y < z;
assert 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 = -27.0 * (j * k);
	double t_2 = t * (a * -4.0);
	double tmp;
	if ((b * c) <= -1.75e+199) {
		tmp = b * c;
	} else if ((b * c) <= -1.6e-231) {
		tmp = t_1;
	} else if ((b * c) <= -1.1e-301) {
		tmp = t_2;
	} else if ((b * c) <= 6.2e-101) {
		tmp = t_1;
	} else if ((b * c) <= 1.6e+42) {
		tmp = t_2;
	} else if ((b * c) <= 1e+92) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = -27.0 * (j * k)
	t_2 = t * (a * -4.0)
	tmp = 0
	if (b * c) <= -1.75e+199:
		tmp = b * c
	elif (b * c) <= -1.6e-231:
		tmp = t_1
	elif (b * c) <= -1.1e-301:
		tmp = t_2
	elif (b * c) <= 6.2e-101:
		tmp = t_1
	elif (b * c) <= 1.6e+42:
		tmp = t_2
	elif (b * c) <= 1e+92:
		tmp = t_1
	else:
		tmp = b * c
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(-27.0 * Float64(j * k))
	t_2 = Float64(t * Float64(a * -4.0))
	tmp = 0.0
	if (Float64(b * c) <= -1.75e+199)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -1.6e-231)
		tmp = t_1;
	elseif (Float64(b * c) <= -1.1e-301)
		tmp = t_2;
	elseif (Float64(b * c) <= 6.2e-101)
		tmp = t_1;
	elseif (Float64(b * c) <= 1.6e+42)
		tmp = t_2;
	elseif (Float64(b * c) <= 1e+92)
		tmp = t_1;
	else
		tmp = Float64(b * c);
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = -27.0 * (j * k);
	t_2 = t * (a * -4.0);
	tmp = 0.0;
	if ((b * c) <= -1.75e+199)
		tmp = b * c;
	elseif ((b * c) <= -1.6e-231)
		tmp = t_1;
	elseif ((b * c) <= -1.1e-301)
		tmp = t_2;
	elseif ((b * c) <= 6.2e-101)
		tmp = t_1;
	elseif ((b * c) <= 1.6e+42)
		tmp = t_2;
	elseif ((b * c) <= 1e+92)
		tmp = t_1;
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -1.75e+199], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -1.6e-231], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -1.1e-301], t$95$2, If[LessEqual[N[(b * c), $MachinePrecision], 6.2e-101], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], 1.6e+42], t$95$2, If[LessEqual[N[(b * c), $MachinePrecision], 1e+92], t$95$1, N[(b * c), $MachinePrecision]]]]]]]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
t_1 := -27 \cdot \left(j \cdot k\right)\\
t_2 := t \cdot \left(a \cdot -4\right)\\
\mathbf{if}\;b \cdot c \leq -1.75 \cdot 10^{+199}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \cdot c \leq -1.6 \cdot 10^{-231}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;b \cdot c \leq -1.1 \cdot 10^{-301}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;b \cdot c \leq 6.2 \cdot 10^{-101}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;b \cdot c \leq 1.6 \cdot 10^{+42}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;b \cdot c \leq 10^{+92}:\\
\;\;\;\;t_1\\

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


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

    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. 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. Taylor expanded in b around inf 65.1%

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

    if -1.7499999999999999e199 < (*.f64 b c) < -1.60000000000000004e-231 or -1.1e-301 < (*.f64 b c) < 6.19999999999999946e-101 or 1.60000000000000001e42 < (*.f64 b c) < 1e92

    1. Initial program 79.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.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. Taylor expanded in j around inf 35.6%

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

    if -1.60000000000000004e-231 < (*.f64 b c) < -1.1e-301 or 6.19999999999999946e-101 < (*.f64 b c) < 1.60000000000000001e42

    1. Initial program 83.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. Simplified89.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. Taylor expanded in a around inf 40.4%

      \[\leadsto \color{blue}{-4 \cdot \left(a \cdot t\right)} \]
    4. Step-by-step derivation
      1. *-commutative40.4%

        \[\leadsto \color{blue}{\left(a \cdot t\right) \cdot -4} \]
      2. *-commutative40.4%

        \[\leadsto \color{blue}{\left(t \cdot a\right)} \cdot -4 \]
      3. associate-*r*40.4%

        \[\leadsto \color{blue}{t \cdot \left(a \cdot -4\right)} \]
    5. Simplified40.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.75 \cdot 10^{+199}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -1.6 \cdot 10^{-231}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;b \cdot c \leq -1.1 \cdot 10^{-301}:\\ \;\;\;\;t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 6.2 \cdot 10^{-101}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{elif}\;b \cdot c \leq 1.6 \cdot 10^{+42}:\\ \;\;\;\;t \cdot \left(a \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 10^{+92}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]

Alternative 8: 50.0% accurate, 1.1× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} t_1 := t \cdot \left(x \cdot \left(y \cdot \left(18 \cdot z\right)\right) + a \cdot -4\right)\\ \mathbf{if}\;b \cdot c \leq -6.2 \cdot 10^{+289}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -9.5 \cdot 10^{-6}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq -5.3 \cdot 10^{-46}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;b \cdot c \leq 3.6 \cdot 10^{+125}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 (* t (+ (* x (* y (* 18.0 z))) (* a -4.0)))))
   (if (<= (* b c) -6.2e+289)
     (* b c)
     (if (<= (* b c) -9.5e-6)
       t_1
       (if (<= (* b c) -5.3e-46)
         (* k (* j -27.0))
         (if (<= (* b c) 3.6e+125) t_1 (* b c)))))))
assert(y < z);
assert(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 = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	double tmp;
	if ((b * c) <= -6.2e+289) {
		tmp = b * c;
	} else if ((b * c) <= -9.5e-6) {
		tmp = t_1;
	} else if ((b * c) <= -5.3e-46) {
		tmp = k * (j * -27.0);
	} else if ((b * c) <= 3.6e+125) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 = t * ((x * (y * (18.0d0 * z))) + (a * (-4.0d0)))
    if ((b * c) <= (-6.2d+289)) then
        tmp = b * c
    else if ((b * c) <= (-9.5d-6)) then
        tmp = t_1
    else if ((b * c) <= (-5.3d-46)) then
        tmp = k * (j * (-27.0d0))
    else if ((b * c) <= 3.6d+125) then
        tmp = t_1
    else
        tmp = b * c
    end if
    code = tmp
end function
assert y < z;
assert 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 = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	double tmp;
	if ((b * c) <= -6.2e+289) {
		tmp = b * c;
	} else if ((b * c) <= -9.5e-6) {
		tmp = t_1;
	} else if ((b * c) <= -5.3e-46) {
		tmp = k * (j * -27.0);
	} else if ((b * c) <= 3.6e+125) {
		tmp = t_1;
	} else {
		tmp = b * c;
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = t * ((x * (y * (18.0 * z))) + (a * -4.0))
	tmp = 0
	if (b * c) <= -6.2e+289:
		tmp = b * c
	elif (b * c) <= -9.5e-6:
		tmp = t_1
	elif (b * c) <= -5.3e-46:
		tmp = k * (j * -27.0)
	elif (b * c) <= 3.6e+125:
		tmp = t_1
	else:
		tmp = b * c
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(t * Float64(Float64(x * Float64(y * Float64(18.0 * z))) + Float64(a * -4.0)))
	tmp = 0.0
	if (Float64(b * c) <= -6.2e+289)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -9.5e-6)
		tmp = t_1;
	elseif (Float64(b * c) <= -5.3e-46)
		tmp = Float64(k * Float64(j * -27.0));
	elseif (Float64(b * c) <= 3.6e+125)
		tmp = t_1;
	else
		tmp = Float64(b * c);
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	tmp = 0.0;
	if ((b * c) <= -6.2e+289)
		tmp = b * c;
	elseif ((b * c) <= -9.5e-6)
		tmp = t_1;
	elseif ((b * c) <= -5.3e-46)
		tmp = k * (j * -27.0);
	elseif ((b * c) <= 3.6e+125)
		tmp = t_1;
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[(t * N[(N[(x * N[(y * N[(18.0 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -6.2e+289], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -9.5e-6], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -5.3e-46], N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 3.6e+125], t$95$1, N[(b * c), $MachinePrecision]]]]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
t_1 := t \cdot \left(x \cdot \left(y \cdot \left(18 \cdot z\right)\right) + a \cdot -4\right)\\
\mathbf{if}\;b \cdot c \leq -6.2 \cdot 10^{+289}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \cdot c \leq -9.5 \cdot 10^{-6}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;b \cdot c \leq 3.6 \cdot 10^{+125}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 b c) < -6.2000000000000002e289 or 3.6000000000000003e125 < (*.f64 b c)

    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. Simplified81.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. Taylor expanded in b around inf 76.1%

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

    if -6.2000000000000002e289 < (*.f64 b c) < -9.5000000000000005e-6 or -5.30000000000000018e-46 < (*.f64 b c) < 3.6000000000000003e125

    1. Initial program 79.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. Simplified86.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. Taylor expanded in t around inf 55.3%

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

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

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

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

        \[\leadsto t \cdot \left(\color{blue}{\left(x \cdot y\right) \cdot \left(z \cdot 18\right)} + \left(-4\right) \cdot a\right) \]
      5. associate-*l*55.3%

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

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

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

    if -9.5000000000000005e-6 < (*.f64 b c) < -5.30000000000000018e-46

    1. Initial program 67.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. Simplified59.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. Taylor expanded in j around inf 67.0%

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

        \[\leadsto \color{blue}{\left(-27 \cdot j\right) \cdot k} \]
    5. Simplified67.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -6.2 \cdot 10^{+289}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -9.5 \cdot 10^{-6}:\\ \;\;\;\;t \cdot \left(x \cdot \left(y \cdot \left(18 \cdot z\right)\right) + a \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq -5.3 \cdot 10^{-46}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;b \cdot c \leq 3.6 \cdot 10^{+125}:\\ \;\;\;\;t \cdot \left(x \cdot \left(y \cdot \left(18 \cdot z\right)\right) + a \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]

Alternative 9: 75.9% accurate, 1.1× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} t_1 := 4 \cdot \left(x \cdot i\right)\\ t_2 := \left(b \cdot c - t_1\right) - \left(j \cdot 27\right) \cdot k\\ t_3 := b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{if}\;t \leq -2.7 \cdot 10^{+87}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;t \leq -2.55 \cdot 10^{-14}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;t \leq -1.65 \cdot 10^{-51}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;t \leq -2 \cdot 10^{-78}:\\ \;\;\;\;\left(b \cdot c + \left(t \cdot a\right) \cdot -4\right) - t_1\\ \mathbf{elif}\;t \leq 1.05 \cdot 10^{-9}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 (* 4.0 (* x i)))
        (t_2 (- (- (* b c) t_1) (* (* j 27.0) k)))
        (t_3 (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))))
   (if (<= t -2.7e+87)
     t_3
     (if (<= t -2.55e-14)
       t_2
       (if (<= t -1.65e-51)
         t_3
         (if (<= t -2e-78)
           (- (+ (* b c) (* (* t a) -4.0)) t_1)
           (if (<= t 1.05e-9) t_2 t_3)))))))
assert(y < z);
assert(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 = 4.0 * (x * i);
	double t_2 = ((b * c) - t_1) - ((j * 27.0) * k);
	double t_3 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	double tmp;
	if (t <= -2.7e+87) {
		tmp = t_3;
	} else if (t <= -2.55e-14) {
		tmp = t_2;
	} else if (t <= -1.65e-51) {
		tmp = t_3;
	} else if (t <= -2e-78) {
		tmp = ((b * c) + ((t * a) * -4.0)) - t_1;
	} else if (t <= 1.05e-9) {
		tmp = t_2;
	} else {
		tmp = t_3;
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 = 4.0d0 * (x * i)
    t_2 = ((b * c) - t_1) - ((j * 27.0d0) * k)
    t_3 = (b * c) + (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0)))
    if (t <= (-2.7d+87)) then
        tmp = t_3
    else if (t <= (-2.55d-14)) then
        tmp = t_2
    else if (t <= (-1.65d-51)) then
        tmp = t_3
    else if (t <= (-2d-78)) then
        tmp = ((b * c) + ((t * a) * (-4.0d0))) - t_1
    else if (t <= 1.05d-9) then
        tmp = t_2
    else
        tmp = t_3
    end if
    code = tmp
end function
assert y < z;
assert 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 = 4.0 * (x * i);
	double t_2 = ((b * c) - t_1) - ((j * 27.0) * k);
	double t_3 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	double tmp;
	if (t <= -2.7e+87) {
		tmp = t_3;
	} else if (t <= -2.55e-14) {
		tmp = t_2;
	} else if (t <= -1.65e-51) {
		tmp = t_3;
	} else if (t <= -2e-78) {
		tmp = ((b * c) + ((t * a) * -4.0)) - t_1;
	} else if (t <= 1.05e-9) {
		tmp = t_2;
	} else {
		tmp = t_3;
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = 4.0 * (x * i)
	t_2 = ((b * c) - t_1) - ((j * 27.0) * k)
	t_3 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))
	tmp = 0
	if t <= -2.7e+87:
		tmp = t_3
	elif t <= -2.55e-14:
		tmp = t_2
	elif t <= -1.65e-51:
		tmp = t_3
	elif t <= -2e-78:
		tmp = ((b * c) + ((t * a) * -4.0)) - t_1
	elif t <= 1.05e-9:
		tmp = t_2
	else:
		tmp = t_3
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(4.0 * Float64(x * i))
	t_2 = Float64(Float64(Float64(b * c) - t_1) - Float64(Float64(j * 27.0) * k))
	t_3 = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))))
	tmp = 0.0
	if (t <= -2.7e+87)
		tmp = t_3;
	elseif (t <= -2.55e-14)
		tmp = t_2;
	elseif (t <= -1.65e-51)
		tmp = t_3;
	elseif (t <= -2e-78)
		tmp = Float64(Float64(Float64(b * c) + Float64(Float64(t * a) * -4.0)) - t_1);
	elseif (t <= 1.05e-9)
		tmp = t_2;
	else
		tmp = t_3;
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = 4.0 * (x * i);
	t_2 = ((b * c) - t_1) - ((j * 27.0) * k);
	t_3 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	tmp = 0.0;
	if (t <= -2.7e+87)
		tmp = t_3;
	elseif (t <= -2.55e-14)
		tmp = t_2;
	elseif (t <= -1.65e-51)
		tmp = t_3;
	elseif (t <= -2e-78)
		tmp = ((b * c) + ((t * a) * -4.0)) - t_1;
	elseif (t <= 1.05e-9)
		tmp = t_2;
	else
		tmp = t_3;
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(b * c), $MachinePrecision] - t$95$1), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.7e+87], t$95$3, If[LessEqual[t, -2.55e-14], t$95$2, If[LessEqual[t, -1.65e-51], t$95$3, If[LessEqual[t, -2e-78], N[(N[(N[(b * c), $MachinePrecision] + N[(N[(t * a), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], If[LessEqual[t, 1.05e-9], t$95$2, t$95$3]]]]]]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
t_1 := 4 \cdot \left(x \cdot i\right)\\
t_2 := \left(b \cdot c - t_1\right) - \left(j \cdot 27\right) \cdot k\\
t_3 := b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\
\mathbf{if}\;t \leq -2.7 \cdot 10^{+87}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;t \leq -2.55 \cdot 10^{-14}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;t \leq -1.65 \cdot 10^{-51}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;t \leq -2 \cdot 10^{-78}:\\
\;\;\;\;\left(b \cdot c + \left(t \cdot a\right) \cdot -4\right) - t_1\\

\mathbf{elif}\;t \leq 1.05 \cdot 10^{-9}:\\
\;\;\;\;t_2\\

\mathbf{else}:\\
\;\;\;\;t_3\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -2.70000000000000007e87 or -2.5499999999999999e-14 < t < -1.64999999999999986e-51 or 1.0500000000000001e-9 < t

    1. Initial program 77.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. Simplified84.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. Taylor expanded in x around inf 84.1%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*84.1%

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

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

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

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

    if -2.70000000000000007e87 < t < -2.5499999999999999e-14 or -2e-78 < t < 1.0500000000000001e-9

    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. Taylor expanded in t around 0 80.0%

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

    if -1.64999999999999986e-51 < t < -2e-78

    1. Initial program 78.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. 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. Taylor expanded in x around inf 92.0%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*92.0%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+87}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{elif}\;t \leq -2.55 \cdot 10^{-14}:\\ \;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{elif}\;t \leq -1.65 \cdot 10^{-51}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{elif}\;t \leq -2 \cdot 10^{-78}:\\ \;\;\;\;\left(b \cdot c + \left(t \cdot a\right) \cdot -4\right) - 4 \cdot \left(x \cdot i\right)\\ \mathbf{elif}\;t \leq 1.05 \cdot 10^{-9}:\\ \;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{else}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \end{array} \]

Alternative 10: 51.8% accurate, 1.2× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} t_1 := b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\ \mathbf{if}\;b \cdot c \leq -9.2 \cdot 10^{+14}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \cdot c \leq -5.5 \cdot 10^{-46}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;b \cdot c \leq 1.32 \cdot 10^{+73}:\\ \;\;\;\;t \cdot \left(x \cdot \left(y \cdot \left(18 \cdot z\right)\right) + a \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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) (* t (* (* x 18.0) (* y z))))))
   (if (<= (* b c) -9.2e+14)
     t_1
     (if (<= (* b c) -5.5e-46)
       (* k (* j -27.0))
       (if (<= (* b c) 1.32e+73)
         (* t (+ (* x (* y (* 18.0 z))) (* a -4.0)))
         t_1)))))
assert(y < z);
assert(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) + (t * ((x * 18.0) * (y * z)));
	double tmp;
	if ((b * c) <= -9.2e+14) {
		tmp = t_1;
	} else if ((b * c) <= -5.5e-46) {
		tmp = k * (j * -27.0);
	} else if ((b * c) <= 1.32e+73) {
		tmp = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 = (b * c) + (t * ((x * 18.0d0) * (y * z)))
    if ((b * c) <= (-9.2d+14)) then
        tmp = t_1
    else if ((b * c) <= (-5.5d-46)) then
        tmp = k * (j * (-27.0d0))
    else if ((b * c) <= 1.32d+73) then
        tmp = t * ((x * (y * (18.0d0 * z))) + (a * (-4.0d0)))
    else
        tmp = t_1
    end if
    code = tmp
end function
assert y < z;
assert 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) + (t * ((x * 18.0) * (y * z)));
	double tmp;
	if ((b * c) <= -9.2e+14) {
		tmp = t_1;
	} else if ((b * c) <= -5.5e-46) {
		tmp = k * (j * -27.0);
	} else if ((b * c) <= 1.32e+73) {
		tmp = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	} else {
		tmp = t_1;
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (b * c) + (t * ((x * 18.0) * (y * z)))
	tmp = 0
	if (b * c) <= -9.2e+14:
		tmp = t_1
	elif (b * c) <= -5.5e-46:
		tmp = k * (j * -27.0)
	elif (b * c) <= 1.32e+73:
		tmp = t * ((x * (y * (18.0 * z))) + (a * -4.0))
	else:
		tmp = t_1
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(b * c) + Float64(t * Float64(Float64(x * 18.0) * Float64(y * z))))
	tmp = 0.0
	if (Float64(b * c) <= -9.2e+14)
		tmp = t_1;
	elseif (Float64(b * c) <= -5.5e-46)
		tmp = Float64(k * Float64(j * -27.0));
	elseif (Float64(b * c) <= 1.32e+73)
		tmp = Float64(t * Float64(Float64(x * Float64(y * Float64(18.0 * z))) + Float64(a * -4.0)));
	else
		tmp = t_1;
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (b * c) + (t * ((x * 18.0) * (y * z)));
	tmp = 0.0;
	if ((b * c) <= -9.2e+14)
		tmp = t_1;
	elseif ((b * c) <= -5.5e-46)
		tmp = k * (j * -27.0);
	elseif ((b * c) <= 1.32e+73)
		tmp = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[(t * N[(N[(x * 18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(b * c), $MachinePrecision], -9.2e+14], t$95$1, If[LessEqual[N[(b * c), $MachinePrecision], -5.5e-46], N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 1.32e+73], N[(t * N[(N[(x * N[(y * N[(18.0 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
t_1 := b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\
\mathbf{if}\;b \cdot c \leq -9.2 \cdot 10^{+14}:\\
\;\;\;\;t_1\\

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

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

\mathbf{else}:\\
\;\;\;\;t_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 b c) < -9.2e14 or 1.32e73 < (*.f64 b c)

    1. Initial program 77.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.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. Taylor expanded in x around inf 75.1%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*75.1%

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

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

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

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

      \[\leadsto b \cdot c + t \cdot \color{blue}{\left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r*69.9%

        \[\leadsto b \cdot c + t \cdot \color{blue}{\left(\left(18 \cdot x\right) \cdot \left(y \cdot z\right)\right)} \]
      2. *-commutative69.9%

        \[\leadsto b \cdot c + t \cdot \left(\color{blue}{\left(x \cdot 18\right)} \cdot \left(y \cdot z\right)\right) \]
    9. Simplified69.9%

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

    if -9.2e14 < (*.f64 b c) < -5.49999999999999983e-46

    1. Initial program 73.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. Simplified67.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. Taylor expanded in j around inf 60.4%

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

        \[\leadsto \color{blue}{\left(-27 \cdot j\right) \cdot k} \]
    5. Simplified60.4%

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

    if -5.49999999999999983e-46 < (*.f64 b c) < 1.32e73

    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.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. Taylor expanded in t around inf 58.4%

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

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

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

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

        \[\leadsto t \cdot \left(\color{blue}{\left(x \cdot y\right) \cdot \left(z \cdot 18\right)} + \left(-4\right) \cdot a\right) \]
      5. associate-*l*58.4%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -9.2 \cdot 10^{+14}:\\ \;\;\;\;b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\ \mathbf{elif}\;b \cdot c \leq -5.5 \cdot 10^{-46}:\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{elif}\;b \cdot c \leq 1.32 \cdot 10^{+73}:\\ \;\;\;\;t \cdot \left(x \cdot \left(y \cdot \left(18 \cdot z\right)\right) + a \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\ \end{array} \]

Alternative 11: 80.6% accurate, 1.3× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -1.55 \cdot 10^{+136} \lor \neg \left(t \leq 1.35 \cdot 10^{-9}\right):\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.55e+136) (not (<= t 1.35e-9)))
   (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))
   (- (- (* b c) (* 4.0 (+ (* t a) (* x i)))) (* (* j 27.0) k))))
assert(y < z);
assert(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.55e+136) || !(t <= 1.35e-9)) {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	} else {
		tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.55d+136)) .or. (.not. (t <= 1.35d-9))) then
        tmp = (b * c) + (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0)))
    else
        tmp = ((b * c) - (4.0d0 * ((t * a) + (x * i)))) - ((j * 27.0d0) * k)
    end if
    code = tmp
end function
assert y < z;
assert 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.55e+136) || !(t <= 1.35e-9)) {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	} else {
		tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (t <= -1.55e+136) or not (t <= 1.35e-9):
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))
	else:
		tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k)
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((t <= -1.55e+136) || !(t <= 1.35e-9))
		tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))));
	else
		tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(t * a) + Float64(x * i)))) - Float64(Float64(j * 27.0) * k));
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((t <= -1.55e+136) || ~((t <= 1.35e-9)))
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	else
		tmp = ((b * c) - (4.0 * ((t * a) + (x * i)))) - ((j * 27.0) * k);
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.55e+136], N[Not[LessEqual[t, 1.35e-9]], $MachinePrecision]], N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.55 \cdot 10^{+136} \lor \neg \left(t \leq 1.35 \cdot 10^{-9}\right):\\
\;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.54999999999999992e136 or 1.3500000000000001e-9 < t

    1. Initial program 75.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. Simplified82.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. Taylor expanded in x around inf 84.3%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*84.3%

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

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

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

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

    if -1.54999999999999992e136 < t < 1.3500000000000001e-9

    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. Taylor expanded in y around 0 81.5%

      \[\leadsto \color{blue}{\left(b \cdot c - \left(4 \cdot \left(a \cdot t\right) + 4 \cdot \left(i \cdot x\right)\right)\right)} - \left(j \cdot 27\right) \cdot k \]
    3. Step-by-step derivation
      1. distribute-lft-out81.5%

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

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

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

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

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

Alternative 12: 62.3% accurate, 1.6× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq -1.32 \cdot 10^{+172} \lor \neg \left(y \leq 3.4 \cdot 10^{-74}\right):\\ \;\;\;\;b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot c + \left(t \cdot a\right) \cdot -4\right) - 4 \cdot \left(x \cdot i\right)\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 (<= y -1.32e+172) (not (<= y 3.4e-74)))
   (+ (* b c) (* t (* (* x 18.0) (* y z))))
   (- (+ (* b c) (* (* t a) -4.0)) (* 4.0 (* x i)))))
assert(y < z);
assert(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 ((y <= -1.32e+172) || !(y <= 3.4e-74)) {
		tmp = (b * c) + (t * ((x * 18.0) * (y * z)));
	} else {
		tmp = ((b * c) + ((t * a) * -4.0)) - (4.0 * (x * i));
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 ((y <= (-1.32d+172)) .or. (.not. (y <= 3.4d-74))) then
        tmp = (b * c) + (t * ((x * 18.0d0) * (y * z)))
    else
        tmp = ((b * c) + ((t * a) * (-4.0d0))) - (4.0d0 * (x * i))
    end if
    code = tmp
end function
assert y < z;
assert 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 ((y <= -1.32e+172) || !(y <= 3.4e-74)) {
		tmp = (b * c) + (t * ((x * 18.0) * (y * z)));
	} else {
		tmp = ((b * c) + ((t * a) * -4.0)) - (4.0 * (x * i));
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (y <= -1.32e+172) or not (y <= 3.4e-74):
		tmp = (b * c) + (t * ((x * 18.0) * (y * z)))
	else:
		tmp = ((b * c) + ((t * a) * -4.0)) - (4.0 * (x * i))
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((y <= -1.32e+172) || !(y <= 3.4e-74))
		tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(x * 18.0) * Float64(y * z))));
	else
		tmp = Float64(Float64(Float64(b * c) + Float64(Float64(t * a) * -4.0)) - Float64(4.0 * Float64(x * i)));
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((y <= -1.32e+172) || ~((y <= 3.4e-74)))
		tmp = (b * c) + (t * ((x * 18.0) * (y * z)));
	else
		tmp = ((b * c) + ((t * a) * -4.0)) - (4.0 * (x * i));
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[y, -1.32e+172], N[Not[LessEqual[y, 3.4e-74]], $MachinePrecision]], N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(x * 18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] + N[(N[(t * a), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.32 \cdot 10^{+172} \lor \neg \left(y \leq 3.4 \cdot 10^{-74}\right):\\
\;\;\;\;b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -1.31999999999999996e172 or 3.4000000000000001e-74 < y

    1. Initial program 74.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. Simplified78.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. Taylor expanded in x around inf 71.3%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*71.3%

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

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

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

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

      \[\leadsto b \cdot c + t \cdot \color{blue}{\left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r*64.7%

        \[\leadsto b \cdot c + t \cdot \color{blue}{\left(\left(18 \cdot x\right) \cdot \left(y \cdot z\right)\right)} \]
      2. *-commutative64.7%

        \[\leadsto b \cdot c + t \cdot \left(\color{blue}{\left(x \cdot 18\right)} \cdot \left(y \cdot z\right)\right) \]
    9. Simplified64.7%

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

    if -1.31999999999999996e172 < y < 3.4000000000000001e-74

    1. Initial program 84.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.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. Taylor expanded in x around inf 69.1%

      \[\leadsto \left(t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right) + b \cdot c\right) - \color{blue}{4 \cdot \left(i \cdot x\right)} \]
    4. Step-by-step derivation
      1. associate-*r*69.1%

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

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

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

      \[\leadsto \color{blue}{\left(-4 \cdot \left(a \cdot t\right) + b \cdot c\right) - 4 \cdot \left(i \cdot x\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification62.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.32 \cdot 10^{+172} \lor \neg \left(y \leq 3.4 \cdot 10^{-74}\right):\\ \;\;\;\;b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot c + \left(t \cdot a\right) \cdot -4\right) - 4 \cdot \left(x \cdot i\right)\\ \end{array} \]

Alternative 13: 71.7% accurate, 1.6× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -6.5 \cdot 10^{+136}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{elif}\;t \leq 2.25 \cdot 10^{-9}:\\ \;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(x \cdot \left(y \cdot \left(18 \cdot z\right)\right) + a \cdot -4\right)\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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 (<= t -6.5e+136)
   (* t (- (* 18.0 (* x (* y z))) (* a 4.0)))
   (if (<= t 2.25e-9)
     (- (- (* b c) (* 4.0 (* x i))) (* (* j 27.0) k))
     (* t (+ (* x (* y (* 18.0 z))) (* a -4.0))))))
assert(y < z);
assert(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+136) {
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	} else if (t <= 2.25e-9) {
		tmp = ((b * c) - (4.0 * (x * i))) - ((j * 27.0) * k);
	} else {
		tmp = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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+136)) then
        tmp = t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0))
    else if (t <= 2.25d-9) then
        tmp = ((b * c) - (4.0d0 * (x * i))) - ((j * 27.0d0) * k)
    else
        tmp = t * ((x * (y * (18.0d0 * z))) + (a * (-4.0d0)))
    end if
    code = tmp
end function
assert y < z;
assert 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+136) {
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	} else if (t <= 2.25e-9) {
		tmp = ((b * c) - (4.0 * (x * i))) - ((j * 27.0) * k);
	} else {
		tmp = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if t <= -6.5e+136:
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0))
	elif t <= 2.25e-9:
		tmp = ((b * c) - (4.0 * (x * i))) - ((j * 27.0) * k)
	else:
		tmp = t * ((x * (y * (18.0 * z))) + (a * -4.0))
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (t <= -6.5e+136)
		tmp = Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0)));
	elseif (t <= 2.25e-9)
		tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) - Float64(Float64(j * 27.0) * k));
	else
		tmp = Float64(t * Float64(Float64(x * Float64(y * Float64(18.0 * z))) + Float64(a * -4.0)));
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (t <= -6.5e+136)
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	elseif (t <= 2.25e-9)
		tmp = ((b * c) - (4.0 * (x * i))) - ((j * 27.0) * k);
	else
		tmp = t * ((x * (y * (18.0 * z))) + (a * -4.0));
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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[t, -6.5e+136], N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.25e-9], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], N[(t * N[(N[(x * N[(y * N[(18.0 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.5 \cdot 10^{+136}:\\
\;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\

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

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


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

    1. Initial program 75.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. Simplified85.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. Taylor expanded in t around inf 83.2%

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

    if -6.4999999999999998e136 < t < 2.24999999999999988e-9

    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. Taylor expanded in t around 0 76.3%

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

    if 2.24999999999999988e-9 < t

    1. Initial program 75.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.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. Taylor expanded in t around inf 65.8%

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

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

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

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

        \[\leadsto t \cdot \left(\color{blue}{\left(x \cdot y\right) \cdot \left(z \cdot 18\right)} + \left(-4\right) \cdot a\right) \]
      5. associate-*l*65.8%

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

        \[\leadsto t \cdot \left(x \cdot \left(y \cdot \left(z \cdot 18\right)\right) + \color{blue}{-4} \cdot a\right) \]
    5. Applied egg-rr65.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -6.5 \cdot 10^{+136}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{elif}\;t \leq 2.25 \cdot 10^{-9}:\\ \;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(x \cdot \left(y \cdot \left(18 \cdot z\right)\right) + a \cdot -4\right)\\ \end{array} \]

Alternative 14: 36.7% accurate, 2.4× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.4 \cdot 10^{+200}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq 9.5 \cdot 10^{+88}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.4e+200)
   (* b c)
   (if (<= (* b c) 9.5e+88) (* -27.0 (* j k)) (* b c))))
assert(y < z);
assert(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.4e+200) {
		tmp = b * c;
	} else if ((b * c) <= 9.5e+88) {
		tmp = -27.0 * (j * k);
	} else {
		tmp = b * c;
	}
	return tmp;
}
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.4d+200)) then
        tmp = b * c
    else if ((b * c) <= 9.5d+88) then
        tmp = (-27.0d0) * (j * k)
    else
        tmp = b * c
    end if
    code = tmp
end function
assert y < z;
assert 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.4e+200) {
		tmp = b * c;
	} else if ((b * c) <= 9.5e+88) {
		tmp = -27.0 * (j * k);
	} else {
		tmp = b * c;
	}
	return tmp;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (b * c) <= -1.4e+200:
		tmp = b * c
	elif (b * c) <= 9.5e+88:
		tmp = -27.0 * (j * k)
	else:
		tmp = b * c
	return tmp
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (Float64(b * c) <= -1.4e+200)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= 9.5e+88)
		tmp = Float64(-27.0 * Float64(j * k));
	else
		tmp = Float64(b * c);
	end
	return tmp
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((b * c) <= -1.4e+200)
		tmp = b * c;
	elseif ((b * c) <= 9.5e+88)
		tmp = -27.0 * (j * k);
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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.4e+200], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 9.5e+88], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]
\begin{array}{l}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1.4 \cdot 10^{+200}:\\
\;\;\;\;b \cdot c\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 b c) < -1.39999999999999992e200 or 9.50000000000000059e88 < (*.f64 b c)

    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. 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. Taylor expanded in b around inf 65.1%

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

    if -1.39999999999999992e200 < (*.f64 b c) < 9.50000000000000059e88

    1. Initial program 80.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. Simplified85.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. Taylor expanded in j around inf 31.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.4 \cdot 10^{+200}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq 9.5 \cdot 10^{+88}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]

Alternative 15: 23.3% accurate, 10.3× speedup?

\[\begin{array}{l} [y, z] = \mathsf{sort}([y, z])\\ [j, k] = \mathsf{sort}([j, k])\\ \\ b \cdot c \end{array} \]
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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(y < z);
assert(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: y and z should be sorted in increasing order before calling this function.
NOTE: 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 y < z;
assert 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;
}
[y, z] = sort([y, z])
[j, k] = sort([j, k])
def code(x, y, z, t, a, b, c, i, j, k):
	return b * c
y, z = sort([y, z])
j, k = sort([j, k])
function code(x, y, z, t, a, b, c, i, j, k)
	return Float64(b * c)
end
y, z = num2cell(sort([y, z])){:}
j, k = num2cell(sort([j, k])){:}
function tmp = code(x, y, z, t, a, b, c, i, j, k)
	tmp = b * c;
end
NOTE: y and z should be sorted in increasing order before calling this function.
NOTE: 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}
[y, z] = \mathsf{sort}([y, z])\\
[j, k] = \mathsf{sort}([j, k])\\
\\
b \cdot c
\end{array}
Derivation
  1. Initial program 79.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. Simplified83.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. Taylor expanded in b around inf 25.8%

    \[\leadsto \color{blue}{b \cdot c} \]
  4. Final simplification25.8%

    \[\leadsto b \cdot c \]

Developer target: 89.4% accurate, 0.9× 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 2023275 
(FPCore (x y z t a b c i j k)
  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1, E"
  :precision binary64

  :herbie-target
  (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)))