?

Average Error: 6.2 → 1.3
Time: 34.4s
Precision: binary64
Cost: 15048

?

\[2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right) \]
\[\begin{array}{l} t_1 := \mathsf{fma}\left(x, y, z \cdot t\right)\\ t_2 := a + b \cdot c\\ t_3 := c \cdot t_2\\ \mathbf{if}\;t_3 \leq -4 \cdot 10^{+175}:\\ \;\;\;\;2 \cdot \left(t_1 - t_2 \cdot \left(c \cdot i\right)\right)\\ \mathbf{elif}\;t_3 \leq 10^{+276}:\\ \;\;\;\;2 \cdot \left(\left(z \cdot t + x \cdot y\right) - t_3 \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \frac{1}{\frac{1}{t_1 - c \cdot \left(i \cdot \mathsf{fma}\left(b, c, a\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))))
(FPCore (x y z t a b c i)
 :precision binary64
 (let* ((t_1 (fma x y (* z t))) (t_2 (+ a (* b c))) (t_3 (* c t_2)))
   (if (<= t_3 -4e+175)
     (* 2.0 (- t_1 (* t_2 (* c i))))
     (if (<= t_3 1e+276)
       (* 2.0 (- (+ (* z t) (* x y)) (* t_3 i)))
       (* 2.0 (/ 1.0 (/ 1.0 (- t_1 (* c (* i (fma b c a)))))))))))
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));
}
double code(double x, double y, double z, double t, double a, double b, double c, double i) {
	double t_1 = fma(x, y, (z * t));
	double t_2 = a + (b * c);
	double t_3 = c * t_2;
	double tmp;
	if (t_3 <= -4e+175) {
		tmp = 2.0 * (t_1 - (t_2 * (c * i)));
	} else if (t_3 <= 1e+276) {
		tmp = 2.0 * (((z * t) + (x * y)) - (t_3 * i));
	} else {
		tmp = 2.0 * (1.0 / (1.0 / (t_1 - (c * (i * fma(b, c, a))))));
	}
	return tmp;
}
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 code(x, y, z, t, a, b, c, i)
	t_1 = fma(x, y, Float64(z * t))
	t_2 = Float64(a + Float64(b * c))
	t_3 = Float64(c * t_2)
	tmp = 0.0
	if (t_3 <= -4e+175)
		tmp = Float64(2.0 * Float64(t_1 - Float64(t_2 * Float64(c * i))));
	elseif (t_3 <= 1e+276)
		tmp = Float64(2.0 * Float64(Float64(Float64(z * t) + Float64(x * y)) - Float64(t_3 * i)));
	else
		tmp = Float64(2.0 * Float64(1.0 / Float64(1.0 / Float64(t_1 - Float64(c * Float64(i * fma(b, c, a)))))));
	end
	return tmp
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]
code[x_, y_, z_, t_, a_, b_, c_, i_] := Block[{t$95$1 = N[(x * y + N[(z * t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(a + N[(b * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(c * t$95$2), $MachinePrecision]}, If[LessEqual[t$95$3, -4e+175], N[(2.0 * N[(t$95$1 - N[(t$95$2 * N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, 1e+276], N[(2.0 * N[(N[(N[(z * t), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision] - N[(t$95$3 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(1.0 / N[(1.0 / N[(t$95$1 - N[(c * N[(i * N[(b * c + a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(\left(a + b \cdot c\right) \cdot c\right) \cdot i\right)
\begin{array}{l}
t_1 := \mathsf{fma}\left(x, y, z \cdot t\right)\\
t_2 := a + b \cdot c\\
t_3 := c \cdot t_2\\
\mathbf{if}\;t_3 \leq -4 \cdot 10^{+175}:\\
\;\;\;\;2 \cdot \left(t_1 - t_2 \cdot \left(c \cdot i\right)\right)\\

\mathbf{elif}\;t_3 \leq 10^{+276}:\\
\;\;\;\;2 \cdot \left(\left(z \cdot t + x \cdot y\right) - t_3 \cdot i\right)\\

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


\end{array}

Error?

Target

Original6.2
Target1.8
Herbie1.3
\[2 \cdot \left(\left(x \cdot y + z \cdot t\right) - \left(a + b \cdot c\right) \cdot \left(c \cdot i\right)\right) \]

Derivation?

  1. Split input into 3 regimes
  2. if (*.f64 (+.f64 a (*.f64 b c)) c) < -3.9999999999999997e175

    1. Initial program 27.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. Simplified4.4

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

      [Start]27.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) \]

      associate-*l* [=>]4.4

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

      fma-def [=>]4.4

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

    if -3.9999999999999997e175 < (*.f64 (+.f64 a (*.f64 b c)) c) < 1.0000000000000001e276

    1. Initial program 0.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) \]

    if 1.0000000000000001e276 < (*.f64 (+.f64 a (*.f64 b c)) c)

    1. Initial program 53.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. Simplified8.3

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

      [Start]53.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) \]

      *-commutative [=>]53.3

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

      associate-*l* [=>]8.3

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

      cancel-sign-sub-inv [=>]8.3

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

      cancel-sign-sub [<=]8.3

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

      fma-def [=>]8.3

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

      remove-double-neg [=>]8.3

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

      +-commutative [=>]8.3

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

      fma-def [=>]8.3

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;c \cdot \left(a + b \cdot c\right) \leq -4 \cdot 10^{+175}:\\ \;\;\;\;2 \cdot \left(\mathsf{fma}\left(x, y, z \cdot t\right) - \left(a + b \cdot c\right) \cdot \left(c \cdot i\right)\right)\\ \mathbf{elif}\;c \cdot \left(a + b \cdot c\right) \leq 10^{+276}:\\ \;\;\;\;2 \cdot \left(\left(z \cdot t + x \cdot y\right) - \left(c \cdot \left(a + b \cdot c\right)\right) \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \frac{1}{\frac{1}{\mathsf{fma}\left(x, y, z \cdot t\right) - c \cdot \left(i \cdot \mathsf{fma}\left(b, c, a\right)\right)}}\\ \end{array} \]

Alternatives

Alternative 1
Error1.3
Cost14792
\[\begin{array}{l} t_1 := \mathsf{fma}\left(x, y, z \cdot t\right)\\ t_2 := a + b \cdot c\\ t_3 := c \cdot t_2\\ \mathbf{if}\;t_3 \leq -4 \cdot 10^{+175}:\\ \;\;\;\;2 \cdot \left(t_1 - t_2 \cdot \left(c \cdot i\right)\right)\\ \mathbf{elif}\;t_3 \leq 10^{+227}:\\ \;\;\;\;2 \cdot \left(\left(z \cdot t + x \cdot y\right) - t_3 \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(t_1 - c \cdot \left(i \cdot \mathsf{fma}\left(b, c, a\right)\right)\right)\\ \end{array} \]
Alternative 2
Error1.3
Cost8521
\[\begin{array}{l} t_1 := a + b \cdot c\\ t_2 := c \cdot t_1\\ \mathbf{if}\;t_2 \leq -4 \cdot 10^{+175} \lor \neg \left(t_2 \leq 10^{+227}\right):\\ \;\;\;\;2 \cdot \left(\mathsf{fma}\left(x, y, z \cdot t\right) - t_1 \cdot \left(c \cdot i\right)\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(\left(z \cdot t + x \cdot y\right) - t_2 \cdot i\right)\\ \end{array} \]
Alternative 3
Error2.0
Cost7876
\[\begin{array}{l} t_1 := a + b \cdot c\\ t_2 := c \cdot t_1\\ \mathbf{if}\;t_2 \leq -\infty:\\ \;\;\;\;2 \cdot \mathsf{fma}\left(y, x, z \cdot t - c \cdot \left(c \cdot \left(b \cdot i\right)\right)\right)\\ \mathbf{elif}\;t_2 \leq 5 \cdot 10^{+299}:\\ \;\;\;\;2 \cdot \left(\left(z \cdot t + x \cdot y\right) - t_2 \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(x \cdot y - c \cdot \left(t_1 \cdot i\right)\right)\\ \end{array} \]
Alternative 4
Error2.0
Cost2248
\[\begin{array}{l} t_1 := a + b \cdot c\\ t_2 := c \cdot \left(t_1 \cdot i\right)\\ t_3 := c \cdot t_1\\ \mathbf{if}\;t_3 \leq -5 \cdot 10^{+281}:\\ \;\;\;\;2 \cdot \left(z \cdot t - t_2\right)\\ \mathbf{elif}\;t_3 \leq 5 \cdot 10^{+299}:\\ \;\;\;\;2 \cdot \left(\left(z \cdot t + x \cdot y\right) - t_3 \cdot i\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(x \cdot y - t_2\right)\\ \end{array} \]
Alternative 5
Error21.4
Cost1892
\[\begin{array}{l} t_1 := 2 \cdot \left(x \cdot y - a \cdot \left(c \cdot i\right)\right)\\ t_2 := 2 \cdot \left(z \cdot t + x \cdot y\right)\\ t_3 := 2 \cdot \left(x \cdot y - c \cdot \left(b \cdot \left(c \cdot i\right)\right)\right)\\ \mathbf{if}\;z \leq -1.8 \cdot 10^{+36}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -5 \cdot 10^{+19}:\\ \;\;\;\;\left(i \cdot \left(a \cdot c\right)\right) \cdot -2\\ \mathbf{elif}\;z \leq -3.4 \cdot 10^{-51}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -3.5 \cdot 10^{-164}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -5.4 \cdot 10^{-173}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -2.85 \cdot 10^{-257}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;z \leq -1.45 \cdot 10^{-266}:\\ \;\;\;\;a \cdot \left(i \cdot \left(c \cdot -2\right)\right)\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{-262}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;z \leq 1.7 \cdot 10^{-167}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 6
Error10.5
Cost1869
\[\begin{array}{l} t_1 := z \cdot t + x \cdot y\\ \mathbf{if}\;x \cdot y \leq -200000:\\ \;\;\;\;2 \cdot \left(t_1 - i \cdot \left(c \cdot \left(b \cdot c\right)\right)\right)\\ \mathbf{elif}\;x \cdot y \leq -4 \cdot 10^{-314} \lor \neg \left(x \cdot y \leq 4 \cdot 10^{-27}\right):\\ \;\;\;\;2 \cdot \left(t_1 - \frac{c \cdot i}{\frac{1}{a}}\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(z \cdot t - c \cdot \left(\left(a + b \cdot c\right) \cdot i\right)\right)\\ \end{array} \]
Alternative 7
Error10.5
Cost1868
\[\begin{array}{l} t_1 := z \cdot t + x \cdot y\\ \mathbf{if}\;x \cdot y \leq -200000:\\ \;\;\;\;2 \cdot \left(t_1 - i \cdot \left(c \cdot \left(b \cdot c\right)\right)\right)\\ \mathbf{elif}\;x \cdot y \leq -4 \cdot 10^{-314}:\\ \;\;\;\;2 \cdot \left(t_1 - \frac{c \cdot i}{\frac{1}{a}}\right)\\ \mathbf{elif}\;x \cdot y \leq 4 \cdot 10^{-27}:\\ \;\;\;\;2 \cdot \left(z \cdot t - c \cdot \left(\left(a + b \cdot c\right) \cdot i\right)\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(t_1 + a \cdot \frac{c}{\frac{-1}{i}}\right)\\ \end{array} \]
Alternative 8
Error18.1
Cost1753
\[\begin{array}{l} t_1 := c \cdot \left(\left(a + b \cdot c\right) \cdot i\right)\\ t_2 := 2 \cdot \left(z \cdot t + x \cdot y\right)\\ \mathbf{if}\;z \leq -2.75 \cdot 10^{+69}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -3.1 \cdot 10^{+19}:\\ \;\;\;\;2 \cdot \left(z \cdot t - t_1\right)\\ \mathbf{elif}\;z \leq -1.9 \cdot 10^{-50}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -3.6 \cdot 10^{-165}:\\ \;\;\;\;2 \cdot \left(x \cdot y - a \cdot \left(c \cdot i\right)\right)\\ \mathbf{elif}\;z \leq -5.1 \cdot 10^{-173} \lor \neg \left(z \leq 1.75 \cdot 10^{-166}\right):\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(x \cdot y - t_1\right)\\ \end{array} \]
Alternative 9
Error21.0
Cost1497
\[\begin{array}{l} t_1 := 2 \cdot \left(z \cdot t + x \cdot y\right)\\ t_2 := \left(c \cdot \left(\left(a + b \cdot c\right) \cdot i\right)\right) \cdot -2\\ \mathbf{if}\;c \leq -6 \cdot 10^{+109}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq 1.05 \cdot 10^{-110}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq 1.75 \cdot 10^{-62}:\\ \;\;\;\;2 \cdot \left(z \cdot t - c \cdot \left(a \cdot i\right)\right)\\ \mathbf{elif}\;c \leq 7.4 \cdot 10^{-23} \lor \neg \left(c \leq 9.5 \cdot 10^{+149}\right) \land c \leq 1.6 \cdot 10^{+181}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 10
Error16.3
Cost1489
\[\begin{array}{l} t_1 := 2 \cdot \left(z \cdot t - c \cdot \left(\left(a + b \cdot c\right) \cdot i\right)\right)\\ \mathbf{if}\;c \leq -4 \cdot 10^{+81}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq -6.6 \cdot 10^{+72}:\\ \;\;\;\;2 \cdot \left(x \cdot y - c \cdot \left(a \cdot i\right)\right)\\ \mathbf{elif}\;c \leq -1.15 \cdot 10^{-53} \lor \neg \left(c \leq 1.05 \cdot 10^{-110}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(z \cdot t + x \cdot y\right)\\ \end{array} \]
Alternative 11
Error8.6
Cost1356
\[\begin{array}{l} t_1 := c \cdot \left(\left(a + b \cdot c\right) \cdot i\right)\\ t_2 := z \cdot t + x \cdot y\\ \mathbf{if}\;c \leq -9.5 \cdot 10^{+117}:\\ \;\;\;\;2 \cdot \left(x \cdot y - t_1\right)\\ \mathbf{elif}\;c \leq -1.8 \cdot 10^{-88}:\\ \;\;\;\;2 \cdot \left(t_2 - \left(b \cdot i\right) \cdot \left(c \cdot c\right)\right)\\ \mathbf{elif}\;c \leq 1.02 \cdot 10^{-25}:\\ \;\;\;\;2 \cdot \left(t_2 - i \cdot \left(a \cdot c\right)\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(z \cdot t - t_1\right)\\ \end{array} \]
Alternative 12
Error37.5
Cost1236
\[\begin{array}{l} t_1 := 2 \cdot \left(z \cdot t\right)\\ t_2 := 2 \cdot \left(x \cdot y\right)\\ \mathbf{if}\;x \leq -2.6 \cdot 10^{-16}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -2.45 \cdot 10^{-90}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -4.1 \cdot 10^{-196}:\\ \;\;\;\;a \cdot \left(i \cdot \left(c \cdot -2\right)\right)\\ \mathbf{elif}\;x \leq -7.4 \cdot 10^{-295}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq 6.2 \cdot 10^{-273}:\\ \;\;\;\;\left(c \cdot \left(c \cdot \left(b \cdot i\right)\right)\right) \cdot -2\\ \mathbf{elif}\;x \leq 1.25 \cdot 10^{-122}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 13
Error22.9
Cost1236
\[\begin{array}{l} t_1 := 2 \cdot \left(z \cdot t - c \cdot \left(a \cdot i\right)\right)\\ t_2 := 2 \cdot \left(z \cdot t + x \cdot y\right)\\ \mathbf{if}\;c \leq 1.28 \cdot 10^{-113}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq 2.25 \cdot 10^{-62}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq 4.5 \cdot 10^{-26}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq 1.25 \cdot 10^{+148}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq 6.2 \cdot 10^{+180}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;-2 \cdot \left(c \cdot \left(i \cdot \left(b \cdot c\right)\right)\right)\\ \end{array} \]
Alternative 14
Error20.6
Cost1233
\[\begin{array}{l} t_1 := 2 \cdot \left(z \cdot t + x \cdot y\right)\\ \mathbf{if}\;z \leq -1.9 \cdot 10^{+36}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -5 \cdot 10^{+19}:\\ \;\;\;\;\left(i \cdot \left(a \cdot c\right)\right) \cdot -2\\ \mathbf{elif}\;z \leq -8.4 \cdot 10^{-55} \lor \neg \left(z \leq 2.4 \cdot 10^{-166}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(x \cdot y - a \cdot \left(c \cdot i\right)\right)\\ \end{array} \]
Alternative 15
Error9.0
Cost1224
\[\begin{array}{l} t_1 := c \cdot \left(\left(a + b \cdot c\right) \cdot i\right)\\ \mathbf{if}\;c \leq -3.9 \cdot 10^{+126}:\\ \;\;\;\;2 \cdot \left(x \cdot y - t_1\right)\\ \mathbf{elif}\;c \leq 8.5 \cdot 10^{-26}:\\ \;\;\;\;2 \cdot \left(\left(z \cdot t + x \cdot y\right) - i \cdot \left(a \cdot c\right)\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(z \cdot t - t_1\right)\\ \end{array} \]
Alternative 16
Error21.5
Cost972
\[\begin{array}{l} t_1 := 2 \cdot \left(z \cdot t + x \cdot y\right)\\ \mathbf{if}\;c \leq 9.5 \cdot 10^{+118}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq 1.16 \cdot 10^{+152}:\\ \;\;\;\;\left(c \cdot \left(c \cdot \left(b \cdot i\right)\right)\right) \cdot -2\\ \mathbf{elif}\;c \leq 2.15 \cdot 10^{+184}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;-2 \cdot \left(c \cdot \left(i \cdot \left(b \cdot c\right)\right)\right)\\ \end{array} \]
Alternative 17
Error36.6
Cost848
\[\begin{array}{l} t_1 := 2 \cdot \left(z \cdot t\right)\\ t_2 := 2 \cdot \left(x \cdot y\right)\\ \mathbf{if}\;x \leq -4.3 \cdot 10^{-17}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -1.95 \cdot 10^{-90}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -2.25 \cdot 10^{-197}:\\ \;\;\;\;a \cdot \left(i \cdot \left(c \cdot -2\right)\right)\\ \mathbf{elif}\;x \leq 1.95 \cdot 10^{-123}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 18
Error22.7
Cost841
\[\begin{array}{l} \mathbf{if}\;x \leq -2.8 \cdot 10^{-305} \lor \neg \left(x \leq 4.2 \cdot 10^{-273}\right):\\ \;\;\;\;2 \cdot \left(z \cdot t + x \cdot y\right)\\ \mathbf{else}:\\ \;\;\;\;\left(c \cdot \left(b \cdot \left(c \cdot i\right)\right)\right) \cdot -2\\ \end{array} \]
Alternative 19
Error22.1
Cost708
\[\begin{array}{l} \mathbf{if}\;i \leq -1.8 \cdot 10^{+225}:\\ \;\;\;\;a \cdot \left(i \cdot \left(c \cdot -2\right)\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(z \cdot t + x \cdot y\right)\\ \end{array} \]
Alternative 20
Error35.5
Cost585
\[\begin{array}{l} \mathbf{if}\;x \leq -2.5 \cdot 10^{-17} \lor \neg \left(x \leq 3 \cdot 10^{-121}\right):\\ \;\;\;\;2 \cdot \left(x \cdot y\right)\\ \mathbf{else}:\\ \;\;\;\;2 \cdot \left(z \cdot t\right)\\ \end{array} \]
Alternative 21
Error42.1
Cost320
\[2 \cdot \left(z \cdot t\right) \]
Alternative 22
Error62.2
Cost64
\[0 \]

Error

Reproduce?

herbie shell --seed 2023187 
(FPCore (x y z t a b c i)
  :name "Diagrams.ThreeD.Shapes:frustum from diagrams-lib-1.3.0.3, A"
  :precision binary64

  :herbie-target
  (* 2.0 (- (+ (* x y) (* z t)) (* (+ a (* b c)) (* c i))))

  (* 2.0 (- (+ (* x y) (* z t)) (* (* (+ a (* b c)) c) i))))