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

Percentage Accurate: 85.2% → 89.5%
Time: 23.4s
Alternatives: 21
Speedup: 0.5×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 21 alternatives:

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

Initial Program: 85.2% accurate, 1.0× speedup?

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

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

Alternative 1: 89.5% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \leq \infty:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<=
      (-
       (-
        (+ (- (* (* (* (* x 18.0) y) z) t) (* t (* a 4.0))) (* b c))
        (* (* x 4.0) i))
       (* (* j 27.0) k))
      INFINITY)
   (-
    (+ (* b c) (* t (- (* (* x 18.0) (* y z)) (* a 4.0))))
    (+ (* x (* 4.0 i)) (* j (* 27.0 k))))
   (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))))
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) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)) <= ((double) INFINITY)) {
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	} else {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	}
	return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (((((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)) <= Double.POSITIVE_INFINITY) {
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	} else {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if ((((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)) <= math.inf:
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)))
	else:
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * 18.0) * y) * z) * t) - Float64(t * Float64(a * 4.0))) + Float64(b * c)) - Float64(Float64(x * 4.0) * i)) - Float64(Float64(j * 27.0) * k)) <= Inf)
		tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(x * 18.0) * Float64(y * z)) - Float64(a * 4.0)))) - Float64(Float64(x * Float64(4.0 * i)) + Float64(j * Float64(27.0 * k))));
	else
		tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (((((((((x * 18.0) * y) * z) * t) - (t * (a * 4.0))) + (b * c)) - ((x * 4.0) * i)) - ((j * 27.0) * k)) <= Inf)
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * (4.0 * i)) + (j * (27.0 * k)));
	else
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(N[(N[(N[(N[(N[(N[(N[(x * 18.0), $MachinePrecision] * y), $MachinePrecision] * z), $MachinePrecision] * t), $MachinePrecision] - N[(t * N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b * c), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], Infinity], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(x * 18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * N[(4.0 * i), $MachinePrecision]), $MachinePrecision] + N[(j * N[(27.0 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - t \cdot \left(a \cdot 4\right)\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \leq \infty:\\
\;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right)\right) - \left(x \cdot \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (-.f64 (+.f64 (-.f64 (*.f64 (*.f64 (*.f64 (*.f64 x #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)) (*.f64 (*.f64 j #s(literal 27 binary64)) k)) < +inf.0

    1. Initial program 93.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. Simplified95.6%

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

    if +inf.0 < (-.f64 (-.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)) (*.f64 (*.f64 j #s(literal 27 binary64)) k))

    1. Initial program 0.0%

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

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

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

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

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

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

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

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

Alternative 2: 35.6% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
t_1 := \left(t \cdot \left(x \cdot z\right)\right) \cdot \left(18 \cdot y\right)\\
t_2 := -4 \cdot \left(t \cdot a\right)\\
\mathbf{if}\;b \cdot c \leq -1.52 \cdot 10^{+223}:\\
\;\;\;\;b \cdot c\\

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

\mathbf{elif}\;b \cdot c \leq 0:\\
\;\;\;\;t\_2\\

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

\mathbf{elif}\;b \cdot c \leq 3.45 \cdot 10^{-62}:\\
\;\;\;\;t\_2\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (*.f64 b c) < -1.52000000000000007e223 or 2.6e253 < (*.f64 b c)

    1. Initial program 76.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. Simplified79.7%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*74.6%

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

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

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

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

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

    if -1.52000000000000007e223 < (*.f64 b c) < -1.14999999999999992e-30 or 0.0 < (*.f64 b c) < 3.00000000000000006e-179

    1. Initial program 78.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.14999999999999992e-30 < (*.f64 b c) < 0.0 or 3.00000000000000006e-179 < (*.f64 b c) < 3.44999999999999979e-62

    1. Initial program 87.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. Simplified94.5%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*84.5%

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

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

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

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

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

    if 3.44999999999999979e-62 < (*.f64 b c) < 5.8000000000000004e44

    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. Simplified88.8%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*85.1%

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

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

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

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

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
    7. Step-by-step derivation
      1. associate-*r*38.5%

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

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

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

    if 5.8000000000000004e44 < (*.f64 b c) < 2.6e253

    1. Initial program 91.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. Simplified96.1%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.52 \cdot 10^{+223}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -1.15 \cdot 10^{-30}:\\ \;\;\;\;\left(t \cdot \left(x \cdot z\right)\right) \cdot \left(18 \cdot y\right)\\ \mathbf{elif}\;b \cdot c \leq 0:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;b \cdot c \leq 3 \cdot 10^{-179}:\\ \;\;\;\;\left(t \cdot \left(x \cdot z\right)\right) \cdot \left(18 \cdot y\right)\\ \mathbf{elif}\;b \cdot c \leq 3.45 \cdot 10^{-62}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;b \cdot c \leq 5.8 \cdot 10^{+44}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 2.6 \cdot 10^{+253}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 44.6% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
t_1 := b \cdot c - 4 \cdot \left(x \cdot i\right)\\
t_2 := -4 \cdot \left(t \cdot a\right)\\
t_3 := 18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\
\mathbf{if}\;t \leq -1.65 \cdot 10^{+159}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;t \leq -2.8 \cdot 10^{+26}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t \leq -2.25 \cdot 10^{-263}:\\
\;\;\;\;t\_1\\

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

\mathbf{elif}\;t \leq 4.5 \cdot 10^{-22}:\\
\;\;\;\;\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right)\\

\mathbf{elif}\;t \leq 1.1 \cdot 10^{+31}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 5.5 \cdot 10^{+245}:\\
\;\;\;\;t\_2\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -1.6499999999999999e159 or 5.4999999999999997e245 < t

    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. Simplified92.3%

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

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

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

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

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

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

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

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

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

    if -1.6499999999999999e159 < t < -2.8e26 or 1.10000000000000005e31 < t < 5.4999999999999997e245

    1. Initial program 86.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. Simplified88.7%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*81.9%

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

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

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

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

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

    if -2.8e26 < t < -2.2499999999999999e-263 or 4.49999999999999987e-22 < t < 1.10000000000000005e31

    1. Initial program 85.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. Simplified88.6%

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

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

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

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

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

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

    if -2.2499999999999999e-263 < t < 1.8999999999999999e-66

    1. Initial program 80.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. Simplified85.2%

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

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

    if 1.8999999999999999e-66 < t < 4.49999999999999987e-22

    1. Initial program 69.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. Simplified69.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.65 \cdot 10^{+159}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{elif}\;t \leq -2.8 \cdot 10^{+26}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;t \leq -2.25 \cdot 10^{-263}:\\ \;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\ \mathbf{elif}\;t \leq 1.9 \cdot 10^{-66}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;t \leq 4.5 \cdot 10^{-22}:\\ \;\;\;\;\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right)\\ \mathbf{elif}\;t \leq 1.1 \cdot 10^{+31}:\\ \;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\ \mathbf{elif}\;t \leq 5.5 \cdot 10^{+245}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 35.2% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.55 \cdot 10^{+223}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -7.6 \cdot 10^{-32}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 5.2 \cdot 10^{-63}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;b \cdot c \leq 2.2 \cdot 10^{+46}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 4 \cdot 10^{+253}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= (* b c) -1.55e+223)
   (* b c)
   (if (<= (* b c) -7.6e-32)
     (* 18.0 (* t (* x (* y z))))
     (if (<= (* b c) 5.2e-63)
       (* -4.0 (* t a))
       (if (<= (* b c) 2.2e+46)
         (* x (* i -4.0))
         (if (<= (* b c) 4e+253) (* 18.0 (* x (* z (* y t)))) (* b c)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((b * c) <= -1.55e+223) {
		tmp = b * c;
	} else if ((b * c) <= -7.6e-32) {
		tmp = 18.0 * (t * (x * (y * z)));
	} else if ((b * c) <= 5.2e-63) {
		tmp = -4.0 * (t * a);
	} else if ((b * c) <= 2.2e+46) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 4e+253) {
		tmp = 18.0 * (x * (z * (y * t)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((b * c) <= (-1.55d+223)) then
        tmp = b * c
    else if ((b * c) <= (-7.6d-32)) then
        tmp = 18.0d0 * (t * (x * (y * z)))
    else if ((b * c) <= 5.2d-63) then
        tmp = (-4.0d0) * (t * a)
    else if ((b * c) <= 2.2d+46) then
        tmp = x * (i * (-4.0d0))
    else if ((b * c) <= 4d+253) then
        tmp = 18.0d0 * (x * (z * (y * t)))
    else
        tmp = b * c
    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 tmp;
	if ((b * c) <= -1.55e+223) {
		tmp = b * c;
	} else if ((b * c) <= -7.6e-32) {
		tmp = 18.0 * (t * (x * (y * z)));
	} else if ((b * c) <= 5.2e-63) {
		tmp = -4.0 * (t * a);
	} else if ((b * c) <= 2.2e+46) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 4e+253) {
		tmp = 18.0 * (x * (z * (y * t)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (b * c) <= -1.55e+223:
		tmp = b * c
	elif (b * c) <= -7.6e-32:
		tmp = 18.0 * (t * (x * (y * z)))
	elif (b * c) <= 5.2e-63:
		tmp = -4.0 * (t * a)
	elif (b * c) <= 2.2e+46:
		tmp = x * (i * -4.0)
	elif (b * c) <= 4e+253:
		tmp = 18.0 * (x * (z * (y * t)))
	else:
		tmp = b * c
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (Float64(b * c) <= -1.55e+223)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -7.6e-32)
		tmp = Float64(18.0 * Float64(t * Float64(x * Float64(y * z))));
	elseif (Float64(b * c) <= 5.2e-63)
		tmp = Float64(-4.0 * Float64(t * a));
	elseif (Float64(b * c) <= 2.2e+46)
		tmp = Float64(x * Float64(i * -4.0));
	elseif (Float64(b * c) <= 4e+253)
		tmp = Float64(18.0 * Float64(x * Float64(z * Float64(y * t))));
	else
		tmp = Float64(b * c);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((b * c) <= -1.55e+223)
		tmp = b * c;
	elseif ((b * c) <= -7.6e-32)
		tmp = 18.0 * (t * (x * (y * z)));
	elseif ((b * c) <= 5.2e-63)
		tmp = -4.0 * (t * a);
	elseif ((b * c) <= 2.2e+46)
		tmp = x * (i * -4.0);
	elseif ((b * c) <= 4e+253)
		tmp = 18.0 * (x * (z * (y * t)));
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -1.55e+223], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -7.6e-32], N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 5.2e-63], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2.2e+46], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 4e+253], N[(18.0 * N[(x * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1.55 \cdot 10^{+223}:\\
\;\;\;\;b \cdot c\\

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

\mathbf{elif}\;b \cdot c \leq 5.2 \cdot 10^{-63}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (*.f64 b c) < -1.54999999999999991e223 or 3.9999999999999997e253 < (*.f64 b c)

    1. Initial program 76.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. Simplified79.7%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*74.6%

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

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

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

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

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

    if -1.54999999999999991e223 < (*.f64 b c) < -7.60000000000000015e-32

    1. Initial program 78.2%

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

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

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

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

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

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

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

    if -7.60000000000000015e-32 < (*.f64 b c) < 5.2000000000000003e-63

    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. Simplified92.5%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*85.5%

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

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

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

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

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

    if 5.2000000000000003e-63 < (*.f64 b c) < 2.2e46

    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. Simplified88.8%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*85.1%

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

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

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

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

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
    7. Step-by-step derivation
      1. associate-*r*38.5%

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

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

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

    if 2.2e46 < (*.f64 b c) < 3.9999999999999997e253

    1. Initial program 91.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. Simplified96.1%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.55 \cdot 10^{+223}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -7.6 \cdot 10^{-32}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 5.2 \cdot 10^{-63}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;b \cdot c \leq 2.2 \cdot 10^{+46}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 4 \cdot 10^{+253}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 35.2% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -5.8 \cdot 10^{+224}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -9.2 \cdot 10^{-31}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 3.4 \cdot 10^{-61}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;b \cdot c \leq 4.2 \cdot 10^{+44}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+254}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= (* b c) -5.8e+224)
   (* b c)
   (if (<= (* b c) -9.2e-31)
     (* t (* 18.0 (* x (* y z))))
     (if (<= (* b c) 3.4e-61)
       (* -4.0 (* t a))
       (if (<= (* b c) 4.2e+44)
         (* x (* i -4.0))
         (if (<= (* b c) 2e+254) (* 18.0 (* x (* z (* y t)))) (* b c)))))))
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) <= -5.8e+224) {
		tmp = b * c;
	} else if ((b * c) <= -9.2e-31) {
		tmp = t * (18.0 * (x * (y * z)));
	} else if ((b * c) <= 3.4e-61) {
		tmp = -4.0 * (t * a);
	} else if ((b * c) <= 4.2e+44) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 2e+254) {
		tmp = 18.0 * (x * (z * (y * t)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((b * c) <= (-5.8d+224)) then
        tmp = b * c
    else if ((b * c) <= (-9.2d-31)) then
        tmp = t * (18.0d0 * (x * (y * z)))
    else if ((b * c) <= 3.4d-61) then
        tmp = (-4.0d0) * (t * a)
    else if ((b * c) <= 4.2d+44) then
        tmp = x * (i * (-4.0d0))
    else if ((b * c) <= 2d+254) then
        tmp = 18.0d0 * (x * (z * (y * t)))
    else
        tmp = b * c
    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 tmp;
	if ((b * c) <= -5.8e+224) {
		tmp = b * c;
	} else if ((b * c) <= -9.2e-31) {
		tmp = t * (18.0 * (x * (y * z)));
	} else if ((b * c) <= 3.4e-61) {
		tmp = -4.0 * (t * a);
	} else if ((b * c) <= 4.2e+44) {
		tmp = x * (i * -4.0);
	} else if ((b * c) <= 2e+254) {
		tmp = 18.0 * (x * (z * (y * t)));
	} else {
		tmp = b * c;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (b * c) <= -5.8e+224:
		tmp = b * c
	elif (b * c) <= -9.2e-31:
		tmp = t * (18.0 * (x * (y * z)))
	elif (b * c) <= 3.4e-61:
		tmp = -4.0 * (t * a)
	elif (b * c) <= 4.2e+44:
		tmp = x * (i * -4.0)
	elif (b * c) <= 2e+254:
		tmp = 18.0 * (x * (z * (y * t)))
	else:
		tmp = b * c
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (Float64(b * c) <= -5.8e+224)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -9.2e-31)
		tmp = Float64(t * Float64(18.0 * Float64(x * Float64(y * z))));
	elseif (Float64(b * c) <= 3.4e-61)
		tmp = Float64(-4.0 * Float64(t * a));
	elseif (Float64(b * c) <= 4.2e+44)
		tmp = Float64(x * Float64(i * -4.0));
	elseif (Float64(b * c) <= 2e+254)
		tmp = Float64(18.0 * Float64(x * Float64(z * Float64(y * t))));
	else
		tmp = Float64(b * c);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((b * c) <= -5.8e+224)
		tmp = b * c;
	elseif ((b * c) <= -9.2e-31)
		tmp = t * (18.0 * (x * (y * z)));
	elseif ((b * c) <= 3.4e-61)
		tmp = -4.0 * (t * a);
	elseif ((b * c) <= 4.2e+44)
		tmp = x * (i * -4.0);
	elseif ((b * c) <= 2e+254)
		tmp = 18.0 * (x * (z * (y * t)));
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -5.8e+224], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -9.2e-31], N[(t * N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 3.4e-61], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 4.2e+44], N[(x * N[(i * -4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 2e+254], N[(18.0 * N[(x * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -5.8 \cdot 10^{+224}:\\
\;\;\;\;b \cdot c\\

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

\mathbf{elif}\;b \cdot c \leq 3.4 \cdot 10^{-61}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (*.f64 b c) < -5.79999999999999978e224 or 1.9999999999999999e254 < (*.f64 b c)

    1. Initial program 76.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. Simplified79.7%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*74.6%

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

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

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

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

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

    if -5.79999999999999978e224 < (*.f64 b c) < -9.1999999999999994e-31

    1. Initial program 78.2%

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

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

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

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

    if -9.1999999999999994e-31 < (*.f64 b c) < 3.3999999999999998e-61

    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. Simplified92.5%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*85.5%

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

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

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

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

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

    if 3.3999999999999998e-61 < (*.f64 b c) < 4.19999999999999974e44

    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. Simplified88.8%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*85.1%

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

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

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

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

      \[\leadsto \color{blue}{-4 \cdot \left(i \cdot x\right)} \]
    7. Step-by-step derivation
      1. associate-*r*38.5%

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

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

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

    if 4.19999999999999974e44 < (*.f64 b c) < 1.9999999999999999e254

    1. Initial program 91.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. Simplified96.1%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -5.8 \cdot 10^{+224}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -9.2 \cdot 10^{-31}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 3.4 \cdot 10^{-61}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{elif}\;b \cdot c \leq 4.2 \cdot 10^{+44}:\\ \;\;\;\;x \cdot \left(i \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 2 \cdot 10^{+254}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 51.2% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
t_1 := t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) + a \cdot -4\right)\\
\mathbf{if}\;b \cdot c \leq -6.6 \cdot 10^{+224}:\\
\;\;\;\;b \cdot c\\

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

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

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

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


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

    1. Initial program 74.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. Simplified77.4%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*74.2%

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

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

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

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

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

    if -6.59999999999999992e224 < (*.f64 b c) < -4.40000000000000003e-24 or -7.5000000000000001e-101 < (*.f64 b c) < 5.2999999999999999e-21

    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. Simplified87.4%

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

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

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

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

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

        \[\leadsto t \cdot \left(\left(y \cdot z\right) \cdot \left(18 \cdot x\right) + \left(-\color{blue}{a \cdot 4}\right)\right) \]
      5. distribute-rgt-neg-in61.2%

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

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

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

    if -4.40000000000000003e-24 < (*.f64 b c) < -7.5000000000000001e-101

    1. Initial program 94.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. Simplified99.7%

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

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

        \[\leadsto \color{blue}{\left(-4\right)} \cdot \left(i \cdot x\right) + j \cdot \left(k \cdot -27\right) \]
      2. distribute-lft-neg-in71.1%

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

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

        \[\leadsto \left(-\color{blue}{i \cdot \left(x \cdot 4\right)}\right) + j \cdot \left(k \cdot -27\right) \]
      5. distribute-rgt-neg-in71.1%

        \[\leadsto \color{blue}{i \cdot \left(-x \cdot 4\right)} + j \cdot \left(k \cdot -27\right) \]
      6. distribute-rgt-neg-in71.1%

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

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

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

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

    if 5.2999999999999999e-21 < (*.f64 b c)

    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. Simplified88.8%

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -6.6 \cdot 10^{+224}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -4.4 \cdot 10^{-24}:\\ \;\;\;\;t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) + a \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq -7.5 \cdot 10^{-101}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + i \cdot \left(x \cdot -4\right)\\ \mathbf{elif}\;b \cdot c \leq 5.3 \cdot 10^{-21}:\\ \;\;\;\;t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) + a \cdot -4\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 79.7% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(j \cdot 27\right) \cdot k\\ \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+246}:\\ \;\;\;\;j \cdot \left(k \cdot -27 + 18 \cdot \frac{t \cdot \left(x \cdot \left(y \cdot z\right)\right)}{j}\right)\\ \mathbf{elif}\;t\_1 \leq 10^{+88}:\\ \;\;\;\;\left(b \cdot c + t \cdot \left(\left(x \cdot 18\right) \cdot \left(y \cdot z\right) - a \cdot 4\right)\right) - \left(x \cdot 4\right) \cdot i\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(i \cdot -4 + 18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* (* j 27.0) k)))
   (if (<= t_1 -1e+246)
     (* j (+ (* k -27.0) (* 18.0 (/ (* t (* x (* y z))) j))))
     (if (<= t_1 1e+88)
       (-
        (+ (* b c) (* t (- (* (* x 18.0) (* y z)) (* a 4.0))))
        (* (* x 4.0) i))
       (+ (* x (+ (* i -4.0) (* 18.0 (* t (* y z))))) (* j (* k -27.0)))))))
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+246) {
		tmp = j * ((k * -27.0) + (18.0 * ((t * (x * (y * z))) / j)));
	} else if (t_1 <= 1e+88) {
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * 4.0) * i);
	} else {
		tmp = (x * ((i * -4.0) + (18.0 * (t * (y * z))))) + (j * (k * -27.0));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: tmp
    t_1 = (j * 27.0d0) * k
    if (t_1 <= (-1d+246)) then
        tmp = j * ((k * (-27.0d0)) + (18.0d0 * ((t * (x * (y * z))) / j)))
    else if (t_1 <= 1d+88) then
        tmp = ((b * c) + (t * (((x * 18.0d0) * (y * z)) - (a * 4.0d0)))) - ((x * 4.0d0) * i)
    else
        tmp = (x * ((i * (-4.0d0)) + (18.0d0 * (t * (y * z))))) + (j * (k * (-27.0d0)))
    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 = (j * 27.0) * k;
	double tmp;
	if (t_1 <= -1e+246) {
		tmp = j * ((k * -27.0) + (18.0 * ((t * (x * (y * z))) / j)));
	} else if (t_1 <= 1e+88) {
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * 4.0) * i);
	} else {
		tmp = (x * ((i * -4.0) + (18.0 * (t * (y * z))))) + (j * (k * -27.0));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (j * 27.0) * k
	tmp = 0
	if t_1 <= -1e+246:
		tmp = j * ((k * -27.0) + (18.0 * ((t * (x * (y * z))) / j)))
	elif t_1 <= 1e+88:
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * 4.0) * i)
	else:
		tmp = (x * ((i * -4.0) + (18.0 * (t * (y * z))))) + (j * (k * -27.0))
	return tmp
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+246)
		tmp = Float64(j * Float64(Float64(k * -27.0) + Float64(18.0 * Float64(Float64(t * Float64(x * Float64(y * z))) / j))));
	elseif (t_1 <= 1e+88)
		tmp = Float64(Float64(Float64(b * c) + Float64(t * Float64(Float64(Float64(x * 18.0) * Float64(y * z)) - Float64(a * 4.0)))) - Float64(Float64(x * 4.0) * i));
	else
		tmp = Float64(Float64(x * Float64(Float64(i * -4.0) + Float64(18.0 * Float64(t * Float64(y * z))))) + Float64(j * Float64(k * -27.0)));
	end
	return tmp
end
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+246)
		tmp = j * ((k * -27.0) + (18.0 * ((t * (x * (y * z))) / j)));
	elseif (t_1 <= 1e+88)
		tmp = ((b * c) + (t * (((x * 18.0) * (y * z)) - (a * 4.0)))) - ((x * 4.0) * i);
	else
		tmp = (x * ((i * -4.0) + (18.0 * (t * (y * z))))) + (j * (k * -27.0));
	end
	tmp_2 = tmp;
end
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, -1e+246], N[(j * N[(N[(k * -27.0), $MachinePrecision] + N[(18.0 * N[(N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 1e+88], N[(N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(N[(x * 18.0), $MachinePrecision] * N[(y * z), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(x * 4.0), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(N[(i * -4.0), $MachinePrecision] + N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq -1 \cdot 10^{+246}:\\
\;\;\;\;j \cdot \left(k \cdot -27 + 18 \cdot \frac{t \cdot \left(x \cdot \left(y \cdot z\right)\right)}{j}\right)\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -1.00000000000000007e246

    1. Initial program 57.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. Simplified62.4%

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

      \[\leadsto \color{blue}{18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Taylor expanded in j around inf 76.7%

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

    if -1.00000000000000007e246 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 9.99999999999999959e87

    1. Initial program 87.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. Simplified92.6%

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

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

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

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

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

    if 9.99999999999999959e87 < (*.f64 (*.f64 j #s(literal 27 binary64)) k)

    1. Initial program 76.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. Simplified76.5%

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

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

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

Alternative 8: 78.2% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
t_1 := t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\
t_2 := b \cdot c + t\_1\\
\mathbf{if}\;t \leq -8.5 \cdot 10^{-40}:\\
\;\;\;\;t\_2\\

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

\mathbf{elif}\;t \leq 2.3 \cdot 10^{-11}:\\
\;\;\;\;x \cdot \left(i \cdot -4 + 18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\

\mathbf{elif}\;t \leq 3.3 \cdot 10^{+89}:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;t\_1 - 4 \cdot \left(x \cdot i\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -8.4999999999999998e-40 or 2.30000000000000014e-11 < t < 3.29999999999999974e89

    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. Simplified92.5%

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

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

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

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

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

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

    if -8.4999999999999998e-40 < t < 1.80000000000000006e-66

    1. Initial program 82.7%

      \[\left(\left(\left(\left(\left(\left(x \cdot 18\right) \cdot y\right) \cdot z\right) \cdot t - \left(a \cdot 4\right) \cdot t\right) + b \cdot c\right) - \left(x \cdot 4\right) \cdot i\right) - \left(j \cdot 27\right) \cdot k \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 92.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. distribute-lft-out92.0%

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

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

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

    if 1.80000000000000006e-66 < t < 2.30000000000000014e-11

    1. Initial program 66.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. Simplified71.5%

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

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

    if 3.29999999999999974e89 < t

    1. Initial program 78.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. Simplified85.3%

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8.5 \cdot 10^{-40}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{elif}\;t \leq 1.8 \cdot 10^{-66}:\\ \;\;\;\;\left(b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{elif}\;t \leq 2.3 \cdot 10^{-11}:\\ \;\;\;\;x \cdot \left(i \cdot -4 + 18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;t \leq 3.3 \cdot 10^{+89}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right) - 4 \cdot \left(x \cdot i\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 73.4% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := b \cdot c - 4 \cdot \left(x \cdot i\right)\\ t_2 := b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{if}\;t \leq -4.4 \cdot 10^{-120}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t \leq 1.55 \cdot 10^{-100}:\\ \;\;\;\;t\_1 - \left(j \cdot 27\right) \cdot k\\ \mathbf{elif}\;t \leq 3.6 \cdot 10^{-11}:\\ \;\;\;\;x \cdot \left(i \cdot -4 + 18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;t \leq 9.8 \cdot 10^{+16}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (- (* b c) (* 4.0 (* x i))))
        (t_2 (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))))
   (if (<= t -4.4e-120)
     t_2
     (if (<= t 1.55e-100)
       (- t_1 (* (* j 27.0) k))
       (if (<= t 3.6e-11)
         (+ (* x (+ (* i -4.0) (* 18.0 (* t (* y z))))) (* j (* k -27.0)))
         (if (<= t 9.8e+16) t_1 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 = (b * c) - (4.0 * (x * i));
	double t_2 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	double tmp;
	if (t <= -4.4e-120) {
		tmp = t_2;
	} else if (t <= 1.55e-100) {
		tmp = t_1 - ((j * 27.0) * k);
	} else if (t <= 3.6e-11) {
		tmp = (x * ((i * -4.0) + (18.0 * (t * (y * z))))) + (j * (k * -27.0));
	} else if (t <= 9.8e+16) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = (b * c) - (4.0d0 * (x * i))
    t_2 = (b * c) + (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0)))
    if (t <= (-4.4d-120)) then
        tmp = t_2
    else if (t <= 1.55d-100) then
        tmp = t_1 - ((j * 27.0d0) * k)
    else if (t <= 3.6d-11) then
        tmp = (x * ((i * (-4.0d0)) + (18.0d0 * (t * (y * z))))) + (j * (k * (-27.0d0)))
    else if (t <= 9.8d+16) then
        tmp = t_1
    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 = (b * c) - (4.0 * (x * i));
	double t_2 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	double tmp;
	if (t <= -4.4e-120) {
		tmp = t_2;
	} else if (t <= 1.55e-100) {
		tmp = t_1 - ((j * 27.0) * k);
	} else if (t <= 3.6e-11) {
		tmp = (x * ((i * -4.0) + (18.0 * (t * (y * z))))) + (j * (k * -27.0));
	} else if (t <= 9.8e+16) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (b * c) - (4.0 * (x * i))
	t_2 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))
	tmp = 0
	if t <= -4.4e-120:
		tmp = t_2
	elif t <= 1.55e-100:
		tmp = t_1 - ((j * 27.0) * k)
	elif t <= 3.6e-11:
		tmp = (x * ((i * -4.0) + (18.0 * (t * (y * z))))) + (j * (k * -27.0))
	elif t <= 9.8e+16:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(b * c) - Float64(4.0 * Float64(x * i)))
	t_2 = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))))
	tmp = 0.0
	if (t <= -4.4e-120)
		tmp = t_2;
	elseif (t <= 1.55e-100)
		tmp = Float64(t_1 - Float64(Float64(j * 27.0) * k));
	elseif (t <= 3.6e-11)
		tmp = Float64(Float64(x * Float64(Float64(i * -4.0) + Float64(18.0 * Float64(t * Float64(y * z))))) + Float64(j * Float64(k * -27.0)));
	elseif (t <= 9.8e+16)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (b * c) - (4.0 * (x * i));
	t_2 = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	tmp = 0.0;
	if (t <= -4.4e-120)
		tmp = t_2;
	elseif (t <= 1.55e-100)
		tmp = t_1 - ((j * 27.0) * k);
	elseif (t <= 3.6e-11)
		tmp = (x * ((i * -4.0) + (18.0 * (t * (y * z))))) + (j * (k * -27.0));
	elseif (t <= 9.8e+16)
		tmp = t_1;
	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[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -4.4e-120], t$95$2, If[LessEqual[t, 1.55e-100], N[(t$95$1 - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.6e-11], N[(N[(x * N[(N[(i * -4.0), $MachinePrecision] + N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 9.8e+16], t$95$1, t$95$2]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := b \cdot c - 4 \cdot \left(x \cdot i\right)\\
t_2 := b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\
\mathbf{if}\;t \leq -4.4 \cdot 10^{-120}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t \leq 1.55 \cdot 10^{-100}:\\
\;\;\;\;t\_1 - \left(j \cdot 27\right) \cdot k\\

\mathbf{elif}\;t \leq 3.6 \cdot 10^{-11}:\\
\;\;\;\;x \cdot \left(i \cdot -4 + 18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\

\mathbf{elif}\;t \leq 9.8 \cdot 10^{+16}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -4.40000000000000025e-120 or 9.8e16 < t

    1. Initial program 85.6%

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

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

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

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

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

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

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

    if -4.40000000000000025e-120 < t < 1.5499999999999999e-100

    1. Initial program 82.6%

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

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

    if 1.5499999999999999e-100 < t < 3.59999999999999985e-11

    1. Initial program 71.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. Simplified79.1%

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

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

    if 3.59999999999999985e-11 < t < 9.8e16

    1. Initial program 100.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. Simplified100.0%

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -4.4 \cdot 10^{-120}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{elif}\;t \leq 1.55 \cdot 10^{-100}:\\ \;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\ \mathbf{elif}\;t \leq 3.6 \cdot 10^{-11}:\\ \;\;\;\;x \cdot \left(i \cdot -4 + 18 \cdot \left(t \cdot \left(y \cdot z\right)\right)\right) + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;t \leq 9.8 \cdot 10^{+16}:\\ \;\;\;\;b \cdot c - 4 \cdot \left(x \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 45.9% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := b \cdot c + j \cdot \left(k \cdot -27\right)\\ t_2 := 18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{if}\;t \leq -3 \cdot 10^{+153}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t \leq 1.35 \cdot 10^{-66}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 3.8 \cdot 10^{-22}:\\ \;\;\;\;\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right)\\ \mathbf{elif}\;t \leq 7.2 \cdot 10^{+30}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 1.6 \cdot 10^{+246}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\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 (+ (* b c) (* j (* k -27.0)))) (t_2 (* 18.0 (* x (* z (* y t))))))
   (if (<= t -3e+153)
     t_2
     (if (<= t 1.35e-66)
       t_1
       (if (<= t 3.8e-22)
         (* (* 18.0 y) (* x (* z t)))
         (if (<= t 7.2e+30) t_1 (if (<= t 1.6e+246) (* -4.0 (* t a)) 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 = (b * c) + (j * (k * -27.0));
	double t_2 = 18.0 * (x * (z * (y * t)));
	double tmp;
	if (t <= -3e+153) {
		tmp = t_2;
	} else if (t <= 1.35e-66) {
		tmp = t_1;
	} else if (t <= 3.8e-22) {
		tmp = (18.0 * y) * (x * (z * t));
	} else if (t <= 7.2e+30) {
		tmp = t_1;
	} else if (t <= 1.6e+246) {
		tmp = -4.0 * (t * a);
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = (b * c) + (j * (k * (-27.0d0)))
    t_2 = 18.0d0 * (x * (z * (y * t)))
    if (t <= (-3d+153)) then
        tmp = t_2
    else if (t <= 1.35d-66) then
        tmp = t_1
    else if (t <= 3.8d-22) then
        tmp = (18.0d0 * y) * (x * (z * t))
    else if (t <= 7.2d+30) then
        tmp = t_1
    else if (t <= 1.6d+246) then
        tmp = (-4.0d0) * (t * a)
    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 = (b * c) + (j * (k * -27.0));
	double t_2 = 18.0 * (x * (z * (y * t)));
	double tmp;
	if (t <= -3e+153) {
		tmp = t_2;
	} else if (t <= 1.35e-66) {
		tmp = t_1;
	} else if (t <= 3.8e-22) {
		tmp = (18.0 * y) * (x * (z * t));
	} else if (t <= 7.2e+30) {
		tmp = t_1;
	} else if (t <= 1.6e+246) {
		tmp = -4.0 * (t * a);
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (b * c) + (j * (k * -27.0))
	t_2 = 18.0 * (x * (z * (y * t)))
	tmp = 0
	if t <= -3e+153:
		tmp = t_2
	elif t <= 1.35e-66:
		tmp = t_1
	elif t <= 3.8e-22:
		tmp = (18.0 * y) * (x * (z * t))
	elif t <= 7.2e+30:
		tmp = t_1
	elif t <= 1.6e+246:
		tmp = -4.0 * (t * a)
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	t_1 = Float64(Float64(b * c) + Float64(j * Float64(k * -27.0)))
	t_2 = Float64(18.0 * Float64(x * Float64(z * Float64(y * t))))
	tmp = 0.0
	if (t <= -3e+153)
		tmp = t_2;
	elseif (t <= 1.35e-66)
		tmp = t_1;
	elseif (t <= 3.8e-22)
		tmp = Float64(Float64(18.0 * y) * Float64(x * Float64(z * t)));
	elseif (t <= 7.2e+30)
		tmp = t_1;
	elseif (t <= 1.6e+246)
		tmp = Float64(-4.0 * Float64(t * a));
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	t_1 = (b * c) + (j * (k * -27.0));
	t_2 = 18.0 * (x * (z * (y * t)));
	tmp = 0.0;
	if (t <= -3e+153)
		tmp = t_2;
	elseif (t <= 1.35e-66)
		tmp = t_1;
	elseif (t <= 3.8e-22)
		tmp = (18.0 * y) * (x * (z * t));
	elseif (t <= 7.2e+30)
		tmp = t_1;
	elseif (t <= 1.6e+246)
		tmp = -4.0 * (t * a);
	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[(b * c), $MachinePrecision] + N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(18.0 * N[(x * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -3e+153], t$95$2, If[LessEqual[t, 1.35e-66], t$95$1, If[LessEqual[t, 3.8e-22], N[(N[(18.0 * y), $MachinePrecision] * N[(x * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 7.2e+30], t$95$1, If[LessEqual[t, 1.6e+246], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := b \cdot c + j \cdot \left(k \cdot -27\right)\\
t_2 := 18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\
\mathbf{if}\;t \leq -3 \cdot 10^{+153}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t \leq 1.35 \cdot 10^{-66}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 3.8 \cdot 10^{-22}:\\
\;\;\;\;\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right)\\

\mathbf{elif}\;t \leq 7.2 \cdot 10^{+30}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 1.6 \cdot 10^{+246}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if t < -3.00000000000000019e153 or 1.60000000000000007e246 < t

    1. Initial program 84.9%

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

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

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

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

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

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

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

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

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

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

    if -3.00000000000000019e153 < t < 1.34999999999999998e-66 or 3.80000000000000023e-22 < t < 7.2000000000000004e30

    1. Initial program 84.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. Simplified88.6%

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

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

    if 1.34999999999999998e-66 < t < 3.80000000000000023e-22

    1. Initial program 69.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. Simplified69.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 7.2000000000000004e30 < t < 1.60000000000000007e246

    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. Simplified85.6%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*79.2%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -3 \cdot 10^{+153}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{elif}\;t \leq 1.35 \cdot 10^{-66}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;t \leq 3.8 \cdot 10^{-22}:\\ \;\;\;\;\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right)\\ \mathbf{elif}\;t \leq 7.2 \cdot 10^{+30}:\\ \;\;\;\;b \cdot c + j \cdot \left(k \cdot -27\right)\\ \mathbf{elif}\;t \leq 1.6 \cdot 10^{+246}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 68.6% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(j \cdot 27\right) \cdot k\\ \mathbf{if}\;t\_1 \leq -5 \cdot 10^{+195} \lor \neg \left(t\_1 \leq 10^{+88}\right):\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + 18 \cdot \left(\left(y \cdot z\right) \cdot \left(x \cdot t\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* (* j 27.0) k)))
   (if (or (<= t_1 -5e+195) (not (<= t_1 1e+88)))
     (+ (* j (* k -27.0)) (* 18.0 (* (* y z) (* x t))))
     (- (* b c) (* 4.0 (+ (* t a) (* x i)))))))
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 <= -5e+195) || !(t_1 <= 1e+88)) {
		tmp = (j * (k * -27.0)) + (18.0 * ((y * z) * (x * t)));
	} else {
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: tmp
    t_1 = (j * 27.0d0) * k
    if ((t_1 <= (-5d+195)) .or. (.not. (t_1 <= 1d+88))) then
        tmp = (j * (k * (-27.0d0))) + (18.0d0 * ((y * z) * (x * t)))
    else
        tmp = (b * c) - (4.0d0 * ((t * a) + (x * i)))
    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 = (j * 27.0) * k;
	double tmp;
	if ((t_1 <= -5e+195) || !(t_1 <= 1e+88)) {
		tmp = (j * (k * -27.0)) + (18.0 * ((y * z) * (x * t)));
	} else {
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (j * 27.0) * k
	tmp = 0
	if (t_1 <= -5e+195) or not (t_1 <= 1e+88):
		tmp = (j * (k * -27.0)) + (18.0 * ((y * z) * (x * t)))
	else:
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)))
	return tmp
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 <= -5e+195) || !(t_1 <= 1e+88))
		tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(18.0 * Float64(Float64(y * z) * Float64(x * t))));
	else
		tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(t * a) + Float64(x * i))));
	end
	return tmp
end
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 <= -5e+195) || ~((t_1 <= 1e+88)))
		tmp = (j * (k * -27.0)) + (18.0 * ((y * z) * (x * t)));
	else
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	end
	tmp_2 = tmp;
end
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, -5e+195], N[Not[LessEqual[t$95$1, 1e+88]], $MachinePrecision]], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(18.0 * N[(N[(y * z), $MachinePrecision] * N[(x * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{+195} \lor \neg \left(t\_1 \leq 10^{+88}\right):\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + 18 \cdot \left(\left(y \cdot z\right) \cdot \left(x \cdot t\right)\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -4.9999999999999998e195 or 9.99999999999999959e87 < (*.f64 (*.f64 j #s(literal 27 binary64)) k)

    1. Initial program 72.0%

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

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

      \[\leadsto \color{blue}{18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*76.4%

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

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

    if -4.9999999999999998e195 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 9.99999999999999959e87

    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 y around 0 78.5%

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

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

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

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

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

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

Alternative 12: 69.2% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(j \cdot 27\right) \cdot k\\ \mathbf{if}\;t\_1 \leq -5 \cdot 10^{+195}:\\ \;\;\;\;j \cdot \left(k \cdot -27 + 18 \cdot \frac{t \cdot \left(x \cdot \left(y \cdot z\right)\right)}{j}\right)\\ \mathbf{elif}\;t\_1 \leq 10^{+88}:\\ \;\;\;\;b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;j \cdot \left(k \cdot -27\right) + 18 \cdot \left(\left(y \cdot z\right) \cdot \left(x \cdot t\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (let* ((t_1 (* (* j 27.0) k)))
   (if (<= t_1 -5e+195)
     (* j (+ (* k -27.0) (* 18.0 (/ (* t (* x (* y z))) j))))
     (if (<= t_1 1e+88)
       (- (* b c) (* 4.0 (+ (* t a) (* x i))))
       (+ (* j (* k -27.0)) (* 18.0 (* (* y z) (* x t))))))))
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 <= -5e+195) {
		tmp = j * ((k * -27.0) + (18.0 * ((t * (x * (y * z))) / j)));
	} else if (t_1 <= 1e+88) {
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	} else {
		tmp = (j * (k * -27.0)) + (18.0 * ((y * z) * (x * t)));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: t_1
    real(8) :: tmp
    t_1 = (j * 27.0d0) * k
    if (t_1 <= (-5d+195)) then
        tmp = j * ((k * (-27.0d0)) + (18.0d0 * ((t * (x * (y * z))) / j)))
    else if (t_1 <= 1d+88) then
        tmp = (b * c) - (4.0d0 * ((t * a) + (x * i)))
    else
        tmp = (j * (k * (-27.0d0))) + (18.0d0 * ((y * z) * (x * t)))
    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 = (j * 27.0) * k;
	double tmp;
	if (t_1 <= -5e+195) {
		tmp = j * ((k * -27.0) + (18.0 * ((t * (x * (y * z))) / j)));
	} else if (t_1 <= 1e+88) {
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	} else {
		tmp = (j * (k * -27.0)) + (18.0 * ((y * z) * (x * t)));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	t_1 = (j * 27.0) * k
	tmp = 0
	if t_1 <= -5e+195:
		tmp = j * ((k * -27.0) + (18.0 * ((t * (x * (y * z))) / j)))
	elif t_1 <= 1e+88:
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)))
	else:
		tmp = (j * (k * -27.0)) + (18.0 * ((y * z) * (x * t)))
	return tmp
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 <= -5e+195)
		tmp = Float64(j * Float64(Float64(k * -27.0) + Float64(18.0 * Float64(Float64(t * Float64(x * Float64(y * z))) / j))));
	elseif (t_1 <= 1e+88)
		tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(t * a) + Float64(x * i))));
	else
		tmp = Float64(Float64(j * Float64(k * -27.0)) + Float64(18.0 * Float64(Float64(y * z) * Float64(x * t))));
	end
	return tmp
end
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 <= -5e+195)
		tmp = j * ((k * -27.0) + (18.0 * ((t * (x * (y * z))) / j)));
	elseif (t_1 <= 1e+88)
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	else
		tmp = (j * (k * -27.0)) + (18.0 * ((y * z) * (x * t)));
	end
	tmp_2 = tmp;
end
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, -5e+195], N[(j * N[(N[(k * -27.0), $MachinePrecision] + N[(18.0 * N[(N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 1e+88], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(j * N[(k * -27.0), $MachinePrecision]), $MachinePrecision] + N[(18.0 * N[(N[(y * z), $MachinePrecision] * N[(x * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left(j \cdot 27\right) \cdot k\\
\mathbf{if}\;t\_1 \leq -5 \cdot 10^{+195}:\\
\;\;\;\;j \cdot \left(k \cdot -27 + 18 \cdot \frac{t \cdot \left(x \cdot \left(y \cdot z\right)\right)}{j}\right)\\

\mathbf{elif}\;t\_1 \leq 10^{+88}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 j #s(literal 27 binary64)) k) < -4.9999999999999998e195

    1. Initial program 64.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. Simplified68.4%

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

      \[\leadsto \color{blue}{18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Taylor expanded in j around inf 80.4%

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

    if -4.9999999999999998e195 < (*.f64 (*.f64 j #s(literal 27 binary64)) k) < 9.99999999999999959e87

    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 y around 0 78.5%

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

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

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

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

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

    if 9.99999999999999959e87 < (*.f64 (*.f64 j #s(literal 27 binary64)) k)

    1. Initial program 76.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. Simplified76.5%

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

      \[\leadsto \color{blue}{18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)} + j \cdot \left(k \cdot -27\right) \]
    5. Step-by-step derivation
      1. associate-*r*76.6%

        \[\leadsto 18 \cdot \color{blue}{\left(\left(t \cdot x\right) \cdot \left(y \cdot z\right)\right)} + j \cdot \left(k \cdot -27\right) \]
    6. Simplified76.6%

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

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

Alternative 13: 50.9% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1.52 \cdot 10^{+223}:\\
\;\;\;\;b \cdot c\\

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

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

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


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

    1. Initial program 74.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. Simplified77.4%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*74.2%

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

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

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

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

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

    if -1.52000000000000007e223 < (*.f64 b c) < -7.9999999999999993e23

    1. Initial program 73.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. Simplified77.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -7.9999999999999993e23 < (*.f64 b c) < 1.6500000000000001e-23

    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. Simplified92.7%

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

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

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

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

    if 1.6500000000000001e-23 < (*.f64 b c)

    1. Initial program 84.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. Simplified87.6%

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

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

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

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

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

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

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

Alternative 14: 31.6% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -5.5 \cdot 10^{+194}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \leq -4.8 \cdot 10^{+163}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{elif}\;b \leq -3 \cdot 10^{+36}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \leq -2.5 \cdot 10^{-147}:\\ \;\;\;\;\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right)\\ \mathbf{elif}\;b \leq 2.2 \cdot 10^{-62}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= b -5.5e+194)
   (* b c)
   (if (<= b -4.8e+163)
     (* 18.0 (* x (* z (* y t))))
     (if (<= b -3e+36)
       (* b c)
       (if (<= b -2.5e-147)
         (* (* 18.0 y) (* x (* z t)))
         (if (<= b 2.2e-62) (* -4.0 (* t a)) (* b c)))))))
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 <= -5.5e+194) {
		tmp = b * c;
	} else if (b <= -4.8e+163) {
		tmp = 18.0 * (x * (z * (y * t)));
	} else if (b <= -3e+36) {
		tmp = b * c;
	} else if (b <= -2.5e-147) {
		tmp = (18.0 * y) * (x * (z * t));
	} else if (b <= 2.2e-62) {
		tmp = -4.0 * (t * a);
	} else {
		tmp = b * c;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (b <= (-5.5d+194)) then
        tmp = b * c
    else if (b <= (-4.8d+163)) then
        tmp = 18.0d0 * (x * (z * (y * t)))
    else if (b <= (-3d+36)) then
        tmp = b * c
    else if (b <= (-2.5d-147)) then
        tmp = (18.0d0 * y) * (x * (z * t))
    else if (b <= 2.2d-62) then
        tmp = (-4.0d0) * (t * a)
    else
        tmp = b * c
    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 tmp;
	if (b <= -5.5e+194) {
		tmp = b * c;
	} else if (b <= -4.8e+163) {
		tmp = 18.0 * (x * (z * (y * t)));
	} else if (b <= -3e+36) {
		tmp = b * c;
	} else if (b <= -2.5e-147) {
		tmp = (18.0 * y) * (x * (z * t));
	} else if (b <= 2.2e-62) {
		tmp = -4.0 * (t * a);
	} else {
		tmp = b * c;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if b <= -5.5e+194:
		tmp = b * c
	elif b <= -4.8e+163:
		tmp = 18.0 * (x * (z * (y * t)))
	elif b <= -3e+36:
		tmp = b * c
	elif b <= -2.5e-147:
		tmp = (18.0 * y) * (x * (z * t))
	elif b <= 2.2e-62:
		tmp = -4.0 * (t * a)
	else:
		tmp = b * c
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (b <= -5.5e+194)
		tmp = Float64(b * c);
	elseif (b <= -4.8e+163)
		tmp = Float64(18.0 * Float64(x * Float64(z * Float64(y * t))));
	elseif (b <= -3e+36)
		tmp = Float64(b * c);
	elseif (b <= -2.5e-147)
		tmp = Float64(Float64(18.0 * y) * Float64(x * Float64(z * t)));
	elseif (b <= 2.2e-62)
		tmp = Float64(-4.0 * Float64(t * a));
	else
		tmp = Float64(b * c);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (b <= -5.5e+194)
		tmp = b * c;
	elseif (b <= -4.8e+163)
		tmp = 18.0 * (x * (z * (y * t)));
	elseif (b <= -3e+36)
		tmp = b * c;
	elseif (b <= -2.5e-147)
		tmp = (18.0 * y) * (x * (z * t));
	elseif (b <= 2.2e-62)
		tmp = -4.0 * (t * a);
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[b, -5.5e+194], N[(b * c), $MachinePrecision], If[LessEqual[b, -4.8e+163], N[(18.0 * N[(x * N[(z * N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -3e+36], N[(b * c), $MachinePrecision], If[LessEqual[b, -2.5e-147], N[(N[(18.0 * y), $MachinePrecision] * N[(x * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 2.2e-62], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -5.5 \cdot 10^{+194}:\\
\;\;\;\;b \cdot c\\

\mathbf{elif}\;b \leq -4.8 \cdot 10^{+163}:\\
\;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\

\mathbf{elif}\;b \leq -3 \cdot 10^{+36}:\\
\;\;\;\;b \cdot c\\

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

\mathbf{elif}\;b \leq 2.2 \cdot 10^{-62}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -5.4999999999999999e194 or -4.7999999999999997e163 < b < -3e36 or 2.20000000000000017e-62 < b

    1. Initial program 83.4%

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

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*84.6%

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

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

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

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

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

    if -5.4999999999999999e194 < b < -4.7999999999999997e163

    1. Initial program 71.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. Simplified85.7%

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

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

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

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

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

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

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

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

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

    if -3e36 < b < -2.50000000000000007e-147

    1. Initial program 77.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -2.50000000000000007e-147 < b < 2.20000000000000017e-62

    1. Initial program 87.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. Simplified92.1%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*85.0%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -5.5 \cdot 10^{+194}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \leq -4.8 \cdot 10^{+163}:\\ \;\;\;\;18 \cdot \left(x \cdot \left(z \cdot \left(y \cdot t\right)\right)\right)\\ \mathbf{elif}\;b \leq -3 \cdot 10^{+36}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \leq -2.5 \cdot 10^{-147}:\\ \;\;\;\;\left(18 \cdot y\right) \cdot \left(x \cdot \left(z \cdot t\right)\right)\\ \mathbf{elif}\;b \leq 2.2 \cdot 10^{-62}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 72.8% accurate, 1.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -2.65 \cdot 10^{-120} \lor \neg \left(t \leq 4.7 \cdot 10^{-114}\right):\\ \;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \mathbf{else}:\\ \;\;\;\;\left(b \cdot c - 4 \cdot \left(x \cdot i\right)\right) - \left(j \cdot 27\right) \cdot k\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= t -2.65e-120) (not (<= t 4.7e-114)))
   (+ (* b c) (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))
   (- (- (* b c) (* 4.0 (* x 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) {
	double tmp;
	if ((t <= -2.65e-120) || !(t <= 4.7e-114)) {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	} else {
		tmp = ((b * c) - (4.0 * (x * i))) - ((j * 27.0) * k);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((t <= (-2.65d-120)) .or. (.not. (t <= 4.7d-114))) then
        tmp = (b * c) + (t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0)))
    else
        tmp = ((b * c) - (4.0d0 * (x * i))) - ((j * 27.0d0) * k)
    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 tmp;
	if ((t <= -2.65e-120) || !(t <= 4.7e-114)) {
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	} else {
		tmp = ((b * c) - (4.0 * (x * i))) - ((j * 27.0) * k);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (t <= -2.65e-120) or not (t <= 4.7e-114):
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)))
	else:
		tmp = ((b * c) - (4.0 * (x * i))) - ((j * 27.0) * k)
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((t <= -2.65e-120) || !(t <= 4.7e-114))
		tmp = Float64(Float64(b * c) + Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0))));
	else
		tmp = Float64(Float64(Float64(b * c) - Float64(4.0 * Float64(x * i))) - Float64(Float64(j * 27.0) * k));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((t <= -2.65e-120) || ~((t <= 4.7e-114)))
		tmp = (b * c) + (t * ((18.0 * (x * (y * z))) - (a * 4.0)));
	else
		tmp = ((b * c) - (4.0 * (x * i))) - ((j * 27.0) * k);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[t, -2.65e-120], N[Not[LessEqual[t, 4.7e-114]], $MachinePrecision]], N[(N[(b * c), $MachinePrecision] + N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * 27.0), $MachinePrecision] * k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.65 \cdot 10^{-120} \lor \neg \left(t \leq 4.7 \cdot 10^{-114}\right):\\
\;\;\;\;b \cdot c + t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -2.64999999999999999e-120 or 4.70000000000000006e-114 < t

    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. Simplified87.9%

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

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

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

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

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

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

    if -2.64999999999999999e-120 < t < 4.70000000000000006e-114

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

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

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

Alternative 16: 34.7% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.52 \cdot 10^{+223}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -3.5 \cdot 10^{-30}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 6.5 \cdot 10^{-23}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= (* b c) -1.52e+223)
   (* b c)
   (if (<= (* b c) -3.5e-30)
     (* 18.0 (* t (* x (* y z))))
     (if (<= (* b c) 6.5e-23) (* -4.0 (* t a)) (* b c)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if ((b * c) <= -1.52e+223) {
		tmp = b * c;
	} else if ((b * c) <= -3.5e-30) {
		tmp = 18.0 * (t * (x * (y * z)));
	} else if ((b * c) <= 6.5e-23) {
		tmp = -4.0 * (t * a);
	} else {
		tmp = b * c;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if ((b * c) <= (-1.52d+223)) then
        tmp = b * c
    else if ((b * c) <= (-3.5d-30)) then
        tmp = 18.0d0 * (t * (x * (y * z)))
    else if ((b * c) <= 6.5d-23) then
        tmp = (-4.0d0) * (t * a)
    else
        tmp = b * c
    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 tmp;
	if ((b * c) <= -1.52e+223) {
		tmp = b * c;
	} else if ((b * c) <= -3.5e-30) {
		tmp = 18.0 * (t * (x * (y * z)));
	} else if ((b * c) <= 6.5e-23) {
		tmp = -4.0 * (t * a);
	} else {
		tmp = b * c;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if (b * c) <= -1.52e+223:
		tmp = b * c
	elif (b * c) <= -3.5e-30:
		tmp = 18.0 * (t * (x * (y * z)))
	elif (b * c) <= 6.5e-23:
		tmp = -4.0 * (t * a)
	else:
		tmp = b * c
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (Float64(b * c) <= -1.52e+223)
		tmp = Float64(b * c);
	elseif (Float64(b * c) <= -3.5e-30)
		tmp = Float64(18.0 * Float64(t * Float64(x * Float64(y * z))));
	elseif (Float64(b * c) <= 6.5e-23)
		tmp = Float64(-4.0 * Float64(t * a));
	else
		tmp = Float64(b * c);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if ((b * c) <= -1.52e+223)
		tmp = b * c;
	elseif ((b * c) <= -3.5e-30)
		tmp = 18.0 * (t * (x * (y * z)));
	elseif ((b * c) <= 6.5e-23)
		tmp = -4.0 * (t * a);
	else
		tmp = b * c;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[N[(b * c), $MachinePrecision], -1.52e+223], N[(b * c), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], -3.5e-30], N[(18.0 * N[(t * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(b * c), $MachinePrecision], 6.5e-23], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision], N[(b * c), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1.52 \cdot 10^{+223}:\\
\;\;\;\;b \cdot c\\

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

\mathbf{elif}\;b \cdot c \leq 6.5 \cdot 10^{-23}:\\
\;\;\;\;-4 \cdot \left(t \cdot a\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 b c) < -1.52000000000000007e223 or 6.5e-23 < (*.f64 b c)

    1. Initial program 81.6%

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

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*80.4%

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

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

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

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

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

    if -1.52000000000000007e223 < (*.f64 b c) < -3.5000000000000003e-30

    1. Initial program 78.2%

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

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

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

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

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

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

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

    if -3.5000000000000003e-30 < (*.f64 b c) < 6.5e-23

    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. Simplified92.9%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*86.1%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.52 \cdot 10^{+223}:\\ \;\;\;\;b \cdot c\\ \mathbf{elif}\;b \cdot c \leq -3.5 \cdot 10^{-30}:\\ \;\;\;\;18 \cdot \left(t \cdot \left(x \cdot \left(y \cdot z\right)\right)\right)\\ \mathbf{elif}\;b \cdot c \leq 6.5 \cdot 10^{-23}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot c\\ \end{array} \]
  5. Add Preprocessing

Alternative 17: 61.3% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -6.8 \cdot 10^{-15}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\ \mathbf{elif}\;z \leq 7.5 \cdot 10^{+92}:\\ \;\;\;\;b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (<= z -6.8e-15)
   (* x (- (* 18.0 (* t (* y z))) (* 4.0 i)))
   (if (<= z 7.5e+92)
     (- (* b c) (* 4.0 (+ (* t a) (* x i))))
     (* t (- (* 18.0 (* x (* y z))) (* a 4.0))))))
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 (z <= -6.8e-15) {
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	} else if (z <= 7.5e+92) {
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	} else {
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (z <= (-6.8d-15)) then
        tmp = x * ((18.0d0 * (t * (y * z))) - (4.0d0 * i))
    else if (z <= 7.5d+92) then
        tmp = (b * c) - (4.0d0 * ((t * a) + (x * i)))
    else
        tmp = t * ((18.0d0 * (x * (y * z))) - (a * 4.0d0))
    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 tmp;
	if (z <= -6.8e-15) {
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	} else if (z <= 7.5e+92) {
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	} else {
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if z <= -6.8e-15:
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i))
	elif z <= 7.5e+92:
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)))
	else:
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if (z <= -6.8e-15)
		tmp = Float64(x * Float64(Float64(18.0 * Float64(t * Float64(y * z))) - Float64(4.0 * i)));
	elseif (z <= 7.5e+92)
		tmp = Float64(Float64(b * c) - Float64(4.0 * Float64(Float64(t * a) + Float64(x * i))));
	else
		tmp = Float64(t * Float64(Float64(18.0 * Float64(x * Float64(y * z))) - Float64(a * 4.0)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (z <= -6.8e-15)
		tmp = x * ((18.0 * (t * (y * z))) - (4.0 * i));
	elseif (z <= 7.5e+92)
		tmp = (b * c) - (4.0 * ((t * a) + (x * i)));
	else
		tmp = t * ((18.0 * (x * (y * z))) - (a * 4.0));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[LessEqual[z, -6.8e-15], N[(x * N[(N[(18.0 * N[(t * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(4.0 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7.5e+92], N[(N[(b * c), $MachinePrecision] - N[(4.0 * N[(N[(t * a), $MachinePrecision] + N[(x * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(N[(18.0 * N[(x * N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(a * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.8 \cdot 10^{-15}:\\
\;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\

\mathbf{elif}\;z \leq 7.5 \cdot 10^{+92}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -6.8000000000000001e-15

    1. Initial program 80.6%

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

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

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

    if -6.8000000000000001e-15 < z < 7.49999999999999946e92

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

      \[\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. distribute-lft-out82.7%

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

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

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

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

    if 7.49999999999999946e92 < z

    1. Initial program 73.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. Simplified76.7%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -6.8 \cdot 10^{-15}:\\ \;\;\;\;x \cdot \left(18 \cdot \left(t \cdot \left(y \cdot z\right)\right) - 4 \cdot i\right)\\ \mathbf{elif}\;z \leq 7.5 \cdot 10^{+92}:\\ \;\;\;\;b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \left(18 \cdot \left(x \cdot \left(y \cdot z\right)\right) - a \cdot 4\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 18: 61.5% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
t_1 := x \cdot \left(y \cdot z\right)\\
\mathbf{if}\;z \leq -10.5:\\
\;\;\;\;j \cdot \left(k \cdot -27\right) + 18 \cdot \left(t \cdot t\_1\right)\\

\mathbf{elif}\;z \leq 1.7 \cdot 10^{+92}:\\
\;\;\;\;b \cdot c - 4 \cdot \left(t \cdot a + x \cdot i\right)\\

\mathbf{else}:\\
\;\;\;\;t \cdot \left(18 \cdot t\_1 - a \cdot 4\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -10.5

    1. Initial program 79.9%

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

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

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

    if -10.5 < z < 1.6999999999999999e92

    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 y around 0 82.9%

      \[\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. distribute-lft-out82.9%

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

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

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

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

    if 1.6999999999999999e92 < z

    1. Initial program 73.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. Simplified76.7%

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

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

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

Alternative 19: 36.4% accurate, 1.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -1.8 \cdot 10^{+105} \lor \neg \left(b \cdot c \leq 2.8 \cdot 10^{+18}\right):\\ \;\;\;\;b \cdot c\\ \mathbf{else}:\\ \;\;\;\;-27 \cdot \left(j \cdot k\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= (* b c) -1.8e+105) (not (<= (* b c) 2.8e+18)))
   (* b c)
   (* -27.0 (* j k))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k) {
	double tmp;
	if (((b * c) <= -1.8e+105) || !((b * c) <= 2.8e+18)) {
		tmp = b * c;
	} else {
		tmp = -27.0 * (j * k);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (((b * c) <= (-1.8d+105)) .or. (.not. ((b * c) <= 2.8d+18))) then
        tmp = b * c
    else
        tmp = (-27.0d0) * (j * k)
    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 tmp;
	if (((b * c) <= -1.8e+105) || !((b * c) <= 2.8e+18)) {
		tmp = b * c;
	} else {
		tmp = -27.0 * (j * k);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if ((b * c) <= -1.8e+105) or not ((b * c) <= 2.8e+18):
		tmp = b * c
	else:
		tmp = -27.0 * (j * k)
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((Float64(b * c) <= -1.8e+105) || !(Float64(b * c) <= 2.8e+18))
		tmp = Float64(b * c);
	else
		tmp = Float64(-27.0 * Float64(j * k));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (((b * c) <= -1.8e+105) || ~(((b * c) <= 2.8e+18)))
		tmp = b * c;
	else
		tmp = -27.0 * (j * k);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -1.8e+105], N[Not[LessEqual[N[(b * c), $MachinePrecision], 2.8e+18]], $MachinePrecision]], N[(b * c), $MachinePrecision], N[(-27.0 * N[(j * k), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -1.8 \cdot 10^{+105} \lor \neg \left(b \cdot c \leq 2.8 \cdot 10^{+18}\right):\\
\;\;\;\;b \cdot c\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 b c) < -1.7999999999999999e105 or 2.8e18 < (*.f64 b c)

    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. Simplified85.1%

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*83.8%

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

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

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

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

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

    if -1.7999999999999999e105 < (*.f64 b c) < 2.8e18

    1. Initial program 84.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. Simplified89.1%

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

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

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

Alternative 20: 34.5% accurate, 1.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \cdot c \leq -8 \cdot 10^{+128} \lor \neg \left(b \cdot c \leq 4.5 \cdot 10^{-25}\right):\\ \;\;\;\;b \cdot c\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k)
 :precision binary64
 (if (or (<= (* b c) -8e+128) (not (<= (* b c) 4.5e-25)))
   (* b c)
   (* -4.0 (* t a))))
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) <= -8e+128) || !((b * c) <= 4.5e-25)) {
		tmp = b * c;
	} else {
		tmp = -4.0 * (t * a);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c, i, j, k)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8) :: tmp
    if (((b * c) <= (-8d+128)) .or. (.not. ((b * c) <= 4.5d-25))) then
        tmp = b * c
    else
        tmp = (-4.0d0) * (t * a)
    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 tmp;
	if (((b * c) <= -8e+128) || !((b * c) <= 4.5e-25)) {
		tmp = b * c;
	} else {
		tmp = -4.0 * (t * a);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k):
	tmp = 0
	if ((b * c) <= -8e+128) or not ((b * c) <= 4.5e-25):
		tmp = b * c
	else:
		tmp = -4.0 * (t * a)
	return tmp
function code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0
	if ((Float64(b * c) <= -8e+128) || !(Float64(b * c) <= 4.5e-25))
		tmp = Float64(b * c);
	else
		tmp = Float64(-4.0 * Float64(t * a));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k)
	tmp = 0.0;
	if (((b * c) <= -8e+128) || ~(((b * c) <= 4.5e-25)))
		tmp = b * c;
	else
		tmp = -4.0 * (t * a);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_] := If[Or[LessEqual[N[(b * c), $MachinePrecision], -8e+128], N[Not[LessEqual[N[(b * c), $MachinePrecision], 4.5e-25]], $MachinePrecision]], N[(b * c), $MachinePrecision], N[(-4.0 * N[(t * a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \cdot c \leq -8 \cdot 10^{+128} \lor \neg \left(b \cdot c \leq 4.5 \cdot 10^{-25}\right):\\
\;\;\;\;b \cdot c\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 b c) < -8.0000000000000006e128 or 4.5000000000000001e-25 < (*.f64 b c)

    1. Initial program 80.9%

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

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*81.4%

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

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

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

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

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

    if -8.0000000000000006e128 < (*.f64 b c) < 4.5000000000000001e-25

    1. Initial program 85.4%

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

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

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

        \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
      3. associate-*l*86.5%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \cdot c \leq -8 \cdot 10^{+128} \lor \neg \left(b \cdot c \leq 4.5 \cdot 10^{-25}\right):\\ \;\;\;\;b \cdot c\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \left(t \cdot a\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 21: 23.1% accurate, 10.3× speedup?

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

\\
b \cdot c
\end{array}
Derivation
  1. Initial program 83.4%

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

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

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

      \[\leadsto \left(\color{blue}{\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 \left(4 \cdot i\right) + j \cdot \left(27 \cdot k\right)\right) \]
    3. associate-*l*84.2%

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

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

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

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

    \[\leadsto \color{blue}{b \cdot c} \]
  7. Final simplification29.5%

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

Developer target: 89.5% accurate, 0.8× speedup?

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

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

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

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


\end{array}
\end{array}

Reproduce

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

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

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