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

Percentage Accurate: 89.9% → 96.1%
Time: 7.1s
Alternatives: 13
Speedup: 0.7×

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 13 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: 89.9% 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: 96.1% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \leq \infty:\\ \;\;\;\;2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), \left(-i\right) \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right) \cdot -2\right) \cdot i\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i)
 :precision binary64
 (if (<= (* 2.0 (- (+ (* x y) (* z t)) (* (* (+ a (* b c)) c) i))) INFINITY)
   (* 2.0 (fma (fma c b a) (* (- i) c) (fma t z (* y x))))
   (* (* (* (fma c b a) c) -2.0) i)))
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double tmp;
	if ((2.0 * (((x * y) + (z * t)) - (((a + (b * c)) * c) * i))) <= ((double) INFINITY)) {
		tmp = 2.0 * fma(fma(c, b, a), (-i * c), fma(t, z, (y * x)));
	} else {
		tmp = ((fma(c, b, a) * c) * -2.0) * i;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i)
	tmp = 0.0
	if (Float64(2.0 * Float64(Float64(Float64(x * y) + Float64(z * t)) - Float64(Float64(Float64(a + Float64(b * c)) * c) * i))) <= Inf)
		tmp = Float64(2.0 * fma(fma(c, b, a), Float64(Float64(-i) * c), fma(t, z, Float64(y * x))));
	else
		tmp = Float64(Float64(Float64(fma(c, b, a) * c) * -2.0) * i);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_] := If[LessEqual[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], Infinity], N[(2.0 * N[(N[(c * b + a), $MachinePrecision] * N[((-i) * c), $MachinePrecision] + N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(N[(c * b + a), $MachinePrecision] * c), $MachinePrecision] * -2.0), $MachinePrecision] * i), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \leq \infty:\\
\;\;\;\;2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), \left(-i\right) \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 #s(literal 2 binary64) (-.f64 (+.f64 (*.f64 x y) (*.f64 z t)) (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i))) < +inf.0

    1. Initial program 93.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. 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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
      3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -\color{blue}{i \cdot c}, x \cdot y + z \cdot t\right) \]
      17. lower-*.f6497.6

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

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

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

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

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

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

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

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

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

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

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

    1. Initial program 0.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. 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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
      3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
    5. Step-by-step derivation
      1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

        \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
      10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

      \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(\mathsf{fma}\left(b, c, a\right) \cdot i, -c, x \cdot y\right)\right)} \]
    7. 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)} \]
    8. Step-by-step derivation
      1. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 2: 41.4% accurate, 0.5× speedup?

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

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

\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{-90}:\\
\;\;\;\;2 \cdot \left(y \cdot x\right)\\

\mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+87}:\\
\;\;\;\;t \cdot \left(z + z\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -9.99999999999999977e101 or 1.9999999999999999e87 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

    1. Initial program 85.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 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-*.f6444.2

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

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

    if -9.99999999999999977e101 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 5.00000000000000019e-90

    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 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-*.f6461.8

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

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

    if 5.00000000000000019e-90 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.9999999999999999e87

    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 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-*.f6454.3

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

      \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
    6. Step-by-step derivation
      1. Applied rewrites54.3%

        \[\leadsto t \cdot \color{blue}{\left(z + z\right)} \]
    7. Recombined 3 regimes into one program.
    8. Add Preprocessing

    Alternative 3: 86.0% accurate, 0.5× speedup?

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

      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 0

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

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

          \[\leadsto 2 \cdot \left(x \cdot y + \color{blue}{\left(-1 \cdot c\right)} \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \]
        3. associate-*r*N/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) \]
        4. +-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)} \]
        5. mul-1-negN/A

          \[\leadsto 2 \cdot \left(\color{blue}{\left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right)} + x \cdot y\right) \]
        6. *-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) + x \cdot y\right) \]
        7. 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) + x \cdot y\right) \]
        8. *-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) + x \cdot y\right) \]
        9. 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)} + x \cdot y\right) \]
        10. lower-fma.f64N/A

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

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

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

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

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

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

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

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

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

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

      if -9.99999999999999977e101 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e201

      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. 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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
        3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto 2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \color{blue}{t \cdot z} + x \cdot y\right) \]
        22. lower-fma.f6499.9

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

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

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

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

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
      5. Step-by-step derivation
        1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

          \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
        10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 2 \cdot \mathsf{fma}\left(z, t, \mathsf{fma}\left(\color{blue}{b \cdot \left(c \cdot i\right)}, -c, x \cdot y\right)\right) \]
      8. Step-by-step derivation
        1. *-commutativeN/A

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

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

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

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

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

      if 1.00000000000000004e201 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

      1. Initial program 75.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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
        3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto 2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -\color{blue}{i \cdot c}, x \cdot y + z \cdot t\right) \]
        17. lower-*.f6489.6

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

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

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

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

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

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

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

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

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

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
      5. Step-by-step derivation
        1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

          \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
        10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

          \[\leadsto 2 \cdot \color{blue}{\left(\left(\left(-i\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot c\right) + t \cdot z\right) + x \cdot y\right)} \]
      6. Applied rewrites85.7%

        \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(\mathsf{fma}\left(b, c, a\right) \cdot i, -c, x \cdot y\right)\right)} \]
      7. 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)} \]
      8. Step-by-step derivation
        1. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      Alternative 4: 80.9% accurate, 0.6× speedup?

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

        1. Initial program 82.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. 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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
          3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
        5. Step-by-step derivation
          1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

            \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
          10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

          \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(\mathsf{fma}\left(b, c, a\right) \cdot i, -c, x \cdot y\right)\right)} \]
        7. 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)} \]
        8. Step-by-step derivation
          1. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

        if -1e153 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e201

        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-*.f6481.4

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

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

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

      Alternative 5: 82.7% accurate, 0.6× speedup?

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

        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 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)} \]
        4. Step-by-step derivation
          1. fp-cancel-sub-sign-invN/A

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

            \[\leadsto 2 \cdot \left(x \cdot y + \color{blue}{\left(-1 \cdot c\right)} \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right) \]
          3. associate-*r*N/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) \]
          4. +-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)} \]
          5. mul-1-negN/A

            \[\leadsto 2 \cdot \left(\color{blue}{\left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right)} + x \cdot y\right) \]
          6. *-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) + x \cdot y\right) \]
          7. 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) + x \cdot y\right) \]
          8. *-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) + x \cdot y\right) \]
          9. 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)} + x \cdot y\right) \]
          10. lower-fma.f64N/A

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

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

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

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

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

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

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

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

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

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

        if -2.00000000000000009e42 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e201

        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-*.f6485.0

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

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

        if 1.00000000000000004e201 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

        1. Initial program 75.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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
          3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto 2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -\color{blue}{i \cdot c}, x \cdot y + z \cdot t\right) \]
          17. lower-*.f6489.6

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

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

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

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

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

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

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

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

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

          \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
        5. Step-by-step derivation
          1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

            \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
          10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

            \[\leadsto 2 \cdot \color{blue}{\left(\left(\left(-i\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot c\right) + t \cdot z\right) + x \cdot y\right)} \]
        6. Applied rewrites85.7%

          \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(\mathsf{fma}\left(b, c, a\right) \cdot i, -c, x \cdot y\right)\right)} \]
        7. 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)} \]
        8. Step-by-step derivation
          1. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

            \[\leadsto \mathsf{fma}\left(c, b, a\right) \cdot \color{blue}{\left(\left(-2 \cdot c\right) \cdot i\right)} \]
        11. Recombined 3 regimes into one program.
        12. Final simplification87.0%

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

        Alternative 6: 82.5% accurate, 0.6× speedup?

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

          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 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. fp-cancel-sub-sign-invN/A

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

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

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

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

              \[\leadsto 2 \cdot \left(\color{blue}{\left(\mathsf{neg}\left(c \cdot \left(i \cdot \left(a + b \cdot c\right)\right)\right)\right)} + t \cdot z\right) \]
            6. *-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) \]
            7. 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) \]
            8. *-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) \]
            9. 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) \]
            10. lower-fma.f64N/A

              \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{neg}\left(i\right), c \cdot \left(a + b \cdot c\right), t \cdot z\right)} \]
            11. 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) \]
            12. *-commutativeN/A

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

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

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

              \[\leadsto 2 \cdot \mathsf{fma}\left(-i, \left(\color{blue}{c \cdot b} + a\right) \cdot c, t \cdot z\right) \]
            16. 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) \]
            17. lower-*.f6484.8

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

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

          if -9.99999999999999977e101 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e201

          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-*.f6483.8

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

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

          if 1.00000000000000004e201 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

          1. Initial program 75.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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
            3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto 2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -\color{blue}{i \cdot c}, x \cdot y + z \cdot t\right) \]
            17. lower-*.f6489.6

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

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

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

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

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

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

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

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

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

            \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
          5. Step-by-step derivation
            1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

              \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
            10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

              \[\leadsto 2 \cdot \color{blue}{\left(\left(\left(-i\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot c\right) + t \cdot z\right) + x \cdot y\right)} \]
          6. Applied rewrites85.7%

            \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(\mathsf{fma}\left(b, c, a\right) \cdot i, -c, x \cdot y\right)\right)} \]
          7. 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)} \]
          8. Step-by-step derivation
            1. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          Alternative 7: 81.6% accurate, 0.6× speedup?

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

            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. 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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
              3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto 2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -\color{blue}{i \cdot c}, x \cdot y + z \cdot t\right) \]
              17. lower-*.f6492.7

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

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

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

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

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

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

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

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

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

              \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
            5. Step-by-step derivation
              1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

                \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
              10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

                \[\leadsto 2 \cdot \color{blue}{\left(\left(\left(-i\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot c\right) + t \cdot z\right) + x \cdot y\right)} \]
            6. Applied rewrites92.7%

              \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(\mathsf{fma}\left(b, c, a\right) \cdot i, -c, x \cdot y\right)\right)} \]
            7. 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)} \]
            8. Step-by-step derivation
              1. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

            if -1e153 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e201

            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-*.f6481.4

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

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

            if 1.00000000000000004e201 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

            1. Initial program 75.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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
              3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto 2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -\color{blue}{i \cdot c}, x \cdot y + z \cdot t\right) \]
              17. lower-*.f6489.6

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

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

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

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

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

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

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

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

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

              \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
            5. Step-by-step derivation
              1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

                \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
              10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

                \[\leadsto 2 \cdot \color{blue}{\left(\left(\left(-i\right) \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot c\right) + t \cdot z\right) + x \cdot y\right)} \]
            6. Applied rewrites85.7%

              \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(\mathsf{fma}\left(b, c, a\right) \cdot i, -c, x \cdot y\right)\right)} \]
            7. 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)} \]
            8. Step-by-step derivation
              1. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

            Alternative 8: 72.6% accurate, 0.6× speedup?

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

              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 b around inf

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

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

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

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

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

                  \[\leadsto \left(\color{blue}{\left({c}^{2} \cdot i\right)} \cdot b\right) \cdot -2 \]
                6. unpow2N/A

                  \[\leadsto \left(\left(\color{blue}{\left(c \cdot c\right)} \cdot i\right) \cdot b\right) \cdot -2 \]
                7. lower-*.f6464.4

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

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

              if -1.00000000000000004e154 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e201

              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-*.f6480.9

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

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

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

            Alternative 9: 72.0% accurate, 0.6× speedup?

            \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\\ \mathbf{if}\;t\_1 \leq -5 \cdot 10^{+199} \lor \neg \left(t\_1 \leq 10^{+201}\right):\\ \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot b\right) \cdot -2\right) \cdot i\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \mathsf{fma}\left(t, z, y \cdot x\right)\\ \end{array} \end{array} \]
            (FPCore (x y z t a b c i)
             :precision binary64
             (let* ((t_1 (* (* (+ a (* b c)) c) i)))
               (if (or (<= t_1 -5e+199) (not (<= t_1 1e+201)))
                 (* (* (* (* c c) b) -2.0) i)
                 (* 2.0 (fma t z (* y x))))))
            double code(double x, double y, double z, double t, double a, double b, double c, double i) {
            	double t_1 = ((a + (b * c)) * c) * i;
            	double tmp;
            	if ((t_1 <= -5e+199) || !(t_1 <= 1e+201)) {
            		tmp = (((c * c) * b) * -2.0) * i;
            	} else {
            		tmp = 2.0 * fma(t, z, (y * x));
            	}
            	return tmp;
            }
            
            function code(x, y, z, t, a, b, c, i)
            	t_1 = Float64(Float64(Float64(a + Float64(b * c)) * c) * i)
            	tmp = 0.0
            	if ((t_1 <= -5e+199) || !(t_1 <= 1e+201))
            		tmp = Float64(Float64(Float64(Float64(c * c) * b) * -2.0) * i);
            	else
            		tmp = Float64(2.0 * fma(t, z, Float64(y * x)));
            	end
            	return tmp
            end
            
            code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(N[(a + N[(b * c), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -5e+199], N[Not[LessEqual[t$95$1, 1e+201]], $MachinePrecision]], N[(N[(N[(N[(c * c), $MachinePrecision] * b), $MachinePrecision] * -2.0), $MachinePrecision] * i), $MachinePrecision], N[(2.0 * N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
            
            \begin{array}{l}
            
            \\
            \begin{array}{l}
            t_1 := \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\\
            \mathbf{if}\;t\_1 \leq -5 \cdot 10^{+199} \lor \neg \left(t\_1 \leq 10^{+201}\right):\\
            \;\;\;\;\left(\left(\left(c \cdot c\right) \cdot b\right) \cdot -2\right) \cdot i\\
            
            \mathbf{else}:\\
            \;\;\;\;2 \cdot \mathsf{fma}\left(t, z, y \cdot x\right)\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 2 regimes
            2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -4.9999999999999998e199 or 1.00000000000000004e201 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

              1. Initial program 81.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(\left(x \cdot y + z \cdot t\right) - \color{blue}{\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i}\right) \]
                3. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto 2 \cdot \mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -\color{blue}{i \cdot c}, x \cdot y + z \cdot t\right) \]
                17. lower-*.f6490.6

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

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

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

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

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

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

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

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

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

                \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(c, b, a\right), -i \cdot c, \mathsf{fma}\left(t, z, y \cdot x\right)\right)} \]
              5. Step-by-step derivation
                1. lift-fma.f64N/A

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

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

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

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

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

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

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

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

                  \[\leadsto 2 \cdot \left(\mathsf{fma}\left(t, z, y \cdot x\right) - i \cdot \color{blue}{\left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)}\right) \]
                10. fp-cancel-sub-sign-invN/A

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

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

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

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

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

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

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

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

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

                \[\leadsto 2 \cdot \color{blue}{\mathsf{fma}\left(z, t, \mathsf{fma}\left(\mathsf{fma}\left(b, c, a\right) \cdot i, -c, x \cdot y\right)\right)} \]
              7. 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)} \]
              8. Step-by-step derivation
                1. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                if -4.9999999999999998e199 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000004e201

                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-*.f6479.3

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

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

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

              Alternative 10: 63.5% accurate, 0.6× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\\ \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+153} \lor \neg \left(t\_1 \leq 5 \cdot 10^{+212}\right):\\ \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \mathsf{fma}\left(t, z, y \cdot x\right)\\ \end{array} \end{array} \]
              (FPCore (x y z t a b c i)
               :precision binary64
               (let* ((t_1 (* (* (+ a (* b c)) c) i)))
                 (if (or (<= t_1 -1e+153) (not (<= t_1 5e+212)))
                   (* (* (* i c) a) -2.0)
                   (* 2.0 (fma t z (* y x))))))
              double code(double x, double y, double z, double t, double a, double b, double c, double i) {
              	double t_1 = ((a + (b * c)) * c) * i;
              	double tmp;
              	if ((t_1 <= -1e+153) || !(t_1 <= 5e+212)) {
              		tmp = ((i * c) * a) * -2.0;
              	} else {
              		tmp = 2.0 * fma(t, z, (y * x));
              	}
              	return tmp;
              }
              
              function code(x, y, z, t, a, b, c, i)
              	t_1 = Float64(Float64(Float64(a + Float64(b * c)) * c) * i)
              	tmp = 0.0
              	if ((t_1 <= -1e+153) || !(t_1 <= 5e+212))
              		tmp = Float64(Float64(Float64(i * c) * a) * -2.0);
              	else
              		tmp = Float64(2.0 * fma(t, z, Float64(y * x)));
              	end
              	return tmp
              end
              
              code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(N[(N[(a + N[(b * c), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -1e+153], N[Not[LessEqual[t$95$1, 5e+212]], $MachinePrecision]], N[(N[(N[(i * c), $MachinePrecision] * a), $MachinePrecision] * -2.0), $MachinePrecision], N[(2.0 * N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_1 := \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\\
              \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+153} \lor \neg \left(t\_1 \leq 5 \cdot 10^{+212}\right):\\
              \;\;\;\;\left(\left(i \cdot c\right) \cdot a\right) \cdot -2\\
              
              \mathbf{else}:\\
              \;\;\;\;2 \cdot \mathsf{fma}\left(t, z, y \cdot x\right)\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < -1e153 or 4.99999999999999992e212 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

                1. Initial program 82.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 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-*.f6446.9

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

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

                if -1e153 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 4.99999999999999992e212

                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-*.f6480.3

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

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

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

              Alternative 11: 93.1% accurate, 0.7× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i \leq 10^{+306}:\\ \;\;\;\;2 \cdot \mathsf{fma}\left(z, t, y \cdot x - i \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)\right)\\ \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
               (if (<= (* (* (+ a (* b c)) c) i) 1e+306)
                 (* 2.0 (fma z t (- (* y x) (* i (* (fma c b a) c)))))
                 (* (* -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 tmp;
              	if ((((a + (b * c)) * c) * i) <= 1e+306) {
              		tmp = 2.0 * fma(z, t, ((y * x) - (i * (fma(c, b, a) * c))));
              	} else {
              		tmp = (-2.0 * (fma(c, b, a) * i)) * c;
              	}
              	return tmp;
              }
              
              function code(x, y, z, t, a, b, c, i)
              	tmp = 0.0
              	if (Float64(Float64(Float64(a + Float64(b * c)) * c) * i) <= 1e+306)
              		tmp = Float64(2.0 * fma(z, t, Float64(Float64(y * x) - Float64(i * Float64(fma(c, b, a) * c)))));
              	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_] := If[LessEqual[N[(N[(N[(a + N[(b * c), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision] * i), $MachinePrecision], 1e+306], N[(2.0 * N[(z * t + N[(N[(y * x), $MachinePrecision] - N[(i * N[(N[(c * b + a), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(-2.0 * N[(N[(c * b + a), $MachinePrecision] * i), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              \mathbf{if}\;\left(\left(a + b \cdot c\right) \cdot c\right) \cdot i \leq 10^{+306}:\\
              \;\;\;\;2 \cdot \mathsf{fma}\left(z, t, y \cdot x - i \cdot \left(\mathsf{fma}\left(c, b, a\right) \cdot c\right)\right)\\
              
              \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 2 regimes
              2. if (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i) < 1.00000000000000002e306

                1. Initial program 97.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. 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. lower--.f6497.6

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

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

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

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

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

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

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

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

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

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

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

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

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

                if 1.00000000000000002e306 < (*.f64 (*.f64 (+.f64 a (*.f64 b c)) c) i)

                1. Initial program 68.9%

                  \[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.f6490.8

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

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

              Alternative 12: 44.4% accurate, 1.2× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \cdot t \leq -5 \cdot 10^{+88} \lor \neg \left(z \cdot t \leq 2 \cdot 10^{+142}\right):\\ \;\;\;\;t \cdot \left(z + z\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(y \cdot x\right)\\ \end{array} \end{array} \]
              (FPCore (x y z t a b c i)
               :precision binary64
               (if (or (<= (* z t) -5e+88) (not (<= (* z t) 2e+142)))
                 (* t (+ z z))
                 (* 2.0 (* y x))))
              double code(double x, double y, double z, double t, double a, double b, double c, double i) {
              	double tmp;
              	if (((z * t) <= -5e+88) || !((z * t) <= 2e+142)) {
              		tmp = t * (z + z);
              	} else {
              		tmp = 2.0 * (y * x);
              	}
              	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) :: tmp
                  if (((z * t) <= (-5d+88)) .or. (.not. ((z * t) <= 2d+142))) then
                      tmp = t * (z + z)
                  else
                      tmp = 2.0d0 * (y * x)
                  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 tmp;
              	if (((z * t) <= -5e+88) || !((z * t) <= 2e+142)) {
              		tmp = t * (z + z);
              	} else {
              		tmp = 2.0 * (y * x);
              	}
              	return tmp;
              }
              
              def code(x, y, z, t, a, b, c, i):
              	tmp = 0
              	if ((z * t) <= -5e+88) or not ((z * t) <= 2e+142):
              		tmp = t * (z + z)
              	else:
              		tmp = 2.0 * (y * x)
              	return tmp
              
              function code(x, y, z, t, a, b, c, i)
              	tmp = 0.0
              	if ((Float64(z * t) <= -5e+88) || !(Float64(z * t) <= 2e+142))
              		tmp = Float64(t * Float64(z + z));
              	else
              		tmp = Float64(2.0 * Float64(y * x));
              	end
              	return tmp
              end
              
              function tmp_2 = code(x, y, z, t, a, b, c, i)
              	tmp = 0.0;
              	if (((z * t) <= -5e+88) || ~(((z * t) <= 2e+142)))
              		tmp = t * (z + z);
              	else
              		tmp = 2.0 * (y * x);
              	end
              	tmp_2 = tmp;
              end
              
              code[x_, y_, z_, t_, a_, b_, c_, i_] := If[Or[LessEqual[N[(z * t), $MachinePrecision], -5e+88], N[Not[LessEqual[N[(z * t), $MachinePrecision], 2e+142]], $MachinePrecision]], N[(t * N[(z + z), $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(y * x), $MachinePrecision]), $MachinePrecision]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              \mathbf{if}\;z \cdot t \leq -5 \cdot 10^{+88} \lor \neg \left(z \cdot t \leq 2 \cdot 10^{+142}\right):\\
              \;\;\;\;t \cdot \left(z + z\right)\\
              
              \mathbf{else}:\\
              \;\;\;\;2 \cdot \left(y \cdot x\right)\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if (*.f64 z t) < -4.99999999999999997e88 or 2.0000000000000001e142 < (*.f64 z t)

                1. Initial program 90.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 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-*.f6458.7

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

                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                6. Step-by-step derivation
                  1. Applied rewrites58.7%

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

                  if -4.99999999999999997e88 < (*.f64 z t) < 2.0000000000000001e142

                  1. Initial program 91.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 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-*.f6439.7

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

                    \[\leadsto \color{blue}{2 \cdot \left(y \cdot x\right)} \]
                7. Recombined 2 regimes into one program.
                8. Final simplification45.9%

                  \[\leadsto \begin{array}{l} \mathbf{if}\;z \cdot t \leq -5 \cdot 10^{+88} \lor \neg \left(z \cdot t \leq 2 \cdot 10^{+142}\right):\\ \;\;\;\;t \cdot \left(z + z\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(y \cdot x\right)\\ \end{array} \]
                9. Add Preprocessing

                Alternative 13: 29.8% accurate, 4.4× speedup?

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

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

                  \[\leadsto \color{blue}{2 \cdot \left(t \cdot z\right)} \]
                6. Step-by-step derivation
                  1. Applied rewrites24.0%

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

                  Developer Target 1: 94.1% 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 2024332 
                  (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))))