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

Percentage Accurate: 84.9% → 93.1%
Time: 10.5s
Alternatives: 20
Speedup: 0.8×

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);
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k)
use fmin_fmax_functions
    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 20 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: 84.9% 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);
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k)
use fmin_fmax_functions
    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: 93.1% accurate, 0.8× speedup?

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

\mathbf{elif}\;x \leq 2.4 \cdot 10^{+56}:\\
\;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, \mathsf{fma}\left(c, b, \left(-4 \cdot x\right) \cdot i\right)\right)\right)\\

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


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

    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. Add Preprocessing
    3. Taylor expanded in x around inf

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

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

      if -3.4999999999999997e57 < x < 2.40000000000000013e56

      1. Initial program 91.7%

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

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

      if 2.40000000000000013e56 < x

      1. Initial program 79.0%

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

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

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

          \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{k \cdot j}{x}, -27, \mathsf{fma}\left(-4, i, \mathsf{fma}\left(18 \cdot t, y \cdot z, \frac{\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)}{x}\right)\right)\right) \cdot x} \]
      6. Recombined 3 regimes into one program.
      7. Add Preprocessing

      Alternative 2: 85.9% accurate, 0.3× speedup?

      \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \mathsf{fma}\left(\left(x \cdot y\right) \cdot 18, z \cdot t, \mathsf{fma}\left(\mathsf{fma}\left(i, x, t \cdot a\right), -4, b \cdot c\right)\right)\\ t_2 := \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\\ \mathbf{if}\;t\_2 \leq -\infty:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+289}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\ \mathbf{elif}\;t\_2 \leq \infty:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\ \end{array} \end{array} \]
      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
      (FPCore (x y z t a b c i j k)
       :precision binary64
       (let* ((t_1
               (fma (* (* x y) 18.0) (* z t) (fma (fma i x (* t a)) -4.0 (* b c))))
              (t_2
               (-
                (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c))
                (* (* x 4.0) i))))
         (if (<= t_2 (- INFINITY))
           t_1
           (if (<= t_2 2e+289)
             (fma (* -27.0 j) k (fma -4.0 (fma t a (* i x)) (* b c)))
             (if (<= t_2 INFINITY) t_1 (* (fma (* (* y z) x) 18.0 (* -4.0 a)) t))))))
      assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
      assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
      double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
      	double t_1 = fma(((x * y) * 18.0), (z * t), fma(fma(i, x, (t * a)), -4.0, (b * c)));
      	double t_2 = ((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i);
      	double tmp;
      	if (t_2 <= -((double) INFINITY)) {
      		tmp = t_1;
      	} else if (t_2 <= 2e+289) {
      		tmp = fma((-27.0 * j), k, fma(-4.0, fma(t, a, (i * x)), (b * c)));
      	} else if (t_2 <= ((double) INFINITY)) {
      		tmp = t_1;
      	} else {
      		tmp = fma(((y * z) * x), 18.0, (-4.0 * a)) * t;
      	}
      	return tmp;
      }
      
      x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
      x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
      function code(x, y, z, t, a, b, c, i, j, k)
      	t_1 = fma(Float64(Float64(x * y) * 18.0), Float64(z * t), fma(fma(i, x, Float64(t * a)), -4.0, Float64(b * c)))
      	t_2 = 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))
      	tmp = 0.0
      	if (t_2 <= Float64(-Inf))
      		tmp = t_1;
      	elseif (t_2 <= 2e+289)
      		tmp = fma(Float64(-27.0 * j), k, fma(-4.0, fma(t, a, Float64(i * x)), Float64(b * c)));
      	elseif (t_2 <= Inf)
      		tmp = t_1;
      	else
      		tmp = Float64(fma(Float64(Float64(y * z) * x), 18.0, Float64(-4.0 * a)) * t);
      	end
      	return tmp
      end
      
      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
      code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(x * y), $MachinePrecision] * 18.0), $MachinePrecision] * N[(z * t), $MachinePrecision] + N[(N[(i * x + N[(t * a), $MachinePrecision]), $MachinePrecision] * -4.0 + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = 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]}, If[LessEqual[t$95$2, (-Infinity)], t$95$1, If[LessEqual[t$95$2, 2e+289], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(-4.0 * N[(t * a + N[(i * x), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, Infinity], t$95$1, N[(N[(N[(N[(y * z), $MachinePrecision] * x), $MachinePrecision] * 18.0 + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]]]]]]
      
      \begin{array}{l}
      [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
      [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
      \\
      \begin{array}{l}
      t_1 := \mathsf{fma}\left(\left(x \cdot y\right) \cdot 18, z \cdot t, \mathsf{fma}\left(\mathsf{fma}\left(i, x, t \cdot a\right), -4, b \cdot c\right)\right)\\
      t_2 := \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\\
      \mathbf{if}\;t\_2 \leq -\infty:\\
      \;\;\;\;t\_1\\
      
      \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+289}:\\
      \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\
      
      \mathbf{elif}\;t\_2 \leq \infty:\\
      \;\;\;\;t\_1\\
      
      \mathbf{else}:\\
      \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) < -inf.0 or 2.0000000000000001e289 < (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) < +inf.0

        1. Initial program 86.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. Add Preprocessing
        3. Applied rewrites87.8%

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

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

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

        if -inf.0 < (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) < 2.0000000000000001e289

        1. Initial program 99.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. Add Preprocessing
        3. Applied rewrites99.8%

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

          \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(a \cdot t\right) + \left(-4 \cdot \left(i \cdot x\right) + b \cdot c\right)}\right) \]
        5. Step-by-step derivation
          1. Applied rewrites90.9%

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

          if +inf.0 < (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i))

          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. Add Preprocessing
          3. Applied rewrites31.8%

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

            \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
          5. Step-by-step derivation
            1. Applied rewrites59.4%

              \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t} \]
          6. Recombined 3 regimes into one program.
          7. Final simplification86.8%

            \[\leadsto \begin{array}{l} \mathbf{if}\;\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 \leq -\infty:\\ \;\;\;\;\mathsf{fma}\left(\left(x \cdot y\right) \cdot 18, z \cdot t, \mathsf{fma}\left(\mathsf{fma}\left(i, x, t \cdot a\right), -4, b \cdot c\right)\right)\\ \mathbf{elif}\;\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 \leq 2 \cdot 10^{+289}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\ \mathbf{elif}\;\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 \leq \infty:\\ \;\;\;\;\mathsf{fma}\left(\left(x \cdot y\right) \cdot 18, z \cdot t, \mathsf{fma}\left(\mathsf{fma}\left(i, x, t \cdot a\right), -4, b \cdot c\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\ \end{array} \]
          8. Add Preprocessing

          Alternative 3: 86.3% accurate, 0.4× speedup?

          \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \left(\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\\ \mathbf{if}\;t\_1 \leq -\infty:\\ \;\;\;\;\mathsf{fma}\left(\left(x \cdot y\right) \cdot 18, z \cdot t, \mathsf{fma}\left(\mathsf{fma}\left(i, x, t \cdot a\right), -4, b \cdot c\right)\right)\\ \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+289}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)\\ \end{array} \end{array} \]
          NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
          NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
          (FPCore (x y z t a b c i j k)
           :precision binary64
           (let* ((t_1
                   (-
                    (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c))
                    (* (* x 4.0) i))))
             (if (<= t_1 (- INFINITY))
               (fma (* (* x y) 18.0) (* z t) (fma (fma i x (* t a)) -4.0 (* b c)))
               (if (<= t_1 2e+289)
                 (fma (* -27.0 j) k (fma -4.0 (fma t a (* i x)) (* b c)))
                 (fma
                  (* -4.0 x)
                  i
                  (fma (fma -4.0 a (* (* (* z y) x) 18.0)) t (* c b)))))))
          assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
          assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
          double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
          	double t_1 = ((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i);
          	double tmp;
          	if (t_1 <= -((double) INFINITY)) {
          		tmp = fma(((x * y) * 18.0), (z * t), fma(fma(i, x, (t * a)), -4.0, (b * c)));
          	} else if (t_1 <= 2e+289) {
          		tmp = fma((-27.0 * j), k, fma(-4.0, fma(t, a, (i * x)), (b * c)));
          	} else {
          		tmp = fma((-4.0 * x), i, fma(fma(-4.0, a, (((z * y) * x) * 18.0)), t, (c * b)));
          	}
          	return tmp;
          }
          
          x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
          x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
          function code(x, y, z, t, a, b, c, i, j, k)
          	t_1 = Float64(Float64(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))
          	tmp = 0.0
          	if (t_1 <= Float64(-Inf))
          		tmp = fma(Float64(Float64(x * y) * 18.0), Float64(z * t), fma(fma(i, x, Float64(t * a)), -4.0, Float64(b * c)));
          	elseif (t_1 <= 2e+289)
          		tmp = fma(Float64(-27.0 * j), k, fma(-4.0, fma(t, a, Float64(i * x)), Float64(b * c)));
          	else
          		tmp = fma(Float64(-4.0 * x), i, fma(fma(-4.0, a, Float64(Float64(Float64(z * y) * x) * 18.0)), t, Float64(c * b)));
          	end
          	return tmp
          end
          
          NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
          NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
          code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(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]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(N[(x * y), $MachinePrecision] * 18.0), $MachinePrecision] * N[(z * t), $MachinePrecision] + N[(N[(i * x + N[(t * a), $MachinePrecision]), $MachinePrecision] * -4.0 + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e+289], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(-4.0 * N[(t * a + N[(i * x), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(-4.0 * x), $MachinePrecision] * i + N[(N[(-4.0 * a + N[(N[(N[(z * y), $MachinePrecision] * x), $MachinePrecision] * 18.0), $MachinePrecision]), $MachinePrecision] * t + N[(c * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
          
          \begin{array}{l}
          [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
          [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
          \\
          \begin{array}{l}
          t_1 := \left(\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\\
          \mathbf{if}\;t\_1 \leq -\infty:\\
          \;\;\;\;\mathsf{fma}\left(\left(x \cdot y\right) \cdot 18, z \cdot t, \mathsf{fma}\left(\mathsf{fma}\left(i, x, t \cdot a\right), -4, b \cdot c\right)\right)\\
          
          \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+289}:\\
          \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\
          
          \mathbf{else}:\\
          \;\;\;\;\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) < -inf.0

            1. Initial program 87.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. Add Preprocessing
            3. Applied rewrites87.8%

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

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

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

            if -inf.0 < (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) < 2.0000000000000001e289

            1. Initial program 99.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. Add Preprocessing
            3. Applied rewrites99.8%

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

              \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(a \cdot t\right) + \left(-4 \cdot \left(i \cdot x\right) + b \cdot c\right)}\right) \]
            5. Step-by-step derivation
              1. Applied rewrites90.9%

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

              if 2.0000000000000001e289 < (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i))

              1. Initial program 61.7%

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

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

                \[\leadsto \color{blue}{\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)} \]
            6. Recombined 3 regimes into one program.
            7. Final simplification88.4%

              \[\leadsto \begin{array}{l} \mathbf{if}\;\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 \leq -\infty:\\ \;\;\;\;\mathsf{fma}\left(\left(x \cdot y\right) \cdot 18, z \cdot t, \mathsf{fma}\left(\mathsf{fma}\left(i, x, t \cdot a\right), -4, b \cdot c\right)\right)\\ \mathbf{elif}\;\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 \leq 2 \cdot 10^{+289}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)\\ \end{array} \]
            8. Add Preprocessing

            Alternative 4: 91.0% accurate, 0.6× speedup?

            \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;\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 \leq 2 \cdot 10^{+289}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, \mathsf{fma}\left(c, b, \left(-4 \cdot x\right) \cdot i\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)\\ \end{array} \end{array} \]
            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
            (FPCore (x y z t a b c i j k)
             :precision binary64
             (if (<=
                  (-
                   (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c))
                   (* (* x 4.0) i))
                  2e+289)
               (fma
                (* -27.0 j)
                k
                (fma (fma z (* y (* 18.0 x)) (* -4.0 a)) t (fma c b (* (* -4.0 x) i))))
               (fma (* -4.0 x) i (fma (fma -4.0 a (* (* (* z y) x) 18.0)) t (* c b)))))
            assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
            assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
            double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
            	double tmp;
            	if ((((((((x * 18.0) * y) * z) * t) - ((a * 4.0) * t)) + (b * c)) - ((x * 4.0) * i)) <= 2e+289) {
            		tmp = fma((-27.0 * j), k, fma(fma(z, (y * (18.0 * x)), (-4.0 * a)), t, fma(c, b, ((-4.0 * x) * i))));
            	} else {
            		tmp = fma((-4.0 * x), i, fma(fma(-4.0, a, (((z * y) * x) * 18.0)), t, (c * b)));
            	}
            	return tmp;
            }
            
            x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
            x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
            function code(x, y, z, t, a, b, c, i, j, k)
            	tmp = 0.0
            	if (Float64(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)) <= 2e+289)
            		tmp = fma(Float64(-27.0 * j), k, fma(fma(z, Float64(y * Float64(18.0 * x)), Float64(-4.0 * a)), t, fma(c, b, Float64(Float64(-4.0 * x) * i))));
            	else
            		tmp = fma(Float64(-4.0 * x), i, fma(fma(-4.0, a, Float64(Float64(Float64(z * y) * x) * 18.0)), t, Float64(c * b)));
            	end
            	return tmp
            end
            
            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
            code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(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], 2e+289], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(z * N[(y * N[(18.0 * x), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t + N[(c * b + N[(N[(-4.0 * x), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(-4.0 * x), $MachinePrecision] * i + N[(N[(-4.0 * a + N[(N[(N[(z * y), $MachinePrecision] * x), $MachinePrecision] * 18.0), $MachinePrecision]), $MachinePrecision] * t + N[(c * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
            
            \begin{array}{l}
            [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
            [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
            \\
            \begin{array}{l}
            \mathbf{if}\;\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 \leq 2 \cdot 10^{+289}:\\
            \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, \mathsf{fma}\left(c, b, \left(-4 \cdot x\right) \cdot i\right)\right)\right)\\
            
            \mathbf{else}:\\
            \;\;\;\;\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 2 regimes
            2. if (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i)) < 2.0000000000000001e289

              1. Initial program 96.6%

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

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

              if 2.0000000000000001e289 < (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #s(literal 18 binary64)) y) z) t) (*.f64 (*.f64 a #s(literal 4 binary64)) t)) (*.f64 b c)) (*.f64 (*.f64 x #s(literal 4 binary64)) i))

              1. Initial program 61.7%

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

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

                \[\leadsto \color{blue}{\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)} \]
            3. Recombined 2 regimes into one program.
            4. Add Preprocessing

            Alternative 5: 84.0% accurate, 0.7× speedup?

            \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \left(j \cdot 27\right) \cdot k\\ \mathbf{if}\;t\_1 \leq -0.0002:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, b \cdot c\right)\right)\\ \mathbf{elif}\;t\_1 \leq 0.0002:\\ \;\;\;\;\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)\\ \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+211}:\\ \;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(-4, i, \left(\left(z \cdot y\right) \cdot t\right) \cdot 18\right), x, c \cdot b\right) - t\_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\ \end{array} \end{array} \]
            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
            (FPCore (x y z t a b c i j k)
             :precision binary64
             (let* ((t_1 (* (* j 27.0) k)))
               (if (<= t_1 -0.0002)
                 (fma (* -27.0 j) k (fma (fma z (* y (* 18.0 x)) (* -4.0 a)) t (* b c)))
                 (if (<= t_1 0.0002)
                   (fma (* -4.0 x) i (fma (fma -4.0 a (* (* (* z y) x) 18.0)) t (* c b)))
                   (if (<= t_1 2e+211)
                     (- (fma (fma -4.0 i (* (* (* z y) t) 18.0)) x (* c b)) t_1)
                     (fma (* -27.0 j) k (fma -4.0 (fma t a (* i x)) (* b c))))))))
            assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
            assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
            double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
            	double t_1 = (j * 27.0) * k;
            	double tmp;
            	if (t_1 <= -0.0002) {
            		tmp = fma((-27.0 * j), k, fma(fma(z, (y * (18.0 * x)), (-4.0 * a)), t, (b * c)));
            	} else if (t_1 <= 0.0002) {
            		tmp = fma((-4.0 * x), i, fma(fma(-4.0, a, (((z * y) * x) * 18.0)), t, (c * b)));
            	} else if (t_1 <= 2e+211) {
            		tmp = fma(fma(-4.0, i, (((z * y) * t) * 18.0)), x, (c * b)) - t_1;
            	} else {
            		tmp = fma((-27.0 * j), k, fma(-4.0, fma(t, a, (i * x)), (b * c)));
            	}
            	return tmp;
            }
            
            x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
            x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
            function code(x, y, z, t, a, b, c, i, j, k)
            	t_1 = Float64(Float64(j * 27.0) * k)
            	tmp = 0.0
            	if (t_1 <= -0.0002)
            		tmp = fma(Float64(-27.0 * j), k, fma(fma(z, Float64(y * Float64(18.0 * x)), Float64(-4.0 * a)), t, Float64(b * c)));
            	elseif (t_1 <= 0.0002)
            		tmp = fma(Float64(-4.0 * x), i, fma(fma(-4.0, a, Float64(Float64(Float64(z * y) * x) * 18.0)), t, Float64(c * b)));
            	elseif (t_1 <= 2e+211)
            		tmp = Float64(fma(fma(-4.0, i, Float64(Float64(Float64(z * y) * t) * 18.0)), x, Float64(c * b)) - t_1);
            	else
            		tmp = fma(Float64(-27.0 * j), k, fma(-4.0, fma(t, a, Float64(i * x)), Float64(b * c)));
            	end
            	return tmp
            end
            
            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
            code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$1, -0.0002], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(z * N[(y * N[(18.0 * x), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 0.0002], N[(N[(-4.0 * x), $MachinePrecision] * i + N[(N[(-4.0 * a + N[(N[(N[(z * y), $MachinePrecision] * x), $MachinePrecision] * 18.0), $MachinePrecision]), $MachinePrecision] * t + N[(c * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e+211], N[(N[(N[(-4.0 * i + N[(N[(N[(z * y), $MachinePrecision] * t), $MachinePrecision] * 18.0), $MachinePrecision]), $MachinePrecision] * x + N[(c * b), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(-4.0 * N[(t * a + N[(i * x), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
            
            \begin{array}{l}
            [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
            [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
            \\
            \begin{array}{l}
            t_1 := \left(j \cdot 27\right) \cdot k\\
            \mathbf{if}\;t\_1 \leq -0.0002:\\
            \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, b \cdot c\right)\right)\\
            
            \mathbf{elif}\;t\_1 \leq 0.0002:\\
            \;\;\;\;\mathsf{fma}\left(-4 \cdot x, i, \mathsf{fma}\left(\mathsf{fma}\left(-4, a, \left(\left(z \cdot y\right) \cdot x\right) \cdot 18\right), t, c \cdot b\right)\right)\\
            
            \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+211}:\\
            \;\;\;\;\mathsf{fma}\left(\mathsf{fma}\left(-4, i, \left(\left(z \cdot y\right) \cdot t\right) \cdot 18\right), x, c \cdot b\right) - t\_1\\
            
            \mathbf{else}:\\
            \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 4 regimes
            2. if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -2.0000000000000001e-4

              1. Initial program 91.2%

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

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

                \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, \color{blue}{b \cdot c}\right)\right) \]
              5. Step-by-step derivation
                1. Applied rewrites91.4%

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

                if -2.0000000000000001e-4 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 2.0000000000000001e-4

                1. Initial program 86.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. Add Preprocessing
                3. Taylor expanded in j around 0

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

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

                if 2.0000000000000001e-4 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 1.9999999999999999e211

                1. Initial program 85.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. Add Preprocessing
                3. Taylor expanded in a around 0

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

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

                  if 1.9999999999999999e211 < (*.f64 (*.f64 j #s(literal 27 binary64)) k)

                  1. Initial program 77.4%

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

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

                    \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(a \cdot t\right) + \left(-4 \cdot \left(i \cdot x\right) + b \cdot c\right)}\right) \]
                  5. Step-by-step derivation
                    1. Applied rewrites94.2%

                      \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{\mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)}\right) \]
                  6. Recombined 4 regimes into one program.
                  7. Add Preprocessing

                  Alternative 6: 53.5% accurate, 0.7× speedup?

                  \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \mathsf{fma}\left(18 \cdot t, y \cdot z, i \cdot -4\right) \cdot x\\ t_2 := \left(j \cdot 27\right) \cdot k\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+36}:\\ \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\ \mathbf{elif}\;t\_2 \leq -2 \cdot 10^{-149}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 4 \cdot 10^{-146}:\\ \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\ \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+125}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \left(i \cdot x\right) \cdot -4\right)\\ \end{array} \end{array} \]
                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                  (FPCore (x y z t a b c i j k)
                   :precision binary64
                   (let* ((t_1 (* (fma (* 18.0 t) (* y z) (* i -4.0)) x)) (t_2 (* (* j 27.0) k)))
                     (if (<= t_2 -2e+36)
                       (fma b c (* (* k j) -27.0))
                       (if (<= t_2 -2e-149)
                         t_1
                         (if (<= t_2 4e-146)
                           (fma (* t a) -4.0 (* b c))
                           (if (<= t_2 2e+125) t_1 (fma (* -27.0 j) k (* (* i x) -4.0))))))))
                  assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                  assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                  double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                  	double t_1 = fma((18.0 * t), (y * z), (i * -4.0)) * x;
                  	double t_2 = (j * 27.0) * k;
                  	double tmp;
                  	if (t_2 <= -2e+36) {
                  		tmp = fma(b, c, ((k * j) * -27.0));
                  	} else if (t_2 <= -2e-149) {
                  		tmp = t_1;
                  	} else if (t_2 <= 4e-146) {
                  		tmp = fma((t * a), -4.0, (b * c));
                  	} else if (t_2 <= 2e+125) {
                  		tmp = t_1;
                  	} else {
                  		tmp = fma((-27.0 * j), k, ((i * x) * -4.0));
                  	}
                  	return tmp;
                  }
                  
                  x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                  x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                  function code(x, y, z, t, a, b, c, i, j, k)
                  	t_1 = Float64(fma(Float64(18.0 * t), Float64(y * z), Float64(i * -4.0)) * x)
                  	t_2 = Float64(Float64(j * 27.0) * k)
                  	tmp = 0.0
                  	if (t_2 <= -2e+36)
                  		tmp = fma(b, c, Float64(Float64(k * j) * -27.0));
                  	elseif (t_2 <= -2e-149)
                  		tmp = t_1;
                  	elseif (t_2 <= 4e-146)
                  		tmp = fma(Float64(t * a), -4.0, Float64(b * c));
                  	elseif (t_2 <= 2e+125)
                  		tmp = t_1;
                  	else
                  		tmp = fma(Float64(-27.0 * j), k, Float64(Float64(i * x) * -4.0));
                  	end
                  	return tmp
                  end
                  
                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                  code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(N[(18.0 * t), $MachinePrecision] * N[(y * z), $MachinePrecision] + N[(i * -4.0), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision]}, Block[{t$95$2 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+36], N[(b * c + N[(N[(k * j), $MachinePrecision] * -27.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, -2e-149], t$95$1, If[LessEqual[t$95$2, 4e-146], N[(N[(t * a), $MachinePrecision] * -4.0 + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 2e+125], t$95$1, N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(i * x), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision]]]]]]]
                  
                  \begin{array}{l}
                  [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                  [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                  \\
                  \begin{array}{l}
                  t_1 := \mathsf{fma}\left(18 \cdot t, y \cdot z, i \cdot -4\right) \cdot x\\
                  t_2 := \left(j \cdot 27\right) \cdot k\\
                  \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+36}:\\
                  \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\
                  
                  \mathbf{elif}\;t\_2 \leq -2 \cdot 10^{-149}:\\
                  \;\;\;\;t\_1\\
                  
                  \mathbf{elif}\;t\_2 \leq 4 \cdot 10^{-146}:\\
                  \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\
                  
                  \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+125}:\\
                  \;\;\;\;t\_1\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \left(i \cdot x\right) \cdot -4\right)\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 4 regimes
                  2. if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -2.00000000000000008e36

                    1. Initial program 90.0%

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

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

                        \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                      2. Taylor expanded in t around 0

                        \[\leadsto b \cdot c - \color{blue}{27 \cdot \left(j \cdot k\right)} \]
                      3. Step-by-step derivation
                        1. Applied rewrites74.5%

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

                        if -2.00000000000000008e36 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -1.99999999999999996e-149 or 4.0000000000000001e-146 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 1.9999999999999998e125

                        1. Initial program 84.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. Add Preprocessing
                        3. Applied rewrites89.0%

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

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

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

                            \[\leadsto \color{blue}{x \cdot \left(-4 \cdot i + 18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right)} \]
                          3. Step-by-step derivation
                            1. Applied rewrites59.6%

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

                            if -1.99999999999999996e-149 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 4.0000000000000001e-146

                            1. Initial program 88.9%

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

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

                                \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                              2. Taylor expanded in j around 0

                                \[\leadsto -4 \cdot \left(a \cdot t\right) + \color{blue}{b \cdot c} \]
                              3. Step-by-step derivation
                                1. Applied rewrites60.0%

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

                                if 1.9999999999999998e125 < (*.f64 (*.f64 j #s(literal 27 binary64)) k)

                                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. Add Preprocessing
                                3. Applied rewrites84.4%

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

                                  \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(i \cdot x\right)}\right) \]
                                5. Step-by-step derivation
                                  1. Applied rewrites82.4%

                                    \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{\left(i \cdot x\right) \cdot -4}\right) \]
                                6. Recombined 4 regimes into one program.
                                7. Final simplification66.5%

                                  \[\leadsto \begin{array}{l} \mathbf{if}\;\left(j \cdot 27\right) \cdot k \leq -2 \cdot 10^{+36}:\\ \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\ \mathbf{elif}\;\left(j \cdot 27\right) \cdot k \leq -2 \cdot 10^{-149}:\\ \;\;\;\;\mathsf{fma}\left(18 \cdot t, y \cdot z, i \cdot -4\right) \cdot x\\ \mathbf{elif}\;\left(j \cdot 27\right) \cdot k \leq 4 \cdot 10^{-146}:\\ \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\ \mathbf{elif}\;\left(j \cdot 27\right) \cdot k \leq 2 \cdot 10^{+125}:\\ \;\;\;\;\mathsf{fma}\left(18 \cdot t, y \cdot z, i \cdot -4\right) \cdot x\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \left(i \cdot x\right) \cdot -4\right)\\ \end{array} \]
                                8. Add Preprocessing

                                Alternative 7: 93.0% accurate, 0.8× speedup?

                                \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;x \leq -3.5 \cdot 10^{+57} \lor \neg \left(x \leq 3.8 \cdot 10^{+75}\right):\\ \;\;\;\;\mathsf{fma}\left(18 \cdot \left(t \cdot y\right), z, \frac{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27}{x} - 4 \cdot i\right) \cdot x\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, \mathsf{fma}\left(c, b, \left(-4 \cdot x\right) \cdot i\right)\right)\right)\\ \end{array} \end{array} \]
                                NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                (FPCore (x y z t a b c i j k)
                                 :precision binary64
                                 (if (or (<= x -3.5e+57) (not (<= x 3.8e+75)))
                                   (*
                                    (fma
                                     (* 18.0 (* t y))
                                     z
                                     (- (/ (- (fma -4.0 (* a t) (* c b)) (* (* k j) 27.0)) x) (* 4.0 i)))
                                    x)
                                   (fma
                                    (* -27.0 j)
                                    k
                                    (fma (fma z (* y (* 18.0 x)) (* -4.0 a)) t (fma c b (* (* -4.0 x) i))))))
                                assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                	double tmp;
                                	if ((x <= -3.5e+57) || !(x <= 3.8e+75)) {
                                		tmp = fma((18.0 * (t * y)), z, (((fma(-4.0, (a * t), (c * b)) - ((k * j) * 27.0)) / x) - (4.0 * i))) * x;
                                	} else {
                                		tmp = fma((-27.0 * j), k, fma(fma(z, (y * (18.0 * x)), (-4.0 * a)), t, fma(c, b, ((-4.0 * x) * i))));
                                	}
                                	return tmp;
                                }
                                
                                x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                function code(x, y, z, t, a, b, c, i, j, k)
                                	tmp = 0.0
                                	if ((x <= -3.5e+57) || !(x <= 3.8e+75))
                                		tmp = Float64(fma(Float64(18.0 * Float64(t * y)), z, Float64(Float64(Float64(fma(-4.0, Float64(a * t), Float64(c * b)) - Float64(Float64(k * j) * 27.0)) / x) - Float64(4.0 * i))) * x);
                                	else
                                		tmp = fma(Float64(-27.0 * j), k, fma(fma(z, Float64(y * Float64(18.0 * x)), Float64(-4.0 * a)), t, fma(c, b, Float64(Float64(-4.0 * x) * i))));
                                	end
                                	return tmp
                                end
                                
                                NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[x, -3.5e+57], N[Not[LessEqual[x, 3.8e+75]], $MachinePrecision]], N[(N[(N[(18.0 * N[(t * y), $MachinePrecision]), $MachinePrecision] * z + N[(N[(N[(N[(-4.0 * N[(a * t), $MachinePrecision] + N[(c * b), $MachinePrecision]), $MachinePrecision] - N[(N[(k * j), $MachinePrecision] * 27.0), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(z * N[(y * N[(18.0 * x), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t + N[(c * b + N[(N[(-4.0 * x), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
                                
                                \begin{array}{l}
                                [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                \\
                                \begin{array}{l}
                                \mathbf{if}\;x \leq -3.5 \cdot 10^{+57} \lor \neg \left(x \leq 3.8 \cdot 10^{+75}\right):\\
                                \;\;\;\;\mathsf{fma}\left(18 \cdot \left(t \cdot y\right), z, \frac{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27}{x} - 4 \cdot i\right) \cdot x\\
                                
                                \mathbf{else}:\\
                                \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, \mathsf{fma}\left(c, b, \left(-4 \cdot x\right) \cdot i\right)\right)\right)\\
                                
                                
                                \end{array}
                                \end{array}
                                
                                Derivation
                                1. Split input into 2 regimes
                                2. if x < -3.4999999999999997e57 or 3.8000000000000002e75 < x

                                  1. Initial program 77.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. Add Preprocessing
                                  3. Taylor expanded in x around inf

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

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

                                    if -3.4999999999999997e57 < x < 3.8000000000000002e75

                                    1. Initial program 92.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. Add Preprocessing
                                    3. Applied rewrites96.7%

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, \mathsf{fma}\left(c, b, \left(-4 \cdot x\right) \cdot i\right)\right)\right)} \]
                                  5. Recombined 2 regimes into one program.
                                  6. Final simplification93.8%

                                    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -3.5 \cdot 10^{+57} \lor \neg \left(x \leq 3.8 \cdot 10^{+75}\right):\\ \;\;\;\;\mathsf{fma}\left(18 \cdot \left(t \cdot y\right), z, \frac{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27}{x} - 4 \cdot i\right) \cdot x\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(\mathsf{fma}\left(z, y \cdot \left(18 \cdot x\right), -4 \cdot a\right), t, \mathsf{fma}\left(c, b, \left(-4 \cdot x\right) \cdot i\right)\right)\right)\\ \end{array} \]
                                  7. Add Preprocessing

                                  Alternative 8: 49.4% accurate, 1.3× speedup?

                                  \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \mathsf{fma}\left(-27 \cdot j, k, \left(i \cdot x\right) \cdot -4\right)\\ t_2 := \mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\ \mathbf{if}\;c \leq -1.45 \cdot 10^{-94}:\\ \;\;\;\;\mathsf{fma}\left(j \cdot -27, k, b \cdot c\right)\\ \mathbf{elif}\;c \leq 3.3 \cdot 10^{-190}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;c \leq 1.08 \cdot 10^{-24}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;c \leq 2.25 \cdot 10^{+45}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;c \leq 4.8 \cdot 10^{+140}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\ \end{array} \end{array} \]
                                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                  (FPCore (x y z t a b c i j k)
                                   :precision binary64
                                   (let* ((t_1 (fma (* -27.0 j) k (* (* i x) -4.0)))
                                          (t_2 (* (fma (* (* y z) x) 18.0 (* -4.0 a)) t)))
                                     (if (<= c -1.45e-94)
                                       (fma (* j -27.0) k (* b c))
                                       (if (<= c 3.3e-190)
                                         t_2
                                         (if (<= c 1.08e-24)
                                           t_1
                                           (if (<= c 2.25e+45)
                                             t_2
                                             (if (<= c 4.8e+140) t_1 (fma b c (* (* k j) -27.0)))))))))
                                  assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                  assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                  double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                  	double t_1 = fma((-27.0 * j), k, ((i * x) * -4.0));
                                  	double t_2 = fma(((y * z) * x), 18.0, (-4.0 * a)) * t;
                                  	double tmp;
                                  	if (c <= -1.45e-94) {
                                  		tmp = fma((j * -27.0), k, (b * c));
                                  	} else if (c <= 3.3e-190) {
                                  		tmp = t_2;
                                  	} else if (c <= 1.08e-24) {
                                  		tmp = t_1;
                                  	} else if (c <= 2.25e+45) {
                                  		tmp = t_2;
                                  	} else if (c <= 4.8e+140) {
                                  		tmp = t_1;
                                  	} else {
                                  		tmp = fma(b, c, ((k * j) * -27.0));
                                  	}
                                  	return tmp;
                                  }
                                  
                                  x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                  x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                  function code(x, y, z, t, a, b, c, i, j, k)
                                  	t_1 = fma(Float64(-27.0 * j), k, Float64(Float64(i * x) * -4.0))
                                  	t_2 = Float64(fma(Float64(Float64(y * z) * x), 18.0, Float64(-4.0 * a)) * t)
                                  	tmp = 0.0
                                  	if (c <= -1.45e-94)
                                  		tmp = fma(Float64(j * -27.0), k, Float64(b * c));
                                  	elseif (c <= 3.3e-190)
                                  		tmp = t_2;
                                  	elseif (c <= 1.08e-24)
                                  		tmp = t_1;
                                  	elseif (c <= 2.25e+45)
                                  		tmp = t_2;
                                  	elseif (c <= 4.8e+140)
                                  		tmp = t_1;
                                  	else
                                  		tmp = fma(b, c, Float64(Float64(k * j) * -27.0));
                                  	end
                                  	return tmp
                                  end
                                  
                                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                  code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(i * x), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(N[(y * z), $MachinePrecision] * x), $MachinePrecision] * 18.0 + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]}, If[LessEqual[c, -1.45e-94], N[(N[(j * -27.0), $MachinePrecision] * k + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 3.3e-190], t$95$2, If[LessEqual[c, 1.08e-24], t$95$1, If[LessEqual[c, 2.25e+45], t$95$2, If[LessEqual[c, 4.8e+140], t$95$1, N[(b * c + N[(N[(k * j), $MachinePrecision] * -27.0), $MachinePrecision]), $MachinePrecision]]]]]]]]
                                  
                                  \begin{array}{l}
                                  [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                  [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                  \\
                                  \begin{array}{l}
                                  t_1 := \mathsf{fma}\left(-27 \cdot j, k, \left(i \cdot x\right) \cdot -4\right)\\
                                  t_2 := \mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\
                                  \mathbf{if}\;c \leq -1.45 \cdot 10^{-94}:\\
                                  \;\;\;\;\mathsf{fma}\left(j \cdot -27, k, b \cdot c\right)\\
                                  
                                  \mathbf{elif}\;c \leq 3.3 \cdot 10^{-190}:\\
                                  \;\;\;\;t\_2\\
                                  
                                  \mathbf{elif}\;c \leq 1.08 \cdot 10^{-24}:\\
                                  \;\;\;\;t\_1\\
                                  
                                  \mathbf{elif}\;c \leq 2.25 \cdot 10^{+45}:\\
                                  \;\;\;\;t\_2\\
                                  
                                  \mathbf{elif}\;c \leq 4.8 \cdot 10^{+140}:\\
                                  \;\;\;\;t\_1\\
                                  
                                  \mathbf{else}:\\
                                  \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\
                                  
                                  
                                  \end{array}
                                  \end{array}
                                  
                                  Derivation
                                  1. Split input into 4 regimes
                                  2. if c < -1.44999999999999998e-94

                                    1. Initial program 87.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. Add Preprocessing
                                    3. Taylor expanded in b around inf

                                      \[\leadsto \color{blue}{b \cdot c} - \left(j \cdot 27\right) \cdot k \]
                                    4. Step-by-step derivation
                                      1. Applied rewrites57.7%

                                        \[\leadsto \color{blue}{c \cdot b} - \left(j \cdot 27\right) \cdot k \]
                                      2. Step-by-step derivation
                                        1. lift--.f64N/A

                                          \[\leadsto \color{blue}{c \cdot b - \left(j \cdot 27\right) \cdot k} \]
                                        2. lift-*.f64N/A

                                          \[\leadsto c \cdot b - \color{blue}{\left(j \cdot 27\right) \cdot k} \]
                                        3. fp-cancel-sub-sign-invN/A

                                          \[\leadsto \color{blue}{c \cdot b + \left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k} \]
                                        4. +-commutativeN/A

                                          \[\leadsto \color{blue}{\left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k + c \cdot b} \]
                                        5. lift-*.f64N/A

                                          \[\leadsto \left(\mathsf{neg}\left(\color{blue}{j \cdot 27}\right)\right) \cdot k + c \cdot b \]
                                        6. *-commutativeN/A

                                          \[\leadsto \left(\mathsf{neg}\left(\color{blue}{27 \cdot j}\right)\right) \cdot k + c \cdot b \]
                                        7. distribute-lft-neg-inN/A

                                          \[\leadsto \color{blue}{\left(\left(\mathsf{neg}\left(27\right)\right) \cdot j\right)} \cdot k + c \cdot b \]
                                        8. metadata-evalN/A

                                          \[\leadsto \left(\color{blue}{-27} \cdot j\right) \cdot k + c \cdot b \]
                                        9. lift-*.f64N/A

                                          \[\leadsto \color{blue}{\left(-27 \cdot j\right)} \cdot k + c \cdot b \]
                                        10. lower-fma.f6458.9

                                          \[\leadsto \color{blue}{\mathsf{fma}\left(-27 \cdot j, k, c \cdot b\right)} \]
                                        11. lift-*.f64N/A

                                          \[\leadsto \mathsf{fma}\left(\color{blue}{-27 \cdot j}, k, c \cdot b\right) \]
                                        12. *-commutativeN/A

                                          \[\leadsto \mathsf{fma}\left(\color{blue}{j \cdot -27}, k, c \cdot b\right) \]
                                        13. lower-*.f6458.9

                                          \[\leadsto \mathsf{fma}\left(\color{blue}{j \cdot -27}, k, c \cdot b\right) \]
                                      3. Applied rewrites58.9%

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

                                      if -1.44999999999999998e-94 < c < 3.30000000000000019e-190 or 1.08000000000000006e-24 < c < 2.2499999999999999e45

                                      1. Initial program 89.0%

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

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

                                        \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
                                      5. Step-by-step derivation
                                        1. Applied rewrites56.4%

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

                                        if 3.30000000000000019e-190 < c < 1.08000000000000006e-24 or 2.2499999999999999e45 < c < 4.7999999999999999e140

                                        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. Add Preprocessing
                                        3. Applied rewrites84.8%

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

                                          \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(i \cdot x\right)}\right) \]
                                        5. Step-by-step derivation
                                          1. Applied rewrites65.3%

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

                                          if 4.7999999999999999e140 < c

                                          1. Initial program 78.7%

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

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

                                              \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                                            2. Taylor expanded in t around 0

                                              \[\leadsto b \cdot c - \color{blue}{27 \cdot \left(j \cdot k\right)} \]
                                            3. Step-by-step derivation
                                              1. Applied rewrites75.5%

                                                \[\leadsto \mathsf{fma}\left(b, \color{blue}{c}, \left(k \cdot j\right) \cdot -27\right) \]
                                            4. Recombined 4 regimes into one program.
                                            5. Add Preprocessing

                                            Alternative 9: 69.4% accurate, 1.4× speedup?

                                            \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1 \cdot 10^{+214}:\\ \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\ \mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+165}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(i, x, t \cdot a\right) \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(k \cdot -27, j, b \cdot c\right)\\ \end{array} \end{array} \]
                                            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                            (FPCore (x y z t a b c i j k)
                                             :precision binary64
                                             (if (<= (* b c) -1e+214)
                                               (fma (* t a) -4.0 (* b c))
                                               (if (<= (* b c) 2e+165)
                                                 (fma (* -27.0 j) k (* (fma i x (* t a)) -4.0))
                                                 (fma (* k -27.0) j (* b c)))))
                                            assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                            assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                            double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                            	double tmp;
                                            	if ((b * c) <= -1e+214) {
                                            		tmp = fma((t * a), -4.0, (b * c));
                                            	} else if ((b * c) <= 2e+165) {
                                            		tmp = fma((-27.0 * j), k, (fma(i, x, (t * a)) * -4.0));
                                            	} else {
                                            		tmp = fma((k * -27.0), j, (b * c));
                                            	}
                                            	return tmp;
                                            }
                                            
                                            x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                            x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                            function code(x, y, z, t, a, b, c, i, j, k)
                                            	tmp = 0.0
                                            	if (Float64(b * c) <= -1e+214)
                                            		tmp = fma(Float64(t * a), -4.0, Float64(b * c));
                                            	elseif (Float64(b * c) <= 2e+165)
                                            		tmp = fma(Float64(-27.0 * j), k, Float64(fma(i, x, Float64(t * a)) * -4.0));
                                            	else
                                            		tmp = fma(Float64(k * -27.0), j, Float64(b * c));
                                            	end
                                            	return tmp
                                            end
                                            
                                            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                            code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -1e+214], N[(N[(t * a), $MachinePrecision] * -4.0 + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2e+165], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(i * x + N[(t * a), $MachinePrecision]), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision], N[(N[(k * -27.0), $MachinePrecision] * j + N[(b * c), $MachinePrecision]), $MachinePrecision]]]
                                            
                                            \begin{array}{l}
                                            [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                            [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                            \\
                                            \begin{array}{l}
                                            \mathbf{if}\;b \cdot c \leq -1 \cdot 10^{+214}:\\
                                            \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\
                                            
                                            \mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+165}:\\
                                            \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(i, x, t \cdot a\right) \cdot -4\right)\\
                                            
                                            \mathbf{else}:\\
                                            \;\;\;\;\mathsf{fma}\left(k \cdot -27, j, b \cdot c\right)\\
                                            
                                            
                                            \end{array}
                                            \end{array}
                                            
                                            Derivation
                                            1. Split input into 3 regimes
                                            2. if (*.f64 b c) < -9.9999999999999995e213

                                              1. Initial program 72.4%

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

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

                                                  \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                                                2. Taylor expanded in j around 0

                                                  \[\leadsto -4 \cdot \left(a \cdot t\right) + \color{blue}{b \cdot c} \]
                                                3. Step-by-step derivation
                                                  1. Applied rewrites89.7%

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

                                                  if -9.9999999999999995e213 < (*.f64 b c) < 1.9999999999999998e165

                                                  1. Initial program 88.7%

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

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

                                                    \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(a \cdot t\right) + \left(-4 \cdot \left(i \cdot x\right) + b \cdot c\right)}\right) \]
                                                  5. Step-by-step derivation
                                                    1. Applied rewrites78.7%

                                                      \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{\mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)}\right) \]
                                                    2. Taylor expanded in b around 0

                                                      \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, -4 \cdot \color{blue}{\left(a \cdot t + i \cdot x\right)}\right) \]
                                                    3. Step-by-step derivation
                                                      1. Applied rewrites73.4%

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

                                                      if 1.9999999999999998e165 < (*.f64 b c)

                                                      1. Initial program 81.8%

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

                                                        \[\leadsto \color{blue}{b \cdot c} - \left(j \cdot 27\right) \cdot k \]
                                                      4. Step-by-step derivation
                                                        1. Applied rewrites77.1%

                                                          \[\leadsto \color{blue}{c \cdot b} - \left(j \cdot 27\right) \cdot k \]
                                                        2. Step-by-step derivation
                                                          1. lift--.f64N/A

                                                            \[\leadsto \color{blue}{c \cdot b - \left(j \cdot 27\right) \cdot k} \]
                                                          2. lift-*.f64N/A

                                                            \[\leadsto c \cdot b - \color{blue}{\left(j \cdot 27\right) \cdot k} \]
                                                          3. fp-cancel-sub-sign-invN/A

                                                            \[\leadsto \color{blue}{c \cdot b + \left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k} \]
                                                          4. +-commutativeN/A

                                                            \[\leadsto \color{blue}{\left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k + c \cdot b} \]
                                                          5. lift-*.f64N/A

                                                            \[\leadsto \left(\mathsf{neg}\left(\color{blue}{j \cdot 27}\right)\right) \cdot k + c \cdot b \]
                                                          6. *-commutativeN/A

                                                            \[\leadsto \left(\mathsf{neg}\left(\color{blue}{27 \cdot j}\right)\right) \cdot k + c \cdot b \]
                                                          7. distribute-lft-neg-inN/A

                                                            \[\leadsto \color{blue}{\left(\left(\mathsf{neg}\left(27\right)\right) \cdot j\right)} \cdot k + c \cdot b \]
                                                          8. metadata-evalN/A

                                                            \[\leadsto \left(\color{blue}{-27} \cdot j\right) \cdot k + c \cdot b \]
                                                          9. lift-*.f64N/A

                                                            \[\leadsto \color{blue}{\left(-27 \cdot j\right)} \cdot k + c \cdot b \]
                                                          10. *-commutativeN/A

                                                            \[\leadsto \color{blue}{k \cdot \left(-27 \cdot j\right)} + c \cdot b \]
                                                          11. lift-*.f64N/A

                                                            \[\leadsto k \cdot \color{blue}{\left(-27 \cdot j\right)} + c \cdot b \]
                                                          12. associate-*r*N/A

                                                            \[\leadsto \color{blue}{\left(k \cdot -27\right) \cdot j} + c \cdot b \]
                                                          13. lower-fma.f64N/A

                                                            \[\leadsto \color{blue}{\mathsf{fma}\left(k \cdot -27, j, c \cdot b\right)} \]
                                                        3. Applied rewrites80.1%

                                                          \[\leadsto \color{blue}{\mathsf{fma}\left(k \cdot -27, j, b \cdot c\right)} \]
                                                      5. Recombined 3 regimes into one program.
                                                      6. Add Preprocessing

                                                      Alternative 10: 54.3% accurate, 1.5× speedup?

                                                      \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1 \cdot 10^{+214}:\\ \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\ \mathbf{elif}\;b \cdot c \leq 5 \cdot 10^{+100}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \left(i \cdot x\right) \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(j \cdot -27, k, b \cdot c\right)\\ \end{array} \end{array} \]
                                                      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                      (FPCore (x y z t a b c i j k)
                                                       :precision binary64
                                                       (if (<= (* b c) -1e+214)
                                                         (fma (* t a) -4.0 (* b c))
                                                         (if (<= (* b c) 5e+100)
                                                           (fma (* -27.0 j) k (* (* i x) -4.0))
                                                           (fma (* j -27.0) k (* b c)))))
                                                      assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                      assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                      double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                      	double tmp;
                                                      	if ((b * c) <= -1e+214) {
                                                      		tmp = fma((t * a), -4.0, (b * c));
                                                      	} else if ((b * c) <= 5e+100) {
                                                      		tmp = fma((-27.0 * j), k, ((i * x) * -4.0));
                                                      	} else {
                                                      		tmp = fma((j * -27.0), k, (b * c));
                                                      	}
                                                      	return tmp;
                                                      }
                                                      
                                                      x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                      x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                      function code(x, y, z, t, a, b, c, i, j, k)
                                                      	tmp = 0.0
                                                      	if (Float64(b * c) <= -1e+214)
                                                      		tmp = fma(Float64(t * a), -4.0, Float64(b * c));
                                                      	elseif (Float64(b * c) <= 5e+100)
                                                      		tmp = fma(Float64(-27.0 * j), k, Float64(Float64(i * x) * -4.0));
                                                      	else
                                                      		tmp = fma(Float64(j * -27.0), k, Float64(b * c));
                                                      	end
                                                      	return tmp
                                                      end
                                                      
                                                      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                      code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -1e+214], N[(N[(t * a), $MachinePrecision] * -4.0 + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 5e+100], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(i * x), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision], N[(N[(j * -27.0), $MachinePrecision] * k + N[(b * c), $MachinePrecision]), $MachinePrecision]]]
                                                      
                                                      \begin{array}{l}
                                                      [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                      [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                      \\
                                                      \begin{array}{l}
                                                      \mathbf{if}\;b \cdot c \leq -1 \cdot 10^{+214}:\\
                                                      \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\
                                                      
                                                      \mathbf{elif}\;b \cdot c \leq 5 \cdot 10^{+100}:\\
                                                      \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \left(i \cdot x\right) \cdot -4\right)\\
                                                      
                                                      \mathbf{else}:\\
                                                      \;\;\;\;\mathsf{fma}\left(j \cdot -27, k, b \cdot c\right)\\
                                                      
                                                      
                                                      \end{array}
                                                      \end{array}
                                                      
                                                      Derivation
                                                      1. Split input into 3 regimes
                                                      2. if (*.f64 b c) < -9.9999999999999995e213

                                                        1. Initial program 72.4%

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

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

                                                            \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                                                          2. Taylor expanded in j around 0

                                                            \[\leadsto -4 \cdot \left(a \cdot t\right) + \color{blue}{b \cdot c} \]
                                                          3. Step-by-step derivation
                                                            1. Applied rewrites89.7%

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

                                                            if -9.9999999999999995e213 < (*.f64 b c) < 4.9999999999999999e100

                                                            1. Initial program 89.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. Add Preprocessing
                                                            3. Applied rewrites91.9%

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

                                                              \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(i \cdot x\right)}\right) \]
                                                            5. Step-by-step derivation
                                                              1. Applied rewrites55.3%

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

                                                              if 4.9999999999999999e100 < (*.f64 b c)

                                                              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. Add Preprocessing
                                                              3. Taylor expanded in b around inf

                                                                \[\leadsto \color{blue}{b \cdot c} - \left(j \cdot 27\right) \cdot k \]
                                                              4. Step-by-step derivation
                                                                1. Applied rewrites69.9%

                                                                  \[\leadsto \color{blue}{c \cdot b} - \left(j \cdot 27\right) \cdot k \]
                                                                2. Step-by-step derivation
                                                                  1. lift--.f64N/A

                                                                    \[\leadsto \color{blue}{c \cdot b - \left(j \cdot 27\right) \cdot k} \]
                                                                  2. lift-*.f64N/A

                                                                    \[\leadsto c \cdot b - \color{blue}{\left(j \cdot 27\right) \cdot k} \]
                                                                  3. fp-cancel-sub-sign-invN/A

                                                                    \[\leadsto \color{blue}{c \cdot b + \left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k} \]
                                                                  4. +-commutativeN/A

                                                                    \[\leadsto \color{blue}{\left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k + c \cdot b} \]
                                                                  5. lift-*.f64N/A

                                                                    \[\leadsto \left(\mathsf{neg}\left(\color{blue}{j \cdot 27}\right)\right) \cdot k + c \cdot b \]
                                                                  6. *-commutativeN/A

                                                                    \[\leadsto \left(\mathsf{neg}\left(\color{blue}{27 \cdot j}\right)\right) \cdot k + c \cdot b \]
                                                                  7. distribute-lft-neg-inN/A

                                                                    \[\leadsto \color{blue}{\left(\left(\mathsf{neg}\left(27\right)\right) \cdot j\right)} \cdot k + c \cdot b \]
                                                                  8. metadata-evalN/A

                                                                    \[\leadsto \left(\color{blue}{-27} \cdot j\right) \cdot k + c \cdot b \]
                                                                  9. lift-*.f64N/A

                                                                    \[\leadsto \color{blue}{\left(-27 \cdot j\right)} \cdot k + c \cdot b \]
                                                                  10. lower-fma.f6472.1

                                                                    \[\leadsto \color{blue}{\mathsf{fma}\left(-27 \cdot j, k, c \cdot b\right)} \]
                                                                  11. lift-*.f64N/A

                                                                    \[\leadsto \mathsf{fma}\left(\color{blue}{-27 \cdot j}, k, c \cdot b\right) \]
                                                                  12. *-commutativeN/A

                                                                    \[\leadsto \mathsf{fma}\left(\color{blue}{j \cdot -27}, k, c \cdot b\right) \]
                                                                  13. lower-*.f6472.1

                                                                    \[\leadsto \mathsf{fma}\left(\color{blue}{j \cdot -27}, k, c \cdot b\right) \]
                                                                3. Applied rewrites72.1%

                                                                  \[\leadsto \color{blue}{\mathsf{fma}\left(j \cdot -27, k, b \cdot c\right)} \]
                                                              5. Recombined 3 regimes into one program.
                                                              6. Add Preprocessing

                                                              Alternative 11: 36.6% accurate, 1.6× speedup?

                                                              \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \left(j \cdot 27\right) \cdot k\\ \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+89} \lor \neg \left(t\_1 \leq 2 \cdot 10^{+65}\right):\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;c \cdot b\\ \end{array} \end{array} \]
                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                              (FPCore (x y z t a b c i j k)
                                                               :precision binary64
                                                               (let* ((t_1 (* (* j 27.0) k)))
                                                                 (if (or (<= t_1 -1e+89) (not (<= t_1 2e+65))) (* k (* j -27.0)) (* c b))))
                                                              assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                              assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                              double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                              	double t_1 = (j * 27.0) * k;
                                                              	double tmp;
                                                              	if ((t_1 <= -1e+89) || !(t_1 <= 2e+65)) {
                                                              		tmp = k * (j * -27.0);
                                                              	} else {
                                                              		tmp = c * b;
                                                              	}
                                                              	return tmp;
                                                              }
                                                              
                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                              module fmin_fmax_functions
                                                                  implicit none
                                                                  private
                                                                  public fmax
                                                                  public fmin
                                                              
                                                                  interface fmax
                                                                      module procedure fmax88
                                                                      module procedure fmax44
                                                                      module procedure fmax84
                                                                      module procedure fmax48
                                                                  end interface
                                                                  interface fmin
                                                                      module procedure fmin88
                                                                      module procedure fmin44
                                                                      module procedure fmin84
                                                                      module procedure fmin48
                                                                  end interface
                                                              contains
                                                                  real(8) function fmax88(x, y) result (res)
                                                                      real(8), intent (in) :: x
                                                                      real(8), intent (in) :: y
                                                                      res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                  end function
                                                                  real(4) function fmax44(x, y) result (res)
                                                                      real(4), intent (in) :: x
                                                                      real(4), intent (in) :: y
                                                                      res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                  end function
                                                                  real(8) function fmax84(x, y) result(res)
                                                                      real(8), intent (in) :: x
                                                                      real(4), intent (in) :: y
                                                                      res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                  end function
                                                                  real(8) function fmax48(x, y) result(res)
                                                                      real(4), intent (in) :: x
                                                                      real(8), intent (in) :: y
                                                                      res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                  end function
                                                                  real(8) function fmin88(x, y) result (res)
                                                                      real(8), intent (in) :: x
                                                                      real(8), intent (in) :: y
                                                                      res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                  end function
                                                                  real(4) function fmin44(x, y) result (res)
                                                                      real(4), intent (in) :: x
                                                                      real(4), intent (in) :: y
                                                                      res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                  end function
                                                                  real(8) function fmin84(x, y) result(res)
                                                                      real(8), intent (in) :: x
                                                                      real(4), intent (in) :: y
                                                                      res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                  end function
                                                                  real(8) function fmin48(x, y) result(res)
                                                                      real(4), intent (in) :: x
                                                                      real(8), intent (in) :: y
                                                                      res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                  end function
                                                              end module
                                                              
                                                              real(8) function code(x, y, z, t, a, b, c, i, j, k)
                                                              use fmin_fmax_functions
                                                                  real(8), intent (in) :: x
                                                                  real(8), intent (in) :: y
                                                                  real(8), intent (in) :: z
                                                                  real(8), intent (in) :: t
                                                                  real(8), intent (in) :: a
                                                                  real(8), intent (in) :: b
                                                                  real(8), intent (in) :: c
                                                                  real(8), intent (in) :: i
                                                                  real(8), intent (in) :: j
                                                                  real(8), intent (in) :: k
                                                                  real(8) :: t_1
                                                                  real(8) :: tmp
                                                                  t_1 = (j * 27.0d0) * k
                                                                  if ((t_1 <= (-1d+89)) .or. (.not. (t_1 <= 2d+65))) then
                                                                      tmp = k * (j * (-27.0d0))
                                                                  else
                                                                      tmp = c * b
                                                                  end if
                                                                  code = tmp
                                                              end function
                                                              
                                                              assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
                                                              assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
                                                              public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                              	double t_1 = (j * 27.0) * k;
                                                              	double tmp;
                                                              	if ((t_1 <= -1e+89) || !(t_1 <= 2e+65)) {
                                                              		tmp = k * (j * -27.0);
                                                              	} else {
                                                              		tmp = c * b;
                                                              	}
                                                              	return tmp;
                                                              }
                                                              
                                                              [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
                                                              [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
                                                              def code(x, y, z, t, a, b, c, i, j, k):
                                                              	t_1 = (j * 27.0) * k
                                                              	tmp = 0
                                                              	if (t_1 <= -1e+89) or not (t_1 <= 2e+65):
                                                              		tmp = k * (j * -27.0)
                                                              	else:
                                                              		tmp = c * b
                                                              	return tmp
                                                              
                                                              x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                              x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                              function code(x, y, z, t, a, b, c, i, j, k)
                                                              	t_1 = Float64(Float64(j * 27.0) * k)
                                                              	tmp = 0.0
                                                              	if ((t_1 <= -1e+89) || !(t_1 <= 2e+65))
                                                              		tmp = Float64(k * Float64(j * -27.0));
                                                              	else
                                                              		tmp = Float64(c * b);
                                                              	end
                                                              	return tmp
                                                              end
                                                              
                                                              x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
                                                              x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
                                                              function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
                                                              	t_1 = (j * 27.0) * k;
                                                              	tmp = 0.0;
                                                              	if ((t_1 <= -1e+89) || ~((t_1 <= 2e+65)))
                                                              		tmp = k * (j * -27.0);
                                                              	else
                                                              		tmp = c * b;
                                                              	end
                                                              	tmp_2 = tmp;
                                                              end
                                                              
                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                              code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -1e+89], N[Not[LessEqual[t$95$1, 2e+65]], $MachinePrecision]], N[(k * N[(j * -27.0), $MachinePrecision]), $MachinePrecision], N[(c * b), $MachinePrecision]]]
                                                              
                                                              \begin{array}{l}
                                                              [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                              [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                              \\
                                                              \begin{array}{l}
                                                              t_1 := \left(j \cdot 27\right) \cdot k\\
                                                              \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+89} \lor \neg \left(t\_1 \leq 2 \cdot 10^{+65}\right):\\
                                                              \;\;\;\;k \cdot \left(j \cdot -27\right)\\
                                                              
                                                              \mathbf{else}:\\
                                                              \;\;\;\;c \cdot b\\
                                                              
                                                              
                                                              \end{array}
                                                              \end{array}
                                                              
                                                              Derivation
                                                              1. Split input into 2 regimes
                                                              2. if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -9.99999999999999995e88 or 2e65 < (*.f64 (*.f64 j #s(literal 27 binary64)) k)

                                                                1. Initial program 83.7%

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

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

                                                                    \[\leadsto \color{blue}{-27 \cdot \left(k \cdot j\right)} \]
                                                                  2. Step-by-step derivation
                                                                    1. Applied rewrites62.4%

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

                                                                    if -9.99999999999999995e88 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 2e65

                                                                    1. Initial program 87.4%

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

                                                                      \[\leadsto \color{blue}{b \cdot c} \]
                                                                    4. Step-by-step derivation
                                                                      1. Applied rewrites30.0%

                                                                        \[\leadsto \color{blue}{c \cdot b} \]
                                                                    5. Recombined 2 regimes into one program.
                                                                    6. Final simplification42.2%

                                                                      \[\leadsto \begin{array}{l} \mathbf{if}\;\left(j \cdot 27\right) \cdot k \leq -1 \cdot 10^{+89} \lor \neg \left(\left(j \cdot 27\right) \cdot k \leq 2 \cdot 10^{+65}\right):\\ \;\;\;\;k \cdot \left(j \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;c \cdot b\\ \end{array} \]
                                                                    7. Add Preprocessing

                                                                    Alternative 12: 36.6% accurate, 1.6× speedup?

                                                                    \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} t_1 := \left(j \cdot 27\right) \cdot k\\ \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+89} \lor \neg \left(t\_1 \leq 2 \cdot 10^{+65}\right):\\ \;\;\;\;-27 \cdot \left(k \cdot j\right)\\ \mathbf{else}:\\ \;\;\;\;c \cdot b\\ \end{array} \end{array} \]
                                                                    NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                    NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                    (FPCore (x y z t a b c i j k)
                                                                     :precision binary64
                                                                     (let* ((t_1 (* (* j 27.0) k)))
                                                                       (if (or (<= t_1 -1e+89) (not (<= t_1 2e+65))) (* -27.0 (* k j)) (* c b))))
                                                                    assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                    assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                    double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                    	double t_1 = (j * 27.0) * k;
                                                                    	double tmp;
                                                                    	if ((t_1 <= -1e+89) || !(t_1 <= 2e+65)) {
                                                                    		tmp = -27.0 * (k * j);
                                                                    	} else {
                                                                    		tmp = c * b;
                                                                    	}
                                                                    	return tmp;
                                                                    }
                                                                    
                                                                    NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                    NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                    module fmin_fmax_functions
                                                                        implicit none
                                                                        private
                                                                        public fmax
                                                                        public fmin
                                                                    
                                                                        interface fmax
                                                                            module procedure fmax88
                                                                            module procedure fmax44
                                                                            module procedure fmax84
                                                                            module procedure fmax48
                                                                        end interface
                                                                        interface fmin
                                                                            module procedure fmin88
                                                                            module procedure fmin44
                                                                            module procedure fmin84
                                                                            module procedure fmin48
                                                                        end interface
                                                                    contains
                                                                        real(8) function fmax88(x, y) result (res)
                                                                            real(8), intent (in) :: x
                                                                            real(8), intent (in) :: y
                                                                            res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                        end function
                                                                        real(4) function fmax44(x, y) result (res)
                                                                            real(4), intent (in) :: x
                                                                            real(4), intent (in) :: y
                                                                            res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                        end function
                                                                        real(8) function fmax84(x, y) result(res)
                                                                            real(8), intent (in) :: x
                                                                            real(4), intent (in) :: y
                                                                            res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                        end function
                                                                        real(8) function fmax48(x, y) result(res)
                                                                            real(4), intent (in) :: x
                                                                            real(8), intent (in) :: y
                                                                            res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                        end function
                                                                        real(8) function fmin88(x, y) result (res)
                                                                            real(8), intent (in) :: x
                                                                            real(8), intent (in) :: y
                                                                            res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                        end function
                                                                        real(4) function fmin44(x, y) result (res)
                                                                            real(4), intent (in) :: x
                                                                            real(4), intent (in) :: y
                                                                            res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                        end function
                                                                        real(8) function fmin84(x, y) result(res)
                                                                            real(8), intent (in) :: x
                                                                            real(4), intent (in) :: y
                                                                            res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                        end function
                                                                        real(8) function fmin48(x, y) result(res)
                                                                            real(4), intent (in) :: x
                                                                            real(8), intent (in) :: y
                                                                            res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                        end function
                                                                    end module
                                                                    
                                                                    real(8) function code(x, y, z, t, a, b, c, i, j, k)
                                                                    use fmin_fmax_functions
                                                                        real(8), intent (in) :: x
                                                                        real(8), intent (in) :: y
                                                                        real(8), intent (in) :: z
                                                                        real(8), intent (in) :: t
                                                                        real(8), intent (in) :: a
                                                                        real(8), intent (in) :: b
                                                                        real(8), intent (in) :: c
                                                                        real(8), intent (in) :: i
                                                                        real(8), intent (in) :: j
                                                                        real(8), intent (in) :: k
                                                                        real(8) :: t_1
                                                                        real(8) :: tmp
                                                                        t_1 = (j * 27.0d0) * k
                                                                        if ((t_1 <= (-1d+89)) .or. (.not. (t_1 <= 2d+65))) then
                                                                            tmp = (-27.0d0) * (k * j)
                                                                        else
                                                                            tmp = c * b
                                                                        end if
                                                                        code = tmp
                                                                    end function
                                                                    
                                                                    assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
                                                                    assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
                                                                    public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                    	double t_1 = (j * 27.0) * k;
                                                                    	double tmp;
                                                                    	if ((t_1 <= -1e+89) || !(t_1 <= 2e+65)) {
                                                                    		tmp = -27.0 * (k * j);
                                                                    	} else {
                                                                    		tmp = c * b;
                                                                    	}
                                                                    	return tmp;
                                                                    }
                                                                    
                                                                    [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
                                                                    [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
                                                                    def code(x, y, z, t, a, b, c, i, j, k):
                                                                    	t_1 = (j * 27.0) * k
                                                                    	tmp = 0
                                                                    	if (t_1 <= -1e+89) or not (t_1 <= 2e+65):
                                                                    		tmp = -27.0 * (k * j)
                                                                    	else:
                                                                    		tmp = c * b
                                                                    	return tmp
                                                                    
                                                                    x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                    x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                    function code(x, y, z, t, a, b, c, i, j, k)
                                                                    	t_1 = Float64(Float64(j * 27.0) * k)
                                                                    	tmp = 0.0
                                                                    	if ((t_1 <= -1e+89) || !(t_1 <= 2e+65))
                                                                    		tmp = Float64(-27.0 * Float64(k * j));
                                                                    	else
                                                                    		tmp = Float64(c * b);
                                                                    	end
                                                                    	return tmp
                                                                    end
                                                                    
                                                                    x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
                                                                    x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
                                                                    function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
                                                                    	t_1 = (j * 27.0) * k;
                                                                    	tmp = 0.0;
                                                                    	if ((t_1 <= -1e+89) || ~((t_1 <= 2e+65)))
                                                                    		tmp = -27.0 * (k * j);
                                                                    	else
                                                                    		tmp = c * b;
                                                                    	end
                                                                    	tmp_2 = tmp;
                                                                    end
                                                                    
                                                                    NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                    NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                    code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := Block[{t$95$1 = N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -1e+89], N[Not[LessEqual[t$95$1, 2e+65]], $MachinePrecision]], N[(-27.0 * N[(k * j), $MachinePrecision]), $MachinePrecision], N[(c * b), $MachinePrecision]]]
                                                                    
                                                                    \begin{array}{l}
                                                                    [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                    [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                    \\
                                                                    \begin{array}{l}
                                                                    t_1 := \left(j \cdot 27\right) \cdot k\\
                                                                    \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+89} \lor \neg \left(t\_1 \leq 2 \cdot 10^{+65}\right):\\
                                                                    \;\;\;\;-27 \cdot \left(k \cdot j\right)\\
                                                                    
                                                                    \mathbf{else}:\\
                                                                    \;\;\;\;c \cdot b\\
                                                                    
                                                                    
                                                                    \end{array}
                                                                    \end{array}
                                                                    
                                                                    Derivation
                                                                    1. Split input into 2 regimes
                                                                    2. if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -9.99999999999999995e88 or 2e65 < (*.f64 (*.f64 j #s(literal 27 binary64)) k)

                                                                      1. Initial program 83.7%

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

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

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

                                                                        if -9.99999999999999995e88 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 2e65

                                                                        1. Initial program 87.4%

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

                                                                          \[\leadsto \color{blue}{b \cdot c} \]
                                                                        4. Step-by-step derivation
                                                                          1. Applied rewrites30.0%

                                                                            \[\leadsto \color{blue}{c \cdot b} \]
                                                                        5. Recombined 2 regimes into one program.
                                                                        6. Final simplification42.1%

                                                                          \[\leadsto \begin{array}{l} \mathbf{if}\;\left(j \cdot 27\right) \cdot k \leq -1 \cdot 10^{+89} \lor \neg \left(\left(j \cdot 27\right) \cdot k \leq 2 \cdot 10^{+65}\right):\\ \;\;\;\;-27 \cdot \left(k \cdot j\right)\\ \mathbf{else}:\\ \;\;\;\;c \cdot b\\ \end{array} \]
                                                                        7. Add Preprocessing

                                                                        Alternative 13: 78.5% accurate, 1.6× speedup?

                                                                        \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 3 \cdot 10^{+55}:\\ \;\;\;\;\mathsf{fma}\left(c, b, -4 \cdot \mathsf{fma}\left(i, x, a \cdot t\right)\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\ \end{array} \end{array} \]
                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                        (FPCore (x y z t a b c i j k)
                                                                         :precision binary64
                                                                         (if (<= y 3e+55)
                                                                           (- (fma c b (* -4.0 (fma i x (* a t)))) (* (* j 27.0) k))
                                                                           (* (fma (* (* y z) x) 18.0 (* -4.0 a)) t)))
                                                                        assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                        assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                        double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                        	double tmp;
                                                                        	if (y <= 3e+55) {
                                                                        		tmp = fma(c, b, (-4.0 * fma(i, x, (a * t)))) - ((j * 27.0) * k);
                                                                        	} else {
                                                                        		tmp = fma(((y * z) * x), 18.0, (-4.0 * a)) * t;
                                                                        	}
                                                                        	return tmp;
                                                                        }
                                                                        
                                                                        x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                        x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                        function code(x, y, z, t, a, b, c, i, j, k)
                                                                        	tmp = 0.0
                                                                        	if (y <= 3e+55)
                                                                        		tmp = Float64(fma(c, b, Float64(-4.0 * fma(i, x, Float64(a * t)))) - Float64(Float64(j * 27.0) * k));
                                                                        	else
                                                                        		tmp = Float64(fma(Float64(Float64(y * z) * x), 18.0, Float64(-4.0 * a)) * t);
                                                                        	end
                                                                        	return tmp
                                                                        end
                                                                        
                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                        code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[y, 3e+55], N[(N[(c * b + N[(-4.0 * N[(i * x + N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(y * z), $MachinePrecision] * x), $MachinePrecision] * 18.0 + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]]
                                                                        
                                                                        \begin{array}{l}
                                                                        [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                        [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                        \\
                                                                        \begin{array}{l}
                                                                        \mathbf{if}\;y \leq 3 \cdot 10^{+55}:\\
                                                                        \;\;\;\;\mathsf{fma}\left(c, b, -4 \cdot \mathsf{fma}\left(i, x, a \cdot t\right)\right) - \left(j \cdot 27\right) \cdot k\\
                                                                        
                                                                        \mathbf{else}:\\
                                                                        \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\
                                                                        
                                                                        
                                                                        \end{array}
                                                                        \end{array}
                                                                        
                                                                        Derivation
                                                                        1. Split input into 2 regimes
                                                                        2. if y < 3.00000000000000017e55

                                                                          1. Initial program 88.9%

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

                                                                            \[\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 \]
                                                                          4. Step-by-step derivation
                                                                            1. Applied rewrites84.1%

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

                                                                            if 3.00000000000000017e55 < y

                                                                            1. Initial program 76.0%

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

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

                                                                              \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
                                                                            5. Step-by-step derivation
                                                                              1. Applied rewrites53.9%

                                                                                \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t} \]
                                                                            6. Recombined 2 regimes into one program.
                                                                            7. Add Preprocessing

                                                                            Alternative 14: 70.7% accurate, 1.7× speedup?

                                                                            \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+109}:\\ \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\ \mathbf{elif}\;t \leq 0.018:\\ \;\;\;\;\mathsf{fma}\left(k \cdot -27, j, \mathsf{fma}\left(i \cdot -4, x, b \cdot c\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(t, a, i \cdot x\right) \cdot -4\right)\\ \end{array} \end{array} \]
                                                                            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                            (FPCore (x y z t a b c i j k)
                                                                             :precision binary64
                                                                             (if (<= t -2.7e+109)
                                                                               (* (fma (* (* y z) x) 18.0 (* -4.0 a)) t)
                                                                               (if (<= t 0.018)
                                                                                 (fma (* k -27.0) j (fma (* i -4.0) x (* b c)))
                                                                                 (fma (* -27.0 j) k (* (fma t a (* i x)) -4.0)))))
                                                                            assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                            assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                            double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                            	double tmp;
                                                                            	if (t <= -2.7e+109) {
                                                                            		tmp = fma(((y * z) * x), 18.0, (-4.0 * a)) * t;
                                                                            	} else if (t <= 0.018) {
                                                                            		tmp = fma((k * -27.0), j, fma((i * -4.0), x, (b * c)));
                                                                            	} else {
                                                                            		tmp = fma((-27.0 * j), k, (fma(t, a, (i * x)) * -4.0));
                                                                            	}
                                                                            	return tmp;
                                                                            }
                                                                            
                                                                            x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                            x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                            function code(x, y, z, t, a, b, c, i, j, k)
                                                                            	tmp = 0.0
                                                                            	if (t <= -2.7e+109)
                                                                            		tmp = Float64(fma(Float64(Float64(y * z) * x), 18.0, Float64(-4.0 * a)) * t);
                                                                            	elseif (t <= 0.018)
                                                                            		tmp = fma(Float64(k * -27.0), j, fma(Float64(i * -4.0), x, Float64(b * c)));
                                                                            	else
                                                                            		tmp = fma(Float64(-27.0 * j), k, Float64(fma(t, a, Float64(i * x)) * -4.0));
                                                                            	end
                                                                            	return tmp
                                                                            end
                                                                            
                                                                            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                            NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                            code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[t, -2.7e+109], N[(N[(N[(N[(y * z), $MachinePrecision] * x), $MachinePrecision] * 18.0 + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[t, 0.018], N[(N[(k * -27.0), $MachinePrecision] * j + N[(N[(i * -4.0), $MachinePrecision] * x + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(t * a + N[(i * x), $MachinePrecision]), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision]]]
                                                                            
                                                                            \begin{array}{l}
                                                                            [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                            [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                            \\
                                                                            \begin{array}{l}
                                                                            \mathbf{if}\;t \leq -2.7 \cdot 10^{+109}:\\
                                                                            \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\
                                                                            
                                                                            \mathbf{elif}\;t \leq 0.018:\\
                                                                            \;\;\;\;\mathsf{fma}\left(k \cdot -27, j, \mathsf{fma}\left(i \cdot -4, x, b \cdot c\right)\right)\\
                                                                            
                                                                            \mathbf{else}:\\
                                                                            \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(t, a, i \cdot x\right) \cdot -4\right)\\
                                                                            
                                                                            
                                                                            \end{array}
                                                                            \end{array}
                                                                            
                                                                            Derivation
                                                                            1. Split input into 3 regimes
                                                                            2. if t < -2.70000000000000001e109

                                                                              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. Add Preprocessing
                                                                              3. Applied rewrites82.9%

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

                                                                                \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
                                                                              5. Step-by-step derivation
                                                                                1. Applied rewrites74.8%

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

                                                                                if -2.70000000000000001e109 < t < 0.0179999999999999986

                                                                                1. Initial program 89.0%

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

                                                                                  \[\leadsto \color{blue}{b \cdot c} - \left(j \cdot 27\right) \cdot k \]
                                                                                4. Step-by-step derivation
                                                                                  1. Applied rewrites55.0%

                                                                                    \[\leadsto \color{blue}{c \cdot b} - \left(j \cdot 27\right) \cdot k \]
                                                                                  2. Step-by-step derivation
                                                                                    1. lift--.f64N/A

                                                                                      \[\leadsto \color{blue}{c \cdot b - \left(j \cdot 27\right) \cdot k} \]
                                                                                    2. lift-*.f64N/A

                                                                                      \[\leadsto c \cdot b - \color{blue}{\left(j \cdot 27\right) \cdot k} \]
                                                                                    3. fp-cancel-sub-sign-invN/A

                                                                                      \[\leadsto \color{blue}{c \cdot b + \left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k} \]
                                                                                    4. +-commutativeN/A

                                                                                      \[\leadsto \color{blue}{\left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k + c \cdot b} \]
                                                                                    5. lift-*.f64N/A

                                                                                      \[\leadsto \left(\mathsf{neg}\left(\color{blue}{j \cdot 27}\right)\right) \cdot k + c \cdot b \]
                                                                                    6. *-commutativeN/A

                                                                                      \[\leadsto \left(\mathsf{neg}\left(\color{blue}{27 \cdot j}\right)\right) \cdot k + c \cdot b \]
                                                                                    7. distribute-lft-neg-inN/A

                                                                                      \[\leadsto \color{blue}{\left(\left(\mathsf{neg}\left(27\right)\right) \cdot j\right)} \cdot k + c \cdot b \]
                                                                                    8. metadata-evalN/A

                                                                                      \[\leadsto \left(\color{blue}{-27} \cdot j\right) \cdot k + c \cdot b \]
                                                                                    9. lift-*.f64N/A

                                                                                      \[\leadsto \color{blue}{\left(-27 \cdot j\right)} \cdot k + c \cdot b \]
                                                                                    10. *-commutativeN/A

                                                                                      \[\leadsto \color{blue}{k \cdot \left(-27 \cdot j\right)} + c \cdot b \]
                                                                                    11. lift-*.f64N/A

                                                                                      \[\leadsto k \cdot \color{blue}{\left(-27 \cdot j\right)} + c \cdot b \]
                                                                                    12. associate-*r*N/A

                                                                                      \[\leadsto \color{blue}{\left(k \cdot -27\right) \cdot j} + c \cdot b \]
                                                                                    13. lower-fma.f64N/A

                                                                                      \[\leadsto \color{blue}{\mathsf{fma}\left(k \cdot -27, j, c \cdot b\right)} \]
                                                                                  3. Applied rewrites55.6%

                                                                                    \[\leadsto \color{blue}{\mathsf{fma}\left(k \cdot -27, j, b \cdot c\right)} \]
                                                                                  4. Taylor expanded in t around 0

                                                                                    \[\leadsto \mathsf{fma}\left(k \cdot -27, j, \color{blue}{b \cdot c - 4 \cdot \left(i \cdot x\right)}\right) \]
                                                                                  5. Step-by-step derivation
                                                                                    1. Applied rewrites80.0%

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

                                                                                    if 0.0179999999999999986 < t

                                                                                    1. Initial program 87.2%

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

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

                                                                                      \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(a \cdot t\right) + \left(-4 \cdot \left(i \cdot x\right) + b \cdot c\right)}\right) \]
                                                                                    5. Step-by-step derivation
                                                                                      1. Applied rewrites77.2%

                                                                                        \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{\mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)}\right) \]
                                                                                      2. Taylor expanded in b around 0

                                                                                        \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, -4 \cdot \color{blue}{\left(a \cdot t + i \cdot x\right)}\right) \]
                                                                                      3. Step-by-step derivation
                                                                                        1. Applied rewrites73.0%

                                                                                          \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(i, x, t \cdot a\right) \cdot \color{blue}{-4}\right) \]
                                                                                        2. Step-by-step derivation
                                                                                          1. Applied rewrites73.0%

                                                                                            \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(t, a, i \cdot x\right) \cdot -4\right) \]
                                                                                        3. Recombined 3 regimes into one program.
                                                                                        4. Add Preprocessing

                                                                                        Alternative 15: 70.5% accurate, 1.7× speedup?

                                                                                        \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -2.7 \cdot 10^{+109}:\\ \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\ \mathbf{elif}\;t \leq 0.018:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(i \cdot x, -4, b \cdot c\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(t, a, i \cdot x\right) \cdot -4\right)\\ \end{array} \end{array} \]
                                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                        (FPCore (x y z t a b c i j k)
                                                                                         :precision binary64
                                                                                         (if (<= t -2.7e+109)
                                                                                           (* (fma (* (* y z) x) 18.0 (* -4.0 a)) t)
                                                                                           (if (<= t 0.018)
                                                                                             (fma (* -27.0 j) k (fma (* i x) -4.0 (* b c)))
                                                                                             (fma (* -27.0 j) k (* (fma t a (* i x)) -4.0)))))
                                                                                        assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                        assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                        double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                                        	double tmp;
                                                                                        	if (t <= -2.7e+109) {
                                                                                        		tmp = fma(((y * z) * x), 18.0, (-4.0 * a)) * t;
                                                                                        	} else if (t <= 0.018) {
                                                                                        		tmp = fma((-27.0 * j), k, fma((i * x), -4.0, (b * c)));
                                                                                        	} else {
                                                                                        		tmp = fma((-27.0 * j), k, (fma(t, a, (i * x)) * -4.0));
                                                                                        	}
                                                                                        	return tmp;
                                                                                        }
                                                                                        
                                                                                        x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                        x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                        function code(x, y, z, t, a, b, c, i, j, k)
                                                                                        	tmp = 0.0
                                                                                        	if (t <= -2.7e+109)
                                                                                        		tmp = Float64(fma(Float64(Float64(y * z) * x), 18.0, Float64(-4.0 * a)) * t);
                                                                                        	elseif (t <= 0.018)
                                                                                        		tmp = fma(Float64(-27.0 * j), k, fma(Float64(i * x), -4.0, Float64(b * c)));
                                                                                        	else
                                                                                        		tmp = fma(Float64(-27.0 * j), k, Float64(fma(t, a, Float64(i * x)) * -4.0));
                                                                                        	end
                                                                                        	return tmp
                                                                                        end
                                                                                        
                                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                        code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[t, -2.7e+109], N[(N[(N[(N[(y * z), $MachinePrecision] * x), $MachinePrecision] * 18.0 + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision], If[LessEqual[t, 0.018], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(i * x), $MachinePrecision] * -4.0 + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(N[(t * a + N[(i * x), $MachinePrecision]), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision]]]
                                                                                        
                                                                                        \begin{array}{l}
                                                                                        [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                                        [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                                        \\
                                                                                        \begin{array}{l}
                                                                                        \mathbf{if}\;t \leq -2.7 \cdot 10^{+109}:\\
                                                                                        \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\
                                                                                        
                                                                                        \mathbf{elif}\;t \leq 0.018:\\
                                                                                        \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(i \cdot x, -4, b \cdot c\right)\right)\\
                                                                                        
                                                                                        \mathbf{else}:\\
                                                                                        \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(t, a, i \cdot x\right) \cdot -4\right)\\
                                                                                        
                                                                                        
                                                                                        \end{array}
                                                                                        \end{array}
                                                                                        
                                                                                        Derivation
                                                                                        1. Split input into 3 regimes
                                                                                        2. if t < -2.70000000000000001e109

                                                                                          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. Add Preprocessing
                                                                                          3. Applied rewrites82.9%

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

                                                                                            \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
                                                                                          5. Step-by-step derivation
                                                                                            1. Applied rewrites74.8%

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

                                                                                            if -2.70000000000000001e109 < t < 0.0179999999999999986

                                                                                            1. Initial program 89.0%

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

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

                                                                                              \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(i \cdot x\right) + b \cdot c}\right) \]
                                                                                            5. Step-by-step derivation
                                                                                              1. Applied rewrites78.8%

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

                                                                                              if 0.0179999999999999986 < t

                                                                                              1. Initial program 87.2%

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

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

                                                                                                \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(a \cdot t\right) + \left(-4 \cdot \left(i \cdot x\right) + b \cdot c\right)}\right) \]
                                                                                              5. Step-by-step derivation
                                                                                                1. Applied rewrites77.2%

                                                                                                  \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{\mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)}\right) \]
                                                                                                2. Taylor expanded in b around 0

                                                                                                  \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, -4 \cdot \color{blue}{\left(a \cdot t + i \cdot x\right)}\right) \]
                                                                                                3. Step-by-step derivation
                                                                                                  1. Applied rewrites73.0%

                                                                                                    \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(i, x, t \cdot a\right) \cdot \color{blue}{-4}\right) \]
                                                                                                  2. Step-by-step derivation
                                                                                                    1. Applied rewrites73.0%

                                                                                                      \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(t, a, i \cdot x\right) \cdot -4\right) \]
                                                                                                  3. Recombined 3 regimes into one program.
                                                                                                  4. Add Preprocessing

                                                                                                  Alternative 16: 78.7% accurate, 1.7× speedup?

                                                                                                  \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;y \leq 3 \cdot 10^{+55}:\\ \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\ \end{array} \end{array} \]
                                                                                                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                  (FPCore (x y z t a b c i j k)
                                                                                                   :precision binary64
                                                                                                   (if (<= y 3e+55)
                                                                                                     (fma (* -27.0 j) k (fma -4.0 (fma t a (* i x)) (* b c)))
                                                                                                     (* (fma (* (* y z) x) 18.0 (* -4.0 a)) t)))
                                                                                                  assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                  assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                  double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                                                  	double tmp;
                                                                                                  	if (y <= 3e+55) {
                                                                                                  		tmp = fma((-27.0 * j), k, fma(-4.0, fma(t, a, (i * x)), (b * c)));
                                                                                                  	} else {
                                                                                                  		tmp = fma(((y * z) * x), 18.0, (-4.0 * a)) * t;
                                                                                                  	}
                                                                                                  	return tmp;
                                                                                                  }
                                                                                                  
                                                                                                  x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                  x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                  function code(x, y, z, t, a, b, c, i, j, k)
                                                                                                  	tmp = 0.0
                                                                                                  	if (y <= 3e+55)
                                                                                                  		tmp = fma(Float64(-27.0 * j), k, fma(-4.0, fma(t, a, Float64(i * x)), Float64(b * c)));
                                                                                                  	else
                                                                                                  		tmp = Float64(fma(Float64(Float64(y * z) * x), 18.0, Float64(-4.0 * a)) * t);
                                                                                                  	end
                                                                                                  	return tmp
                                                                                                  end
                                                                                                  
                                                                                                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                  NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                  code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[y, 3e+55], N[(N[(-27.0 * j), $MachinePrecision] * k + N[(-4.0 * N[(t * a + N[(i * x), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(y * z), $MachinePrecision] * x), $MachinePrecision] * 18.0 + N[(-4.0 * a), $MachinePrecision]), $MachinePrecision] * t), $MachinePrecision]]
                                                                                                  
                                                                                                  \begin{array}{l}
                                                                                                  [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                                                  [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                                                  \\
                                                                                                  \begin{array}{l}
                                                                                                  \mathbf{if}\;y \leq 3 \cdot 10^{+55}:\\
                                                                                                  \;\;\;\;\mathsf{fma}\left(-27 \cdot j, k, \mathsf{fma}\left(-4, \mathsf{fma}\left(t, a, i \cdot x\right), b \cdot c\right)\right)\\
                                                                                                  
                                                                                                  \mathbf{else}:\\
                                                                                                  \;\;\;\;\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t\\
                                                                                                  
                                                                                                  
                                                                                                  \end{array}
                                                                                                  \end{array}
                                                                                                  
                                                                                                  Derivation
                                                                                                  1. Split input into 2 regimes
                                                                                                  2. if y < 3.00000000000000017e55

                                                                                                    1. Initial program 88.9%

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

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

                                                                                                      \[\leadsto \mathsf{fma}\left(-27 \cdot j, k, \color{blue}{-4 \cdot \left(a \cdot t\right) + \left(-4 \cdot \left(i \cdot x\right) + b \cdot c\right)}\right) \]
                                                                                                    5. Step-by-step derivation
                                                                                                      1. Applied rewrites83.6%

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

                                                                                                      if 3.00000000000000017e55 < y

                                                                                                      1. Initial program 76.0%

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

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

                                                                                                        \[\leadsto \color{blue}{t \cdot \left(-4 \cdot a + 18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} \]
                                                                                                      5. Step-by-step derivation
                                                                                                        1. Applied rewrites53.9%

                                                                                                          \[\leadsto \color{blue}{\mathsf{fma}\left(\left(y \cdot z\right) \cdot x, 18, -4 \cdot a\right) \cdot t} \]
                                                                                                      6. Recombined 2 regimes into one program.
                                                                                                      7. Add Preprocessing

                                                                                                      Alternative 17: 51.0% accurate, 2.3× speedup?

                                                                                                      \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;k \leq -1.05 \cdot 10^{-5} \lor \neg \left(k \leq 3.7 \cdot 10^{+35}\right):\\ \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\ \end{array} \end{array} \]
                                                                                                      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                      (FPCore (x y z t a b c i j k)
                                                                                                       :precision binary64
                                                                                                       (if (or (<= k -1.05e-5) (not (<= k 3.7e+35)))
                                                                                                         (fma b c (* (* k j) -27.0))
                                                                                                         (fma (* t a) -4.0 (* b c))))
                                                                                                      assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                      assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                      double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                                                      	double tmp;
                                                                                                      	if ((k <= -1.05e-5) || !(k <= 3.7e+35)) {
                                                                                                      		tmp = fma(b, c, ((k * j) * -27.0));
                                                                                                      	} else {
                                                                                                      		tmp = fma((t * a), -4.0, (b * c));
                                                                                                      	}
                                                                                                      	return tmp;
                                                                                                      }
                                                                                                      
                                                                                                      x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                      x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                      function code(x, y, z, t, a, b, c, i, j, k)
                                                                                                      	tmp = 0.0
                                                                                                      	if ((k <= -1.05e-5) || !(k <= 3.7e+35))
                                                                                                      		tmp = fma(b, c, Float64(Float64(k * j) * -27.0));
                                                                                                      	else
                                                                                                      		tmp = fma(Float64(t * a), -4.0, Float64(b * c));
                                                                                                      	end
                                                                                                      	return tmp
                                                                                                      end
                                                                                                      
                                                                                                      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                      NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                      code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[k, -1.05e-5], N[Not[LessEqual[k, 3.7e+35]], $MachinePrecision]], N[(b * c + N[(N[(k * j), $MachinePrecision] * -27.0), $MachinePrecision]), $MachinePrecision], N[(N[(t * a), $MachinePrecision] * -4.0 + N[(b * c), $MachinePrecision]), $MachinePrecision]]
                                                                                                      
                                                                                                      \begin{array}{l}
                                                                                                      [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                                                      [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                                                      \\
                                                                                                      \begin{array}{l}
                                                                                                      \mathbf{if}\;k \leq -1.05 \cdot 10^{-5} \lor \neg \left(k \leq 3.7 \cdot 10^{+35}\right):\\
                                                                                                      \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\
                                                                                                      
                                                                                                      \mathbf{else}:\\
                                                                                                      \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\
                                                                                                      
                                                                                                      
                                                                                                      \end{array}
                                                                                                      \end{array}
                                                                                                      
                                                                                                      Derivation
                                                                                                      1. Split input into 2 regimes
                                                                                                      2. if k < -1.04999999999999994e-5 or 3.7e35 < k

                                                                                                        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. Add Preprocessing
                                                                                                        3. Taylor expanded in x around 0

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

                                                                                                            \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                                                                                                          2. Taylor expanded in t around 0

                                                                                                            \[\leadsto b \cdot c - \color{blue}{27 \cdot \left(j \cdot k\right)} \]
                                                                                                          3. Step-by-step derivation
                                                                                                            1. Applied rewrites62.5%

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

                                                                                                            if -1.04999999999999994e-5 < k < 3.7e35

                                                                                                            1. Initial program 84.6%

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

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

                                                                                                                \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                                                                                                              2. Taylor expanded in j around 0

                                                                                                                \[\leadsto -4 \cdot \left(a \cdot t\right) + \color{blue}{b \cdot c} \]
                                                                                                              3. Step-by-step derivation
                                                                                                                1. Applied rewrites47.4%

                                                                                                                  \[\leadsto \mathsf{fma}\left(t \cdot a, \color{blue}{-4}, b \cdot c\right) \]
                                                                                                              4. Recombined 2 regimes into one program.
                                                                                                              5. Final simplification54.9%

                                                                                                                \[\leadsto \begin{array}{l} \mathbf{if}\;k \leq -1.05 \cdot 10^{-5} \lor \neg \left(k \leq 3.7 \cdot 10^{+35}\right):\\ \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\ \end{array} \]
                                                                                                              6. Add Preprocessing

                                                                                                              Alternative 18: 50.9% accurate, 2.3× speedup?

                                                                                                              \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;k \leq -1.05 \cdot 10^{-5}:\\ \;\;\;\;\mathsf{fma}\left(j \cdot -27, k, b \cdot c\right)\\ \mathbf{elif}\;k \leq 3.7 \cdot 10^{+35}:\\ \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\ \end{array} \end{array} \]
                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                              (FPCore (x y z t a b c i j k)
                                                                                                               :precision binary64
                                                                                                               (if (<= k -1.05e-5)
                                                                                                                 (fma (* j -27.0) k (* b c))
                                                                                                                 (if (<= k 3.7e+35) (fma (* t a) -4.0 (* b c)) (fma b c (* (* k j) -27.0)))))
                                                                                                              assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                              assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                              double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                                                              	double tmp;
                                                                                                              	if (k <= -1.05e-5) {
                                                                                                              		tmp = fma((j * -27.0), k, (b * c));
                                                                                                              	} else if (k <= 3.7e+35) {
                                                                                                              		tmp = fma((t * a), -4.0, (b * c));
                                                                                                              	} else {
                                                                                                              		tmp = fma(b, c, ((k * j) * -27.0));
                                                                                                              	}
                                                                                                              	return tmp;
                                                                                                              }
                                                                                                              
                                                                                                              x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                              x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                              function code(x, y, z, t, a, b, c, i, j, k)
                                                                                                              	tmp = 0.0
                                                                                                              	if (k <= -1.05e-5)
                                                                                                              		tmp = fma(Float64(j * -27.0), k, Float64(b * c));
                                                                                                              	elseif (k <= 3.7e+35)
                                                                                                              		tmp = fma(Float64(t * a), -4.0, Float64(b * c));
                                                                                                              	else
                                                                                                              		tmp = fma(b, c, Float64(Float64(k * j) * -27.0));
                                                                                                              	end
                                                                                                              	return tmp
                                                                                                              end
                                                                                                              
                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                              code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[k, -1.05e-5], N[(N[(j * -27.0), $MachinePrecision] * k + N[(b * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 3.7e+35], N[(N[(t * a), $MachinePrecision] * -4.0 + N[(b * c), $MachinePrecision]), $MachinePrecision], N[(b * c + N[(N[(k * j), $MachinePrecision] * -27.0), $MachinePrecision]), $MachinePrecision]]]
                                                                                                              
                                                                                                              \begin{array}{l}
                                                                                                              [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                                                              [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                                                              \\
                                                                                                              \begin{array}{l}
                                                                                                              \mathbf{if}\;k \leq -1.05 \cdot 10^{-5}:\\
                                                                                                              \;\;\;\;\mathsf{fma}\left(j \cdot -27, k, b \cdot c\right)\\
                                                                                                              
                                                                                                              \mathbf{elif}\;k \leq 3.7 \cdot 10^{+35}:\\
                                                                                                              \;\;\;\;\mathsf{fma}\left(t \cdot a, -4, b \cdot c\right)\\
                                                                                                              
                                                                                                              \mathbf{else}:\\
                                                                                                              \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\
                                                                                                              
                                                                                                              
                                                                                                              \end{array}
                                                                                                              \end{array}
                                                                                                              
                                                                                                              Derivation
                                                                                                              1. Split input into 3 regimes
                                                                                                              2. if k < -1.04999999999999994e-5

                                                                                                                1. Initial program 88.9%

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

                                                                                                                  \[\leadsto \color{blue}{b \cdot c} - \left(j \cdot 27\right) \cdot k \]
                                                                                                                4. Step-by-step derivation
                                                                                                                  1. Applied rewrites58.2%

                                                                                                                    \[\leadsto \color{blue}{c \cdot b} - \left(j \cdot 27\right) \cdot k \]
                                                                                                                  2. Step-by-step derivation
                                                                                                                    1. lift--.f64N/A

                                                                                                                      \[\leadsto \color{blue}{c \cdot b - \left(j \cdot 27\right) \cdot k} \]
                                                                                                                    2. lift-*.f64N/A

                                                                                                                      \[\leadsto c \cdot b - \color{blue}{\left(j \cdot 27\right) \cdot k} \]
                                                                                                                    3. fp-cancel-sub-sign-invN/A

                                                                                                                      \[\leadsto \color{blue}{c \cdot b + \left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k} \]
                                                                                                                    4. +-commutativeN/A

                                                                                                                      \[\leadsto \color{blue}{\left(\mathsf{neg}\left(j \cdot 27\right)\right) \cdot k + c \cdot b} \]
                                                                                                                    5. lift-*.f64N/A

                                                                                                                      \[\leadsto \left(\mathsf{neg}\left(\color{blue}{j \cdot 27}\right)\right) \cdot k + c \cdot b \]
                                                                                                                    6. *-commutativeN/A

                                                                                                                      \[\leadsto \left(\mathsf{neg}\left(\color{blue}{27 \cdot j}\right)\right) \cdot k + c \cdot b \]
                                                                                                                    7. distribute-lft-neg-inN/A

                                                                                                                      \[\leadsto \color{blue}{\left(\left(\mathsf{neg}\left(27\right)\right) \cdot j\right)} \cdot k + c \cdot b \]
                                                                                                                    8. metadata-evalN/A

                                                                                                                      \[\leadsto \left(\color{blue}{-27} \cdot j\right) \cdot k + c \cdot b \]
                                                                                                                    9. lift-*.f64N/A

                                                                                                                      \[\leadsto \color{blue}{\left(-27 \cdot j\right)} \cdot k + c \cdot b \]
                                                                                                                    10. lower-fma.f6459.5

                                                                                                                      \[\leadsto \color{blue}{\mathsf{fma}\left(-27 \cdot j, k, c \cdot b\right)} \]
                                                                                                                    11. lift-*.f64N/A

                                                                                                                      \[\leadsto \mathsf{fma}\left(\color{blue}{-27 \cdot j}, k, c \cdot b\right) \]
                                                                                                                    12. *-commutativeN/A

                                                                                                                      \[\leadsto \mathsf{fma}\left(\color{blue}{j \cdot -27}, k, c \cdot b\right) \]
                                                                                                                    13. lower-*.f6459.5

                                                                                                                      \[\leadsto \mathsf{fma}\left(\color{blue}{j \cdot -27}, k, c \cdot b\right) \]
                                                                                                                  3. Applied rewrites59.5%

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

                                                                                                                  if -1.04999999999999994e-5 < k < 3.7e35

                                                                                                                  1. Initial program 84.6%

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

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

                                                                                                                      \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                                                                                                                    2. Taylor expanded in j around 0

                                                                                                                      \[\leadsto -4 \cdot \left(a \cdot t\right) + \color{blue}{b \cdot c} \]
                                                                                                                    3. Step-by-step derivation
                                                                                                                      1. Applied rewrites47.4%

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

                                                                                                                      if 3.7e35 < k

                                                                                                                      1. Initial program 85.5%

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

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

                                                                                                                          \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                                                                                                                        2. Taylor expanded in t around 0

                                                                                                                          \[\leadsto b \cdot c - \color{blue}{27 \cdot \left(j \cdot k\right)} \]
                                                                                                                        3. Step-by-step derivation
                                                                                                                          1. Applied rewrites68.3%

                                                                                                                            \[\leadsto \mathsf{fma}\left(b, \color{blue}{c}, \left(k \cdot j\right) \cdot -27\right) \]
                                                                                                                        4. Recombined 3 regimes into one program.
                                                                                                                        5. Add Preprocessing

                                                                                                                        Alternative 19: 45.3% accurate, 3.0× speedup?

                                                                                                                        \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ \begin{array}{l} \mathbf{if}\;a \leq -5.6 \cdot 10^{+145}:\\ \;\;\;\;-4 \cdot \left(a \cdot t\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\ \end{array} \end{array} \]
                                                                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                        (FPCore (x y z t a b c i j k)
                                                                                                                         :precision binary64
                                                                                                                         (if (<= a -5.6e+145) (* -4.0 (* a t)) (fma b c (* (* k j) -27.0))))
                                                                                                                        assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                                        assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                                        double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                                                                        	double tmp;
                                                                                                                        	if (a <= -5.6e+145) {
                                                                                                                        		tmp = -4.0 * (a * t);
                                                                                                                        	} else {
                                                                                                                        		tmp = fma(b, c, ((k * j) * -27.0));
                                                                                                                        	}
                                                                                                                        	return tmp;
                                                                                                                        }
                                                                                                                        
                                                                                                                        x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                                        x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                                        function code(x, y, z, t, a, b, c, i, j, k)
                                                                                                                        	tmp = 0.0
                                                                                                                        	if (a <= -5.6e+145)
                                                                                                                        		tmp = Float64(-4.0 * Float64(a * t));
                                                                                                                        	else
                                                                                                                        		tmp = fma(b, c, Float64(Float64(k * j) * -27.0));
                                                                                                                        	end
                                                                                                                        	return tmp
                                                                                                                        end
                                                                                                                        
                                                                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                        NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                        code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[a, -5.6e+145], N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision], N[(b * c + N[(N[(k * j), $MachinePrecision] * -27.0), $MachinePrecision]), $MachinePrecision]]
                                                                                                                        
                                                                                                                        \begin{array}{l}
                                                                                                                        [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                                                                        [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                                                                        \\
                                                                                                                        \begin{array}{l}
                                                                                                                        \mathbf{if}\;a \leq -5.6 \cdot 10^{+145}:\\
                                                                                                                        \;\;\;\;-4 \cdot \left(a \cdot t\right)\\
                                                                                                                        
                                                                                                                        \mathbf{else}:\\
                                                                                                                        \;\;\;\;\mathsf{fma}\left(b, c, \left(k \cdot j\right) \cdot -27\right)\\
                                                                                                                        
                                                                                                                        
                                                                                                                        \end{array}
                                                                                                                        \end{array}
                                                                                                                        
                                                                                                                        Derivation
                                                                                                                        1. Split input into 2 regimes
                                                                                                                        2. if a < -5.5999999999999997e145

                                                                                                                          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. Add Preprocessing
                                                                                                                          3. Taylor expanded in a around inf

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

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

                                                                                                                            if -5.5999999999999997e145 < a

                                                                                                                            1. Initial program 86.6%

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

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

                                                                                                                                \[\leadsto \color{blue}{\mathsf{fma}\left(-4, a \cdot t, c \cdot b\right) - \left(k \cdot j\right) \cdot 27} \]
                                                                                                                              2. Taylor expanded in t around 0

                                                                                                                                \[\leadsto b \cdot c - \color{blue}{27 \cdot \left(j \cdot k\right)} \]
                                                                                                                              3. Step-by-step derivation
                                                                                                                                1. Applied rewrites50.5%

                                                                                                                                  \[\leadsto \mathsf{fma}\left(b, \color{blue}{c}, \left(k \cdot j\right) \cdot -27\right) \]
                                                                                                                              4. Recombined 2 regimes into one program.
                                                                                                                              5. Add Preprocessing

                                                                                                                              Alternative 20: 23.8% accurate, 11.3× speedup?

                                                                                                                              \[\begin{array}{l} [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\ [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\ \\ c \cdot b \end{array} \]
                                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                              (FPCore (x y z t a b c i j k) :precision binary64 (* c b))
                                                                                                                              assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                                              assert(x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k);
                                                                                                                              double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                                                                              	return c * b;
                                                                                                                              }
                                                                                                                              
                                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                              module fmin_fmax_functions
                                                                                                                                  implicit none
                                                                                                                                  private
                                                                                                                                  public fmax
                                                                                                                                  public fmin
                                                                                                                              
                                                                                                                                  interface fmax
                                                                                                                                      module procedure fmax88
                                                                                                                                      module procedure fmax44
                                                                                                                                      module procedure fmax84
                                                                                                                                      module procedure fmax48
                                                                                                                                  end interface
                                                                                                                                  interface fmin
                                                                                                                                      module procedure fmin88
                                                                                                                                      module procedure fmin44
                                                                                                                                      module procedure fmin84
                                                                                                                                      module procedure fmin48
                                                                                                                                  end interface
                                                                                                                              contains
                                                                                                                                  real(8) function fmax88(x, y) result (res)
                                                                                                                                      real(8), intent (in) :: x
                                                                                                                                      real(8), intent (in) :: y
                                                                                                                                      res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                                                                  end function
                                                                                                                                  real(4) function fmax44(x, y) result (res)
                                                                                                                                      real(4), intent (in) :: x
                                                                                                                                      real(4), intent (in) :: y
                                                                                                                                      res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                                                                  end function
                                                                                                                                  real(8) function fmax84(x, y) result(res)
                                                                                                                                      real(8), intent (in) :: x
                                                                                                                                      real(4), intent (in) :: y
                                                                                                                                      res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                                                                                  end function
                                                                                                                                  real(8) function fmax48(x, y) result(res)
                                                                                                                                      real(4), intent (in) :: x
                                                                                                                                      real(8), intent (in) :: y
                                                                                                                                      res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                                                                                  end function
                                                                                                                                  real(8) function fmin88(x, y) result (res)
                                                                                                                                      real(8), intent (in) :: x
                                                                                                                                      real(8), intent (in) :: y
                                                                                                                                      res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                                                                  end function
                                                                                                                                  real(4) function fmin44(x, y) result (res)
                                                                                                                                      real(4), intent (in) :: x
                                                                                                                                      real(4), intent (in) :: y
                                                                                                                                      res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                                                                  end function
                                                                                                                                  real(8) function fmin84(x, y) result(res)
                                                                                                                                      real(8), intent (in) :: x
                                                                                                                                      real(4), intent (in) :: y
                                                                                                                                      res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                                                                                  end function
                                                                                                                                  real(8) function fmin48(x, y) result(res)
                                                                                                                                      real(4), intent (in) :: x
                                                                                                                                      real(8), intent (in) :: y
                                                                                                                                      res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                                                                                  end function
                                                                                                                              end module
                                                                                                                              
                                                                                                                              real(8) function code(x, y, z, t, a, b, c, i, j, k)
                                                                                                                              use fmin_fmax_functions
                                                                                                                                  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 = c * b
                                                                                                                              end function
                                                                                                                              
                                                                                                                              assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
                                                                                                                              assert x < y && y < z && z < t && t < a && a < b && b < c && c < i && i < j && j < k;
                                                                                                                              public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
                                                                                                                              	return c * b;
                                                                                                                              }
                                                                                                                              
                                                                                                                              [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                                              [x, y, z, t, a, b, c, i, j, k] = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                                              def code(x, y, z, t, a, b, c, i, j, k):
                                                                                                                              	return c * b
                                                                                                                              
                                                                                                                              x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                                              x, y, z, t, a, b, c, i, j, k = sort([x, y, z, t, a, b, c, i, j, k])
                                                                                                                              function code(x, y, z, t, a, b, c, i, j, k)
                                                                                                                              	return Float64(c * b)
                                                                                                                              end
                                                                                                                              
                                                                                                                              x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
                                                                                                                              x, y, z, t, a, b, c, i, j, k = num2cell(sort([x, y, z, t, a, b, c, i, j, k])){:}
                                                                                                                              function tmp = code(x, y, z, t, a, b, c, i, j, k)
                                                                                                                              	tmp = c * b;
                                                                                                                              end
                                                                                                                              
                                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                              NOTE: x, y, z, t, a, b, c, i, j, and k should be sorted in increasing order before calling this function.
                                                                                                                              code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := N[(c * b), $MachinePrecision]
                                                                                                                              
                                                                                                                              \begin{array}{l}
                                                                                                                              [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\\\
                                                                                                                              [x, y, z, t, a, b, c, i, j, k] = \mathsf{sort}([x, y, z, t, a, b, c, i, j, k])\\
                                                                                                                              \\
                                                                                                                              c \cdot b
                                                                                                                              \end{array}
                                                                                                                              
                                                                                                                              Derivation
                                                                                                                              1. Initial program 86.0%

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

                                                                                                                                \[\leadsto \color{blue}{b \cdot c} \]
                                                                                                                              4. Step-by-step derivation
                                                                                                                                1. Applied rewrites23.8%

                                                                                                                                  \[\leadsto \color{blue}{c \cdot b} \]
                                                                                                                                2. Add Preprocessing

                                                                                                                                Developer Target 1: 89.7% 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;
                                                                                                                                }
                                                                                                                                
                                                                                                                                module fmin_fmax_functions
                                                                                                                                    implicit none
                                                                                                                                    private
                                                                                                                                    public fmax
                                                                                                                                    public fmin
                                                                                                                                
                                                                                                                                    interface fmax
                                                                                                                                        module procedure fmax88
                                                                                                                                        module procedure fmax44
                                                                                                                                        module procedure fmax84
                                                                                                                                        module procedure fmax48
                                                                                                                                    end interface
                                                                                                                                    interface fmin
                                                                                                                                        module procedure fmin88
                                                                                                                                        module procedure fmin44
                                                                                                                                        module procedure fmin84
                                                                                                                                        module procedure fmin48
                                                                                                                                    end interface
                                                                                                                                contains
                                                                                                                                    real(8) function fmax88(x, y) result (res)
                                                                                                                                        real(8), intent (in) :: x
                                                                                                                                        real(8), intent (in) :: y
                                                                                                                                        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                                                                    end function
                                                                                                                                    real(4) function fmax44(x, y) result (res)
                                                                                                                                        real(4), intent (in) :: x
                                                                                                                                        real(4), intent (in) :: y
                                                                                                                                        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                                                                    end function
                                                                                                                                    real(8) function fmax84(x, y) result(res)
                                                                                                                                        real(8), intent (in) :: x
                                                                                                                                        real(4), intent (in) :: y
                                                                                                                                        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                                                                                    end function
                                                                                                                                    real(8) function fmax48(x, y) result(res)
                                                                                                                                        real(4), intent (in) :: x
                                                                                                                                        real(8), intent (in) :: y
                                                                                                                                        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                                                                                    end function
                                                                                                                                    real(8) function fmin88(x, y) result (res)
                                                                                                                                        real(8), intent (in) :: x
                                                                                                                                        real(8), intent (in) :: y
                                                                                                                                        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                                                                    end function
                                                                                                                                    real(4) function fmin44(x, y) result (res)
                                                                                                                                        real(4), intent (in) :: x
                                                                                                                                        real(4), intent (in) :: y
                                                                                                                                        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                                                                    end function
                                                                                                                                    real(8) function fmin84(x, y) result(res)
                                                                                                                                        real(8), intent (in) :: x
                                                                                                                                        real(4), intent (in) :: y
                                                                                                                                        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                                                                                    end function
                                                                                                                                    real(8) function fmin48(x, y) result(res)
                                                                                                                                        real(4), intent (in) :: x
                                                                                                                                        real(8), intent (in) :: y
                                                                                                                                        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                                                                                    end function
                                                                                                                                end module
                                                                                                                                
                                                                                                                                real(8) function code(x, y, z, t, a, b, c, i, j, k)
                                                                                                                                use fmin_fmax_functions
                                                                                                                                    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 2025022 
                                                                                                                                (FPCore (x y z t a b c i j k)
                                                                                                                                  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1, E"
                                                                                                                                  :precision binary64
                                                                                                                                
                                                                                                                                  :alt
                                                                                                                                  (! :herbie-platform default (if (< t -8105407698770699/5000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- (- (* (* 18 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4)) (- (* (* k j) 27) (* c b))) (if (< t 8284013971902611/50000000000000) (+ (- (* (* 18 y) (* x (* z t))) (* (+ (* a t) (* i x)) 4)) (- (* c b) (* 27 (* k j)))) (- (- (* (* 18 t) (* (* x y) z)) (* (+ (* a t) (* i x)) 4)) (- (* (* k j) 27) (* c b))))))
                                                                                                                                
                                                                                                                                  (- (- (+ (- (* (* (* (* x 18.0) y) z) t) (* (* a 4.0) t)) (* b c)) (* (* x 4.0) i)) (* (* j 27.0) k)))