Average Error: 20.2 → 9.6
Time: 38.4s
Precision: binary64
Cost: 8524
\[ \begin{array}{c}[t, a] = \mathsf{sort}([t, a])\\ \end{array} \]
\[\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} \]
\[\begin{array}{l} t_1 := \left(9 \cdot \frac{x \cdot y}{z \cdot c} + \frac{b}{z \cdot c}\right) + \frac{a}{\frac{c}{t}} \cdot -4\\ t_2 := y \cdot \left(x \cdot 9\right)\\ \mathbf{if}\;t_2 \leq -2 \cdot 10^{+278}:\\ \;\;\;\;y \cdot \left(\frac{x}{z} \cdot \frac{9}{c}\right)\\ \mathbf{elif}\;t_2 \leq -2 \cdot 10^{-77}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_2 \leq 0:\\ \;\;\;\;\frac{\mathsf{fma}\left(t, a \cdot -4, \frac{b + 9 \cdot \left(x \cdot y\right)}{z}\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)))
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1
         (+
          (+ (* 9.0 (/ (* x y) (* z c))) (/ b (* z c)))
          (* (/ a (/ c t)) -4.0)))
        (t_2 (* y (* x 9.0))))
   (if (<= t_2 -2e+278)
     (* y (* (/ x z) (/ 9.0 c)))
     (if (<= t_2 -2e-77)
       t_1
       (if (<= t_2 0.0)
         (/ (fma t (* a -4.0) (/ (+ b (* 9.0 (* x y))) z)) c)
         t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = ((9.0 * ((x * y) / (z * c))) + (b / (z * c))) + ((a / (c / t)) * -4.0);
	double t_2 = y * (x * 9.0);
	double tmp;
	if (t_2 <= -2e+278) {
		tmp = y * ((x / z) * (9.0 / c));
	} else if (t_2 <= -2e-77) {
		tmp = t_1;
	} else if (t_2 <= 0.0) {
		tmp = fma(t, (a * -4.0), ((b + (9.0 * (x * y))) / z)) / c;
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c)
	return Float64(Float64(Float64(Float64(Float64(x * 9.0) * y) - Float64(Float64(Float64(z * 4.0) * t) * a)) + b) / Float64(z * c))
end
function code(x, y, z, t, a, b, c)
	t_1 = Float64(Float64(Float64(9.0 * Float64(Float64(x * y) / Float64(z * c))) + Float64(b / Float64(z * c))) + Float64(Float64(a / Float64(c / t)) * -4.0))
	t_2 = Float64(y * Float64(x * 9.0))
	tmp = 0.0
	if (t_2 <= -2e+278)
		tmp = Float64(y * Float64(Float64(x / z) * Float64(9.0 / c)));
	elseif (t_2 <= -2e-77)
		tmp = t_1;
	elseif (t_2 <= 0.0)
		tmp = Float64(fma(t, Float64(a * -4.0), Float64(Float64(b + Float64(9.0 * Float64(x * y))) / z)) / c);
	else
		tmp = t_1;
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_] := N[(N[(N[(N[(N[(x * 9.0), $MachinePrecision] * y), $MachinePrecision] - N[(N[(N[(z * 4.0), $MachinePrecision] * t), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(N[(N[(9.0 * N[(N[(x * y), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision] * -4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(x * 9.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+278], N[(y * N[(N[(x / z), $MachinePrecision] * N[(9.0 / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, -2e-77], t$95$1, If[LessEqual[t$95$2, 0.0], N[(N[(t * N[(a * -4.0), $MachinePrecision] + N[(N[(b + N[(9.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision], t$95$1]]]]]
\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c}
\begin{array}{l}
t_1 := \left(9 \cdot \frac{x \cdot y}{z \cdot c} + \frac{b}{z \cdot c}\right) + \frac{a}{\frac{c}{t}} \cdot -4\\
t_2 := y \cdot \left(x \cdot 9\right)\\
\mathbf{if}\;t_2 \leq -2 \cdot 10^{+278}:\\
\;\;\;\;y \cdot \left(\frac{x}{z} \cdot \frac{9}{c}\right)\\

\mathbf{elif}\;t_2 \leq -2 \cdot 10^{-77}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;t_2 \leq 0:\\
\;\;\;\;\frac{\mathsf{fma}\left(t, a \cdot -4, \frac{b + 9 \cdot \left(x \cdot y\right)}{z}\right)}{c}\\

\mathbf{else}:\\
\;\;\;\;t_1\\


\end{array}

Error

Target

Original20.2
Target14.3
Herbie9.6
\[\begin{array}{l} \mathbf{if}\;\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} < -1.100156740804105 \cdot 10^{-171}:\\ \;\;\;\;\frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{z \cdot c}\\ \mathbf{elif}\;\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} < 0:\\ \;\;\;\;\frac{\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z}}{c}\\ \mathbf{elif}\;\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} < 1.1708877911747488 \cdot 10^{-53}:\\ \;\;\;\;\frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{z \cdot c}\\ \mathbf{elif}\;\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} < 2.876823679546137 \cdot 10^{+130}:\\ \;\;\;\;\left(\left(9 \cdot \frac{y}{c}\right) \cdot \frac{x}{z} + \frac{b}{c \cdot z}\right) - 4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} < 1.3838515042456319 \cdot 10^{+158}:\\ \;\;\;\;\frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;\left(9 \cdot \left(\frac{y}{c \cdot z} \cdot x\right) + \frac{b}{c \cdot z}\right) - 4 \cdot \frac{a \cdot t}{c}\\ \end{array} \]

Derivation

  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 x 9) y) < -1.99999999999999993e278

    1. Initial program 55.6

      \[\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} \]
    2. Taylor expanded in x around inf 54.6

      \[\leadsto \color{blue}{9 \cdot \frac{y \cdot x}{c \cdot z}} \]
    3. Simplified17.6

      \[\leadsto \color{blue}{\frac{\frac{y}{c}}{\frac{z}{9 \cdot x}}} \]
    4. Applied egg-rr25.0

      \[\leadsto \color{blue}{\left(\frac{y}{z \cdot c} \cdot x\right) \cdot 9} \]
    5. Taylor expanded in y around 0 54.6

      \[\leadsto \color{blue}{9 \cdot \frac{y \cdot x}{c \cdot z}} \]
    6. Simplified19.7

      \[\leadsto \color{blue}{y \cdot \left(\frac{x}{z} \cdot \frac{9}{c}\right)} \]

    if -1.99999999999999993e278 < (*.f64 (*.f64 x 9) y) < -1.9999999999999999e-77 or 0.0 < (*.f64 (*.f64 x 9) y)

    1. Initial program 19.4

      \[\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} \]
    2. Taylor expanded in x around 0 10.6

      \[\leadsto \color{blue}{\left(\frac{b}{c \cdot z} + 9 \cdot \frac{y \cdot x}{c \cdot z}\right) - 4 \cdot \frac{a \cdot t}{c}} \]
    3. Applied egg-rr9.9

      \[\leadsto \left(\frac{b}{c \cdot z} + 9 \cdot \frac{y \cdot x}{c \cdot z}\right) - 4 \cdot \color{blue}{\left(\frac{a}{1} \cdot \frac{t}{c}\right)} \]
    4. Applied egg-rr9.8

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

    if -1.9999999999999999e-77 < (*.f64 (*.f64 x 9) y) < 0.0

    1. Initial program 16.9

      \[\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} \]
    2. Simplified7.6

      \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, a \cdot -4, \frac{\mathsf{fma}\left(x, 9 \cdot y, b\right)}{z}\right)}{c}} \]
    3. Taylor expanded in x around 0 7.6

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

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

Alternatives

Alternative 1
Error9.1
Cost7380
\[\begin{array}{l} t_1 := \frac{-4 \cdot \left(a \cdot t\right) + 9 \cdot \frac{x \cdot y}{z}}{c}\\ t_2 := \frac{b + \left(y \cdot \left(x \cdot 9\right) + a \cdot \left(t \cdot \left(z \cdot -4\right)\right)\right)}{z \cdot c}\\ t_3 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ \mathbf{if}\;t_2 \leq -\infty:\\ \;\;\;\;t_3\\ \mathbf{elif}\;t_2 \leq -1 \cdot 10^{-272}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;t_2 \leq 0:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_2 \leq 10^{+283}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;t_2 \leq \infty:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \]
Alternative 2
Error10.3
Cost2636
\[\begin{array}{l} t_1 := \left(9 \cdot \frac{x \cdot y}{z \cdot c} + \frac{b}{z \cdot c}\right) + \frac{a}{\frac{c}{t}} \cdot -4\\ t_2 := y \cdot \left(x \cdot 9\right)\\ \mathbf{if}\;t_2 \leq -2 \cdot 10^{+278}:\\ \;\;\;\;y \cdot \left(\frac{x}{z} \cdot \frac{9}{c}\right)\\ \mathbf{elif}\;t_2 \leq -2 \cdot 10^{-77}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_2 \leq 0:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 3
Error36.1
Cost1768
\[\begin{array}{l} t_1 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ t_2 := -4 \cdot \frac{a \cdot t}{c}\\ t_3 := y \cdot \left(9 \cdot \frac{x}{z \cdot c}\right)\\ \mathbf{if}\;a \leq -3.515267876064152 \cdot 10^{-54}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 1.6784706012168662 \cdot 10^{-299}:\\ \;\;\;\;\frac{1}{c \cdot \frac{z}{b}}\\ \mathbf{elif}\;a \leq 2.5101721251697066 \cdot 10^{-166}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;a \leq 1.8204891852780966 \cdot 10^{-128}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;a \leq 4.543885549368346 \cdot 10^{-80}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq 5.164631704653901 \cdot 10^{-36}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;a \leq 2.160283008660652 \cdot 10^{-19}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;a \leq 7.9 \cdot 10^{+96}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq 1.4 \cdot 10^{+118}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;a \leq 1.28 \cdot 10^{+131}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 4
Error37.3
Cost1768
\[\begin{array}{l} t_1 := 9 \cdot \frac{\frac{x \cdot y}{c}}{z}\\ t_2 := y \cdot \left(\frac{x}{z} \cdot \frac{9}{c}\right)\\ t_3 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ \mathbf{if}\;b \leq -6.5 \cdot 10^{+125}:\\ \;\;\;\;\frac{1}{\frac{z \cdot c}{b}}\\ \mathbf{elif}\;b \leq -5.793446081208312 \cdot 10^{+38}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z} \cdot \frac{1}{c}\\ \mathbf{elif}\;b \leq -2.6044119630332434 \cdot 10^{-289}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;b \leq 2.380637636591706 \cdot 10^{-253}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 1.425173050214676 \cdot 10^{-180}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;b \leq 6.705889245927755 \cdot 10^{-18}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 166898499687296160:\\ \;\;\;\;\frac{1}{z \cdot \frac{c}{b}}\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b}{c}\\ \end{array} \]
Alternative 5
Error37.3
Cost1768
\[\begin{array}{l} t_1 := y \cdot \left(\frac{x}{z} \cdot \frac{9}{c}\right)\\ t_2 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ \mathbf{if}\;b \leq -6.5 \cdot 10^{+125}:\\ \;\;\;\;\frac{1}{\frac{z \cdot c}{b}}\\ \mathbf{elif}\;b \leq -5.793446081208312 \cdot 10^{+38}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z} \cdot \frac{1}{c}\\ \mathbf{elif}\;b \leq -2.6044119630332434 \cdot 10^{-289}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 2.380637636591706 \cdot 10^{-253}:\\ \;\;\;\;\frac{\frac{9 \cdot \left(x \cdot y\right)}{z}}{c}\\ \mathbf{elif}\;b \leq 1.425173050214676 \cdot 10^{-180}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;b \leq 6.705889245927755 \cdot 10^{-18}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 166898499687296160:\\ \;\;\;\;\frac{1}{z \cdot \frac{c}{b}}\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;9 \cdot \frac{\frac{x \cdot y}{c}}{z}\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b}{c}\\ \end{array} \]
Alternative 6
Error36.3
Cost1768
\[\begin{array}{l} t_1 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ t_2 := \frac{1}{z} \cdot \frac{b}{c}\\ \mathbf{if}\;b \leq -6.5 \cdot 10^{+125}:\\ \;\;\;\;\frac{1}{\frac{z \cdot c}{b}}\\ \mathbf{elif}\;b \leq -5.793446081208312 \cdot 10^{+38}:\\ \;\;\;\;y \cdot \left(\frac{x}{z} \cdot \frac{9}{c}\right)\\ \mathbf{elif}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z} \cdot \frac{1}{c}\\ \mathbf{elif}\;b \leq -2.6044119630332434 \cdot 10^{-289}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 2.380637636591706 \cdot 10^{-253}:\\ \;\;\;\;\frac{\frac{9 \cdot \left(x \cdot y\right)}{z}}{c}\\ \mathbf{elif}\;b \leq 1.425173050214676 \cdot 10^{-180}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;b \leq 3.016413154419153 \cdot 10^{-113}:\\ \;\;\;\;\frac{\frac{y}{c}}{0.1111111111111111 \cdot \frac{z}{x}}\\ \mathbf{elif}\;b \leq 14368825.573521053:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 7
Error36.4
Cost1768
\[\begin{array}{l} t_1 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ t_2 := \frac{1}{z} \cdot \frac{b}{c}\\ \mathbf{if}\;b \leq -6.5 \cdot 10^{+125}:\\ \;\;\;\;\frac{1}{\frac{z \cdot c}{b}}\\ \mathbf{elif}\;b \leq -5.793446081208312 \cdot 10^{+38}:\\ \;\;\;\;9 \cdot \frac{x \cdot y}{z \cdot c}\\ \mathbf{elif}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z} \cdot \frac{1}{c}\\ \mathbf{elif}\;b \leq -2.6044119630332434 \cdot 10^{-289}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 2.380637636591706 \cdot 10^{-253}:\\ \;\;\;\;\frac{\frac{9 \cdot \left(x \cdot y\right)}{z}}{c}\\ \mathbf{elif}\;b \leq 1.425173050214676 \cdot 10^{-180}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;b \leq 3.016413154419153 \cdot 10^{-113}:\\ \;\;\;\;\frac{\frac{y}{c}}{0.1111111111111111 \cdot \frac{z}{x}}\\ \mathbf{elif}\;b \leq 14368825.573521053:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 8
Error36.4
Cost1768
\[\begin{array}{l} t_1 := \frac{1}{z} \cdot \frac{b}{c}\\ t_2 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ \mathbf{if}\;b \leq -6.5 \cdot 10^{+125}:\\ \;\;\;\;\frac{1}{\frac{z \cdot c}{b}}\\ \mathbf{elif}\;b \leq -5.793446081208312 \cdot 10^{+38}:\\ \;\;\;\;9 \cdot \frac{x \cdot y}{z \cdot c}\\ \mathbf{elif}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z} \cdot \frac{1}{c}\\ \mathbf{elif}\;b \leq -2.6044119630332434 \cdot 10^{-289}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 2.380637636591706 \cdot 10^{-253}:\\ \;\;\;\;\frac{\frac{9 \cdot \left(x \cdot y\right)}{z}}{c}\\ \mathbf{elif}\;b \leq 6.38909174151942 \cdot 10^{-172}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;b \leq 3.016413154419153 \cdot 10^{-113}:\\ \;\;\;\;\frac{\frac{y}{c}}{\frac{z}{x \cdot 9}}\\ \mathbf{elif}\;b \leq 14368825.573521053:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 9
Error21.2
Cost1620
\[\begin{array}{l} t_1 := -4 \cdot \left(a \cdot t\right)\\ t_2 := \frac{t_1 + 9 \cdot \frac{x \cdot y}{z}}{c}\\ t_3 := \frac{\frac{b}{z} + t_1}{c}\\ \mathbf{if}\;b \leq -4.811921203428343 \cdot 10^{+28}:\\ \;\;\;\;9 \cdot \frac{x \cdot y}{z \cdot c} + \frac{b}{z \cdot c}\\ \mathbf{elif}\;b \leq -3.7674917591847585 \cdot 10^{-11}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;b \leq -3.6887096644098937 \cdot 10^{-82}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq -4.245674279982199 \cdot 10^{-153}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;b \leq 1.0173971860826272 \cdot 10^{-38}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 1.1727522011229865 \cdot 10^{+36}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \]
Alternative 10
Error37.0
Cost1504
\[\begin{array}{l} t_1 := y \cdot \left(\frac{x}{z} \cdot \frac{9}{c}\right)\\ t_2 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ \mathbf{if}\;b \leq -6.5 \cdot 10^{+125}:\\ \;\;\;\;\frac{1}{\frac{z \cdot c}{b}}\\ \mathbf{elif}\;b \leq -5.793446081208312 \cdot 10^{+38}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z} \cdot \frac{1}{c}\\ \mathbf{elif}\;b \leq 1.425173050214676 \cdot 10^{-180}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 6.705889245927755 \cdot 10^{-18}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 166898499687296160:\\ \;\;\;\;\frac{1}{z \cdot \frac{c}{b}}\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;y \cdot \left(9 \cdot \frac{x}{z \cdot c}\right)\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b}{c}\\ \end{array} \]
Alternative 11
Error24.6
Cost1364
\[\begin{array}{l} t_1 := \frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\ t_2 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{if}\;x \leq -1.2478404297295135 \cdot 10^{+52}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -2.878173907709029 \cdot 10^{-45}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -9.579095069913847 \cdot 10^{-85}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -1.3065364056124767 \cdot 10^{-96}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;x \leq 5.7 \cdot 10^{+74}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;9 \cdot \frac{x}{\frac{c}{\frac{y}{z}}}\\ \end{array} \]
Alternative 12
Error24.6
Cost1364
\[\begin{array}{l} t_1 := \frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\ \mathbf{if}\;x \leq -1.2478404297295135 \cdot 10^{+52}:\\ \;\;\;\;9 \cdot \frac{x \cdot y}{z \cdot c} + \frac{b}{z \cdot c}\\ \mathbf{elif}\;x \leq -2.878173907709029 \cdot 10^{-45}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -9.579095069913847 \cdot 10^{-85}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{elif}\;x \leq -1.3065364056124767 \cdot 10^{-96}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;x \leq 5.7 \cdot 10^{+74}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;9 \cdot \frac{x}{\frac{c}{\frac{y}{z}}}\\ \end{array} \]
Alternative 13
Error35.0
Cost1240
\[\begin{array}{l} t_1 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ t_2 := \frac{1}{z} \cdot \frac{b}{c}\\ \mathbf{if}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;b \leq 6.38909174151942 \cdot 10^{-172}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 3.016413154419153 \cdot 10^{-113}:\\ \;\;\;\;9 \cdot \left(x \cdot \frac{\frac{y}{z}}{c}\right)\\ \mathbf{elif}\;b \leq 14368825.573521053:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 14
Error26.8
Cost1232
\[\begin{array}{l} t_1 := \frac{\frac{b + 9 \cdot \left(x \cdot y\right)}{z}}{c}\\ \mathbf{if}\;a \leq -2.2087449210898305 \cdot 10^{-45}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;a \leq 3.9866529264522505 \cdot 10^{-11}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 5.59931114048127 \cdot 10^{+48}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;a \leq 3.4 \cdot 10^{+129}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(t \cdot \frac{-4}{c}\right)\\ \end{array} \]
Alternative 15
Error26.4
Cost1232
\[\begin{array}{l} t_1 := b + 9 \cdot \left(x \cdot y\right)\\ \mathbf{if}\;a \leq -2.2087449210898305 \cdot 10^{-45}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;a \leq 3.9866529264522505 \cdot 10^{-11}:\\ \;\;\;\;\frac{\frac{t_1}{z}}{c}\\ \mathbf{elif}\;a \leq 7.580476320761814 \cdot 10^{+27}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;a \leq 1.05 \cdot 10^{+131}:\\ \;\;\;\;\frac{t_1}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(t \cdot \frac{-4}{c}\right)\\ \end{array} \]
Alternative 16
Error34.2
Cost976
\[\begin{array}{l} t_1 := -4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{if}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;b \leq 6.705889245927755 \cdot 10^{-18}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;\frac{1}{c \cdot \frac{z}{b}}\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b}{c}\\ \end{array} \]
Alternative 17
Error34.3
Cost976
\[\begin{array}{l} \mathbf{if}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;b \leq 6.705889245927755 \cdot 10^{-18}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;\frac{1}{c \cdot \frac{z}{b}}\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b}{c}\\ \end{array} \]
Alternative 18
Error34.2
Cost976
\[\begin{array}{l} t_1 := a \cdot \left(t \cdot \frac{-4}{c}\right)\\ t_2 := \frac{1}{z} \cdot \frac{b}{c}\\ \mathbf{if}\;b \leq -1.228368652689895 \cdot 10^{-5}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;b \leq 14368825.573521053:\\ \;\;\;\;t_1\\ \mathbf{elif}\;b \leq 2.036095319220653 \cdot 10^{+46}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;b \leq 1.25 \cdot 10^{+116}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 19
Error42.6
Cost580
\[\begin{array}{l} \mathbf{if}\;z \leq -2.5 \cdot 10^{-124}:\\ \;\;\;\;\frac{1}{c \cdot \frac{z}{b}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \end{array} \]
Alternative 20
Error42.7
Cost452
\[\begin{array}{l} \mathbf{if}\;z \leq -2.5 \cdot 10^{-124}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \end{array} \]
Alternative 21
Error44.1
Cost320
\[\frac{\frac{b}{z}}{c} \]

Error

Reproduce

herbie shell --seed 2022217 
(FPCore (x y z t a b c)
  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1, J"
  :precision binary64

  :herbie-target
  (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) -1.100156740804105e-171) (/ (+ (- (* (* x 9.0) y) (* (* z 4.0) (* t a))) b) (* z c)) (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) 0.0) (/ (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) z) c) (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) 1.1708877911747488e-53) (/ (+ (- (* (* x 9.0) y) (* (* z 4.0) (* t a))) b) (* z c)) (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) 2.876823679546137e+130) (- (+ (* (* 9.0 (/ y c)) (/ x z)) (/ b (* c z))) (* 4.0 (/ (* a t) c))) (if (< (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)) 1.3838515042456319e+158) (/ (+ (- (* (* x 9.0) y) (* (* z 4.0) (* t a))) b) (* z c)) (- (+ (* 9.0 (* (/ y (* c z)) x)) (/ b (* c z))) (* 4.0 (/ (* a t) c))))))))

  (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)))