Diagrams.ThreeD.Shapes:frustum from diagrams-lib-1.3.0.3, A

Percentage Accurate: 90.3% → 93.3%
Time: 10.8s
Alternatives: 16
Speedup: 1.1×

Specification

?
\[\begin{array}{l} \\ 2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (* 2.0 (- (+ (* x y) (* z t)) (* (* (+ a (* b c)) c) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
}
real(8) function code(x, y, z, t, a, b, c, i)
    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
    code = 2.0d0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
}
def code(x, y, z, t, a, b, c, i):
	return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))
function code(x, y, z, t, a, b, c, i)
	return Float64(2.0 * Float64(Float64(Float64(x * y) + Float64(z * t)) - Float64(Float64(Float64(a + Float64(b * c)) * c) * i)))
end
function tmp = code(x, y, z, t, a, b, c, i)
	tmp = 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(2.0 * N[(N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(a + N[(b * c), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)
\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 16 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: 90.3% accurate, 1.0× speedup?

\[\begin{array}{l} \\ 2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (* 2.0 (- (+ (* x y) (* z t)) (* (* (+ a (* b c)) c) i))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
}
real(8) function code(x, y, z, t, a, b, c, i)
    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
    code = 2.0d0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
}
def code(x, y, z, t, a, b, c, i):
	return 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))
function code(x, y, z, t, a, b, c, i)
	return Float64(2.0 * Float64(Float64(Float64(x * y) + Float64(z * t)) - Float64(Float64(Float64(a + Float64(b * c)) * c) * i)))
end
function tmp = code(x, y, z, t, a, b, c, i)
	tmp = 2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i));
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(2.0 * N[(N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(a + N[(b * c), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)
\end{array}

Alternative 1: 93.3% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_1 \leq 5 \cdot 10^{+270}:\\ \;\;\;\;\left(\left(t \cdot z + y \cdot x\right) - t\_1\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \left(-c\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right)\right) \cdot 2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (let* ((t_1 (* i (* (+ (* c b) a) c))))
   (if (<= t_1 5e+270)
     (* (- (+ (* t z) (* y x)) t_1) 2.0)
     (* (fma z t (fma y x (* (- c) (* (fma c b a) i)))) 2.0))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double t_1 = i * (((c * b) + a) * c);
	double tmp;
	if (t_1 <= 5e+270) {
		tmp = (((t * z) + (y * x)) - t_1) * 2.0;
	} else {
		tmp = fma(z, t, fma(y, x, (-c * (fma(c, b, a) * i)))) * 2.0;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i)
	t_1 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
	tmp = 0.0
	if (t_1 <= 5e+270)
		tmp = Float64(Float64(Float64(Float64(t * z) + Float64(y * x)) - t_1) * 2.0);
	else
		tmp = Float64(fma(z, t, fma(y, x, Float64(Float64(-c) * Float64(fma(c, b, a) * i)))) * 2.0);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 5e+270], N[(N[(N[(N[(t * z), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] * 2.0), $MachinePrecision], N[(N[(z * t + N[(y * x + N[((-c) * N[(N[(c * b + a), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
\mathbf{if}\;t\_1 \leq 5 \cdot 10^{+270}:\\
\;\;\;\;\left(\left(t \cdot z + y \cdot x\right) - t\_1\right) \cdot 2\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \left(-c\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right)\right) \cdot 2\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 4.99999999999999976e270

    1. Initial program 97.6%

      \[2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \]
    2. Add Preprocessing

    if 4.99999999999999976e270 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

    1. Initial program 72.7%

      \[2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift--.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)} \]
      2. lift-+.f64N/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(x \cdot y + z \cdot t\right)} - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \]
      3. +-commutativeN/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(z \cdot t + x \cdot y\right)} - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \]
      4. associate--l+N/A

        \[\leadsto 2 \cdot \color{blue}{\left(z \cdot t + \left(x \cdot y - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)} \]
      5. lift-*.f64N/A

        \[\leadsto 2 \cdot \left(\color{blue}{z \cdot t} + \left(x \cdot y - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right) \]
      6. lower-fma.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, x \cdot y - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)} \]
      7. sub-negN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \color{blue}{x \cdot y + \left(\mathsf{neg}\left(\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)}\right) \]
      8. lift-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \color{blue}{x \cdot y} + \left(\mathsf{neg}\left(\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)\right) \]
      9. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \color{blue}{y \cdot x} + \left(\mathsf{neg}\left(\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)\right) \]
      10. lower-fma.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \color{blue}{\mathsf{fma}\left(y, x, \mathsf{neg}\left(\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)}\right) \]
      11. lift-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \mathsf{neg}\left(\color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right)\right)\right) \]
      12. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \mathsf{neg}\left(\color{blue}{i \cdot \left(\left(a + b \cdot c\right) \cdot c\right)}\right)\right)\right) \]
      13. lift-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \mathsf{neg}\left(i \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right)}\right)\right)\right) \]
      14. associate-*r*N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \mathsf{neg}\left(\color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c}\right)\right)\right) \]
      15. distribute-rgt-neg-inN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right) \cdot \left(\mathsf{neg}\left(c\right)\right)}\right)\right) \]
      16. lower-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right) \cdot \left(\mathsf{neg}\left(c\right)\right)}\right)\right) \]
    4. Applied rewrites98.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 5 \cdot 10^{+270}:\\ \;\;\;\;\left(\left(t \cdot z + y \cdot x\right) - i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \left(-c\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right)\right) \cdot 2\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 86.7% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, t \cdot z\right) \cdot 2\\ t_2 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+85}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 10^{-25}:\\ \;\;\;\;\mathsf{fma}\left(\left(-a\right) \cdot c, i, \mathsf{fma}\left(t, z, y \cdot x\right)\right) \cdot 2\\ \mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+298}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (let* ((t_1 (* (fma (- i) (* (fma c b a) c) (* t z)) 2.0))
        (t_2 (* i (* (+ (* c b) a) c))))
   (if (<= t_2 -2e+85)
     t_1
     (if (<= t_2 1e-25)
       (* (fma (* (- a) c) i (fma t z (* y x))) 2.0)
       (if (<= t_2 5e+298)
         t_1
         (* (fma (- c) (* (fma b c a) i) (* y x)) 2.0))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double t_1 = fma(-i, (fma(c, b, a) * c), (t * z)) * 2.0;
	double t_2 = i * (((c * b) + a) * c);
	double tmp;
	if (t_2 <= -2e+85) {
		tmp = t_1;
	} else if (t_2 <= 1e-25) {
		tmp = fma((-a * c), i, fma(t, z, (y * x))) * 2.0;
	} else if (t_2 <= 5e+298) {
		tmp = t_1;
	} else {
		tmp = fma(-c, (fma(b, c, a) * i), (y * x)) * 2.0;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i)
	t_1 = Float64(fma(Float64(-i), Float64(fma(c, b, a) * c), Float64(t * z)) * 2.0)
	t_2 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
	tmp = 0.0
	if (t_2 <= -2e+85)
		tmp = t_1;
	elseif (t_2 <= 1e-25)
		tmp = Float64(fma(Float64(Float64(-a) * c), i, fma(t, z, Float64(y * x))) * 2.0);
	elseif (t_2 <= 5e+298)
		tmp = t_1;
	else
		tmp = Float64(fma(Float64(-c), Float64(fma(b, c, a) * i), Float64(y * x)) * 2.0);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[((-i) * N[(N[(c * b + a), $MachinePrecision] * c), $MachinePrecision] + N[(t * z), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]}, Block[{t$95$2 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+85], t$95$1, If[LessEqual[t$95$2, 1e-25], N[(N[(N[((-a) * c), $MachinePrecision] * i + N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], If[LessEqual[t$95$2, 5e+298], t$95$1, N[(N[((-c) * N[(N[(b * c + a), $MachinePrecision] * i), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, t \cdot z\right) \cdot 2\\
t_2 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
\mathbf{if}\;t\_2 \leq -2 \cdot 10^{+85}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t\_2 \leq 10^{-25}:\\
\;\;\;\;\mathsf{fma}\left(\left(-a\right) \cdot c, i, \mathsf{fma}\left(t, z, y \cdot x\right)\right) \cdot 2\\

\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+298}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -2e85 or 1.00000000000000004e-25 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 5.0000000000000003e298

    1. Initial program 95.8%

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

      \[\leadsto 2 \cdot \color{blue}{\left(t \cdot z - c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
    4. Step-by-step derivation
      1. sub-negN/A

        \[\leadsto 2 \cdot \color{blue}{\left(t \cdot z + \left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right)\right)} \]
      2. +-commutativeN/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right) + t \cdot z\right)} \]
      3. *-commutativeN/A

        \[\leadsto 2 \cdot \left(\left(\mathsf{neg}\left(\color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c}\right)\right) + t \cdot z\right) \]
      4. associate-*l*N/A

        \[\leadsto 2 \cdot \left(\left(\mathsf{neg}\left(\color{blue}{i \cdot \left(\left(a + b \cdot c\right) \cdot c\right)}\right)\right) + t \cdot z\right) \]
      5. *-commutativeN/A

        \[\leadsto 2 \cdot \left(\left(\mathsf{neg}\left(i \cdot \color{blue}{\left(c \cdot \left(a + b \cdot c\right)\right)}\right)\right) + t \cdot z\right) \]
      6. distribute-lft-neg-inN/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(\mathsf{neg}\left(i\right)\right) \cdot \left(c \cdot \left(a + b \cdot c\right)\right)} + t \cdot z\right) \]
      7. mul-1-negN/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(-1 \cdot i\right)} \cdot \left(c \cdot \left(a + b \cdot c\right)\right) + t \cdot z\right) \]
      8. lower-fma.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(-1 \cdot i, c \cdot \left(a + b \cdot c\right), t \cdot z\right)} \]
      9. mul-1-negN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\mathsf{neg}\left(i\right)}, c \cdot \left(a + b \cdot c\right), t \cdot z\right) \]
      10. lower-neg.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{-i}, c \cdot \left(a + b \cdot c\right), t \cdot z\right) \]
      11. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \color{blue}{\left(a + b \cdot c\right) \cdot c}, t \cdot z\right) \]
      12. lower-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \color{blue}{\left(a + b \cdot c\right) \cdot c}, t \cdot z\right) \]
      13. +-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \color{blue}{\left(b \cdot c + a\right)} \cdot c, t \cdot z\right) \]
      14. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \left(\color{blue}{c \cdot b} + a\right) \cdot c, t \cdot z\right) \]
      15. lower-fma.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot c, t \cdot z\right) \]
      16. lower-*.f6491.9

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, \color{blue}{t \cdot z}\right) \]
    5. Applied rewrites91.9%

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

    if -2e85 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e-25

    1. Initial program 99.1%

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

      \[\leadsto 2 \cdot \color{blue}{\left(\left(t \cdot z + x \cdot y\right) - a \cdot \left(c \cdot i\right)\right)} \]
    4. Step-by-step derivation
      1. sub-negN/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(t \cdot z + x \cdot y\right) + \left(\mathsf{neg}\left(a \cdot \left(c \cdot i\right)\right)\right)\right)} \]
      2. +-commutativeN/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(\mathsf{neg}\left(a \cdot \left(c \cdot i\right)\right)\right) + \left(t \cdot z + x \cdot y\right)\right)} \]
      3. associate-*r*N/A

        \[\leadsto 2 \cdot \left(\left(\mathsf{neg}\left(\color{blue}{\left(a \cdot c\right) \cdot i}\right)\right) + \left(t \cdot z + x \cdot y\right)\right) \]
      4. distribute-lft-neg-inN/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(\mathsf{neg}\left(a \cdot c\right)\right) \cdot i} + \left(t \cdot z + x \cdot y\right)\right) \]
      5. mul-1-negN/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(-1 \cdot \left(a \cdot c\right)\right)} \cdot i + \left(t \cdot z + x \cdot y\right)\right) \]
      6. lower-fma.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(-1 \cdot \left(a \cdot c\right), i, t \cdot z + x \cdot y\right)} \]
      7. associate-*r*N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\left(-1 \cdot a\right) \cdot c}, i, t \cdot z + x \cdot y\right) \]
      8. lower-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\left(-1 \cdot a\right) \cdot c}, i, t \cdot z + x \cdot y\right) \]
      9. neg-mul-1N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\left(\mathsf{neg}\left(a\right)\right)} \cdot c, i, t \cdot z + x \cdot y\right) \]
      10. lower-neg.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\left(-a\right)} \cdot c, i, t \cdot z + x \cdot y\right) \]
      11. lower-fma.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\left(-a\right) \cdot c, i, \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)}\right) \]
      12. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\left(-a\right) \cdot c, i, \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right)\right) \]
      13. lower-*.f6498.0

        \[\leadsto 2 \cdot \mathsf{fma}\left(\left(-a\right) \cdot c, i, \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right)\right) \]
    5. Applied rewrites98.0%

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

    if 5.0000000000000003e298 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

    1. Initial program 70.5%

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

      \[\leadsto 2 \cdot \color{blue}{\left(-1 \cdot \left(a \cdot \left(c \cdot i\right)\right)\right)} \]
    4. Step-by-step derivation
      1. associate-*r*N/A

        \[\leadsto 2 \cdot \left(-1 \cdot \color{blue}{\left(\left(a \cdot c\right) \cdot i\right)}\right) \]
      2. associate-*r*N/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(-1 \cdot \left(a \cdot c\right)\right) \cdot i\right)} \]
      3. lower-*.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(-1 \cdot \left(a \cdot c\right)\right) \cdot i\right)} \]
      4. associate-*r*N/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(\left(-1 \cdot a\right) \cdot c\right)} \cdot i\right) \]
      5. lower-*.f64N/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(\left(-1 \cdot a\right) \cdot c\right)} \cdot i\right) \]
      6. neg-mul-1N/A

        \[\leadsto 2 \cdot \left(\left(\color{blue}{\left(\mathsf{neg}\left(a\right)\right)} \cdot c\right) \cdot i\right) \]
      7. lower-neg.f6432.8

        \[\leadsto 2 \cdot \left(\left(\color{blue}{\left(-a\right)} \cdot c\right) \cdot i\right) \]
    5. Applied rewrites32.8%

      \[\leadsto 2 \cdot \color{blue}{\left(\left(\left(-a\right) \cdot c\right) \cdot i\right)} \]
    6. Taylor expanded in z around 0

      \[\leadsto 2 \cdot \color{blue}{\left(x \cdot y - c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
    7. Step-by-step derivation
      1. sub-negN/A

        \[\leadsto 2 \cdot \color{blue}{\left(x \cdot y + \left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right)\right)} \]
      2. mul-1-negN/A

        \[\leadsto 2 \cdot \left(x \cdot y + \color{blue}{-1 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)}\right) \]
      3. +-commutativeN/A

        \[\leadsto 2 \cdot \color{blue}{\left(-1 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) + x \cdot y\right)} \]
      4. associate-*r*N/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(-1 \cdot c\right) \cdot \left(i \cdot \left(a + b \cdot c\right)\right)} + x \cdot y\right) \]
      5. lower-fma.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(-1 \cdot c, i \cdot \left(a + b \cdot c\right), x \cdot y\right)} \]
      6. neg-mul-1N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\mathsf{neg}\left(c\right)}, i \cdot \left(a + b \cdot c\right), x \cdot y\right) \]
      7. lower-neg.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{-c}, i \cdot \left(a + b \cdot c\right), x \cdot y\right) \]
      8. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(a + b \cdot c\right) \cdot i}, x \cdot y\right) \]
      9. lower-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(a + b \cdot c\right) \cdot i}, x \cdot y\right) \]
      10. +-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(b \cdot c + a\right)} \cdot i, x \cdot y\right) \]
      11. lower-fma.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\mathsf{fma}\left(b, c, a\right)} \cdot i, x \cdot y\right) \]
      12. lower-*.f6488.1

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, \color{blue}{x \cdot y}\right) \]
    8. Applied rewrites88.1%

      \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, x \cdot y\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification93.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq -2 \cdot 10^{+85}:\\ \;\;\;\;\mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, t \cdot z\right) \cdot 2\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 10^{-25}:\\ \;\;\;\;\mathsf{fma}\left(\left(-a\right) \cdot c, i, \mathsf{fma}\left(t, z, y \cdot x\right)\right) \cdot 2\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 5 \cdot 10^{+298}:\\ \;\;\;\;\mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, t \cdot z\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 84.8% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, t \cdot z\right) \cdot 2\\ t_2 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+85}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 10^{-25}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+298}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (let* ((t_1 (* (fma (- i) (* (fma c b a) c) (* t z)) 2.0))
        (t_2 (* i (* (+ (* c b) a) c))))
   (if (<= t_2 -2e+85)
     t_1
     (if (<= t_2 1e-25)
       (* (fma t z (* y x)) 2.0)
       (if (<= t_2 5e+298)
         t_1
         (* (fma (- c) (* (fma b c a) i) (* y x)) 2.0))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double t_1 = fma(-i, (fma(c, b, a) * c), (t * z)) * 2.0;
	double t_2 = i * (((c * b) + a) * c);
	double tmp;
	if (t_2 <= -2e+85) {
		tmp = t_1;
	} else if (t_2 <= 1e-25) {
		tmp = fma(t, z, (y * x)) * 2.0;
	} else if (t_2 <= 5e+298) {
		tmp = t_1;
	} else {
		tmp = fma(-c, (fma(b, c, a) * i), (y * x)) * 2.0;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i)
	t_1 = Float64(fma(Float64(-i), Float64(fma(c, b, a) * c), Float64(t * z)) * 2.0)
	t_2 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
	tmp = 0.0
	if (t_2 <= -2e+85)
		tmp = t_1;
	elseif (t_2 <= 1e-25)
		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
	elseif (t_2 <= 5e+298)
		tmp = t_1;
	else
		tmp = Float64(fma(Float64(-c), Float64(fma(b, c, a) * i), Float64(y * x)) * 2.0);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[((-i) * N[(N[(c * b + a), $MachinePrecision] * c), $MachinePrecision] + N[(t * z), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]}, Block[{t$95$2 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+85], t$95$1, If[LessEqual[t$95$2, 1e-25], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], If[LessEqual[t$95$2, 5e+298], t$95$1, N[(N[((-c) * N[(N[(b * c + a), $MachinePrecision] * i), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, t \cdot z\right) \cdot 2\\
t_2 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
\mathbf{if}\;t\_2 \leq -2 \cdot 10^{+85}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t\_2 \leq 10^{-25}:\\
\;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\

\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+298}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -2e85 or 1.00000000000000004e-25 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 5.0000000000000003e298

    1. Initial program 95.8%

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

      \[\leadsto 2 \cdot \color{blue}{\left(t \cdot z - c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
    4. Step-by-step derivation
      1. sub-negN/A

        \[\leadsto 2 \cdot \color{blue}{\left(t \cdot z + \left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right)\right)} \]
      2. +-commutativeN/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right) + t \cdot z\right)} \]
      3. *-commutativeN/A

        \[\leadsto 2 \cdot \left(\left(\mathsf{neg}\left(\color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c}\right)\right) + t \cdot z\right) \]
      4. associate-*l*N/A

        \[\leadsto 2 \cdot \left(\left(\mathsf{neg}\left(\color{blue}{i \cdot \left(\left(a + b \cdot c\right) \cdot c\right)}\right)\right) + t \cdot z\right) \]
      5. *-commutativeN/A

        \[\leadsto 2 \cdot \left(\left(\mathsf{neg}\left(i \cdot \color{blue}{\left(c \cdot \left(a + b \cdot c\right)\right)}\right)\right) + t \cdot z\right) \]
      6. distribute-lft-neg-inN/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(\mathsf{neg}\left(i\right)\right) \cdot \left(c \cdot \left(a + b \cdot c\right)\right)} + t \cdot z\right) \]
      7. mul-1-negN/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(-1 \cdot i\right)} \cdot \left(c \cdot \left(a + b \cdot c\right)\right) + t \cdot z\right) \]
      8. lower-fma.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(-1 \cdot i, c \cdot \left(a + b \cdot c\right), t \cdot z\right)} \]
      9. mul-1-negN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\mathsf{neg}\left(i\right)}, c \cdot \left(a + b \cdot c\right), t \cdot z\right) \]
      10. lower-neg.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{-i}, c \cdot \left(a + b \cdot c\right), t \cdot z\right) \]
      11. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \color{blue}{\left(a + b \cdot c\right) \cdot c}, t \cdot z\right) \]
      12. lower-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \color{blue}{\left(a + b \cdot c\right) \cdot c}, t \cdot z\right) \]
      13. +-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \color{blue}{\left(b \cdot c + a\right)} \cdot c, t \cdot z\right) \]
      14. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \left(\color{blue}{c \cdot b} + a\right) \cdot c, t \cdot z\right) \]
      15. lower-fma.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot c, t \cdot z\right) \]
      16. lower-*.f6491.9

        \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, \color{blue}{t \cdot z}\right) \]
    5. Applied rewrites91.9%

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

    if -2e85 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e-25

    1. Initial program 99.1%

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

      \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
    4. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
      2. lower-fma.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
      3. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
      4. lower-*.f6494.0

        \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
    5. Applied rewrites94.0%

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

    if 5.0000000000000003e298 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

    1. Initial program 70.5%

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

      \[\leadsto 2 \cdot \color{blue}{\left(-1 \cdot \left(a \cdot \left(c \cdot i\right)\right)\right)} \]
    4. Step-by-step derivation
      1. associate-*r*N/A

        \[\leadsto 2 \cdot \left(-1 \cdot \color{blue}{\left(\left(a \cdot c\right) \cdot i\right)}\right) \]
      2. associate-*r*N/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(-1 \cdot \left(a \cdot c\right)\right) \cdot i\right)} \]
      3. lower-*.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\left(\left(-1 \cdot \left(a \cdot c\right)\right) \cdot i\right)} \]
      4. associate-*r*N/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(\left(-1 \cdot a\right) \cdot c\right)} \cdot i\right) \]
      5. lower-*.f64N/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(\left(-1 \cdot a\right) \cdot c\right)} \cdot i\right) \]
      6. neg-mul-1N/A

        \[\leadsto 2 \cdot \left(\left(\color{blue}{\left(\mathsf{neg}\left(a\right)\right)} \cdot c\right) \cdot i\right) \]
      7. lower-neg.f6432.8

        \[\leadsto 2 \cdot \left(\left(\color{blue}{\left(-a\right)} \cdot c\right) \cdot i\right) \]
    5. Applied rewrites32.8%

      \[\leadsto 2 \cdot \color{blue}{\left(\left(\left(-a\right) \cdot c\right) \cdot i\right)} \]
    6. Taylor expanded in z around 0

      \[\leadsto 2 \cdot \color{blue}{\left(x \cdot y - c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
    7. Step-by-step derivation
      1. sub-negN/A

        \[\leadsto 2 \cdot \color{blue}{\left(x \cdot y + \left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right)\right)} \]
      2. mul-1-negN/A

        \[\leadsto 2 \cdot \left(x \cdot y + \color{blue}{-1 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)}\right) \]
      3. +-commutativeN/A

        \[\leadsto 2 \cdot \color{blue}{\left(-1 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) + x \cdot y\right)} \]
      4. associate-*r*N/A

        \[\leadsto 2 \cdot \left(\color{blue}{\left(-1 \cdot c\right) \cdot \left(i \cdot \left(a + b \cdot c\right)\right)} + x \cdot y\right) \]
      5. lower-fma.f64N/A

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(-1 \cdot c, i \cdot \left(a + b \cdot c\right), x \cdot y\right)} \]
      6. neg-mul-1N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\mathsf{neg}\left(c\right)}, i \cdot \left(a + b \cdot c\right), x \cdot y\right) \]
      7. lower-neg.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{-c}, i \cdot \left(a + b \cdot c\right), x \cdot y\right) \]
      8. *-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(a + b \cdot c\right) \cdot i}, x \cdot y\right) \]
      9. lower-*.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(a + b \cdot c\right) \cdot i}, x \cdot y\right) \]
      10. +-commutativeN/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(b \cdot c + a\right)} \cdot i, x \cdot y\right) \]
      11. lower-fma.f64N/A

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\mathsf{fma}\left(b, c, a\right)} \cdot i, x \cdot y\right) \]
      12. lower-*.f6488.1

        \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, \color{blue}{x \cdot y}\right) \]
    8. Applied rewrites88.1%

      \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, x \cdot y\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification92.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq -2 \cdot 10^{+85}:\\ \;\;\;\;\mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, t \cdot z\right) \cdot 2\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 10^{-25}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 5 \cdot 10^{+298}:\\ \;\;\;\;\mathsf{fma}\left(-i, \mathsf{fma}\left(c, b, a\right) \cdot c, t \cdot z\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 71.1% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(c \cdot b + a\right) \cdot c\\ \mathbf{if}\;t\_1 \leq -\infty:\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot b\right) \cdot -2\right) \cdot i\\ \mathbf{elif}\;t\_1 \leq -2 \cdot 10^{+185}:\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+179}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (let* ((t_1 (* (+ (* c b) a) c)))
   (if (<= t_1 (- INFINITY))
     (* (* (* (* c c) b) -2.0) i)
     (if (<= t_1 -2e+185)
       (* (* (* i c) a) -2.0)
       (if (<= t_1 2e+179)
         (* (fma t z (* y x)) 2.0)
         (* (* (* (* c c) i) b) -2.0))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double t_1 = ((c * b) + a) * c;
	double tmp;
	if (t_1 <= -((double) INFINITY)) {
		tmp = (((c * c) * b) * -2.0) * i;
	} else if (t_1 <= -2e+185) {
		tmp = ((i * c) * a) * -2.0;
	} else if (t_1 <= 2e+179) {
		tmp = fma(t, z, (y * x)) * 2.0;
	} else {
		tmp = (((c * c) * i) * b) * -2.0;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i)
	t_1 = Float64(Float64(Float64(c * b) + a) * c)
	tmp = 0.0
	if (t_1 <= Float64(-Inf))
		tmp = Float64(Float64(Float64(Float64(c * c) * b) * -2.0) * i);
	elseif (t_1 <= -2e+185)
		tmp = Float64(Float64(Float64(i * c) * a) * -2.0);
	elseif (t_1 <= 2e+179)
		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
	else
		tmp = Float64(Float64(Float64(Float64(c * c) * i) * b) * -2.0);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(N[(N[(c * c), $MachinePrecision] * b), $MachinePrecision] * -2.0), $MachinePrecision] * i), $MachinePrecision], If[LessEqual[t$95$1, -2e+185], N[(N[(N[(i * c), $MachinePrecision] * a), $MachinePrecision] * -2.0), $MachinePrecision], If[LessEqual[t$95$1, 2e+179], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], N[(N[(N[(N[(c * c), $MachinePrecision] * i), $MachinePrecision] * b), $MachinePrecision] * -2.0), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left(c \cdot b + a\right) \cdot c\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;\left(\left(\left(c \cdot c\right) \cdot b\right) \cdot -2\right) \cdot i\\

\mathbf{elif}\;t\_1 \leq -2 \cdot 10^{+185}:\\
\;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\

\mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+179}:\\
\;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (*.f64 (+.f64 a (*.f64 b c)) c) < -inf.0

    1. Initial program 70.3%

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

      \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
    4. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
      2. associate-*r*N/A

        \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
      3. distribute-rgt-inN/A

        \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
      4. associate-*r*N/A

        \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
      5. distribute-lft-outN/A

        \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
      6. lower-*.f64N/A

        \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
      7. distribute-lft-outN/A

        \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
      8. associate-*r*N/A

        \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
      9. distribute-rgt-inN/A

        \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
      10. lower-*.f64N/A

        \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
      11. *-commutativeN/A

        \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
      12. lower-*.f64N/A

        \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
      13. +-commutativeN/A

        \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
      14. *-commutativeN/A

        \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
      15. lower-fma.f6484.4

        \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
    5. Applied rewrites84.4%

      \[\leadsto \color{blue}{\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c} \]
    6. Step-by-step derivation
      1. Applied rewrites84.2%

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

        \[\leadsto \left(-2 \cdot \left(b \cdot {c}^{2}\right)\right) \cdot i \]
      3. Step-by-step derivation
        1. Applied rewrites70.3%

          \[\leadsto \left(\left(\left(c \cdot c\right) \cdot b\right) \cdot -2\right) \cdot i \]

        if -inf.0 < (*.f64 (+.f64 a (*.f64 b c)) c) < -2e185

        1. Initial program 99.7%

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

          \[\leadsto \color{blue}{-2 \cdot \left(a \cdot \left(c \cdot i\right)\right)} \]
        4. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \color{blue}{\left(a \cdot \left(c \cdot i\right)\right) \cdot -2} \]
          2. lower-*.f64N/A

            \[\leadsto \color{blue}{\left(a \cdot \left(c \cdot i\right)\right) \cdot -2} \]
          3. *-commutativeN/A

            \[\leadsto \color{blue}{\left(\left(c \cdot i\right) \cdot a\right)} \cdot -2 \]
          4. lower-*.f64N/A

            \[\leadsto \color{blue}{\left(\left(c \cdot i\right) \cdot a\right)} \cdot -2 \]
          5. *-commutativeN/A

            \[\leadsto \left(\color{blue}{\left(i \cdot c\right)} \cdot a\right) \cdot -2 \]
          6. lower-*.f6458.6

            \[\leadsto \left(\color{blue}{\left(i \cdot c\right)} \cdot a\right) \cdot -2 \]
        5. Applied rewrites58.6%

          \[\leadsto \color{blue}{\left(\left(i \cdot c\right) \cdot a\right) \cdot -2} \]

        if -2e185 < (*.f64 (+.f64 a (*.f64 b c)) c) < 1.99999999999999996e179

        1. Initial program 98.8%

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

          \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
        4. Step-by-step derivation
          1. lower-*.f64N/A

            \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
          2. lower-fma.f64N/A

            \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
          3. *-commutativeN/A

            \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
          4. lower-*.f6476.1

            \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
        5. Applied rewrites76.1%

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

        if 1.99999999999999996e179 < (*.f64 (+.f64 a (*.f64 b c)) c)

        1. Initial program 82.3%

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

          \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
        4. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
          2. associate-*r*N/A

            \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
          3. distribute-rgt-inN/A

            \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
          4. associate-*r*N/A

            \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
          5. distribute-lft-outN/A

            \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
          6. lower-*.f64N/A

            \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
          7. distribute-lft-outN/A

            \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
          8. associate-*r*N/A

            \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
          9. distribute-rgt-inN/A

            \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
          10. lower-*.f64N/A

            \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
          11. *-commutativeN/A

            \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
          12. lower-*.f64N/A

            \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
          13. +-commutativeN/A

            \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
          14. *-commutativeN/A

            \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
          15. lower-fma.f6484.6

            \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
        5. Applied rewrites84.6%

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

          \[\leadsto -2 \cdot \color{blue}{\left(b \cdot \left({c}^{2} \cdot i\right)\right)} \]
        7. Step-by-step derivation
          1. Applied rewrites71.5%

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

          \[\leadsto \begin{array}{l} \mathbf{if}\;\left(c \cdot b + a\right) \cdot c \leq -\infty:\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot b\right) \cdot -2\right) \cdot i\\ \mathbf{elif}\;\left(c \cdot b + a\right) \cdot c \leq -2 \cdot 10^{+185}:\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \mathbf{elif}\;\left(c \cdot b + a\right) \cdot c \leq 2 \cdot 10^{+179}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\ \end{array} \]
        10. Add Preprocessing

        Alternative 5: 71.6% accurate, 0.5× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\ t_2 := \left(c \cdot b + a\right) \cdot c\\ \mathbf{if}\;t\_2 \leq -\infty:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq -2 \cdot 10^{+185}:\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+179}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
        (FPCore (x y z t a b c i)
         :precision binary64
         (let* ((t_1 (* (* (* (* c c) i) b) -2.0)) (t_2 (* (+ (* c b) a) c)))
           (if (<= t_2 (- INFINITY))
             t_1
             (if (<= t_2 -2e+185)
               (* (* (* i c) a) -2.0)
               (if (<= t_2 2e+179) (* (fma t z (* y x)) 2.0) t_1)))))
        double code(double x, double y, double z, double t, double a, double b, double c, double i) {
        	double t_1 = (((c * c) * i) * b) * -2.0;
        	double t_2 = ((c * b) + a) * c;
        	double tmp;
        	if (t_2 <= -((double) INFINITY)) {
        		tmp = t_1;
        	} else if (t_2 <= -2e+185) {
        		tmp = ((i * c) * a) * -2.0;
        	} else if (t_2 <= 2e+179) {
        		tmp = fma(t, z, (y * x)) * 2.0;
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        function code(x, y, z, t, a, b, c, i)
        	t_1 = Float64(Float64(Float64(Float64(c * c) * i) * b) * -2.0)
        	t_2 = Float64(Float64(Float64(c * b) + a) * c)
        	tmp = 0.0
        	if (t_2 <= Float64(-Inf))
        		tmp = t_1;
        	elseif (t_2 <= -2e+185)
        		tmp = Float64(Float64(Float64(i * c) * a) * -2.0);
        	elseif (t_2 <= 2e+179)
        		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
        	else
        		tmp = t_1;
        	end
        	return tmp
        end
        
        code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(N[(N[(c * c), $MachinePrecision] * i), $MachinePrecision] * b), $MachinePrecision] * -2.0), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], t$95$1, If[LessEqual[t$95$2, -2e+185], N[(N[(N[(i * c), $MachinePrecision] * a), $MachinePrecision] * -2.0), $MachinePrecision], If[LessEqual[t$95$2, 2e+179], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], t$95$1]]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\
        t_2 := \left(c \cdot b + a\right) \cdot c\\
        \mathbf{if}\;t\_2 \leq -\infty:\\
        \;\;\;\;t\_1\\
        
        \mathbf{elif}\;t\_2 \leq -2 \cdot 10^{+185}:\\
        \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\
        
        \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+179}:\\
        \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_1\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if (*.f64 (+.f64 a (*.f64 b c)) c) < -inf.0 or 1.99999999999999996e179 < (*.f64 (+.f64 a (*.f64 b c)) c)

          1. Initial program 76.4%

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

            \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
          4. Step-by-step derivation
            1. *-commutativeN/A

              \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
            2. associate-*r*N/A

              \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
            3. distribute-rgt-inN/A

              \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
            4. associate-*r*N/A

              \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
            5. distribute-lft-outN/A

              \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
            6. lower-*.f64N/A

              \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
            7. distribute-lft-outN/A

              \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
            8. associate-*r*N/A

              \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
            9. distribute-rgt-inN/A

              \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
            10. lower-*.f64N/A

              \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
            11. *-commutativeN/A

              \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
            12. lower-*.f64N/A

              \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
            13. +-commutativeN/A

              \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
            14. *-commutativeN/A

              \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
            15. lower-fma.f6484.5

              \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
          5. Applied rewrites84.5%

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

            \[\leadsto -2 \cdot \color{blue}{\left(b \cdot \left({c}^{2} \cdot i\right)\right)} \]
          7. Step-by-step derivation
            1. Applied rewrites69.6%

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

            if -inf.0 < (*.f64 (+.f64 a (*.f64 b c)) c) < -2e185

            1. Initial program 99.7%

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

              \[\leadsto \color{blue}{-2 \cdot \left(a \cdot \left(c \cdot i\right)\right)} \]
            4. Step-by-step derivation
              1. *-commutativeN/A

                \[\leadsto \color{blue}{\left(a \cdot \left(c \cdot i\right)\right) \cdot -2} \]
              2. lower-*.f64N/A

                \[\leadsto \color{blue}{\left(a \cdot \left(c \cdot i\right)\right) \cdot -2} \]
              3. *-commutativeN/A

                \[\leadsto \color{blue}{\left(\left(c \cdot i\right) \cdot a\right)} \cdot -2 \]
              4. lower-*.f64N/A

                \[\leadsto \color{blue}{\left(\left(c \cdot i\right) \cdot a\right)} \cdot -2 \]
              5. *-commutativeN/A

                \[\leadsto \left(\color{blue}{\left(i \cdot c\right)} \cdot a\right) \cdot -2 \]
              6. lower-*.f6458.6

                \[\leadsto \left(\color{blue}{\left(i \cdot c\right)} \cdot a\right) \cdot -2 \]
            5. Applied rewrites58.6%

              \[\leadsto \color{blue}{\left(\left(i \cdot c\right) \cdot a\right) \cdot -2} \]

            if -2e185 < (*.f64 (+.f64 a (*.f64 b c)) c) < 1.99999999999999996e179

            1. Initial program 98.8%

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

              \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
            4. Step-by-step derivation
              1. lower-*.f64N/A

                \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
              2. lower-fma.f64N/A

                \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
              3. *-commutativeN/A

                \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
              4. lower-*.f6476.1

                \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
            5. Applied rewrites76.1%

              \[\leadsto \color{blue}{2 \cdot \mathsf{fma}\left(t, z, y \cdot x\right)} \]
          8. Recombined 3 regimes into one program.
          9. Final simplification73.0%

            \[\leadsto \begin{array}{l} \mathbf{if}\;\left(c \cdot b + a\right) \cdot c \leq -\infty:\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\ \mathbf{elif}\;\left(c \cdot b + a\right) \cdot c \leq -2 \cdot 10^{+185}:\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \mathbf{elif}\;\left(c \cdot b + a\right) \cdot c \leq 2 \cdot 10^{+179}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\ \end{array} \]
          10. Add Preprocessing

          Alternative 6: 82.2% accurate, 0.5× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+85}:\\ \;\;\;\;\left(\left(-2 \cdot \mathsf{fma}\left(b, c, a\right)\right) \cdot c\right) \cdot i\\ \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{-42}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\ \end{array} \end{array} \]
          (FPCore (x y z t a b c i)
           :precision binary64
           (let* ((t_1 (* i (* (+ (* c b) a) c))))
             (if (<= t_1 -2e+85)
               (* (* (* -2.0 (fma b c a)) c) i)
               (if (<= t_1 2e-42)
                 (* (fma t z (* y x)) 2.0)
                 (* (fma (- c) (* (fma b c a) i) (* y x)) 2.0)))))
          double code(double x, double y, double z, double t, double a, double b, double c, double i) {
          	double t_1 = i * (((c * b) + a) * c);
          	double tmp;
          	if (t_1 <= -2e+85) {
          		tmp = ((-2.0 * fma(b, c, a)) * c) * i;
          	} else if (t_1 <= 2e-42) {
          		tmp = fma(t, z, (y * x)) * 2.0;
          	} else {
          		tmp = fma(-c, (fma(b, c, a) * i), (y * x)) * 2.0;
          	}
          	return tmp;
          }
          
          function code(x, y, z, t, a, b, c, i)
          	t_1 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
          	tmp = 0.0
          	if (t_1 <= -2e+85)
          		tmp = Float64(Float64(Float64(-2.0 * fma(b, c, a)) * c) * i);
          	elseif (t_1 <= 2e-42)
          		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
          	else
          		tmp = Float64(fma(Float64(-c), Float64(fma(b, c, a) * i), Float64(y * x)) * 2.0);
          	end
          	return tmp
          end
          
          code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -2e+85], N[(N[(N[(-2.0 * N[(b * c + a), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision], If[LessEqual[t$95$1, 2e-42], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], N[(N[((-c) * N[(N[(b * c + a), $MachinePrecision] * i), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
          \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+85}:\\
          \;\;\;\;\left(\left(-2 \cdot \mathsf{fma}\left(b, c, a\right)\right) \cdot c\right) \cdot i\\
          
          \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{-42}:\\
          \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\
          
          \mathbf{else}:\\
          \;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -2e85

            1. Initial program 93.3%

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

              \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
            4. Step-by-step derivation
              1. *-commutativeN/A

                \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
              2. associate-*r*N/A

                \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
              3. distribute-rgt-inN/A

                \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
              4. associate-*r*N/A

                \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
              5. distribute-lft-outN/A

                \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
              6. lower-*.f64N/A

                \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
              7. distribute-lft-outN/A

                \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
              8. associate-*r*N/A

                \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
              9. distribute-rgt-inN/A

                \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
              10. lower-*.f64N/A

                \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
              11. *-commutativeN/A

                \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
              12. lower-*.f64N/A

                \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
              13. +-commutativeN/A

                \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
              14. *-commutativeN/A

                \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
              15. lower-fma.f6473.0

                \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
            5. Applied rewrites73.0%

              \[\leadsto \color{blue}{\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c} \]
            6. Step-by-step derivation
              1. Applied rewrites81.8%

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

              if -2e85 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 2.00000000000000008e-42

              1. Initial program 99.1%

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

                \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
              4. Step-by-step derivation
                1. lower-*.f64N/A

                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                2. lower-fma.f64N/A

                  \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
                3. *-commutativeN/A

                  \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                4. lower-*.f6494.8

                  \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
              5. Applied rewrites94.8%

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

              if 2.00000000000000008e-42 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

              1. Initial program 83.1%

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

                \[\leadsto 2 \cdot \color{blue}{\left(-1 \cdot \left(a \cdot \left(c \cdot i\right)\right)\right)} \]
              4. Step-by-step derivation
                1. associate-*r*N/A

                  \[\leadsto 2 \cdot \left(-1 \cdot \color{blue}{\left(\left(a \cdot c\right) \cdot i\right)}\right) \]
                2. associate-*r*N/A

                  \[\leadsto 2 \cdot \color{blue}{\left(\left(-1 \cdot \left(a \cdot c\right)\right) \cdot i\right)} \]
                3. lower-*.f64N/A

                  \[\leadsto 2 \cdot \color{blue}{\left(\left(-1 \cdot \left(a \cdot c\right)\right) \cdot i\right)} \]
                4. associate-*r*N/A

                  \[\leadsto 2 \cdot \left(\color{blue}{\left(\left(-1 \cdot a\right) \cdot c\right)} \cdot i\right) \]
                5. lower-*.f64N/A

                  \[\leadsto 2 \cdot \left(\color{blue}{\left(\left(-1 \cdot a\right) \cdot c\right)} \cdot i\right) \]
                6. neg-mul-1N/A

                  \[\leadsto 2 \cdot \left(\left(\color{blue}{\left(\mathsf{neg}\left(a\right)\right)} \cdot c\right) \cdot i\right) \]
                7. lower-neg.f6433.8

                  \[\leadsto 2 \cdot \left(\left(\color{blue}{\left(-a\right)} \cdot c\right) \cdot i\right) \]
              5. Applied rewrites33.8%

                \[\leadsto 2 \cdot \color{blue}{\left(\left(\left(-a\right) \cdot c\right) \cdot i\right)} \]
              6. Taylor expanded in z around 0

                \[\leadsto 2 \cdot \color{blue}{\left(x \cdot y - c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
              7. Step-by-step derivation
                1. sub-negN/A

                  \[\leadsto 2 \cdot \color{blue}{\left(x \cdot y + \left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right)\right)} \]
                2. mul-1-negN/A

                  \[\leadsto 2 \cdot \left(x \cdot y + \color{blue}{-1 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)}\right) \]
                3. +-commutativeN/A

                  \[\leadsto 2 \cdot \color{blue}{\left(-1 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) + x \cdot y\right)} \]
                4. associate-*r*N/A

                  \[\leadsto 2 \cdot \left(\color{blue}{\left(-1 \cdot c\right) \cdot \left(i \cdot \left(a + b \cdot c\right)\right)} + x \cdot y\right) \]
                5. lower-fma.f64N/A

                  \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(-1 \cdot c, i \cdot \left(a + b \cdot c\right), x \cdot y\right)} \]
                6. neg-mul-1N/A

                  \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{\mathsf{neg}\left(c\right)}, i \cdot \left(a + b \cdot c\right), x \cdot y\right) \]
                7. lower-neg.f64N/A

                  \[\leadsto 2 \cdot \mathsf{fma}\left(\color{blue}{-c}, i \cdot \left(a + b \cdot c\right), x \cdot y\right) \]
                8. *-commutativeN/A

                  \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(a + b \cdot c\right) \cdot i}, x \cdot y\right) \]
                9. lower-*.f64N/A

                  \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(a + b \cdot c\right) \cdot i}, x \cdot y\right) \]
                10. +-commutativeN/A

                  \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\left(b \cdot c + a\right)} \cdot i, x \cdot y\right) \]
                11. lower-fma.f64N/A

                  \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \color{blue}{\mathsf{fma}\left(b, c, a\right)} \cdot i, x \cdot y\right) \]
                12. lower-*.f6479.0

                  \[\leadsto 2 \cdot \mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, \color{blue}{x \cdot y}\right) \]
              8. Applied rewrites79.0%

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

              \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq -2 \cdot 10^{+85}:\\ \;\;\;\;\left(\left(-2 \cdot \mathsf{fma}\left(b, c, a\right)\right) \cdot c\right) \cdot i\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 2 \cdot 10^{-42}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(-c, \mathsf{fma}\left(b, c, a\right) \cdot i, y \cdot x\right) \cdot 2\\ \end{array} \]
            9. Add Preprocessing

            Alternative 7: 79.4% accurate, 0.6× speedup?

            \[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+85}:\\ \;\;\;\;\left(\left(-2 \cdot \mathsf{fma}\left(b, c, a\right)\right) \cdot c\right) \cdot i\\ \mathbf{elif}\;t\_1 \leq 10^{-25}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c\\ \end{array} \end{array} \]
            (FPCore (x y z t a b c i)
             :precision binary64
             (let* ((t_1 (* i (* (+ (* c b) a) c))))
               (if (<= t_1 -2e+85)
                 (* (* (* -2.0 (fma b c a)) c) i)
                 (if (<= t_1 1e-25)
                   (* (fma t z (* y x)) 2.0)
                   (* (* -2.0 (* (fma c b a) i)) c)))))
            double code(double x, double y, double z, double t, double a, double b, double c, double i) {
            	double t_1 = i * (((c * b) + a) * c);
            	double tmp;
            	if (t_1 <= -2e+85) {
            		tmp = ((-2.0 * fma(b, c, a)) * c) * i;
            	} else if (t_1 <= 1e-25) {
            		tmp = fma(t, z, (y * x)) * 2.0;
            	} else {
            		tmp = (-2.0 * (fma(c, b, a) * i)) * c;
            	}
            	return tmp;
            }
            
            function code(x, y, z, t, a, b, c, i)
            	t_1 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
            	tmp = 0.0
            	if (t_1 <= -2e+85)
            		tmp = Float64(Float64(Float64(-2.0 * fma(b, c, a)) * c) * i);
            	elseif (t_1 <= 1e-25)
            		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
            	else
            		tmp = Float64(Float64(-2.0 * Float64(fma(c, b, a) * i)) * c);
            	end
            	return tmp
            end
            
            code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -2e+85], N[(N[(N[(-2.0 * N[(b * c + a), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision], If[LessEqual[t$95$1, 1e-25], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], N[(N[(-2.0 * N[(N[(c * b + a), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision]]]]
            
            \begin{array}{l}
            
            \\
            \begin{array}{l}
            t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
            \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+85}:\\
            \;\;\;\;\left(\left(-2 \cdot \mathsf{fma}\left(b, c, a\right)\right) \cdot c\right) \cdot i\\
            
            \mathbf{elif}\;t\_1 \leq 10^{-25}:\\
            \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\
            
            \mathbf{else}:\\
            \;\;\;\;\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 3 regimes
            2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -2e85

              1. Initial program 93.3%

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

                \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
              4. Step-by-step derivation
                1. *-commutativeN/A

                  \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
                2. associate-*r*N/A

                  \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
                3. distribute-rgt-inN/A

                  \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                4. associate-*r*N/A

                  \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
                5. distribute-lft-outN/A

                  \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                6. lower-*.f64N/A

                  \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
                7. distribute-lft-outN/A

                  \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                8. associate-*r*N/A

                  \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
                9. distribute-rgt-inN/A

                  \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
                10. lower-*.f64N/A

                  \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
                11. *-commutativeN/A

                  \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                12. lower-*.f64N/A

                  \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                13. +-commutativeN/A

                  \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
                14. *-commutativeN/A

                  \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
                15. lower-fma.f6473.0

                  \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
              5. Applied rewrites73.0%

                \[\leadsto \color{blue}{\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c} \]
              6. Step-by-step derivation
                1. Applied rewrites81.8%

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

                if -2e85 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e-25

                1. Initial program 99.1%

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

                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                4. Step-by-step derivation
                  1. lower-*.f64N/A

                    \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                  2. lower-fma.f64N/A

                    \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
                  3. *-commutativeN/A

                    \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                  4. lower-*.f6494.0

                    \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                5. Applied rewrites94.0%

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

                if 1.00000000000000004e-25 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

                1. Initial program 82.7%

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

                  \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
                4. Step-by-step derivation
                  1. *-commutativeN/A

                    \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
                  2. associate-*r*N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
                  3. distribute-rgt-inN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  4. associate-*r*N/A

                    \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
                  5. distribute-lft-outN/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                  6. lower-*.f64N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
                  7. distribute-lft-outN/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                  8. associate-*r*N/A

                    \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
                  9. distribute-rgt-inN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
                  10. lower-*.f64N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
                  11. *-commutativeN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  12. lower-*.f64N/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  13. +-commutativeN/A

                    \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
                  14. *-commutativeN/A

                    \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
                  15. lower-fma.f6476.3

                    \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
                5. Applied rewrites76.3%

                  \[\leadsto \color{blue}{\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c} \]
              7. Recombined 3 regimes into one program.
              8. Final simplification85.5%

                \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq -2 \cdot 10^{+85}:\\ \;\;\;\;\left(\left(-2 \cdot \mathsf{fma}\left(b, c, a\right)\right) \cdot c\right) \cdot i\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 10^{-25}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c\\ \end{array} \]
              9. Add Preprocessing

              Alternative 8: 79.9% accurate, 0.6× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c\\ t_2 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+85}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 10^{-25}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
              (FPCore (x y z t a b c i)
               :precision binary64
               (let* ((t_1 (* (* -2.0 (* (fma c b a) i)) c)) (t_2 (* i (* (+ (* c b) a) c))))
                 (if (<= t_2 -2e+85) t_1 (if (<= t_2 1e-25) (* (fma t z (* y x)) 2.0) t_1))))
              double code(double x, double y, double z, double t, double a, double b, double c, double i) {
              	double t_1 = (-2.0 * (fma(c, b, a) * i)) * c;
              	double t_2 = i * (((c * b) + a) * c);
              	double tmp;
              	if (t_2 <= -2e+85) {
              		tmp = t_1;
              	} else if (t_2 <= 1e-25) {
              		tmp = fma(t, z, (y * x)) * 2.0;
              	} else {
              		tmp = t_1;
              	}
              	return tmp;
              }
              
              function code(x, y, z, t, a, b, c, i)
              	t_1 = Float64(Float64(-2.0 * Float64(fma(c, b, a) * i)) * c)
              	t_2 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
              	tmp = 0.0
              	if (t_2 <= -2e+85)
              		tmp = t_1;
              	elseif (t_2 <= 1e-25)
              		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
              	else
              		tmp = t_1;
              	end
              	return tmp
              end
              
              code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(-2.0 * N[(N[(c * b + a), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision]}, Block[{t$95$2 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+85], t$95$1, If[LessEqual[t$95$2, 1e-25], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], t$95$1]]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_1 := \left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c\\
              t_2 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
              \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+85}:\\
              \;\;\;\;t\_1\\
              
              \mathbf{elif}\;t\_2 \leq 10^{-25}:\\
              \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\
              
              \mathbf{else}:\\
              \;\;\;\;t\_1\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -2e85 or 1.00000000000000004e-25 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

                1. Initial program 87.0%

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

                  \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
                4. Step-by-step derivation
                  1. *-commutativeN/A

                    \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
                  2. associate-*r*N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
                  3. distribute-rgt-inN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  4. associate-*r*N/A

                    \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
                  5. distribute-lft-outN/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                  6. lower-*.f64N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
                  7. distribute-lft-outN/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                  8. associate-*r*N/A

                    \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
                  9. distribute-rgt-inN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
                  10. lower-*.f64N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
                  11. *-commutativeN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  12. lower-*.f64N/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  13. +-commutativeN/A

                    \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
                  14. *-commutativeN/A

                    \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
                  15. lower-fma.f6475.0

                    \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
                5. Applied rewrites75.0%

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

                if -2e85 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e-25

                1. Initial program 99.1%

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

                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                4. Step-by-step derivation
                  1. lower-*.f64N/A

                    \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                  2. lower-fma.f64N/A

                    \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
                  3. *-commutativeN/A

                    \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                  4. lower-*.f6494.0

                    \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                5. Applied rewrites94.0%

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

                \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq -2 \cdot 10^{+85}:\\ \;\;\;\;\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 10^{-25}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c\\ \end{array} \]
              5. Add Preprocessing

              Alternative 9: 74.2% accurate, 0.6× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(\left(-2 \cdot \left(c \cdot b\right)\right) \cdot i\right) \cdot c\\ t_2 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+233}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 10^{+254}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
              (FPCore (x y z t a b c i)
               :precision binary64
               (let* ((t_1 (* (* (* -2.0 (* c b)) i) c)) (t_2 (* i (* (+ (* c b) a) c))))
                 (if (<= t_2 -2e+233)
                   t_1
                   (if (<= t_2 1e+254) (* (fma t z (* y x)) 2.0) t_1))))
              double code(double x, double y, double z, double t, double a, double b, double c, double i) {
              	double t_1 = ((-2.0 * (c * b)) * i) * c;
              	double t_2 = i * (((c * b) + a) * c);
              	double tmp;
              	if (t_2 <= -2e+233) {
              		tmp = t_1;
              	} else if (t_2 <= 1e+254) {
              		tmp = fma(t, z, (y * x)) * 2.0;
              	} else {
              		tmp = t_1;
              	}
              	return tmp;
              }
              
              function code(x, y, z, t, a, b, c, i)
              	t_1 = Float64(Float64(Float64(-2.0 * Float64(c * b)) * i) * c)
              	t_2 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
              	tmp = 0.0
              	if (t_2 <= -2e+233)
              		tmp = t_1;
              	elseif (t_2 <= 1e+254)
              		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
              	else
              		tmp = t_1;
              	end
              	return tmp
              end
              
              code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(N[(-2.0 * N[(c * b), $MachinePrecision]), $MachinePrecision] * i), $MachinePrecision] * c), $MachinePrecision]}, Block[{t$95$2 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+233], t$95$1, If[LessEqual[t$95$2, 1e+254], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], t$95$1]]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_1 := \left(\left(-2 \cdot \left(c \cdot b\right)\right) \cdot i\right) \cdot c\\
              t_2 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
              \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+233}:\\
              \;\;\;\;t\_1\\
              
              \mathbf{elif}\;t\_2 \leq 10^{+254}:\\
              \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\
              
              \mathbf{else}:\\
              \;\;\;\;t\_1\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -1.99999999999999995e233 or 9.9999999999999994e253 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

                1. Initial program 81.1%

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

                  \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
                4. Step-by-step derivation
                  1. *-commutativeN/A

                    \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
                  2. associate-*r*N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
                  3. distribute-rgt-inN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  4. associate-*r*N/A

                    \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
                  5. distribute-lft-outN/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                  6. lower-*.f64N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
                  7. distribute-lft-outN/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                  8. associate-*r*N/A

                    \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
                  9. distribute-rgt-inN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
                  10. lower-*.f64N/A

                    \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
                  11. *-commutativeN/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  12. lower-*.f64N/A

                    \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                  13. +-commutativeN/A

                    \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
                  14. *-commutativeN/A

                    \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
                  15. lower-fma.f6484.7

                    \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
                5. Applied rewrites84.7%

                  \[\leadsto \color{blue}{\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c} \]
                6. Step-by-step derivation
                  1. Applied rewrites83.7%

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

                    \[\leadsto \left(c \cdot \left(-2 \cdot \left(b \cdot c\right)\right)\right) \cdot i \]
                  3. Step-by-step derivation
                    1. Applied rewrites60.3%

                      \[\leadsto \left(c \cdot \left(-2 \cdot \left(b \cdot c\right)\right)\right) \cdot i \]
                    2. Step-by-step derivation
                      1. Applied rewrites61.3%

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

                      if -1.99999999999999995e233 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 9.9999999999999994e253

                      1. Initial program 99.3%

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

                        \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                      4. Step-by-step derivation
                        1. lower-*.f64N/A

                          \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                        2. lower-fma.f64N/A

                          \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
                        3. *-commutativeN/A

                          \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                        4. lower-*.f6478.6

                          \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                      5. Applied rewrites78.6%

                        \[\leadsto \color{blue}{2 \cdot \mathsf{fma}\left(t, z, y \cdot x\right)} \]
                    3. Recombined 2 regimes into one program.
                    4. Final simplification72.1%

                      \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq -2 \cdot 10^{+233}:\\ \;\;\;\;\left(\left(-2 \cdot \left(c \cdot b\right)\right) \cdot i\right) \cdot c\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 10^{+254}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(-2 \cdot \left(c \cdot b\right)\right) \cdot i\right) \cdot c\\ \end{array} \]
                    5. Add Preprocessing

                    Alternative 10: 73.8% accurate, 0.6× speedup?

                    \[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+233}:\\ \;\;\;\;\left(\left(-2 \cdot \left(c \cdot b\right)\right) \cdot c\right) \cdot i\\ \mathbf{elif}\;t\_1 \leq 10^{+254}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\ \end{array} \end{array} \]
                    (FPCore (x y z t a b c i)
                     :precision binary64
                     (let* ((t_1 (* i (* (+ (* c b) a) c))))
                       (if (<= t_1 -2e+233)
                         (* (* (* -2.0 (* c b)) c) i)
                         (if (<= t_1 1e+254)
                           (* (fma t z (* y x)) 2.0)
                           (* (* (* (* c c) i) b) -2.0)))))
                    double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                    	double t_1 = i * (((c * b) + a) * c);
                    	double tmp;
                    	if (t_1 <= -2e+233) {
                    		tmp = ((-2.0 * (c * b)) * c) * i;
                    	} else if (t_1 <= 1e+254) {
                    		tmp = fma(t, z, (y * x)) * 2.0;
                    	} else {
                    		tmp = (((c * c) * i) * b) * -2.0;
                    	}
                    	return tmp;
                    }
                    
                    function code(x, y, z, t, a, b, c, i)
                    	t_1 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
                    	tmp = 0.0
                    	if (t_1 <= -2e+233)
                    		tmp = Float64(Float64(Float64(-2.0 * Float64(c * b)) * c) * i);
                    	elseif (t_1 <= 1e+254)
                    		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
                    	else
                    		tmp = Float64(Float64(Float64(Float64(c * c) * i) * b) * -2.0);
                    	end
                    	return tmp
                    end
                    
                    code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -2e+233], N[(N[(N[(-2.0 * N[(c * b), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision], If[LessEqual[t$95$1, 1e+254], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], N[(N[(N[(N[(c * c), $MachinePrecision] * i), $MachinePrecision] * b), $MachinePrecision] * -2.0), $MachinePrecision]]]]
                    
                    \begin{array}{l}
                    
                    \\
                    \begin{array}{l}
                    t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
                    \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+233}:\\
                    \;\;\;\;\left(\left(-2 \cdot \left(c \cdot b\right)\right) \cdot c\right) \cdot i\\
                    
                    \mathbf{elif}\;t\_1 \leq 10^{+254}:\\
                    \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\
                    
                    \mathbf{else}:\\
                    \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\
                    
                    
                    \end{array}
                    \end{array}
                    
                    Derivation
                    1. Split input into 3 regimes
                    2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -1.99999999999999995e233

                      1. Initial program 91.0%

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

                        \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
                      4. Step-by-step derivation
                        1. *-commutativeN/A

                          \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
                        2. associate-*r*N/A

                          \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
                        3. distribute-rgt-inN/A

                          \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                        4. associate-*r*N/A

                          \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
                        5. distribute-lft-outN/A

                          \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                        6. lower-*.f64N/A

                          \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
                        7. distribute-lft-outN/A

                          \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                        8. associate-*r*N/A

                          \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
                        9. distribute-rgt-inN/A

                          \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
                        10. lower-*.f64N/A

                          \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
                        11. *-commutativeN/A

                          \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                        12. lower-*.f64N/A

                          \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                        13. +-commutativeN/A

                          \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
                        14. *-commutativeN/A

                          \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
                        15. lower-fma.f6484.2

                          \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
                      5. Applied rewrites84.2%

                        \[\leadsto \color{blue}{\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c} \]
                      6. Step-by-step derivation
                        1. Applied rewrites88.6%

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

                          \[\leadsto \left(c \cdot \left(-2 \cdot \left(b \cdot c\right)\right)\right) \cdot i \]
                        3. Step-by-step derivation
                          1. Applied rewrites65.4%

                            \[\leadsto \left(c \cdot \left(-2 \cdot \left(b \cdot c\right)\right)\right) \cdot i \]

                          if -1.99999999999999995e233 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 9.9999999999999994e253

                          1. Initial program 99.3%

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

                            \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                          4. Step-by-step derivation
                            1. lower-*.f64N/A

                              \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                            2. lower-fma.f64N/A

                              \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
                            3. *-commutativeN/A

                              \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                            4. lower-*.f6478.6

                              \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                          5. Applied rewrites78.6%

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

                          if 9.9999999999999994e253 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

                          1. Initial program 73.7%

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

                            \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
                          4. Step-by-step derivation
                            1. *-commutativeN/A

                              \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
                            2. associate-*r*N/A

                              \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
                            3. distribute-rgt-inN/A

                              \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                            4. associate-*r*N/A

                              \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
                            5. distribute-lft-outN/A

                              \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                            6. lower-*.f64N/A

                              \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
                            7. distribute-lft-outN/A

                              \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                            8. associate-*r*N/A

                              \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
                            9. distribute-rgt-inN/A

                              \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
                            10. lower-*.f64N/A

                              \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
                            11. *-commutativeN/A

                              \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                            12. lower-*.f64N/A

                              \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                            13. +-commutativeN/A

                              \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
                            14. *-commutativeN/A

                              \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
                            15. lower-fma.f6485.1

                              \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
                          5. Applied rewrites85.1%

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

                            \[\leadsto -2 \cdot \color{blue}{\left(b \cdot \left({c}^{2} \cdot i\right)\right)} \]
                          7. Step-by-step derivation
                            1. Applied rewrites58.0%

                              \[\leadsto \left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot \color{blue}{-2} \]
                          8. Recombined 3 regimes into one program.
                          9. Final simplification72.0%

                            \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq -2 \cdot 10^{+233}:\\ \;\;\;\;\left(\left(-2 \cdot \left(c \cdot b\right)\right) \cdot c\right) \cdot i\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 10^{+254}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot i\right) \cdot b\right) \cdot -2\\ \end{array} \]
                          10. Add Preprocessing

                          Alternative 11: 62.4% accurate, 0.6× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\ \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+163}:\\ \;\;\;\;\left(\left(-2 \cdot a\right) \cdot c\right) \cdot i\\ \mathbf{elif}\;t\_1 \leq 3 \cdot 10^{+140}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \end{array} \end{array} \]
                          (FPCore (x y z t a b c i)
                           :precision binary64
                           (let* ((t_1 (* i (* (+ (* c b) a) c))))
                             (if (<= t_1 -4e+163)
                               (* (* (* -2.0 a) c) i)
                               (if (<= t_1 3e+140) (* (fma t z (* y x)) 2.0) (* (* (* i c) a) -2.0)))))
                          double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                          	double t_1 = i * (((c * b) + a) * c);
                          	double tmp;
                          	if (t_1 <= -4e+163) {
                          		tmp = ((-2.0 * a) * c) * i;
                          	} else if (t_1 <= 3e+140) {
                          		tmp = fma(t, z, (y * x)) * 2.0;
                          	} else {
                          		tmp = ((i * c) * a) * -2.0;
                          	}
                          	return tmp;
                          }
                          
                          function code(x, y, z, t, a, b, c, i)
                          	t_1 = Float64(i * Float64(Float64(Float64(c * b) + a) * c))
                          	tmp = 0.0
                          	if (t_1 <= -4e+163)
                          		tmp = Float64(Float64(Float64(-2.0 * a) * c) * i);
                          	elseif (t_1 <= 3e+140)
                          		tmp = Float64(fma(t, z, Float64(y * x)) * 2.0);
                          	else
                          		tmp = Float64(Float64(Float64(i * c) * a) * -2.0);
                          	end
                          	return tmp
                          end
                          
                          code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(i * N[(N[(N[(c * b), $MachinePrecision] + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -4e+163], N[(N[(N[(-2.0 * a), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision], If[LessEqual[t$95$1, 3e+140], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision], N[(N[(N[(i * c), $MachinePrecision] * a), $MachinePrecision] * -2.0), $MachinePrecision]]]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          t_1 := i \cdot \left(\left(c \cdot b + a\right) \cdot c\right)\\
                          \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+163}:\\
                          \;\;\;\;\left(\left(-2 \cdot a\right) \cdot c\right) \cdot i\\
                          
                          \mathbf{elif}\;t\_1 \leq 3 \cdot 10^{+140}:\\
                          \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 3 regimes
                          2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -3.9999999999999998e163

                            1. Initial program 92.6%

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

                              \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
                            4. Step-by-step derivation
                              1. *-commutativeN/A

                                \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
                              2. associate-*r*N/A

                                \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
                              3. distribute-rgt-inN/A

                                \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                              4. associate-*r*N/A

                                \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
                              5. distribute-lft-outN/A

                                \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                              6. lower-*.f64N/A

                                \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
                              7. distribute-lft-outN/A

                                \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                              8. associate-*r*N/A

                                \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
                              9. distribute-rgt-inN/A

                                \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
                              10. lower-*.f64N/A

                                \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
                              11. *-commutativeN/A

                                \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                              12. lower-*.f64N/A

                                \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                              13. +-commutativeN/A

                                \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
                              14. *-commutativeN/A

                                \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
                              15. lower-fma.f6476.0

                                \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
                            5. Applied rewrites76.0%

                              \[\leadsto \color{blue}{\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c} \]
                            6. Step-by-step derivation
                              1. Applied rewrites83.2%

                                \[\leadsto \left(c \cdot \left(-2 \cdot \mathsf{fma}\left(b, c, a\right)\right)\right) \cdot \color{blue}{i} \]
                              2. Taylor expanded in a around inf

                                \[\leadsto \left(c \cdot \left(-2 \cdot a\right)\right) \cdot i \]
                              3. Step-by-step derivation
                                1. Applied rewrites37.9%

                                  \[\leadsto \left(c \cdot \left(-2 \cdot a\right)\right) \cdot i \]

                                if -3.9999999999999998e163 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 2.99999999999999997e140

                                1. Initial program 99.2%

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

                                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                                4. Step-by-step derivation
                                  1. lower-*.f64N/A

                                    \[\leadsto \color{blue}{2 \cdot \left(t \cdot z + x \cdot y\right)} \]
                                  2. lower-fma.f64N/A

                                    \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)} \]
                                  3. *-commutativeN/A

                                    \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                                  4. lower-*.f6485.6

                                    \[\leadsto 2 \cdot \mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right) \]
                                5. Applied rewrites85.6%

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

                                if 2.99999999999999997e140 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

                                1. Initial program 79.0%

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

                                  \[\leadsto \color{blue}{-2 \cdot \left(a \cdot \left(c \cdot i\right)\right)} \]
                                4. Step-by-step derivation
                                  1. *-commutativeN/A

                                    \[\leadsto \color{blue}{\left(a \cdot \left(c \cdot i\right)\right) \cdot -2} \]
                                  2. lower-*.f64N/A

                                    \[\leadsto \color{blue}{\left(a \cdot \left(c \cdot i\right)\right) \cdot -2} \]
                                  3. *-commutativeN/A

                                    \[\leadsto \color{blue}{\left(\left(c \cdot i\right) \cdot a\right)} \cdot -2 \]
                                  4. lower-*.f64N/A

                                    \[\leadsto \color{blue}{\left(\left(c \cdot i\right) \cdot a\right)} \cdot -2 \]
                                  5. *-commutativeN/A

                                    \[\leadsto \left(\color{blue}{\left(i \cdot c\right)} \cdot a\right) \cdot -2 \]
                                  6. lower-*.f6441.2

                                    \[\leadsto \left(\color{blue}{\left(i \cdot c\right)} \cdot a\right) \cdot -2 \]
                                5. Applied rewrites41.2%

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

                                \[\leadsto \begin{array}{l} \mathbf{if}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq -4 \cdot 10^{+163}:\\ \;\;\;\;\left(\left(-2 \cdot a\right) \cdot c\right) \cdot i\\ \mathbf{elif}\;i \cdot \left(\left(c \cdot b + a\right) \cdot c\right) \leq 3 \cdot 10^{+140}:\\ \;\;\;\;\mathsf{fma}\left(t, z, y \cdot x\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \end{array} \]
                              6. Add Preprocessing

                              Alternative 12: 44.4% accurate, 0.8× speedup?

                              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(y \cdot x\right) \cdot 2\\ \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \cdot x \leq 10^{-67}:\\ \;\;\;\;\left(t \cdot z\right) \cdot 2\\ \mathbf{elif}\;y \cdot x \leq 5 \cdot 10^{+49}:\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                              (FPCore (x y z t a b c i)
                               :precision binary64
                               (let* ((t_1 (* (* y x) 2.0)))
                                 (if (<= (* y x) -4e+62)
                                   t_1
                                   (if (<= (* y x) 1e-67)
                                     (* (* t z) 2.0)
                                     (if (<= (* y x) 5e+49) (* (* (* i c) a) -2.0) t_1)))))
                              double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                              	double t_1 = (y * x) * 2.0;
                              	double tmp;
                              	if ((y * x) <= -4e+62) {
                              		tmp = t_1;
                              	} else if ((y * x) <= 1e-67) {
                              		tmp = (t * z) * 2.0;
                              	} else if ((y * x) <= 5e+49) {
                              		tmp = ((i * c) * a) * -2.0;
                              	} else {
                              		tmp = t_1;
                              	}
                              	return tmp;
                              }
                              
                              real(8) function code(x, y, z, t, a, b, c, i)
                                  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) :: t_1
                                  real(8) :: tmp
                                  t_1 = (y * x) * 2.0d0
                                  if ((y * x) <= (-4d+62)) then
                                      tmp = t_1
                                  else if ((y * x) <= 1d-67) then
                                      tmp = (t * z) * 2.0d0
                                  else if ((y * x) <= 5d+49) then
                                      tmp = ((i * c) * a) * (-2.0d0)
                                  else
                                      tmp = t_1
                                  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 t_1 = (y * x) * 2.0;
                              	double tmp;
                              	if ((y * x) <= -4e+62) {
                              		tmp = t_1;
                              	} else if ((y * x) <= 1e-67) {
                              		tmp = (t * z) * 2.0;
                              	} else if ((y * x) <= 5e+49) {
                              		tmp = ((i * c) * a) * -2.0;
                              	} else {
                              		tmp = t_1;
                              	}
                              	return tmp;
                              }
                              
                              def code(x, y, z, t, a, b, c, i):
                              	t_1 = (y * x) * 2.0
                              	tmp = 0
                              	if (y * x) <= -4e+62:
                              		tmp = t_1
                              	elif (y * x) <= 1e-67:
                              		tmp = (t * z) * 2.0
                              	elif (y * x) <= 5e+49:
                              		tmp = ((i * c) * a) * -2.0
                              	else:
                              		tmp = t_1
                              	return tmp
                              
                              function code(x, y, z, t, a, b, c, i)
                              	t_1 = Float64(Float64(y * x) * 2.0)
                              	tmp = 0.0
                              	if (Float64(y * x) <= -4e+62)
                              		tmp = t_1;
                              	elseif (Float64(y * x) <= 1e-67)
                              		tmp = Float64(Float64(t * z) * 2.0);
                              	elseif (Float64(y * x) <= 5e+49)
                              		tmp = Float64(Float64(Float64(i * c) * a) * -2.0);
                              	else
                              		tmp = t_1;
                              	end
                              	return tmp
                              end
                              
                              function tmp_2 = code(x, y, z, t, a, b, c, i)
                              	t_1 = (y * x) * 2.0;
                              	tmp = 0.0;
                              	if ((y * x) <= -4e+62)
                              		tmp = t_1;
                              	elseif ((y * x) <= 1e-67)
                              		tmp = (t * z) * 2.0;
                              	elseif ((y * x) <= 5e+49)
                              		tmp = ((i * c) * a) * -2.0;
                              	else
                              		tmp = t_1;
                              	end
                              	tmp_2 = tmp;
                              end
                              
                              code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * x), $MachinePrecision] * 2.0), $MachinePrecision]}, If[LessEqual[N[(y * x), $MachinePrecision], -4e+62], t$95$1, If[LessEqual[N[(y * x), $MachinePrecision], 1e-67], N[(N[(t * z), $MachinePrecision] * 2.0), $MachinePrecision], If[LessEqual[N[(y * x), $MachinePrecision], 5e+49], N[(N[(N[(i * c), $MachinePrecision] * a), $MachinePrecision] * -2.0), $MachinePrecision], t$95$1]]]]
                              
                              \begin{array}{l}
                              
                              \\
                              \begin{array}{l}
                              t_1 := \left(y \cdot x\right) \cdot 2\\
                              \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\
                              \;\;\;\;t\_1\\
                              
                              \mathbf{elif}\;y \cdot x \leq 10^{-67}:\\
                              \;\;\;\;\left(t \cdot z\right) \cdot 2\\
                              
                              \mathbf{elif}\;y \cdot x \leq 5 \cdot 10^{+49}:\\
                              \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\
                              
                              \mathbf{else}:\\
                              \;\;\;\;t\_1\\
                              
                              
                              \end{array}
                              \end{array}
                              
                              Derivation
                              1. Split input into 3 regimes
                              2. if (*.f64 x y) < -4.00000000000000014e62 or 5.0000000000000004e49 < (*.f64 x y)

                                1. Initial program 89.3%

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

                                  \[\leadsto \color{blue}{2 \cdot \left(x \cdot y\right)} \]
                                4. Step-by-step derivation
                                  1. lower-*.f64N/A

                                    \[\leadsto \color{blue}{2 \cdot \left(x \cdot y\right)} \]
                                  2. *-commutativeN/A

                                    \[\leadsto 2 \cdot \color{blue}{\left(y \cdot x\right)} \]
                                  3. lower-*.f6460.0

                                    \[\leadsto 2 \cdot \color{blue}{\left(y \cdot x\right)} \]
                                5. Applied rewrites60.0%

                                  \[\leadsto \color{blue}{2 \cdot \left(y \cdot x\right)} \]

                                if -4.00000000000000014e62 < (*.f64 x y) < 9.99999999999999943e-68

                                1. Initial program 94.3%

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

                                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                4. Step-by-step derivation
                                  1. lower-*.f64N/A

                                    \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                  2. lower-*.f6442.9

                                    \[\leadsto 2 \cdot \color{blue}{\left(t \cdot z\right)} \]
                                5. Applied rewrites42.9%

                                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]

                                if 9.99999999999999943e-68 < (*.f64 x y) < 5.0000000000000004e49

                                1. Initial program 95.5%

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

                                  \[\leadsto \color{blue}{-2 \cdot \left(a \cdot \left(c \cdot i\right)\right)} \]
                                4. Step-by-step derivation
                                  1. *-commutativeN/A

                                    \[\leadsto \color{blue}{\left(a \cdot \left(c \cdot i\right)\right) \cdot -2} \]
                                  2. lower-*.f64N/A

                                    \[\leadsto \color{blue}{\left(a \cdot \left(c \cdot i\right)\right) \cdot -2} \]
                                  3. *-commutativeN/A

                                    \[\leadsto \color{blue}{\left(\left(c \cdot i\right) \cdot a\right)} \cdot -2 \]
                                  4. lower-*.f64N/A

                                    \[\leadsto \color{blue}{\left(\left(c \cdot i\right) \cdot a\right)} \cdot -2 \]
                                  5. *-commutativeN/A

                                    \[\leadsto \left(\color{blue}{\left(i \cdot c\right)} \cdot a\right) \cdot -2 \]
                                  6. lower-*.f6448.8

                                    \[\leadsto \left(\color{blue}{\left(i \cdot c\right)} \cdot a\right) \cdot -2 \]
                                5. Applied rewrites48.8%

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

                                \[\leadsto \begin{array}{l} \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\ \;\;\;\;\left(y \cdot x\right) \cdot 2\\ \mathbf{elif}\;y \cdot x \leq 10^{-67}:\\ \;\;\;\;\left(t \cdot z\right) \cdot 2\\ \mathbf{elif}\;y \cdot x \leq 5 \cdot 10^{+49}:\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \mathbf{else}:\\ \;\;\;\;\left(y \cdot x\right) \cdot 2\\ \end{array} \]
                              5. Add Preprocessing

                              Alternative 13: 44.2% accurate, 0.8× speedup?

                              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(y \cdot x\right) \cdot 2\\ \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \cdot x \leq 10^{-67}:\\ \;\;\;\;\left(t \cdot z\right) \cdot 2\\ \mathbf{elif}\;y \cdot x \leq 10^{+41}:\\ \;\;\;\;\left(\left(-2 \cdot a\right) \cdot c\right) \cdot i\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                              (FPCore (x y z t a b c i)
                               :precision binary64
                               (let* ((t_1 (* (* y x) 2.0)))
                                 (if (<= (* y x) -4e+62)
                                   t_1
                                   (if (<= (* y x) 1e-67)
                                     (* (* t z) 2.0)
                                     (if (<= (* y x) 1e+41) (* (* (* -2.0 a) c) i) t_1)))))
                              double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                              	double t_1 = (y * x) * 2.0;
                              	double tmp;
                              	if ((y * x) <= -4e+62) {
                              		tmp = t_1;
                              	} else if ((y * x) <= 1e-67) {
                              		tmp = (t * z) * 2.0;
                              	} else if ((y * x) <= 1e+41) {
                              		tmp = ((-2.0 * a) * c) * i;
                              	} else {
                              		tmp = t_1;
                              	}
                              	return tmp;
                              }
                              
                              real(8) function code(x, y, z, t, a, b, c, i)
                                  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) :: t_1
                                  real(8) :: tmp
                                  t_1 = (y * x) * 2.0d0
                                  if ((y * x) <= (-4d+62)) then
                                      tmp = t_1
                                  else if ((y * x) <= 1d-67) then
                                      tmp = (t * z) * 2.0d0
                                  else if ((y * x) <= 1d+41) then
                                      tmp = (((-2.0d0) * a) * c) * i
                                  else
                                      tmp = t_1
                                  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 t_1 = (y * x) * 2.0;
                              	double tmp;
                              	if ((y * x) <= -4e+62) {
                              		tmp = t_1;
                              	} else if ((y * x) <= 1e-67) {
                              		tmp = (t * z) * 2.0;
                              	} else if ((y * x) <= 1e+41) {
                              		tmp = ((-2.0 * a) * c) * i;
                              	} else {
                              		tmp = t_1;
                              	}
                              	return tmp;
                              }
                              
                              def code(x, y, z, t, a, b, c, i):
                              	t_1 = (y * x) * 2.0
                              	tmp = 0
                              	if (y * x) <= -4e+62:
                              		tmp = t_1
                              	elif (y * x) <= 1e-67:
                              		tmp = (t * z) * 2.0
                              	elif (y * x) <= 1e+41:
                              		tmp = ((-2.0 * a) * c) * i
                              	else:
                              		tmp = t_1
                              	return tmp
                              
                              function code(x, y, z, t, a, b, c, i)
                              	t_1 = Float64(Float64(y * x) * 2.0)
                              	tmp = 0.0
                              	if (Float64(y * x) <= -4e+62)
                              		tmp = t_1;
                              	elseif (Float64(y * x) <= 1e-67)
                              		tmp = Float64(Float64(t * z) * 2.0);
                              	elseif (Float64(y * x) <= 1e+41)
                              		tmp = Float64(Float64(Float64(-2.0 * a) * c) * i);
                              	else
                              		tmp = t_1;
                              	end
                              	return tmp
                              end
                              
                              function tmp_2 = code(x, y, z, t, a, b, c, i)
                              	t_1 = (y * x) * 2.0;
                              	tmp = 0.0;
                              	if ((y * x) <= -4e+62)
                              		tmp = t_1;
                              	elseif ((y * x) <= 1e-67)
                              		tmp = (t * z) * 2.0;
                              	elseif ((y * x) <= 1e+41)
                              		tmp = ((-2.0 * a) * c) * i;
                              	else
                              		tmp = t_1;
                              	end
                              	tmp_2 = tmp;
                              end
                              
                              code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * x), $MachinePrecision] * 2.0), $MachinePrecision]}, If[LessEqual[N[(y * x), $MachinePrecision], -4e+62], t$95$1, If[LessEqual[N[(y * x), $MachinePrecision], 1e-67], N[(N[(t * z), $MachinePrecision] * 2.0), $MachinePrecision], If[LessEqual[N[(y * x), $MachinePrecision], 1e+41], N[(N[(N[(-2.0 * a), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision], t$95$1]]]]
                              
                              \begin{array}{l}
                              
                              \\
                              \begin{array}{l}
                              t_1 := \left(y \cdot x\right) \cdot 2\\
                              \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\
                              \;\;\;\;t\_1\\
                              
                              \mathbf{elif}\;y \cdot x \leq 10^{-67}:\\
                              \;\;\;\;\left(t \cdot z\right) \cdot 2\\
                              
                              \mathbf{elif}\;y \cdot x \leq 10^{+41}:\\
                              \;\;\;\;\left(\left(-2 \cdot a\right) \cdot c\right) \cdot i\\
                              
                              \mathbf{else}:\\
                              \;\;\;\;t\_1\\
                              
                              
                              \end{array}
                              \end{array}
                              
                              Derivation
                              1. Split input into 3 regimes
                              2. if (*.f64 x y) < -4.00000000000000014e62 or 1.00000000000000001e41 < (*.f64 x y)

                                1. Initial program 89.6%

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

                                  \[\leadsto \color{blue}{2 \cdot \left(x \cdot y\right)} \]
                                4. Step-by-step derivation
                                  1. lower-*.f64N/A

                                    \[\leadsto \color{blue}{2 \cdot \left(x \cdot y\right)} \]
                                  2. *-commutativeN/A

                                    \[\leadsto 2 \cdot \color{blue}{\left(y \cdot x\right)} \]
                                  3. lower-*.f6459.2

                                    \[\leadsto 2 \cdot \color{blue}{\left(y \cdot x\right)} \]
                                5. Applied rewrites59.2%

                                  \[\leadsto \color{blue}{2 \cdot \left(y \cdot x\right)} \]

                                if -4.00000000000000014e62 < (*.f64 x y) < 9.99999999999999943e-68

                                1. Initial program 94.3%

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

                                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                4. Step-by-step derivation
                                  1. lower-*.f64N/A

                                    \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                  2. lower-*.f6442.9

                                    \[\leadsto 2 \cdot \color{blue}{\left(t \cdot z\right)} \]
                                5. Applied rewrites42.9%

                                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]

                                if 9.99999999999999943e-68 < (*.f64 x y) < 1.00000000000000001e41

                                1. Initial program 94.7%

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

                                  \[\leadsto \color{blue}{-2 \cdot \left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \]
                                4. Step-by-step derivation
                                  1. *-commutativeN/A

                                    \[\leadsto -2 \cdot \color{blue}{\left(\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c\right)} \]
                                  2. associate-*r*N/A

                                    \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \cdot c} \]
                                  3. distribute-rgt-inN/A

                                    \[\leadsto \left(-2 \cdot \color{blue}{\left(a \cdot i + \left(b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                                  4. associate-*r*N/A

                                    \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{b \cdot \left(c \cdot i\right)}\right)\right) \cdot c \]
                                  5. distribute-lft-outN/A

                                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                                  6. lower-*.f64N/A

                                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i\right) + -2 \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot c} \]
                                  7. distribute-lft-outN/A

                                    \[\leadsto \color{blue}{\left(-2 \cdot \left(a \cdot i + b \cdot \left(c \cdot i\right)\right)\right)} \cdot c \]
                                  8. associate-*r*N/A

                                    \[\leadsto \left(-2 \cdot \left(a \cdot i + \color{blue}{\left(b \cdot c\right) \cdot i}\right)\right) \cdot c \]
                                  9. distribute-rgt-inN/A

                                    \[\leadsto \left(-2 \cdot \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right)}\right) \cdot c \]
                                  10. lower-*.f64N/A

                                    \[\leadsto \color{blue}{\left(-2 \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)} \cdot c \]
                                  11. *-commutativeN/A

                                    \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                                  12. lower-*.f64N/A

                                    \[\leadsto \left(-2 \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot i\right)}\right) \cdot c \]
                                  13. +-commutativeN/A

                                    \[\leadsto \left(-2 \cdot \left(\color{blue}{\left(b \cdot c + a\right)} \cdot i\right)\right) \cdot c \]
                                  14. *-commutativeN/A

                                    \[\leadsto \left(-2 \cdot \left(\left(\color{blue}{c \cdot b} + a\right) \cdot i\right)\right) \cdot c \]
                                  15. lower-fma.f6462.4

                                    \[\leadsto \left(-2 \cdot \left(\color{blue}{\mathsf{fma}\left(c, b, a\right)} \cdot i\right)\right) \cdot c \]
                                5. Applied rewrites62.4%

                                  \[\leadsto \color{blue}{\left(-2 \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right) \cdot c} \]
                                6. Step-by-step derivation
                                  1. Applied rewrites73.2%

                                    \[\leadsto \left(c \cdot \left(-2 \cdot \mathsf{fma}\left(b, c, a\right)\right)\right) \cdot \color{blue}{i} \]
                                  2. Taylor expanded in a around inf

                                    \[\leadsto \left(c \cdot \left(-2 \cdot a\right)\right) \cdot i \]
                                  3. Step-by-step derivation
                                    1. Applied rewrites45.9%

                                      \[\leadsto \left(c \cdot \left(-2 \cdot a\right)\right) \cdot i \]
                                  4. Recombined 3 regimes into one program.
                                  5. Final simplification49.7%

                                    \[\leadsto \begin{array}{l} \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\ \;\;\;\;\left(y \cdot x\right) \cdot 2\\ \mathbf{elif}\;y \cdot x \leq 10^{-67}:\\ \;\;\;\;\left(t \cdot z\right) \cdot 2\\ \mathbf{elif}\;y \cdot x \leq 10^{+41}:\\ \;\;\;\;\left(\left(-2 \cdot a\right) \cdot c\right) \cdot i\\ \mathbf{else}:\\ \;\;\;\;\left(y \cdot x\right) \cdot 2\\ \end{array} \]
                                  6. Add Preprocessing

                                  Alternative 14: 94.1% accurate, 1.1× speedup?

                                  \[\begin{array}{l} \\ \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \left(-c\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right)\right) \cdot 2 \end{array} \]
                                  (FPCore (x y z t a b c i)
                                   :precision binary64
                                   (* (fma z t (fma y x (* (- c) (* (fma c b a) i)))) 2.0))
                                  double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                                  	return fma(z, t, fma(y, x, (-c * (fma(c, b, a) * i)))) * 2.0;
                                  }
                                  
                                  function code(x, y, z, t, a, b, c, i)
                                  	return Float64(fma(z, t, fma(y, x, Float64(Float64(-c) * Float64(fma(c, b, a) * i)))) * 2.0)
                                  end
                                  
                                  code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(z * t + N[(y * x + N[((-c) * N[(N[(c * b + a), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \left(-c\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right)\right) \cdot 2
                                  \end{array}
                                  
                                  Derivation
                                  1. Initial program 92.4%

                                    \[2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \]
                                  2. Add Preprocessing
                                  3. Step-by-step derivation
                                    1. lift--.f64N/A

                                      \[\leadsto 2 \cdot \color{blue}{\left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)} \]
                                    2. lift-+.f64N/A

                                      \[\leadsto 2 \cdot \left(\color{blue}{\left(x \cdot y + z \cdot t\right)} - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \]
                                    3. +-commutativeN/A

                                      \[\leadsto 2 \cdot \left(\color{blue}{\left(z \cdot t + x \cdot y\right)} - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \]
                                    4. associate--l+N/A

                                      \[\leadsto 2 \cdot \color{blue}{\left(z \cdot t + \left(x \cdot y - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)} \]
                                    5. lift-*.f64N/A

                                      \[\leadsto 2 \cdot \left(\color{blue}{z \cdot t} + \left(x \cdot y - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right) \]
                                    6. lower-fma.f64N/A

                                      \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, x \cdot y - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)} \]
                                    7. sub-negN/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \color{blue}{x \cdot y + \left(\mathsf{neg}\left(\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)}\right) \]
                                    8. lift-*.f64N/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \color{blue}{x \cdot y} + \left(\mathsf{neg}\left(\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)\right) \]
                                    9. *-commutativeN/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \color{blue}{y \cdot x} + \left(\mathsf{neg}\left(\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)\right) \]
                                    10. lower-fma.f64N/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \color{blue}{\mathsf{fma}\left(y, x, \mathsf{neg}\left(\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)\right)}\right) \]
                                    11. lift-*.f64N/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \mathsf{neg}\left(\color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right)\right)\right) \]
                                    12. *-commutativeN/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \mathsf{neg}\left(\color{blue}{i \cdot \left(\left(a + b \cdot c\right) \cdot c\right)}\right)\right)\right) \]
                                    13. lift-*.f64N/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \mathsf{neg}\left(i \cdot \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right)}\right)\right)\right) \]
                                    14. associate-*r*N/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \mathsf{neg}\left(\color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right) \cdot c}\right)\right)\right) \]
                                    15. distribute-rgt-neg-inN/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right) \cdot \left(\mathsf{neg}\left(c\right)\right)}\right)\right) \]
                                    16. lower-*.f64N/A

                                      \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \color{blue}{\left(i \cdot \left(a + b \cdot c\right)\right) \cdot \left(\mathsf{neg}\left(c\right)\right)}\right)\right) \]
                                  4. Applied rewrites95.8%

                                    \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \left(i \cdot \mathsf{fma}\left(c, b, a\right)\right) \cdot \left(-c\right)\right)\right)} \]
                                  5. Final simplification95.8%

                                    \[\leadsto \mathsf{fma}\left(z, t, \mathsf{fma}\left(y, x, \left(-c\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot i\right)\right)\right) \cdot 2 \]
                                  6. Add Preprocessing

                                  Alternative 15: 44.1% accurate, 1.2× speedup?

                                  \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(y \cdot x\right) \cdot 2\\ \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \cdot x \leq 2 \cdot 10^{-47}:\\ \;\;\;\;\left(t \cdot z\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                                  (FPCore (x y z t a b c i)
                                   :precision binary64
                                   (let* ((t_1 (* (* y x) 2.0)))
                                     (if (<= (* y x) -4e+62) t_1 (if (<= (* y x) 2e-47) (* (* t z) 2.0) t_1))))
                                  double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                                  	double t_1 = (y * x) * 2.0;
                                  	double tmp;
                                  	if ((y * x) <= -4e+62) {
                                  		tmp = t_1;
                                  	} else if ((y * x) <= 2e-47) {
                                  		tmp = (t * z) * 2.0;
                                  	} else {
                                  		tmp = t_1;
                                  	}
                                  	return tmp;
                                  }
                                  
                                  real(8) function code(x, y, z, t, a, b, c, i)
                                      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) :: t_1
                                      real(8) :: tmp
                                      t_1 = (y * x) * 2.0d0
                                      if ((y * x) <= (-4d+62)) then
                                          tmp = t_1
                                      else if ((y * x) <= 2d-47) then
                                          tmp = (t * z) * 2.0d0
                                      else
                                          tmp = t_1
                                      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 t_1 = (y * x) * 2.0;
                                  	double tmp;
                                  	if ((y * x) <= -4e+62) {
                                  		tmp = t_1;
                                  	} else if ((y * x) <= 2e-47) {
                                  		tmp = (t * z) * 2.0;
                                  	} else {
                                  		tmp = t_1;
                                  	}
                                  	return tmp;
                                  }
                                  
                                  def code(x, y, z, t, a, b, c, i):
                                  	t_1 = (y * x) * 2.0
                                  	tmp = 0
                                  	if (y * x) <= -4e+62:
                                  		tmp = t_1
                                  	elif (y * x) <= 2e-47:
                                  		tmp = (t * z) * 2.0
                                  	else:
                                  		tmp = t_1
                                  	return tmp
                                  
                                  function code(x, y, z, t, a, b, c, i)
                                  	t_1 = Float64(Float64(y * x) * 2.0)
                                  	tmp = 0.0
                                  	if (Float64(y * x) <= -4e+62)
                                  		tmp = t_1;
                                  	elseif (Float64(y * x) <= 2e-47)
                                  		tmp = Float64(Float64(t * z) * 2.0);
                                  	else
                                  		tmp = t_1;
                                  	end
                                  	return tmp
                                  end
                                  
                                  function tmp_2 = code(x, y, z, t, a, b, c, i)
                                  	t_1 = (y * x) * 2.0;
                                  	tmp = 0.0;
                                  	if ((y * x) <= -4e+62)
                                  		tmp = t_1;
                                  	elseif ((y * x) <= 2e-47)
                                  		tmp = (t * z) * 2.0;
                                  	else
                                  		tmp = t_1;
                                  	end
                                  	tmp_2 = tmp;
                                  end
                                  
                                  code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(y * x), $MachinePrecision] * 2.0), $MachinePrecision]}, If[LessEqual[N[(y * x), $MachinePrecision], -4e+62], t$95$1, If[LessEqual[N[(y * x), $MachinePrecision], 2e-47], N[(N[(t * z), $MachinePrecision] * 2.0), $MachinePrecision], t$95$1]]]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \begin{array}{l}
                                  t_1 := \left(y \cdot x\right) \cdot 2\\
                                  \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\
                                  \;\;\;\;t\_1\\
                                  
                                  \mathbf{elif}\;y \cdot x \leq 2 \cdot 10^{-47}:\\
                                  \;\;\;\;\left(t \cdot z\right) \cdot 2\\
                                  
                                  \mathbf{else}:\\
                                  \;\;\;\;t\_1\\
                                  
                                  
                                  \end{array}
                                  \end{array}
                                  
                                  Derivation
                                  1. Split input into 2 regimes
                                  2. if (*.f64 x y) < -4.00000000000000014e62 or 1.9999999999999999e-47 < (*.f64 x y)

                                    1. Initial program 90.0%

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

                                      \[\leadsto \color{blue}{2 \cdot \left(x \cdot y\right)} \]
                                    4. Step-by-step derivation
                                      1. lower-*.f64N/A

                                        \[\leadsto \color{blue}{2 \cdot \left(x \cdot y\right)} \]
                                      2. *-commutativeN/A

                                        \[\leadsto 2 \cdot \color{blue}{\left(y \cdot x\right)} \]
                                      3. lower-*.f6454.8

                                        \[\leadsto 2 \cdot \color{blue}{\left(y \cdot x\right)} \]
                                    5. Applied rewrites54.8%

                                      \[\leadsto \color{blue}{2 \cdot \left(y \cdot x\right)} \]

                                    if -4.00000000000000014e62 < (*.f64 x y) < 1.9999999999999999e-47

                                    1. Initial program 94.5%

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

                                      \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                    4. Step-by-step derivation
                                      1. lower-*.f64N/A

                                        \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                      2. lower-*.f6441.8

                                        \[\leadsto 2 \cdot \color{blue}{\left(t \cdot z\right)} \]
                                    5. Applied rewrites41.8%

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

                                    \[\leadsto \begin{array}{l} \mathbf{if}\;y \cdot x \leq -4 \cdot 10^{+62}:\\ \;\;\;\;\left(y \cdot x\right) \cdot 2\\ \mathbf{elif}\;y \cdot x \leq 2 \cdot 10^{-47}:\\ \;\;\;\;\left(t \cdot z\right) \cdot 2\\ \mathbf{else}:\\ \;\;\;\;\left(y \cdot x\right) \cdot 2\\ \end{array} \]
                                  5. Add Preprocessing

                                  Alternative 16: 29.0% accurate, 3.6× speedup?

                                  \[\begin{array}{l} \\ \left(t \cdot z\right) \cdot 2 \end{array} \]
                                  (FPCore (x y z t a b c i) :precision binary64 (* (* t z) 2.0))
                                  double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                                  	return (t * z) * 2.0;
                                  }
                                  
                                  real(8) function code(x, y, z, t, a, b, c, i)
                                      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
                                      code = (t * z) * 2.0d0
                                  end function
                                  
                                  public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                                  	return (t * z) * 2.0;
                                  }
                                  
                                  def code(x, y, z, t, a, b, c, i):
                                  	return (t * z) * 2.0
                                  
                                  function code(x, y, z, t, a, b, c, i)
                                  	return Float64(Float64(t * z) * 2.0)
                                  end
                                  
                                  function tmp = code(x, y, z, t, a, b, c, i)
                                  	tmp = (t * z) * 2.0;
                                  end
                                  
                                  code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(N[(t * z), $MachinePrecision] * 2.0), $MachinePrecision]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \left(t \cdot z\right) \cdot 2
                                  \end{array}
                                  
                                  Derivation
                                  1. Initial program 92.4%

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

                                    \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                  4. Step-by-step derivation
                                    1. lower-*.f64N/A

                                      \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                    2. lower-*.f6429.4

                                      \[\leadsto 2 \cdot \color{blue}{\left(t \cdot z\right)} \]
                                  5. Applied rewrites29.4%

                                    \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                                  6. Final simplification29.4%

                                    \[\leadsto \left(t \cdot z\right) \cdot 2 \]
                                  7. Add Preprocessing

                                  Developer Target 1: 94.2% accurate, 1.0× speedup?

                                  \[\begin{array}{l} \\ 2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(a + b \cdot c\right) \cdot \left(c \cdot i\right)\right) \end{array} \]
                                  (FPCore (x y z t a b c i)
                                   :precision binary64
                                   (* 2.0 (- (+ (* x y) (* z t)) (* (+ a (* b c)) (* c i)))))
                                  double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                                  	return 2.0 * (((x * y) + (z * t)) - ((a + (b * c)) * (c * i)));
                                  }
                                  
                                  real(8) function code(x, y, z, t, a, b, c, i)
                                      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
                                      code = 2.0d0 * (((x * y) + (z * t)) - ((a + (b * c)) * (c * i)))
                                  end function
                                  
                                  public static double code(double x, double y, double z, double t, double a, double b, double c, double i) {
                                  	return 2.0 * (((x * y) + (z * t)) - ((a + (b * c)) * (c * i)));
                                  }
                                  
                                  def code(x, y, z, t, a, b, c, i):
                                  	return 2.0 * (((x * y) + (z * t)) - ((a + (b * c)) * (c * i)))
                                  
                                  function code(x, y, z, t, a, b, c, i)
                                  	return Float64(2.0 * Float64(Float64(Float64(x * y) + Float64(z * t)) - Float64(Float64(a + Float64(b * c)) * Float64(c * i))))
                                  end
                                  
                                  function tmp = code(x, y, z, t, a, b, c, i)
                                  	tmp = 2.0 * (((x * y) + (z * t)) - ((a + (b * c)) * (c * i)));
                                  end
                                  
                                  code[x_, y_, z_, t_, a_, b_, c_, i_] := N[(2.0 * N[(N[(N[(x * y), $MachinePrecision] + N[(z * t), $MachinePrecision]), $MachinePrecision] - N[(N[(a + N[(b * c), $MachinePrecision]), $MachinePrecision] * N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(a + b \cdot c\right) \cdot \left(c \cdot i\right)\right)
                                  \end{array}
                                  

                                  Reproduce

                                  ?
                                  herbie shell --seed 2024284 
                                  (FPCore (x y z t a b c i)
                                    :name "Diagrams.ThreeD.Shapes:frustum from diagrams-lib-1.3.0.3, A"
                                    :precision binary64
                                  
                                    :alt
                                    (! :herbie-platform default (* 2 (- (+ (* x y) (* z t)) (* (+ a (* b c)) (* c i)))))
                                  
                                    (* 2.0 (- (+ (* x y) (* z t)) (* (* (+ a (* b c)) c) i))))