?

Average Error: 31.66% → 7.49%
Time: 35.5s
Precision: binary64
Cost: 13780

?

\[ \begin{array}{c}[x, y] = \mathsf{sort}([x, y])\\ [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 := a \cdot \left(t \cdot -4\right)\\ t_2 := \frac{\left(\left(x \cdot 9\right) \cdot y + a \cdot \left(t \cdot \left(z \cdot -4\right)\right)\right) + b}{z \cdot c}\\ t_3 := \frac{t_1 + \frac{\mathsf{fma}\left(x, 9 \cdot y, b\right)}{z}}{c}\\ \mathbf{if}\;t_2 \leq -5 \cdot 10^{+305}:\\ \;\;\;\;\frac{t_1 + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{elif}\;t_2 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;t_2 \leq 5000000:\\ \;\;\;\;t_3\\ \mathbf{elif}\;t_2 \leq 5 \cdot 10^{+304}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;t_2 \leq \infty:\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z} + \left(\left(9 \cdot y\right) \cdot \frac{\frac{x}{z}}{c} + -4 \cdot \frac{a}{\frac{c}{t}}\right)\\ \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 (* a (* t -4.0)))
        (t_2 (/ (+ (+ (* (* x 9.0) y) (* a (* t (* z -4.0)))) b) (* z c)))
        (t_3 (/ (+ t_1 (/ (fma x (* 9.0 y) b) z)) c)))
   (if (<= t_2 -5e+305)
     (/ (+ t_1 (* 9.0 (/ y (/ z x)))) c)
     (if (<= t_2 -5e-305)
       t_2
       (if (<= t_2 5000000.0)
         t_3
         (if (<= t_2 5e+304)
           t_2
           (if (<= t_2 INFINITY)
             t_3
             (+
              (/ (/ b c) z)
              (+ (* (* 9.0 y) (/ (/ x z) c)) (* -4.0 (/ a (/ c t))))))))))))
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 = a * (t * -4.0);
	double t_2 = ((((x * 9.0) * y) + (a * (t * (z * -4.0)))) + b) / (z * c);
	double t_3 = (t_1 + (fma(x, (9.0 * y), b) / z)) / c;
	double tmp;
	if (t_2 <= -5e+305) {
		tmp = (t_1 + (9.0 * (y / (z / x)))) / c;
	} else if (t_2 <= -5e-305) {
		tmp = t_2;
	} else if (t_2 <= 5000000.0) {
		tmp = t_3;
	} else if (t_2 <= 5e+304) {
		tmp = t_2;
	} else if (t_2 <= ((double) INFINITY)) {
		tmp = t_3;
	} else {
		tmp = ((b / c) / z) + (((9.0 * y) * ((x / z) / c)) + (-4.0 * (a / (c / t))));
	}
	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(a * Float64(t * -4.0))
	t_2 = Float64(Float64(Float64(Float64(Float64(x * 9.0) * y) + Float64(a * Float64(t * Float64(z * -4.0)))) + b) / Float64(z * c))
	t_3 = Float64(Float64(t_1 + Float64(fma(x, Float64(9.0 * y), b) / z)) / c)
	tmp = 0.0
	if (t_2 <= -5e+305)
		tmp = Float64(Float64(t_1 + Float64(9.0 * Float64(y / Float64(z / x)))) / c);
	elseif (t_2 <= -5e-305)
		tmp = t_2;
	elseif (t_2 <= 5000000.0)
		tmp = t_3;
	elseif (t_2 <= 5e+304)
		tmp = t_2;
	elseif (t_2 <= Inf)
		tmp = t_3;
	else
		tmp = Float64(Float64(Float64(b / c) / z) + Float64(Float64(Float64(9.0 * y) * Float64(Float64(x / z) / c)) + Float64(-4.0 * Float64(a / Float64(c / t)))));
	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[(a * N[(t * -4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(N[(N[(x * 9.0), $MachinePrecision] * y), $MachinePrecision] + N[(a * N[(t * N[(z * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(t$95$1 + N[(N[(x * N[(9.0 * y), $MachinePrecision] + b), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]}, If[LessEqual[t$95$2, -5e+305], N[(N[(t$95$1 + N[(9.0 * N[(y / N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision], If[LessEqual[t$95$2, -5e-305], t$95$2, If[LessEqual[t$95$2, 5000000.0], t$95$3, If[LessEqual[t$95$2, 5e+304], t$95$2, If[LessEqual[t$95$2, Infinity], t$95$3, N[(N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision] + N[(N[(N[(9.0 * y), $MachinePrecision] * N[(N[(x / z), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\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 := a \cdot \left(t \cdot -4\right)\\
t_2 := \frac{\left(\left(x \cdot 9\right) \cdot y + a \cdot \left(t \cdot \left(z \cdot -4\right)\right)\right) + b}{z \cdot c}\\
t_3 := \frac{t_1 + \frac{\mathsf{fma}\left(x, 9 \cdot y, b\right)}{z}}{c}\\
\mathbf{if}\;t_2 \leq -5 \cdot 10^{+305}:\\
\;\;\;\;\frac{t_1 + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\

\mathbf{elif}\;t_2 \leq -5 \cdot 10^{-305}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;t_2 \leq 5000000:\\
\;\;\;\;t_3\\

\mathbf{elif}\;t_2 \leq 5 \cdot 10^{+304}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;t_2 \leq \infty:\\
\;\;\;\;t_3\\

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


\end{array}

Error?

Target

Original31.66%
Target22.27%
Herbie7.49%
\[\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 4 regimes
  2. if (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < -5.00000000000000009e305

    1. Initial program 98.5

      \[\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. Simplified39.92

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

      [Start]98.5

      \[ \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} \]

      associate-/r* [=>]90.11

      \[ \color{blue}{\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}} \]
    3. Taylor expanded in x around inf 49.37

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

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

      [Start]49.37

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

      associate-/l* [=>]37.42

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

    if -5.00000000000000009e305 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < -4.99999999999999985e-305 or 5e6 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < 4.9999999999999997e304

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

    if -4.99999999999999985e-305 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < 5e6 or 4.9999999999999997e304 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < +inf.0

    1. Initial program 46.02

      \[\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. Simplified11.77

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

      [Start]46.02

      \[ \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} \]

      associate-/r* [=>]24.66

      \[ \color{blue}{\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}} \]

    if +inf.0 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c))

    1. Initial program 100

      \[\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. Simplified97.13

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

      [Start]100

      \[ \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} \]

      associate-*l* [=>]100

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

      associate-*l* [=>]97.13

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

      \[\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}} \]
    4. Simplified23.34

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

      [Start]48.54

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

      associate--l+ [=>]48.54

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

      associate-/r* [=>]45.51

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

      *-commutative [<=]45.51

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

      associate-*r/ [=>]45.54

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

      associate-*r* [=>]45.53

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

      *-commutative [<=]45.53

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

      associate-/l* [=>]39.78

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

      associate-/l* [=>]23.34

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

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

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

Alternatives

Alternative 1
Error7.82%
Cost7892
\[\begin{array}{l} t_1 := \frac{\left(\left(x \cdot 9\right) \cdot y + a \cdot \left(t \cdot \left(z \cdot -4\right)\right)\right) + b}{z \cdot c}\\ \mathbf{if}\;t_1 \leq -5 \cdot 10^{+305}:\\ \;\;\;\;\frac{a \cdot \left(t \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{elif}\;t_1 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_1 \leq 10^{-127}:\\ \;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) + \left(t \cdot a\right) \cdot \left(z \cdot -4\right)\right)}{z} \cdot \frac{1}{c}\\ \mathbf{elif}\;t_1 \leq 5 \cdot 10^{+304}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_1 \leq \infty:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(t \cdot a\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z} + \left(\left(9 \cdot y\right) \cdot \frac{\frac{x}{z}}{c} + -4 \cdot \frac{a}{\frac{c}{t}}\right)\\ \end{array} \]
Alternative 2
Error13.67%
Cost6352
\[\begin{array}{l} t_1 := \frac{\left(\left(x \cdot 9\right) \cdot y + a \cdot \left(t \cdot \left(z \cdot -4\right)\right)\right) + b}{z \cdot c}\\ \mathbf{if}\;t_1 \leq -5 \cdot 10^{+305}:\\ \;\;\;\;\frac{a \cdot \left(t \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{elif}\;t_1 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_1 \leq 0:\\ \;\;\;\;\frac{\frac{b}{z} + 9 \cdot \frac{x \cdot y}{z}}{c}\\ \mathbf{elif}\;t_1 \leq 5 \cdot 10^{+304}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(t \cdot a\right)}{c}\\ \end{array} \]
Alternative 3
Error11.52%
Cost6352
\[\begin{array}{l} t_1 := \frac{\left(\left(x \cdot 9\right) \cdot y + a \cdot \left(t \cdot \left(z \cdot -4\right)\right)\right) + b}{z \cdot c}\\ \mathbf{if}\;t_1 \leq -5 \cdot 10^{+305}:\\ \;\;\;\;\frac{a \cdot \left(t \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{elif}\;t_1 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_1 \leq 0:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b + \left(x \cdot \left(9 \cdot y\right) + \left(t \cdot a\right) \cdot \left(z \cdot -4\right)\right)}{c}\\ \mathbf{elif}\;t_1 \leq 5 \cdot 10^{+304}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(t \cdot a\right)}{c}\\ \end{array} \]
Alternative 4
Error11.6%
Cost6352
\[\begin{array}{l} t_1 := \frac{\left(\left(x \cdot 9\right) \cdot y + a \cdot \left(t \cdot \left(z \cdot -4\right)\right)\right) + b}{z \cdot c}\\ \mathbf{if}\;t_1 \leq -5 \cdot 10^{+305}:\\ \;\;\;\;\frac{a \cdot \left(t \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{elif}\;t_1 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_1 \leq 10^{-127}:\\ \;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) + \left(t \cdot a\right) \cdot \left(z \cdot -4\right)\right)}{z} \cdot \frac{1}{c}\\ \mathbf{elif}\;t_1 \leq 5 \cdot 10^{+304}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(t \cdot a\right)}{c}\\ \end{array} \]
Alternative 5
Error40.38%
Cost2016
\[\begin{array}{l} t_1 := \frac{a \cdot \left(t \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ t_2 := -4 \cdot \frac{a}{\frac{c}{t}} + \frac{b}{z \cdot c}\\ t_3 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{if}\;c \leq -4.4 \cdot 10^{+188}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;c \leq -2.7 \cdot 10^{+113}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq -6.6 \cdot 10^{+65}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;c \leq -1.1 \cdot 10^{+35}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq 1.55 \cdot 10^{-75}:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(t \cdot a\right)}{c}\\ \mathbf{elif}\;c \leq 3.7 \cdot 10^{+19}:\\ \;\;\;\;\frac{\frac{b}{z} + 9 \cdot \frac{x \cdot y}{z}}{c}\\ \mathbf{elif}\;c \leq 3.2 \cdot 10^{+140}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq 1.4 \cdot 10^{+143}:\\ \;\;\;\;9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 6
Error39.54%
Cost1756
\[\begin{array}{l} t_1 := -4 \cdot \frac{a}{\frac{c}{t}} + \frac{b}{z \cdot c}\\ t_2 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{if}\;c \leq -4.2 \cdot 10^{+188}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq -2.1 \cdot 10^{+107}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq -4.1 \cdot 10^{+65}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq -1.6 \cdot 10^{-10}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq 4 \cdot 10^{-66}:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(t \cdot a\right)}{c}\\ \mathbf{elif}\;c \leq 2.3 \cdot 10^{+54}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq 1.3 \cdot 10^{+251}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{z} \cdot \frac{9 \cdot y}{c}\\ \end{array} \]
Alternative 7
Error39.03%
Cost1756
\[\begin{array}{l} t_1 := -4 \cdot \frac{a}{\frac{c}{t}} + \frac{b}{z \cdot c}\\ t_2 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{if}\;c \leq -2.26 \cdot 10^{+188}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq -1.05 \cdot 10^{+109}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq -7.4 \cdot 10^{+65}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;c \leq -5.8 \cdot 10^{-10}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;c \leq 1.55 \cdot 10^{-75}:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(t \cdot a\right)}{c}\\ \mathbf{elif}\;c \leq 5.5 \cdot 10^{+19}:\\ \;\;\;\;\frac{\frac{b}{z} + 9 \cdot \frac{x \cdot y}{z}}{c}\\ \mathbf{elif}\;c \leq 1.3 \cdot 10^{+251}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{z} \cdot \frac{9 \cdot y}{c}\\ \end{array} \]
Alternative 8
Error26.91%
Cost1744
\[\begin{array}{l} t_1 := \frac{b + \left(x \cdot \left(9 \cdot y\right) + \left(t \cdot a\right) \cdot \left(z \cdot -4\right)\right)}{z \cdot c}\\ t_2 := -4 \cdot \frac{a}{\frac{c}{t}} + \frac{b}{z \cdot c}\\ \mathbf{if}\;a \leq -2 \cdot 10^{-102}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;a \leq 3.5 \cdot 10^{-305}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 2.55 \cdot 10^{-259}:\\ \;\;\;\;\frac{\frac{b}{z} + 9 \cdot \frac{x \cdot y}{z}}{c}\\ \mathbf{elif}\;a \leq 4.1 \cdot 10^{+14}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq 5.8 \cdot 10^{+225}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;\frac{a \cdot \left(t \cdot -4\right) + \frac{y}{z} \cdot \frac{x}{0.1111111111111111}}{c}\\ \end{array} \]
Alternative 9
Error56.19%
Cost1632
\[\begin{array}{l} t_1 := 9 \cdot \frac{x}{z \cdot \frac{c}{y}}\\ \mathbf{if}\;z \leq -9 \cdot 10^{+157}:\\ \;\;\;\;t \cdot \frac{a \cdot -4}{c}\\ \mathbf{elif}\;z \leq -1.7 \cdot 10^{+132}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -1.9 \cdot 10^{+90}:\\ \;\;\;\;-4 \cdot \frac{t \cdot a}{c}\\ \mathbf{elif}\;z \leq -1.2 \cdot 10^{-44}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 3.9 \cdot 10^{-175}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;z \leq 5.7 \cdot 10^{-98}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 6.8 \cdot 10^{-37}:\\ \;\;\;\;\frac{b}{c} \cdot \frac{1}{z}\\ \mathbf{elif}\;z \leq 1.2 \cdot 10^{+73}:\\ \;\;\;\;9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 10
Error55.89%
Cost1632
\[\begin{array}{l} \mathbf{if}\;z \leq -1.05 \cdot 10^{+158}:\\ \;\;\;\;t \cdot \frac{a \cdot -4}{c}\\ \mathbf{elif}\;z \leq -1.05 \cdot 10^{+126}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -1.86 \cdot 10^{+90}:\\ \;\;\;\;-4 \cdot \frac{t \cdot a}{c}\\ \mathbf{elif}\;z \leq -1.08 \cdot 10^{-44}:\\ \;\;\;\;9 \cdot \frac{x}{z \cdot \frac{c}{y}}\\ \mathbf{elif}\;z \leq 9.5 \cdot 10^{-177}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;z \leq 3.15 \cdot 10^{-101}:\\ \;\;\;\;\left(x \cdot \frac{y}{c}\right) \cdot \frac{9}{z}\\ \mathbf{elif}\;z \leq 2.6 \cdot 10^{-36}:\\ \;\;\;\;\frac{b}{c} \cdot \frac{1}{z}\\ \mathbf{elif}\;z \leq 1.55 \cdot 10^{+69}:\\ \;\;\;\;9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 11
Error55.81%
Cost1632
\[\begin{array}{l} \mathbf{if}\;z \leq -9 \cdot 10^{+157}:\\ \;\;\;\;t \cdot \frac{a \cdot -4}{c}\\ \mathbf{elif}\;z \leq -1.85 \cdot 10^{+132}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -3.1 \cdot 10^{+90}:\\ \;\;\;\;-4 \cdot \frac{t \cdot a}{c}\\ \mathbf{elif}\;z \leq -1.1 \cdot 10^{-44}:\\ \;\;\;\;\frac{x}{z} \cdot \frac{9 \cdot y}{c}\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{-175}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;z \leq 3.2 \cdot 10^{-101}:\\ \;\;\;\;\left(x \cdot \frac{y}{c}\right) \cdot \frac{9}{z}\\ \mathbf{elif}\;z \leq 2.75 \cdot 10^{-36}:\\ \;\;\;\;\frac{b}{c} \cdot \frac{1}{z}\\ \mathbf{elif}\;z \leq 2.6 \cdot 10^{+69}:\\ \;\;\;\;9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 12
Error56.04%
Cost1632
\[\begin{array}{l} \mathbf{if}\;z \leq -9.8 \cdot 10^{+157}:\\ \;\;\;\;t \cdot \frac{a \cdot -4}{c}\\ \mathbf{elif}\;z \leq -3 \cdot 10^{+131}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -1.86 \cdot 10^{+90}:\\ \;\;\;\;-4 \cdot \frac{t \cdot a}{c}\\ \mathbf{elif}\;z \leq -1.45 \cdot 10^{-26}:\\ \;\;\;\;\frac{x \cdot \frac{y}{z}}{\frac{c}{9}}\\ \mathbf{elif}\;z \leq 6.2 \cdot 10^{-172}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;z \leq 1.95 \cdot 10^{-100}:\\ \;\;\;\;\left(x \cdot \frac{y}{c}\right) \cdot \frac{9}{z}\\ \mathbf{elif}\;z \leq 2.7 \cdot 10^{-36}:\\ \;\;\;\;\frac{b}{c} \cdot \frac{1}{z}\\ \mathbf{elif}\;z \leq 1.3 \cdot 10^{+73}:\\ \;\;\;\;9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 13
Error56.03%
Cost1632
\[\begin{array}{l} \mathbf{if}\;z \leq -4.3 \cdot 10^{+159}:\\ \;\;\;\;t \cdot \frac{a \cdot -4}{c}\\ \mathbf{elif}\;z \leq -1.3 \cdot 10^{+129}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -2.4 \cdot 10^{+90}:\\ \;\;\;\;-4 \cdot \frac{t \cdot a}{c}\\ \mathbf{elif}\;z \leq -5.4 \cdot 10^{-27}:\\ \;\;\;\;\frac{x \cdot \frac{y}{z}}{\frac{c}{9}}\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-176}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;z \leq 1.28 \cdot 10^{-99}:\\ \;\;\;\;\left(x \cdot \frac{y}{c}\right) \cdot \frac{9}{z}\\ \mathbf{elif}\;z \leq 2100000:\\ \;\;\;\;\frac{b}{c} \cdot \frac{1}{z}\\ \mathbf{elif}\;z \leq 1.5 \cdot 10^{+69}:\\ \;\;\;\;\frac{y \cdot \left(9 \cdot \frac{x}{c}\right)}{z}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 14
Error55.61%
Cost1368
\[\begin{array}{l} t_1 := 9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\ \mathbf{if}\;z \leq -9 \cdot 10^{+157}:\\ \;\;\;\;t \cdot \frac{a \cdot -4}{c}\\ \mathbf{elif}\;z \leq -1.85 \cdot 10^{+132}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -1.86 \cdot 10^{+90}:\\ \;\;\;\;-4 \cdot \frac{t \cdot a}{c}\\ \mathbf{elif}\;z \leq -5.4 \cdot 10^{-27}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{-36}:\\ \;\;\;\;\frac{b}{c} \cdot \frac{1}{z}\\ \mathbf{elif}\;z \leq 4 \cdot 10^{+73}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 15
Error40.66%
Cost1232
\[\begin{array}{l} t_1 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{if}\;z \leq -4.2 \cdot 10^{+158}:\\ \;\;\;\;t \cdot \frac{a \cdot -4}{c}\\ \mathbf{elif}\;z \leq 1.6 \cdot 10^{+63}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{+91}:\\ \;\;\;\;-4 \cdot \frac{t}{\frac{c}{a}}\\ \mathbf{elif}\;z \leq 3.2 \cdot 10^{+98}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 16
Error55.29%
Cost976
\[\begin{array}{l} t_1 := -4 \cdot \frac{t}{\frac{c}{a}}\\ \mathbf{if}\;z \leq -1.02 \cdot 10^{+163}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -2 \cdot 10^{+128}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -4.6 \cdot 10^{+45}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 1.6 \cdot 10^{+44}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 17
Error55.18%
Cost976
\[\begin{array}{l} t_1 := t \cdot \frac{a \cdot -4}{c}\\ \mathbf{if}\;z \leq -2.2 \cdot 10^{+158}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -2.15 \cdot 10^{+128}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -8.5 \cdot 10^{+45}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 6.2 \cdot 10^{+45}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 18
Error55.17%
Cost976
\[\begin{array}{l} \mathbf{if}\;z \leq -4.3 \cdot 10^{+159}:\\ \;\;\;\;t \cdot \frac{a \cdot -4}{c}\\ \mathbf{elif}\;z \leq -1.05 \cdot 10^{+126}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -3.2 \cdot 10^{+45}:\\ \;\;\;\;-4 \cdot \frac{t \cdot a}{c}\\ \mathbf{elif}\;z \leq 3.6 \cdot 10^{+44}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]
Alternative 19
Error31.01%
Cost969
\[\begin{array}{l} \mathbf{if}\;z \leq -3.8 \cdot 10^{+91} \lor \neg \left(z \leq 1.2 \cdot 10^{+35}\right):\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(t \cdot a\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \end{array} \]
Alternative 20
Error55.53%
Cost713
\[\begin{array}{l} \mathbf{if}\;z \leq -9 \cdot 10^{+157} \lor \neg \left(z \leq 9 \cdot 10^{+43}\right):\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \end{array} \]
Alternative 21
Error65.62%
Cost585
\[\begin{array}{l} \mathbf{if}\;c \leq -2.2 \cdot 10^{-39} \lor \neg \left(c \leq 4.6 \cdot 10^{-38}\right):\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{z}}{c}\\ \end{array} \]
Alternative 22
Error67.62%
Cost320
\[\frac{b}{z \cdot c} \]
Alternative 23
Error68.13%
Cost320
\[\frac{\frac{b}{c}}{z} \]

Error

Reproduce?

herbie shell --seed 2023102 
(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)))