Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, J

Percentage Accurate: 80.0% → 88.9%
Time: 17.8s
Alternatives: 18
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \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} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (/ (+ (- (* (* 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) {
	return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
real(8) function code(x, y, z, t, a, b, c)
    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
    code = ((((x * 9.0d0) * y) - (((z * 4.0d0) * t) * a)) + b) / (z * c)
end function
public static 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);
}
def code(x, y, z, t, a, b, c):
	return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c)
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 tmp = code(x, y, z, t, a, b, c)
	tmp = ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
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]
\begin{array}{l}

\\
\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}
\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 18 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: 80.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \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} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (/ (+ (- (* (* 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) {
	return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
real(8) function code(x, y, z, t, a, b, c)
    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
    code = ((((x * 9.0d0) * y) - (((z * 4.0d0) * t) * a)) + b) / (z * c)
end function
public static 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);
}
def code(x, y, z, t, a, b, c):
	return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c)
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 tmp = code(x, y, z, t, a, b, c)
	tmp = ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
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]
\begin{array}{l}

\\
\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}
\end{array}

Alternative 1: 88.9% accurate, 0.1× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -7 \cdot 10^{-35}:\\ \;\;\;\;\mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{z \cdot c}{y}}, \frac{b}{z \cdot c}\right)\right)\\ \mathbf{elif}\;z \leq 9 \cdot 10^{-13}:\\ \;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(t \cdot \frac{a}{c}, -4, \mathsf{fma}\left(\frac{x}{z}, \frac{9}{\frac{c}{y}}, \frac{\frac{b}{c}}{z}\right)\right)\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (<= z -7e-35)
   (fma -4.0 (/ a (/ c t)) (fma 9.0 (/ x (/ (* z c) y)) (/ b (* z c))))
   (if (<= z 9e-13)
     (/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c))
     (fma (* t (/ a c)) -4.0 (fma (/ x z) (/ 9.0 (/ c y)) (/ (/ b c) z))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if (z <= -7e-35) {
		tmp = fma(-4.0, (a / (c / t)), fma(9.0, (x / ((z * c) / y)), (b / (z * c))));
	} else if (z <= 9e-13) {
		tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
	} else {
		tmp = fma((t * (a / c)), -4.0, fma((x / z), (9.0 / (c / y)), ((b / c) / z)));
	}
	return tmp;
}
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if (z <= -7e-35)
		tmp = fma(-4.0, Float64(a / Float64(c / t)), fma(9.0, Float64(x / Float64(Float64(z * c) / y)), Float64(b / Float64(z * c))));
	elseif (z <= 9e-13)
		tmp = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c));
	else
		tmp = fma(Float64(t * Float64(a / c)), -4.0, fma(Float64(x / z), Float64(9.0 / Float64(c / y)), Float64(Float64(b / c) / z)));
	end
	return tmp
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[z, -7e-35], N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision] + N[(9.0 * N[(x / N[(N[(z * c), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision] + N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e-13], N[(N[(b + N[(N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * N[(t * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision], N[(N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision] * -4.0 + N[(N[(x / z), $MachinePrecision] * N[(9.0 / N[(c / y), $MachinePrecision]), $MachinePrecision] + N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7 \cdot 10^{-35}:\\
\;\;\;\;\mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{z \cdot c}{y}}, \frac{b}{z \cdot c}\right)\right)\\

\mathbf{elif}\;z \leq 9 \cdot 10^{-13}:\\
\;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -6.99999999999999992e-35

    1. Initial program 66.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. Step-by-step derivation
      1. associate-+l-66.9%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*72.5%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in x around 0 87.6%

      \[\leadsto \color{blue}{\left(9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right) - 4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. cancel-sign-sub-inv87.6%

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

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

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(-4, \frac{a \cdot t}{c}, 9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right)} \]
      5. associate-/l*87.2%

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

        \[\leadsto \mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \color{blue}{\mathsf{fma}\left(9, \frac{x \cdot y}{c \cdot z}, \frac{b}{c \cdot z}\right)}\right) \]
      7. associate-/l*90.0%

        \[\leadsto \mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \color{blue}{\frac{x}{\frac{c \cdot z}{y}}}, \frac{b}{c \cdot z}\right)\right) \]
      8. *-commutative90.0%

        \[\leadsto \mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{\color{blue}{z \cdot c}}{y}}, \frac{b}{c \cdot z}\right)\right) \]
      9. *-commutative90.0%

        \[\leadsto \mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{z \cdot c}{y}}, \frac{b}{\color{blue}{z \cdot c}}\right)\right) \]
    6. Simplified90.0%

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

    if -6.99999999999999992e-35 < z < 9e-13

    1. Initial program 98.0%

      \[\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 9e-13 < z

    1. Initial program 72.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. Step-by-step derivation
      1. associate-+l-72.6%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative72.6%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*72.6%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in x around 0 83.6%

      \[\leadsto \color{blue}{\left(9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right) - 4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. cancel-sign-sub-inv83.6%

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

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

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

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{a \cdot t}{c}, -4, 9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right)} \]
      6. associate-/l*81.9%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{a}{\frac{c}{t}}}, -4, 9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right) \]
      7. associate-/r/83.2%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{a}{c} \cdot t}, -4, 9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right) \]
      8. associate-*r/83.2%

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

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

        \[\leadsto \mathsf{fma}\left(\frac{a}{c} \cdot t, -4, \frac{\color{blue}{\left(x \cdot 9\right)} \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right) \]
      11. associate-*r*83.2%

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

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

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

        \[\leadsto \mathsf{fma}\left(\frac{a}{c} \cdot t, -4, \color{blue}{\mathsf{fma}\left(\frac{x}{z}, \frac{9 \cdot y}{c}, \frac{b}{c \cdot z}\right)}\right) \]
      15. associate-/l*87.8%

        \[\leadsto \mathsf{fma}\left(\frac{a}{c} \cdot t, -4, \mathsf{fma}\left(\frac{x}{z}, \color{blue}{\frac{9}{\frac{c}{y}}}, \frac{b}{c \cdot z}\right)\right) \]
      16. associate-/r*87.5%

        \[\leadsto \mathsf{fma}\left(\frac{a}{c} \cdot t, -4, \mathsf{fma}\left(\frac{x}{z}, \frac{9}{\frac{c}{y}}, \color{blue}{\frac{\frac{b}{c}}{z}}\right)\right) \]
    6. Simplified87.5%

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

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

Alternative 2: 89.0% accurate, 0.1× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -1.1 \cdot 10^{-44} \lor \neg \left(z \leq 5.2 \cdot 10^{+76}\right):\\ \;\;\;\;\mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{z \cdot c}{y}}, \frac{b}{z \cdot c}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= z -1.1e-44) (not (<= z 5.2e+76)))
   (fma -4.0 (/ a (/ c t)) (fma 9.0 (/ x (/ (* z c) y)) (/ b (* z c))))
   (/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -1.1e-44) || !(z <= 5.2e+76)) {
		tmp = fma(-4.0, (a / (c / t)), fma(9.0, (x / ((z * c) / y)), (b / (z * c))));
	} else {
		tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
	}
	return tmp;
}
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((z <= -1.1e-44) || !(z <= 5.2e+76))
		tmp = fma(-4.0, Float64(a / Float64(c / t)), fma(9.0, Float64(x / Float64(Float64(z * c) / y)), Float64(b / Float64(z * c))));
	else
		tmp = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c));
	end
	return tmp
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -1.1e-44], N[Not[LessEqual[z, 5.2e+76]], $MachinePrecision]], N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision] + N[(9.0 * N[(x / N[(N[(z * c), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision] + N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b + N[(N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * N[(t * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.1 \cdot 10^{-44} \lor \neg \left(z \leq 5.2 \cdot 10^{+76}\right):\\
\;\;\;\;\mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{z \cdot c}{y}}, \frac{b}{z \cdot c}\right)\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.10000000000000006e-44 or 5.1999999999999999e76 < z

    1. Initial program 67.0%

      \[\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. Step-by-step derivation
      1. associate-+l-67.0%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative67.0%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*71.6%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in x around 0 87.8%

      \[\leadsto \color{blue}{\left(9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right) - 4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. cancel-sign-sub-inv87.8%

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

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

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(-4, \frac{a \cdot t}{c}, 9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}\right)} \]
      5. associate-/l*87.6%

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

        \[\leadsto \mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \color{blue}{\mathsf{fma}\left(9, \frac{x \cdot y}{c \cdot z}, \frac{b}{c \cdot z}\right)}\right) \]
      7. associate-/l*90.3%

        \[\leadsto \mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \color{blue}{\frac{x}{\frac{c \cdot z}{y}}}, \frac{b}{c \cdot z}\right)\right) \]
      8. *-commutative90.3%

        \[\leadsto \mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{\color{blue}{z \cdot c}}{y}}, \frac{b}{c \cdot z}\right)\right) \]
      9. *-commutative90.3%

        \[\leadsto \mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{z \cdot c}{y}}, \frac{b}{\color{blue}{z \cdot c}}\right)\right) \]
    6. Simplified90.3%

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

    if -1.10000000000000006e-44 < z < 5.1999999999999999e76

    1. Initial program 96.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} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification93.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.1 \cdot 10^{-44} \lor \neg \left(z \leq 5.2 \cdot 10^{+76}\right):\\ \;\;\;\;\mathsf{fma}\left(-4, \frac{a}{\frac{c}{t}}, \mathsf{fma}\left(9, \frac{x}{\frac{z \cdot c}{y}}, \frac{b}{z \cdot c}\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\ \end{array} \]

Alternative 3: 86.6% accurate, 0.3× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} t_1 := \frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\ \mathbf{if}\;t_1 \leq 0:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(a \cdot t\right)\right)}{c}\\ \mathbf{elif}\;t_1 \leq \infty:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c))))
   (if (<= t_1 0.0)
     (* (/ 1.0 z) (/ (+ b (- (* x (* 9.0 y)) (* (* z 4.0) (* a t)))) c))
     (if (<= t_1 INFINITY) t_1 (* -4.0 (* t (/ a c)))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
	double tmp;
	if (t_1 <= 0.0) {
		tmp = (1.0 / z) * ((b + ((x * (9.0 * y)) - ((z * 4.0) * (a * t)))) / c);
	} else if (t_1 <= ((double) INFINITY)) {
		tmp = t_1;
	} else {
		tmp = -4.0 * (t * (a / c));
	}
	return tmp;
}
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
	double tmp;
	if (t_1 <= 0.0) {
		tmp = (1.0 / z) * ((b + ((x * (9.0 * y)) - ((z * 4.0) * (a * t)))) / c);
	} else if (t_1 <= Double.POSITIVE_INFINITY) {
		tmp = t_1;
	} else {
		tmp = -4.0 * (t * (a / c));
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	t_1 = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c)
	tmp = 0
	if t_1 <= 0.0:
		tmp = (1.0 / z) * ((b + ((x * (9.0 * y)) - ((z * 4.0) * (a * t)))) / c)
	elif t_1 <= math.inf:
		tmp = t_1
	else:
		tmp = -4.0 * (t * (a / c))
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	t_1 = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c))
	tmp = 0.0
	if (t_1 <= 0.0)
		tmp = Float64(Float64(1.0 / z) * Float64(Float64(b + Float64(Float64(x * Float64(9.0 * y)) - Float64(Float64(z * 4.0) * Float64(a * t)))) / c));
	elseif (t_1 <= Inf)
		tmp = t_1;
	else
		tmp = Float64(-4.0 * Float64(t * Float64(a / c)));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
	tmp = 0.0;
	if (t_1 <= 0.0)
		tmp = (1.0 / z) * ((b + ((x * (9.0 * y)) - ((z * 4.0) * (a * t)))) / c);
	elseif (t_1 <= Inf)
		tmp = t_1;
	else
		tmp = -4.0 * (t * (a / c));
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(N[(b + N[(N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * N[(t * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 0.0], N[(N[(1.0 / z), $MachinePrecision] * N[(N[(b + N[(N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision] - N[(N[(z * 4.0), $MachinePrecision] * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, Infinity], t$95$1, N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
t_1 := \frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\
\mathbf{if}\;t_1 \leq 0:\\
\;\;\;\;\frac{1}{z} \cdot \frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(a \cdot t\right)\right)}{c}\\

\mathbf{elif}\;t_1 \leq \infty:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c)) < -0.0

    1. Initial program 83.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} \]
    2. Step-by-step derivation
      1. associate-+l-83.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative83.1%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*83.9%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. *-un-lft-identity83.1%

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

        \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
      3. associate-+l-87.1%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{c} \]
      4. associate-*r*87.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{c} \]
      5. associate-+l-87.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{c} \]
      6. associate-*l*87.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{c} \]
      7. associate-*r*87.1%

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

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

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

    1. Initial program 90.7%

      \[\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 +inf.0 < (/.f64 (+.f64 (-.f64 (*.f64 (*.f64 x 9) y) (*.f64 (*.f64 (*.f64 z 4) t) a)) b) (*.f64 z c))

    1. Initial program 0.0%

      \[\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. Step-by-step derivation
      1. associate-+l-0.0%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative0.0%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*12.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 70.6%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative70.6%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*81.1%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
      3. associate-/r/78.9%

        \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right)} \cdot -4 \]
    6. Simplified78.9%

      \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right) \cdot -4} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification88.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c} \leq 0:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(a \cdot t\right)\right)}{c}\\ \mathbf{elif}\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c} \leq \infty:\\ \;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \end{array} \]

Alternative 4: 86.7% accurate, 0.8× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -2.8 \cdot 10^{-57} \lor \neg \left(z \leq 10^{-131}\right):\\ \;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(a \cdot t\right)\right)}{z} \cdot \frac{1}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= z -2.8e-57) (not (<= z 1e-131)))
   (* (/ (+ b (- (* x (* 9.0 y)) (* (* z 4.0) (* a t)))) z) (/ 1.0 c))
   (/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -2.8e-57) || !(z <= 1e-131)) {
		tmp = ((b + ((x * (9.0 * y)) - ((z * 4.0) * (a * t)))) / z) * (1.0 / c);
	} else {
		tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: tmp
    if ((z <= (-2.8d-57)) .or. (.not. (z <= 1d-131))) then
        tmp = ((b + ((x * (9.0d0 * y)) - ((z * 4.0d0) * (a * t)))) / z) * (1.0d0 / c)
    else
        tmp = (b + ((y * (9.0d0 * x)) - (a * (t * (z * 4.0d0))))) / (z * c)
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -2.8e-57) || !(z <= 1e-131)) {
		tmp = ((b + ((x * (9.0 * y)) - ((z * 4.0) * (a * t)))) / z) * (1.0 / c);
	} else {
		tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (z <= -2.8e-57) or not (z <= 1e-131):
		tmp = ((b + ((x * (9.0 * y)) - ((z * 4.0) * (a * t)))) / z) * (1.0 / c)
	else:
		tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c)
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((z <= -2.8e-57) || !(z <= 1e-131))
		tmp = Float64(Float64(Float64(b + Float64(Float64(x * Float64(9.0 * y)) - Float64(Float64(z * 4.0) * Float64(a * t)))) / z) * Float64(1.0 / c));
	else
		tmp = Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((z <= -2.8e-57) || ~((z <= 1e-131)))
		tmp = ((b + ((x * (9.0 * y)) - ((z * 4.0) * (a * t)))) / z) * (1.0 / c);
	else
		tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -2.8e-57], N[Not[LessEqual[z, 1e-131]], $MachinePrecision]], N[(N[(N[(b + N[(N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision] - N[(N[(z * 4.0), $MachinePrecision] * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] * N[(1.0 / c), $MachinePrecision]), $MachinePrecision], N[(N[(b + N[(N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * N[(t * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.8 \cdot 10^{-57} \lor \neg \left(z \leq 10^{-131}\right):\\
\;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(a \cdot t\right)\right)}{z} \cdot \frac{1}{c}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -2.7999999999999999e-57 or 9.9999999999999999e-132 < z

    1. Initial program 73.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. Step-by-step derivation
      1. associate-+l-73.9%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*76.6%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. associate-/r*86.4%

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

        \[\leadsto \color{blue}{\frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{z} \cdot \frac{1}{c}} \]
      3. associate-+l-86.4%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{z} \cdot \frac{1}{c} \]
      4. associate-*r*80.5%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{z} \cdot \frac{1}{c} \]
      5. associate-+l-80.5%

        \[\leadsto \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{z} \cdot \frac{1}{c} \]
      6. associate-*l*80.5%

        \[\leadsto \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 \frac{1}{c} \]
      7. associate-*r*86.4%

        \[\leadsto \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 \frac{1}{c} \]
    5. Applied egg-rr86.4%

      \[\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 \frac{1}{c}} \]

    if -2.7999999999999999e-57 < z < 9.9999999999999999e-132

    1. Initial program 97.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} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification91.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.8 \cdot 10^{-57} \lor \neg \left(z \leq 10^{-131}\right):\\ \;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(a \cdot t\right)\right)}{z} \cdot \frac{1}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\ \end{array} \]

Alternative 5: 49.8% accurate, 0.9× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} t_1 := y \cdot \frac{9}{c \cdot \frac{z}{x}}\\ t_2 := -4 \cdot \frac{a}{\frac{c}{t}}\\ t_3 := \frac{b}{z \cdot c}\\ \mathbf{if}\;z \leq -5.6 \cdot 10^{+46}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -3.2 \cdot 10^{-103}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -3 \cdot 10^{-165}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;z \leq -2.8 \cdot 10^{-226}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 9.8 \cdot 10^{-185}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;z \leq 1.05 \cdot 10^{+86}:\\ \;\;\;\;9 \cdot \left(\frac{x}{z} \cdot \frac{y}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (* y (/ 9.0 (* c (/ z x)))))
        (t_2 (* -4.0 (/ a (/ c t))))
        (t_3 (/ b (* z c))))
   (if (<= z -5.6e+46)
     t_2
     (if (<= z -3.2e-103)
       t_1
       (if (<= z -3e-165)
         t_3
         (if (<= z -2.8e-226)
           t_1
           (if (<= z 9.8e-185)
             t_3
             (if (<= z 1.05e+86) (* 9.0 (* (/ x z) (/ y c))) t_2))))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = y * (9.0 / (c * (z / x)));
	double t_2 = -4.0 * (a / (c / t));
	double t_3 = b / (z * c);
	double tmp;
	if (z <= -5.6e+46) {
		tmp = t_2;
	} else if (z <= -3.2e-103) {
		tmp = t_1;
	} else if (z <= -3e-165) {
		tmp = t_3;
	} else if (z <= -2.8e-226) {
		tmp = t_1;
	} else if (z <= 9.8e-185) {
		tmp = t_3;
	} else if (z <= 1.05e+86) {
		tmp = 9.0 * ((x / z) * (y / c));
	} else {
		tmp = t_2;
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = y * (9.0d0 / (c * (z / x)))
    t_2 = (-4.0d0) * (a / (c / t))
    t_3 = b / (z * c)
    if (z <= (-5.6d+46)) then
        tmp = t_2
    else if (z <= (-3.2d-103)) then
        tmp = t_1
    else if (z <= (-3d-165)) then
        tmp = t_3
    else if (z <= (-2.8d-226)) then
        tmp = t_1
    else if (z <= 9.8d-185) then
        tmp = t_3
    else if (z <= 1.05d+86) then
        tmp = 9.0d0 * ((x / z) * (y / c))
    else
        tmp = t_2
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = y * (9.0 / (c * (z / x)));
	double t_2 = -4.0 * (a / (c / t));
	double t_3 = b / (z * c);
	double tmp;
	if (z <= -5.6e+46) {
		tmp = t_2;
	} else if (z <= -3.2e-103) {
		tmp = t_1;
	} else if (z <= -3e-165) {
		tmp = t_3;
	} else if (z <= -2.8e-226) {
		tmp = t_1;
	} else if (z <= 9.8e-185) {
		tmp = t_3;
	} else if (z <= 1.05e+86) {
		tmp = 9.0 * ((x / z) * (y / c));
	} else {
		tmp = t_2;
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	t_1 = y * (9.0 / (c * (z / x)))
	t_2 = -4.0 * (a / (c / t))
	t_3 = b / (z * c)
	tmp = 0
	if z <= -5.6e+46:
		tmp = t_2
	elif z <= -3.2e-103:
		tmp = t_1
	elif z <= -3e-165:
		tmp = t_3
	elif z <= -2.8e-226:
		tmp = t_1
	elif z <= 9.8e-185:
		tmp = t_3
	elif z <= 1.05e+86:
		tmp = 9.0 * ((x / z) * (y / c))
	else:
		tmp = t_2
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	t_1 = Float64(y * Float64(9.0 / Float64(c * Float64(z / x))))
	t_2 = Float64(-4.0 * Float64(a / Float64(c / t)))
	t_3 = Float64(b / Float64(z * c))
	tmp = 0.0
	if (z <= -5.6e+46)
		tmp = t_2;
	elseif (z <= -3.2e-103)
		tmp = t_1;
	elseif (z <= -3e-165)
		tmp = t_3;
	elseif (z <= -2.8e-226)
		tmp = t_1;
	elseif (z <= 9.8e-185)
		tmp = t_3;
	elseif (z <= 1.05e+86)
		tmp = Float64(9.0 * Float64(Float64(x / z) * Float64(y / c)));
	else
		tmp = t_2;
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = y * (9.0 / (c * (z / x)));
	t_2 = -4.0 * (a / (c / t));
	t_3 = b / (z * c);
	tmp = 0.0;
	if (z <= -5.6e+46)
		tmp = t_2;
	elseif (z <= -3.2e-103)
		tmp = t_1;
	elseif (z <= -3e-165)
		tmp = t_3;
	elseif (z <= -2.8e-226)
		tmp = t_1;
	elseif (z <= 9.8e-185)
		tmp = t_3;
	elseif (z <= 1.05e+86)
		tmp = 9.0 * ((x / z) * (y / c));
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(y * N[(9.0 / N[(c * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -5.6e+46], t$95$2, If[LessEqual[z, -3.2e-103], t$95$1, If[LessEqual[z, -3e-165], t$95$3, If[LessEqual[z, -2.8e-226], t$95$1, If[LessEqual[z, 9.8e-185], t$95$3, If[LessEqual[z, 1.05e+86], N[(9.0 * N[(N[(x / z), $MachinePrecision] * N[(y / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
t_1 := y \cdot \frac{9}{c \cdot \frac{z}{x}}\\
t_2 := -4 \cdot \frac{a}{\frac{c}{t}}\\
t_3 := \frac{b}{z \cdot c}\\
\mathbf{if}\;z \leq -5.6 \cdot 10^{+46}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq -3.2 \cdot 10^{-103}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -3 \cdot 10^{-165}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;z \leq -2.8 \cdot 10^{-226}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq 9.8 \cdot 10^{-185}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;z \leq 1.05 \cdot 10^{+86}:\\
\;\;\;\;9 \cdot \left(\frac{x}{z} \cdot \frac{y}{c}\right)\\

\mathbf{else}:\\
\;\;\;\;t_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -5.60000000000000037e46 or 1.0499999999999999e86 < z

    1. Initial program 64.7%

      \[\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. Step-by-step derivation
      1. associate-+l-64.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative64.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*70.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 62.0%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative62.0%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*63.1%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
    6. Simplified63.1%

      \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}} \cdot -4} \]

    if -5.60000000000000037e46 < z < -3.19999999999999976e-103 or -2.99999999999999979e-165 < z < -2.80000000000000008e-226

    1. Initial program 89.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} \]
    2. Step-by-step derivation
      1. associate-+l-89.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative89.1%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*87.9%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around 0 76.3%

      \[\leadsto \color{blue}{\frac{b + 9 \cdot \left(x \cdot y\right)}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative76.3%

        \[\leadsto \frac{b + 9 \cdot \left(x \cdot y\right)}{\color{blue}{z \cdot c}} \]
    6. Simplified76.3%

      \[\leadsto \color{blue}{\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}} \]
    7. Taylor expanded in b around 0 65.6%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}} \]
    8. Step-by-step derivation
      1. fma-def65.6%

        \[\leadsto \color{blue}{\mathsf{fma}\left(9, \frac{x \cdot y}{c \cdot z}, \frac{b}{c \cdot z}\right)} \]
      2. associate-/l*73.8%

        \[\leadsto \mathsf{fma}\left(9, \color{blue}{\frac{x}{\frac{c \cdot z}{y}}}, \frac{b}{c \cdot z}\right) \]
      3. *-commutative73.8%

        \[\leadsto \mathsf{fma}\left(9, \frac{x}{\frac{\color{blue}{z \cdot c}}{y}}, \frac{b}{c \cdot z}\right) \]
      4. associate-/r/70.3%

        \[\leadsto \mathsf{fma}\left(9, \color{blue}{\frac{x}{z \cdot c} \cdot y}, \frac{b}{c \cdot z}\right) \]
      5. *-commutative70.3%

        \[\leadsto \mathsf{fma}\left(9, \frac{x}{\color{blue}{c \cdot z}} \cdot y, \frac{b}{c \cdot z}\right) \]
    9. Simplified70.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(9, \frac{x}{c \cdot z} \cdot y, \frac{b}{c \cdot z}\right)} \]
    10. Taylor expanded in x around inf 53.2%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z}} \]
    11. Step-by-step derivation
      1. *-commutative53.2%

        \[\leadsto 9 \cdot \frac{\color{blue}{y \cdot x}}{c \cdot z} \]
      2. times-frac55.0%

        \[\leadsto 9 \cdot \color{blue}{\left(\frac{y}{c} \cdot \frac{x}{z}\right)} \]
      3. associate-*l*55.0%

        \[\leadsto \color{blue}{\left(9 \cdot \frac{y}{c}\right) \cdot \frac{x}{z}} \]
      4. associate-*r/55.1%

        \[\leadsto \color{blue}{\frac{9 \cdot y}{c}} \cdot \frac{x}{z} \]
      5. associate-*l/55.1%

        \[\leadsto \color{blue}{\left(\frac{9}{c} \cdot y\right)} \cdot \frac{x}{z} \]
      6. *-commutative55.1%

        \[\leadsto \color{blue}{\left(y \cdot \frac{9}{c}\right)} \cdot \frac{x}{z} \]
      7. associate-*l*53.1%

        \[\leadsto \color{blue}{y \cdot \left(\frac{9}{c} \cdot \frac{x}{z}\right)} \]
      8. *-commutative53.1%

        \[\leadsto y \cdot \color{blue}{\left(\frac{x}{z} \cdot \frac{9}{c}\right)} \]
      9. associate-*r/53.0%

        \[\leadsto y \cdot \color{blue}{\frac{\frac{x}{z} \cdot 9}{c}} \]
      10. *-commutative53.0%

        \[\leadsto y \cdot \frac{\color{blue}{9 \cdot \frac{x}{z}}}{c} \]
      11. associate-/l*53.0%

        \[\leadsto y \cdot \color{blue}{\frac{9}{\frac{c}{\frac{x}{z}}}} \]
      12. associate-/l*57.9%

        \[\leadsto y \cdot \frac{9}{\color{blue}{\frac{c \cdot z}{x}}} \]
      13. associate-*r/53.9%

        \[\leadsto y \cdot \frac{9}{\color{blue}{c \cdot \frac{z}{x}}} \]
    12. Simplified53.9%

      \[\leadsto \color{blue}{y \cdot \frac{9}{c \cdot \frac{z}{x}}} \]

    if -3.19999999999999976e-103 < z < -2.99999999999999979e-165 or -2.80000000000000008e-226 < z < 9.8000000000000005e-185

    1. Initial program 99.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} \]
    2. Step-by-step derivation
      1. associate-+l-99.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative99.1%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*99.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 65.8%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative65.8%

        \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
    6. Simplified65.8%

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]

    if 9.8000000000000005e-185 < z < 1.0499999999999999e86

    1. Initial program 93.3%

      \[\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. Step-by-step derivation
      1. associate-+l-93.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative93.3%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*91.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. *-un-lft-identity93.3%

        \[\leadsto \frac{\color{blue}{1 \cdot \left(\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b\right)}}{z \cdot c} \]
      2. times-frac93.6%

        \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
      3. associate-+l-93.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{c} \]
      4. associate-*r*93.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{c} \]
      5. associate-+l-93.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{c} \]
      6. associate-*l*93.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{c} \]
      7. associate-*r*93.6%

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

      \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
    6. Step-by-step derivation
      1. div-inv93.5%

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

      \[\leadsto \frac{1}{z} \cdot \color{blue}{\left(\left(\left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b\right) \cdot \frac{1}{c}\right)} \]
    8. Taylor expanded in x around inf 53.1%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z}} \]
    9. Step-by-step derivation
      1. *-commutative53.1%

        \[\leadsto 9 \cdot \frac{x \cdot y}{\color{blue}{z \cdot c}} \]
      2. times-frac58.6%

        \[\leadsto 9 \cdot \color{blue}{\left(\frac{x}{z} \cdot \frac{y}{c}\right)} \]
    10. Simplified58.6%

      \[\leadsto \color{blue}{9 \cdot \left(\frac{x}{z} \cdot \frac{y}{c}\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification61.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.6 \cdot 10^{+46}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;z \leq -3.2 \cdot 10^{-103}:\\ \;\;\;\;y \cdot \frac{9}{c \cdot \frac{z}{x}}\\ \mathbf{elif}\;z \leq -3 \cdot 10^{-165}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;z \leq -2.8 \cdot 10^{-226}:\\ \;\;\;\;y \cdot \frac{9}{c \cdot \frac{z}{x}}\\ \mathbf{elif}\;z \leq 9.8 \cdot 10^{-185}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;z \leq 1.05 \cdot 10^{+86}:\\ \;\;\;\;9 \cdot \left(\frac{x}{z} \cdot \frac{y}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]

Alternative 6: 50.1% accurate, 0.9× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} t_1 := y \cdot \frac{9}{c \cdot \frac{z}{x}}\\ t_2 := -4 \cdot \frac{a}{\frac{c}{t}}\\ t_3 := \frac{b}{z \cdot c}\\ \mathbf{if}\;z \leq -4 \cdot 10^{+45}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -1.38 \cdot 10^{-104}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -8 \cdot 10^{-168}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;z \leq -1.15 \cdot 10^{-226}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{-184}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;z \leq 9 \cdot 10^{+83}:\\ \;\;\;\;\frac{x}{z} \cdot \frac{9}{\frac{c}{y}}\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (* y (/ 9.0 (* c (/ z x)))))
        (t_2 (* -4.0 (/ a (/ c t))))
        (t_3 (/ b (* z c))))
   (if (<= z -4e+45)
     t_2
     (if (<= z -1.38e-104)
       t_1
       (if (<= z -8e-168)
         t_3
         (if (<= z -1.15e-226)
           t_1
           (if (<= z 2.8e-184)
             t_3
             (if (<= z 9e+83) (* (/ x z) (/ 9.0 (/ c y))) t_2))))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = y * (9.0 / (c * (z / x)));
	double t_2 = -4.0 * (a / (c / t));
	double t_3 = b / (z * c);
	double tmp;
	if (z <= -4e+45) {
		tmp = t_2;
	} else if (z <= -1.38e-104) {
		tmp = t_1;
	} else if (z <= -8e-168) {
		tmp = t_3;
	} else if (z <= -1.15e-226) {
		tmp = t_1;
	} else if (z <= 2.8e-184) {
		tmp = t_3;
	} else if (z <= 9e+83) {
		tmp = (x / z) * (9.0 / (c / y));
	} else {
		tmp = t_2;
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = y * (9.0d0 / (c * (z / x)))
    t_2 = (-4.0d0) * (a / (c / t))
    t_3 = b / (z * c)
    if (z <= (-4d+45)) then
        tmp = t_2
    else if (z <= (-1.38d-104)) then
        tmp = t_1
    else if (z <= (-8d-168)) then
        tmp = t_3
    else if (z <= (-1.15d-226)) then
        tmp = t_1
    else if (z <= 2.8d-184) then
        tmp = t_3
    else if (z <= 9d+83) then
        tmp = (x / z) * (9.0d0 / (c / y))
    else
        tmp = t_2
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = y * (9.0 / (c * (z / x)));
	double t_2 = -4.0 * (a / (c / t));
	double t_3 = b / (z * c);
	double tmp;
	if (z <= -4e+45) {
		tmp = t_2;
	} else if (z <= -1.38e-104) {
		tmp = t_1;
	} else if (z <= -8e-168) {
		tmp = t_3;
	} else if (z <= -1.15e-226) {
		tmp = t_1;
	} else if (z <= 2.8e-184) {
		tmp = t_3;
	} else if (z <= 9e+83) {
		tmp = (x / z) * (9.0 / (c / y));
	} else {
		tmp = t_2;
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	t_1 = y * (9.0 / (c * (z / x)))
	t_2 = -4.0 * (a / (c / t))
	t_3 = b / (z * c)
	tmp = 0
	if z <= -4e+45:
		tmp = t_2
	elif z <= -1.38e-104:
		tmp = t_1
	elif z <= -8e-168:
		tmp = t_3
	elif z <= -1.15e-226:
		tmp = t_1
	elif z <= 2.8e-184:
		tmp = t_3
	elif z <= 9e+83:
		tmp = (x / z) * (9.0 / (c / y))
	else:
		tmp = t_2
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	t_1 = Float64(y * Float64(9.0 / Float64(c * Float64(z / x))))
	t_2 = Float64(-4.0 * Float64(a / Float64(c / t)))
	t_3 = Float64(b / Float64(z * c))
	tmp = 0.0
	if (z <= -4e+45)
		tmp = t_2;
	elseif (z <= -1.38e-104)
		tmp = t_1;
	elseif (z <= -8e-168)
		tmp = t_3;
	elseif (z <= -1.15e-226)
		tmp = t_1;
	elseif (z <= 2.8e-184)
		tmp = t_3;
	elseif (z <= 9e+83)
		tmp = Float64(Float64(x / z) * Float64(9.0 / Float64(c / y)));
	else
		tmp = t_2;
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = y * (9.0 / (c * (z / x)));
	t_2 = -4.0 * (a / (c / t));
	t_3 = b / (z * c);
	tmp = 0.0;
	if (z <= -4e+45)
		tmp = t_2;
	elseif (z <= -1.38e-104)
		tmp = t_1;
	elseif (z <= -8e-168)
		tmp = t_3;
	elseif (z <= -1.15e-226)
		tmp = t_1;
	elseif (z <= 2.8e-184)
		tmp = t_3;
	elseif (z <= 9e+83)
		tmp = (x / z) * (9.0 / (c / y));
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(y * N[(9.0 / N[(c * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -4e+45], t$95$2, If[LessEqual[z, -1.38e-104], t$95$1, If[LessEqual[z, -8e-168], t$95$3, If[LessEqual[z, -1.15e-226], t$95$1, If[LessEqual[z, 2.8e-184], t$95$3, If[LessEqual[z, 9e+83], N[(N[(x / z), $MachinePrecision] * N[(9.0 / N[(c / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
t_1 := y \cdot \frac{9}{c \cdot \frac{z}{x}}\\
t_2 := -4 \cdot \frac{a}{\frac{c}{t}}\\
t_3 := \frac{b}{z \cdot c}\\
\mathbf{if}\;z \leq -4 \cdot 10^{+45}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq -1.38 \cdot 10^{-104}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -8 \cdot 10^{-168}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;z \leq -1.15 \cdot 10^{-226}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq 2.8 \cdot 10^{-184}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;z \leq 9 \cdot 10^{+83}:\\
\;\;\;\;\frac{x}{z} \cdot \frac{9}{\frac{c}{y}}\\

\mathbf{else}:\\
\;\;\;\;t_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -3.9999999999999997e45 or 8.9999999999999999e83 < z

    1. Initial program 64.7%

      \[\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. Step-by-step derivation
      1. associate-+l-64.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative64.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*70.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 62.0%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative62.0%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*63.1%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
    6. Simplified63.1%

      \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}} \cdot -4} \]

    if -3.9999999999999997e45 < z < -1.38000000000000006e-104 or -8.0000000000000004e-168 < z < -1.15e-226

    1. Initial program 89.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} \]
    2. Step-by-step derivation
      1. associate-+l-89.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative89.1%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*87.9%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around 0 76.3%

      \[\leadsto \color{blue}{\frac{b + 9 \cdot \left(x \cdot y\right)}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative76.3%

        \[\leadsto \frac{b + 9 \cdot \left(x \cdot y\right)}{\color{blue}{z \cdot c}} \]
    6. Simplified76.3%

      \[\leadsto \color{blue}{\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}} \]
    7. Taylor expanded in b around 0 65.6%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z} + \frac{b}{c \cdot z}} \]
    8. Step-by-step derivation
      1. fma-def65.6%

        \[\leadsto \color{blue}{\mathsf{fma}\left(9, \frac{x \cdot y}{c \cdot z}, \frac{b}{c \cdot z}\right)} \]
      2. associate-/l*73.8%

        \[\leadsto \mathsf{fma}\left(9, \color{blue}{\frac{x}{\frac{c \cdot z}{y}}}, \frac{b}{c \cdot z}\right) \]
      3. *-commutative73.8%

        \[\leadsto \mathsf{fma}\left(9, \frac{x}{\frac{\color{blue}{z \cdot c}}{y}}, \frac{b}{c \cdot z}\right) \]
      4. associate-/r/70.3%

        \[\leadsto \mathsf{fma}\left(9, \color{blue}{\frac{x}{z \cdot c} \cdot y}, \frac{b}{c \cdot z}\right) \]
      5. *-commutative70.3%

        \[\leadsto \mathsf{fma}\left(9, \frac{x}{\color{blue}{c \cdot z}} \cdot y, \frac{b}{c \cdot z}\right) \]
    9. Simplified70.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(9, \frac{x}{c \cdot z} \cdot y, \frac{b}{c \cdot z}\right)} \]
    10. Taylor expanded in x around inf 53.2%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z}} \]
    11. Step-by-step derivation
      1. *-commutative53.2%

        \[\leadsto 9 \cdot \frac{\color{blue}{y \cdot x}}{c \cdot z} \]
      2. times-frac55.0%

        \[\leadsto 9 \cdot \color{blue}{\left(\frac{y}{c} \cdot \frac{x}{z}\right)} \]
      3. associate-*l*55.0%

        \[\leadsto \color{blue}{\left(9 \cdot \frac{y}{c}\right) \cdot \frac{x}{z}} \]
      4. associate-*r/55.1%

        \[\leadsto \color{blue}{\frac{9 \cdot y}{c}} \cdot \frac{x}{z} \]
      5. associate-*l/55.1%

        \[\leadsto \color{blue}{\left(\frac{9}{c} \cdot y\right)} \cdot \frac{x}{z} \]
      6. *-commutative55.1%

        \[\leadsto \color{blue}{\left(y \cdot \frac{9}{c}\right)} \cdot \frac{x}{z} \]
      7. associate-*l*53.1%

        \[\leadsto \color{blue}{y \cdot \left(\frac{9}{c} \cdot \frac{x}{z}\right)} \]
      8. *-commutative53.1%

        \[\leadsto y \cdot \color{blue}{\left(\frac{x}{z} \cdot \frac{9}{c}\right)} \]
      9. associate-*r/53.0%

        \[\leadsto y \cdot \color{blue}{\frac{\frac{x}{z} \cdot 9}{c}} \]
      10. *-commutative53.0%

        \[\leadsto y \cdot \frac{\color{blue}{9 \cdot \frac{x}{z}}}{c} \]
      11. associate-/l*53.0%

        \[\leadsto y \cdot \color{blue}{\frac{9}{\frac{c}{\frac{x}{z}}}} \]
      12. associate-/l*57.9%

        \[\leadsto y \cdot \frac{9}{\color{blue}{\frac{c \cdot z}{x}}} \]
      13. associate-*r/53.9%

        \[\leadsto y \cdot \frac{9}{\color{blue}{c \cdot \frac{z}{x}}} \]
    12. Simplified53.9%

      \[\leadsto \color{blue}{y \cdot \frac{9}{c \cdot \frac{z}{x}}} \]

    if -1.38000000000000006e-104 < z < -8.0000000000000004e-168 or -1.15e-226 < z < 2.7999999999999998e-184

    1. Initial program 99.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} \]
    2. Step-by-step derivation
      1. associate-+l-99.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative99.1%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*99.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 65.8%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative65.8%

        \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
    6. Simplified65.8%

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]

    if 2.7999999999999998e-184 < z < 8.9999999999999999e83

    1. Initial program 93.3%

      \[\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. Step-by-step derivation
      1. associate-+l-93.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative93.3%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*91.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in x around inf 53.1%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z}} \]
    5. Step-by-step derivation
      1. associate-*r/53.1%

        \[\leadsto \color{blue}{\frac{9 \cdot \left(x \cdot y\right)}{c \cdot z}} \]
      2. associate-*r*53.1%

        \[\leadsto \frac{\color{blue}{\left(9 \cdot x\right) \cdot y}}{c \cdot z} \]
      3. *-commutative53.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right)} \cdot y}{c \cdot z} \]
      4. associate-*r*53.1%

        \[\leadsto \frac{\color{blue}{x \cdot \left(9 \cdot y\right)}}{c \cdot z} \]
      5. *-commutative53.1%

        \[\leadsto \frac{x \cdot \left(9 \cdot y\right)}{\color{blue}{z \cdot c}} \]
      6. times-frac58.7%

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \frac{9 \cdot y}{c}} \]
      7. associate-/l*58.8%

        \[\leadsto \frac{x}{z} \cdot \color{blue}{\frac{9}{\frac{c}{y}}} \]
    6. Simplified58.8%

      \[\leadsto \color{blue}{\frac{x}{z} \cdot \frac{9}{\frac{c}{y}}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification61.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4 \cdot 10^{+45}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;z \leq -1.38 \cdot 10^{-104}:\\ \;\;\;\;y \cdot \frac{9}{c \cdot \frac{z}{x}}\\ \mathbf{elif}\;z \leq -8 \cdot 10^{-168}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;z \leq -1.15 \cdot 10^{-226}:\\ \;\;\;\;y \cdot \frac{9}{c \cdot \frac{z}{x}}\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{-184}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;z \leq 9 \cdot 10^{+83}:\\ \;\;\;\;\frac{x}{z} \cdot \frac{9}{\frac{c}{y}}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]

Alternative 7: 67.8% accurate, 0.9× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} t_1 := b + 9 \cdot \left(x \cdot y\right)\\ t_2 := -4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{if}\;z \leq -4.5 \cdot 10^{+210}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -7.5 \cdot 10^{+151}:\\ \;\;\;\;\frac{t_1}{z \cdot c}\\ \mathbf{elif}\;z \leq -4.2 \cdot 10^{+137}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{+90}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{t_1}{c}\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (+ b (* 9.0 (* x y)))) (t_2 (* -4.0 (/ a (/ c t)))))
   (if (<= z -4.5e+210)
     t_2
     (if (<= z -7.5e+151)
       (/ t_1 (* z c))
       (if (<= z -4.2e+137)
         (* -4.0 (/ (* a t) c))
         (if (<= z 5e+90) (* (/ 1.0 z) (/ t_1 c)) t_2))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = b + (9.0 * (x * y));
	double t_2 = -4.0 * (a / (c / t));
	double tmp;
	if (z <= -4.5e+210) {
		tmp = t_2;
	} else if (z <= -7.5e+151) {
		tmp = t_1 / (z * c);
	} else if (z <= -4.2e+137) {
		tmp = -4.0 * ((a * t) / c);
	} else if (z <= 5e+90) {
		tmp = (1.0 / z) * (t_1 / c);
	} else {
		tmp = t_2;
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = b + (9.0d0 * (x * y))
    t_2 = (-4.0d0) * (a / (c / t))
    if (z <= (-4.5d+210)) then
        tmp = t_2
    else if (z <= (-7.5d+151)) then
        tmp = t_1 / (z * c)
    else if (z <= (-4.2d+137)) then
        tmp = (-4.0d0) * ((a * t) / c)
    else if (z <= 5d+90) then
        tmp = (1.0d0 / z) * (t_1 / c)
    else
        tmp = t_2
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = b + (9.0 * (x * y));
	double t_2 = -4.0 * (a / (c / t));
	double tmp;
	if (z <= -4.5e+210) {
		tmp = t_2;
	} else if (z <= -7.5e+151) {
		tmp = t_1 / (z * c);
	} else if (z <= -4.2e+137) {
		tmp = -4.0 * ((a * t) / c);
	} else if (z <= 5e+90) {
		tmp = (1.0 / z) * (t_1 / c);
	} else {
		tmp = t_2;
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	t_1 = b + (9.0 * (x * y))
	t_2 = -4.0 * (a / (c / t))
	tmp = 0
	if z <= -4.5e+210:
		tmp = t_2
	elif z <= -7.5e+151:
		tmp = t_1 / (z * c)
	elif z <= -4.2e+137:
		tmp = -4.0 * ((a * t) / c)
	elif z <= 5e+90:
		tmp = (1.0 / z) * (t_1 / c)
	else:
		tmp = t_2
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	t_1 = Float64(b + Float64(9.0 * Float64(x * y)))
	t_2 = Float64(-4.0 * Float64(a / Float64(c / t)))
	tmp = 0.0
	if (z <= -4.5e+210)
		tmp = t_2;
	elseif (z <= -7.5e+151)
		tmp = Float64(t_1 / Float64(z * c));
	elseif (z <= -4.2e+137)
		tmp = Float64(-4.0 * Float64(Float64(a * t) / c));
	elseif (z <= 5e+90)
		tmp = Float64(Float64(1.0 / z) * Float64(t_1 / c));
	else
		tmp = t_2;
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = b + (9.0 * (x * y));
	t_2 = -4.0 * (a / (c / t));
	tmp = 0.0;
	if (z <= -4.5e+210)
		tmp = t_2;
	elseif (z <= -7.5e+151)
		tmp = t_1 / (z * c);
	elseif (z <= -4.2e+137)
		tmp = -4.0 * ((a * t) / c);
	elseif (z <= 5e+90)
		tmp = (1.0 / z) * (t_1 / c);
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(b + N[(9.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -4.5e+210], t$95$2, If[LessEqual[z, -7.5e+151], N[(t$95$1 / N[(z * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -4.2e+137], N[(-4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5e+90], N[(N[(1.0 / z), $MachinePrecision] * N[(t$95$1 / c), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
t_1 := b + 9 \cdot \left(x \cdot y\right)\\
t_2 := -4 \cdot \frac{a}{\frac{c}{t}}\\
\mathbf{if}\;z \leq -4.5 \cdot 10^{+210}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq -7.5 \cdot 10^{+151}:\\
\;\;\;\;\frac{t_1}{z \cdot c}\\

\mathbf{elif}\;z \leq -4.2 \cdot 10^{+137}:\\
\;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\

\mathbf{elif}\;z \leq 5 \cdot 10^{+90}:\\
\;\;\;\;\frac{1}{z} \cdot \frac{t_1}{c}\\

\mathbf{else}:\\
\;\;\;\;t_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -4.50000000000000004e210 or 5.0000000000000004e90 < z

    1. Initial program 59.7%

      \[\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. Step-by-step derivation
      1. associate-+l-59.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative59.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*63.6%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 73.1%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative73.1%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*73.7%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
    6. Simplified73.7%

      \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}} \cdot -4} \]

    if -4.50000000000000004e210 < z < -7.49999999999999977e151

    1. Initial program 84.7%

      \[\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. Step-by-step derivation
      1. associate-+l-84.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative84.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*97.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around 0 85.6%

      \[\leadsto \color{blue}{\frac{b + 9 \cdot \left(x \cdot y\right)}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative85.6%

        \[\leadsto \frac{b + 9 \cdot \left(x \cdot y\right)}{\color{blue}{z \cdot c}} \]
    6. Simplified85.6%

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

    if -7.49999999999999977e151 < z < -4.1999999999999998e137

    1. Initial program 52.0%

      \[\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. Step-by-step derivation
      1. associate-+l-52.0%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative52.0%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*52.0%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 100.0%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]

    if -4.1999999999999998e137 < z < 5.0000000000000004e90

    1. Initial program 91.3%

      \[\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. Step-by-step derivation
      1. associate-+l-91.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative91.3%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*91.5%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. *-un-lft-identity88.8%

        \[\leadsto \frac{\color{blue}{1 \cdot \left(\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b\right)}}{z \cdot c} \]
      2. times-frac89.7%

        \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
      3. associate-+l-89.7%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{c} \]
      4. associate-*r*92.2%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{c} \]
      5. associate-+l-92.2%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{c} \]
      6. associate-*l*92.2%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{c} \]
      7. associate-*r*89.7%

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

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

      \[\leadsto \frac{1}{z} \cdot \color{blue}{\frac{b + 9 \cdot \left(x \cdot y\right)}{c}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification78.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4.5 \cdot 10^{+210}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;z \leq -7.5 \cdot 10^{+151}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{elif}\;z \leq -4.2 \cdot 10^{+137}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{+90}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b + 9 \cdot \left(x \cdot y\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]

Alternative 8: 47.4% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;a \leq -1.25 \cdot 10^{-37}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;a \leq -5.7 \cdot 10^{-272}:\\ \;\;\;\;\frac{x}{z \cdot \frac{\frac{c}{y}}{9}}\\ \mathbf{elif}\;a \leq 1280000000000:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;a \leq 3.4 \cdot 10^{+198}:\\ \;\;\;\;\frac{1}{z} \cdot \left(9 \cdot \frac{x}{\frac{c}{y}}\right)\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (<= a -1.25e-37)
   (* -4.0 (/ a (/ c t)))
   (if (<= a -5.7e-272)
     (/ x (* z (/ (/ c y) 9.0)))
     (if (<= a 1280000000000.0)
       (/ b (* z c))
       (if (<= a 3.4e+198)
         (* (/ 1.0 z) (* 9.0 (/ x (/ c y))))
         (* -4.0 (* t (/ a c))))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if (a <= -1.25e-37) {
		tmp = -4.0 * (a / (c / t));
	} else if (a <= -5.7e-272) {
		tmp = x / (z * ((c / y) / 9.0));
	} else if (a <= 1280000000000.0) {
		tmp = b / (z * c);
	} else if (a <= 3.4e+198) {
		tmp = (1.0 / z) * (9.0 * (x / (c / y)));
	} else {
		tmp = -4.0 * (t * (a / c));
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: tmp
    if (a <= (-1.25d-37)) then
        tmp = (-4.0d0) * (a / (c / t))
    else if (a <= (-5.7d-272)) then
        tmp = x / (z * ((c / y) / 9.0d0))
    else if (a <= 1280000000000.0d0) then
        tmp = b / (z * c)
    else if (a <= 3.4d+198) then
        tmp = (1.0d0 / z) * (9.0d0 * (x / (c / y)))
    else
        tmp = (-4.0d0) * (t * (a / c))
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if (a <= -1.25e-37) {
		tmp = -4.0 * (a / (c / t));
	} else if (a <= -5.7e-272) {
		tmp = x / (z * ((c / y) / 9.0));
	} else if (a <= 1280000000000.0) {
		tmp = b / (z * c);
	} else if (a <= 3.4e+198) {
		tmp = (1.0 / z) * (9.0 * (x / (c / y)));
	} else {
		tmp = -4.0 * (t * (a / c));
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if a <= -1.25e-37:
		tmp = -4.0 * (a / (c / t))
	elif a <= -5.7e-272:
		tmp = x / (z * ((c / y) / 9.0))
	elif a <= 1280000000000.0:
		tmp = b / (z * c)
	elif a <= 3.4e+198:
		tmp = (1.0 / z) * (9.0 * (x / (c / y)))
	else:
		tmp = -4.0 * (t * (a / c))
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if (a <= -1.25e-37)
		tmp = Float64(-4.0 * Float64(a / Float64(c / t)));
	elseif (a <= -5.7e-272)
		tmp = Float64(x / Float64(z * Float64(Float64(c / y) / 9.0)));
	elseif (a <= 1280000000000.0)
		tmp = Float64(b / Float64(z * c));
	elseif (a <= 3.4e+198)
		tmp = Float64(Float64(1.0 / z) * Float64(9.0 * Float64(x / Float64(c / y))));
	else
		tmp = Float64(-4.0 * Float64(t * Float64(a / c)));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if (a <= -1.25e-37)
		tmp = -4.0 * (a / (c / t));
	elseif (a <= -5.7e-272)
		tmp = x / (z * ((c / y) / 9.0));
	elseif (a <= 1280000000000.0)
		tmp = b / (z * c);
	elseif (a <= 3.4e+198)
		tmp = (1.0 / z) * (9.0 * (x / (c / y)));
	else
		tmp = -4.0 * (t * (a / c));
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[a, -1.25e-37], N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, -5.7e-272], N[(x / N[(z * N[(N[(c / y), $MachinePrecision] / 9.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1280000000000.0], N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 3.4e+198], N[(N[(1.0 / z), $MachinePrecision] * N[(9.0 * N[(x / N[(c / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.25 \cdot 10^{-37}:\\
\;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\

\mathbf{elif}\;a \leq -5.7 \cdot 10^{-272}:\\
\;\;\;\;\frac{x}{z \cdot \frac{\frac{c}{y}}{9}}\\

\mathbf{elif}\;a \leq 1280000000000:\\
\;\;\;\;\frac{b}{z \cdot c}\\

\mathbf{elif}\;a \leq 3.4 \cdot 10^{+198}:\\
\;\;\;\;\frac{1}{z} \cdot \left(9 \cdot \frac{x}{\frac{c}{y}}\right)\\

\mathbf{else}:\\
\;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if a < -1.2499999999999999e-37

    1. Initial program 81.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. Step-by-step derivation
      1. associate-+l-81.9%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*79.4%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 49.3%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative49.3%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*51.7%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
    6. Simplified51.7%

      \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}} \cdot -4} \]

    if -1.2499999999999999e-37 < a < -5.6999999999999999e-272

    1. Initial program 87.3%

      \[\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. Step-by-step derivation
      1. associate-+l-87.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative87.3%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*94.3%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in x around inf 55.6%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z}} \]
    5. Step-by-step derivation
      1. associate-*r/55.6%

        \[\leadsto \color{blue}{\frac{9 \cdot \left(x \cdot y\right)}{c \cdot z}} \]
      2. associate-*r*55.5%

        \[\leadsto \frac{\color{blue}{\left(9 \cdot x\right) \cdot y}}{c \cdot z} \]
      3. *-commutative55.5%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right)} \cdot y}{c \cdot z} \]
      4. associate-*r*55.5%

        \[\leadsto \frac{\color{blue}{x \cdot \left(9 \cdot y\right)}}{c \cdot z} \]
      5. *-commutative55.5%

        \[\leadsto \frac{x \cdot \left(9 \cdot y\right)}{\color{blue}{z \cdot c}} \]
      6. times-frac50.8%

        \[\leadsto \color{blue}{\frac{x}{z} \cdot \frac{9 \cdot y}{c}} \]
      7. associate-/l*50.7%

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

      \[\leadsto \color{blue}{\frac{x}{z} \cdot \frac{9}{\frac{c}{y}}} \]
    7. Step-by-step derivation
      1. *-commutative50.7%

        \[\leadsto \color{blue}{\frac{9}{\frac{c}{y}} \cdot \frac{x}{z}} \]
      2. clear-num50.7%

        \[\leadsto \color{blue}{\frac{1}{\frac{\frac{c}{y}}{9}}} \cdot \frac{x}{z} \]
      3. frac-times54.2%

        \[\leadsto \color{blue}{\frac{1 \cdot x}{\frac{\frac{c}{y}}{9} \cdot z}} \]
      4. *-un-lft-identity54.2%

        \[\leadsto \frac{\color{blue}{x}}{\frac{\frac{c}{y}}{9} \cdot z} \]
    8. Applied egg-rr54.2%

      \[\leadsto \color{blue}{\frac{x}{\frac{\frac{c}{y}}{9} \cdot z}} \]

    if -5.6999999999999999e-272 < a < 1.28e12

    1. Initial program 81.8%

      \[\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. Step-by-step derivation
      1. associate-+l-81.8%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative81.8%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*85.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 53.1%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative53.1%

        \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
    6. Simplified53.1%

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]

    if 1.28e12 < a < 3.4e198

    1. Initial program 85.0%

      \[\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. Step-by-step derivation
      1. associate-+l-85.0%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative85.0%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*85.0%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. *-un-lft-identity77.5%

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

        \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
      3. associate-+l-78.2%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{c} \]
      4. associate-*r*85.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{c} \]
      5. associate-+l-85.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{c} \]
      6. associate-*l*85.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{c} \]
      7. associate-*r*78.1%

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

      \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
    6. Taylor expanded in x around inf 43.3%

      \[\leadsto \frac{1}{z} \cdot \color{blue}{\left(9 \cdot \frac{x \cdot y}{c}\right)} \]
    7. Step-by-step derivation
      1. associate-/l*48.1%

        \[\leadsto \frac{1}{z} \cdot \left(9 \cdot \color{blue}{\frac{x}{\frac{c}{y}}}\right) \]
    8. Simplified48.1%

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

    if 3.4e198 < a

    1. Initial program 87.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. Step-by-step derivation
      1. associate-+l-87.6%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative87.6%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*81.4%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 63.8%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative63.8%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*75.1%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
      3. associate-/r/75.0%

        \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right)} \cdot -4 \]
    6. Simplified75.0%

      \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right) \cdot -4} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification53.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -1.25 \cdot 10^{-37}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;a \leq -5.7 \cdot 10^{-272}:\\ \;\;\;\;\frac{x}{z \cdot \frac{\frac{c}{y}}{9}}\\ \mathbf{elif}\;a \leq 1280000000000:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;a \leq 3.4 \cdot 10^{+198}:\\ \;\;\;\;\frac{1}{z} \cdot \left(9 \cdot \frac{x}{\frac{c}{y}}\right)\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \end{array} \]

Alternative 9: 68.2% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} t_1 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ t_2 := -4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{if}\;z \leq -6.2 \cdot 10^{+214}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -2.45 \cdot 10^{+151}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -1.6 \cdot 10^{+109}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 3.7 \cdot 10^{+90}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (/ (+ b (* 9.0 (* x y))) (* z c))) (t_2 (* -4.0 (/ a (/ c t)))))
   (if (<= z -6.2e+214)
     t_2
     (if (<= z -2.45e+151)
       t_1
       (if (<= z -1.6e+109)
         (* -4.0 (/ (* a t) c))
         (if (<= z 3.7e+90) t_1 t_2))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = (b + (9.0 * (x * y))) / (z * c);
	double t_2 = -4.0 * (a / (c / t));
	double tmp;
	if (z <= -6.2e+214) {
		tmp = t_2;
	} else if (z <= -2.45e+151) {
		tmp = t_1;
	} else if (z <= -1.6e+109) {
		tmp = -4.0 * ((a * t) / c);
	} else if (z <= 3.7e+90) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = (b + (9.0d0 * (x * y))) / (z * c)
    t_2 = (-4.0d0) * (a / (c / t))
    if (z <= (-6.2d+214)) then
        tmp = t_2
    else if (z <= (-2.45d+151)) then
        tmp = t_1
    else if (z <= (-1.6d+109)) then
        tmp = (-4.0d0) * ((a * t) / c)
    else if (z <= 3.7d+90) then
        tmp = t_1
    else
        tmp = t_2
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = (b + (9.0 * (x * y))) / (z * c);
	double t_2 = -4.0 * (a / (c / t));
	double tmp;
	if (z <= -6.2e+214) {
		tmp = t_2;
	} else if (z <= -2.45e+151) {
		tmp = t_1;
	} else if (z <= -1.6e+109) {
		tmp = -4.0 * ((a * t) / c);
	} else if (z <= 3.7e+90) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	t_1 = (b + (9.0 * (x * y))) / (z * c)
	t_2 = -4.0 * (a / (c / t))
	tmp = 0
	if z <= -6.2e+214:
		tmp = t_2
	elif z <= -2.45e+151:
		tmp = t_1
	elif z <= -1.6e+109:
		tmp = -4.0 * ((a * t) / c)
	elif z <= 3.7e+90:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	t_1 = Float64(Float64(b + Float64(9.0 * Float64(x * y))) / Float64(z * c))
	t_2 = Float64(-4.0 * Float64(a / Float64(c / t)))
	tmp = 0.0
	if (z <= -6.2e+214)
		tmp = t_2;
	elseif (z <= -2.45e+151)
		tmp = t_1;
	elseif (z <= -1.6e+109)
		tmp = Float64(-4.0 * Float64(Float64(a * t) / c));
	elseif (z <= 3.7e+90)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = (b + (9.0 * (x * y))) / (z * c);
	t_2 = -4.0 * (a / (c / t));
	tmp = 0.0;
	if (z <= -6.2e+214)
		tmp = t_2;
	elseif (z <= -2.45e+151)
		tmp = t_1;
	elseif (z <= -1.6e+109)
		tmp = -4.0 * ((a * t) / c);
	elseif (z <= 3.7e+90)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(N[(b + N[(9.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -6.2e+214], t$95$2, If[LessEqual[z, -2.45e+151], t$95$1, If[LessEqual[z, -1.6e+109], N[(-4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.7e+90], t$95$1, t$95$2]]]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
t_1 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\
t_2 := -4 \cdot \frac{a}{\frac{c}{t}}\\
\mathbf{if}\;z \leq -6.2 \cdot 10^{+214}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq -2.45 \cdot 10^{+151}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -1.6 \cdot 10^{+109}:\\
\;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\

\mathbf{elif}\;z \leq 3.7 \cdot 10^{+90}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;t_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -6.19999999999999957e214 or 3.7e90 < z

    1. Initial program 59.7%

      \[\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. Step-by-step derivation
      1. associate-+l-59.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative59.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*63.6%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 73.1%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative73.1%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*73.7%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
    6. Simplified73.7%

      \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}} \cdot -4} \]

    if -6.19999999999999957e214 < z < -2.45e151 or -1.6000000000000001e109 < z < 3.7e90

    1. Initial program 92.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} \]
    2. Step-by-step derivation
      1. associate-+l-92.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative92.1%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*92.9%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around 0 80.0%

      \[\leadsto \color{blue}{\frac{b + 9 \cdot \left(x \cdot y\right)}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative80.0%

        \[\leadsto \frac{b + 9 \cdot \left(x \cdot y\right)}{\color{blue}{z \cdot c}} \]
    6. Simplified80.0%

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

    if -2.45e151 < z < -1.6000000000000001e109

    1. Initial program 57.2%

      \[\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. Step-by-step derivation
      1. associate-+l-57.2%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*57.3%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 64.9%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification78.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -6.2 \cdot 10^{+214}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;z \leq -2.45 \cdot 10^{+151}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{elif}\;z \leq -1.6 \cdot 10^{+109}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 3.7 \cdot 10^{+90}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]

Alternative 10: 68.7% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -4.2 \cdot 10^{+253}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;z \leq -1.8 \cdot 10^{+47}:\\ \;\;\;\;\frac{b + -4 \cdot \left(z \cdot \left(a \cdot t\right)\right)}{z \cdot c}\\ \mathbf{elif}\;z \leq 5.2 \cdot 10^{+90}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b + 9 \cdot \left(x \cdot y\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (<= z -4.2e+253)
   (* -4.0 (* t (/ a c)))
   (if (<= z -1.8e+47)
     (/ (+ b (* -4.0 (* z (* a t)))) (* z c))
     (if (<= z 5.2e+90)
       (* (/ 1.0 z) (/ (+ b (* 9.0 (* x y))) c))
       (* -4.0 (/ a (/ c t)))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if (z <= -4.2e+253) {
		tmp = -4.0 * (t * (a / c));
	} else if (z <= -1.8e+47) {
		tmp = (b + (-4.0 * (z * (a * t)))) / (z * c);
	} else if (z <= 5.2e+90) {
		tmp = (1.0 / z) * ((b + (9.0 * (x * y))) / c);
	} else {
		tmp = -4.0 * (a / (c / t));
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: tmp
    if (z <= (-4.2d+253)) then
        tmp = (-4.0d0) * (t * (a / c))
    else if (z <= (-1.8d+47)) then
        tmp = (b + ((-4.0d0) * (z * (a * t)))) / (z * c)
    else if (z <= 5.2d+90) then
        tmp = (1.0d0 / z) * ((b + (9.0d0 * (x * y))) / c)
    else
        tmp = (-4.0d0) * (a / (c / t))
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if (z <= -4.2e+253) {
		tmp = -4.0 * (t * (a / c));
	} else if (z <= -1.8e+47) {
		tmp = (b + (-4.0 * (z * (a * t)))) / (z * c);
	} else if (z <= 5.2e+90) {
		tmp = (1.0 / z) * ((b + (9.0 * (x * y))) / c);
	} else {
		tmp = -4.0 * (a / (c / t));
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if z <= -4.2e+253:
		tmp = -4.0 * (t * (a / c))
	elif z <= -1.8e+47:
		tmp = (b + (-4.0 * (z * (a * t)))) / (z * c)
	elif z <= 5.2e+90:
		tmp = (1.0 / z) * ((b + (9.0 * (x * y))) / c)
	else:
		tmp = -4.0 * (a / (c / t))
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if (z <= -4.2e+253)
		tmp = Float64(-4.0 * Float64(t * Float64(a / c)));
	elseif (z <= -1.8e+47)
		tmp = Float64(Float64(b + Float64(-4.0 * Float64(z * Float64(a * t)))) / Float64(z * c));
	elseif (z <= 5.2e+90)
		tmp = Float64(Float64(1.0 / z) * Float64(Float64(b + Float64(9.0 * Float64(x * y))) / c));
	else
		tmp = Float64(-4.0 * Float64(a / Float64(c / t)));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if (z <= -4.2e+253)
		tmp = -4.0 * (t * (a / c));
	elseif (z <= -1.8e+47)
		tmp = (b + (-4.0 * (z * (a * t)))) / (z * c);
	elseif (z <= 5.2e+90)
		tmp = (1.0 / z) * ((b + (9.0 * (x * y))) / c);
	else
		tmp = -4.0 * (a / (c / t));
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[z, -4.2e+253], N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.8e+47], N[(N[(b + N[(-4.0 * N[(z * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.2e+90], N[(N[(1.0 / z), $MachinePrecision] * N[(N[(b + N[(9.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision], N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.2 \cdot 10^{+253}:\\
\;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\

\mathbf{elif}\;z \leq -1.8 \cdot 10^{+47}:\\
\;\;\;\;\frac{b + -4 \cdot \left(z \cdot \left(a \cdot t\right)\right)}{z \cdot c}\\

\mathbf{elif}\;z \leq 5.2 \cdot 10^{+90}:\\
\;\;\;\;\frac{1}{z} \cdot \frac{b + 9 \cdot \left(x \cdot y\right)}{c}\\

\mathbf{else}:\\
\;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -4.2000000000000003e253

    1. Initial program 21.2%

      \[\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. Step-by-step derivation
      1. associate-+l-21.2%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*31.5%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 63.8%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative63.8%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*73.3%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
      3. associate-/r/73.4%

        \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right)} \cdot -4 \]
    6. Simplified73.4%

      \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right) \cdot -4} \]

    if -4.2000000000000003e253 < z < -1.80000000000000004e47

    1. Initial program 72.7%

      \[\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. Step-by-step derivation
      1. associate-+l-72.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative72.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*79.6%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in x around 0 66.0%

      \[\leadsto \frac{\color{blue}{-4 \cdot \left(a \cdot \left(t \cdot z\right)\right)} + b}{z \cdot c} \]
    5. Step-by-step derivation
      1. *-commutative66.0%

        \[\leadsto \frac{\color{blue}{\left(a \cdot \left(t \cdot z\right)\right) \cdot -4} + b}{z \cdot c} \]
      2. *-commutative66.0%

        \[\leadsto \frac{\color{blue}{\left(\left(t \cdot z\right) \cdot a\right)} \cdot -4 + b}{z \cdot c} \]
      3. *-commutative66.0%

        \[\leadsto \frac{\left(\color{blue}{\left(z \cdot t\right)} \cdot a\right) \cdot -4 + b}{z \cdot c} \]
      4. associate-*l*68.3%

        \[\leadsto \frac{\color{blue}{\left(z \cdot \left(t \cdot a\right)\right)} \cdot -4 + b}{z \cdot c} \]
      5. *-commutative68.3%

        \[\leadsto \frac{\left(z \cdot \color{blue}{\left(a \cdot t\right)}\right) \cdot -4 + b}{z \cdot c} \]
    6. Simplified68.3%

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

    if -1.80000000000000004e47 < z < 5.1999999999999997e90

    1. Initial program 94.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. Step-by-step derivation
      1. associate-+l-94.6%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative94.6%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*93.7%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. *-un-lft-identity90.6%

        \[\leadsto \frac{\color{blue}{1 \cdot \left(\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b\right)}}{z \cdot c} \]
      2. times-frac91.0%

        \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
      3. associate-+l-91.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{c} \]
      4. associate-*r*95.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{c} \]
      5. associate-+l-95.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{c} \]
      6. associate-*l*95.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{c} \]
      7. associate-*r*91.0%

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

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

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

    if 5.1999999999999997e90 < z

    1. Initial program 65.3%

      \[\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. Step-by-step derivation
      1. associate-+l-65.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative65.3%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*68.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 73.2%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative73.2%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*74.0%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
    6. Simplified74.0%

      \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}} \cdot -4} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification78.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4.2 \cdot 10^{+253}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;z \leq -1.8 \cdot 10^{+47}:\\ \;\;\;\;\frac{b + -4 \cdot \left(z \cdot \left(a \cdot t\right)\right)}{z \cdot c}\\ \mathbf{elif}\;z \leq 5.2 \cdot 10^{+90}:\\ \;\;\;\;\frac{1}{z} \cdot \frac{b + 9 \cdot \left(x \cdot y\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]

Alternative 11: 80.9% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \frac{b + \left(y \cdot \left(9 \cdot x\right) - \left(z \cdot 4\right) \cdot \left(a \cdot t\right)\right)}{z \cdot c} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (/ (+ b (- (* y (* 9.0 x)) (* (* z 4.0) (* a t)))) (* z c)))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	return (b + ((y * (9.0 * x)) - ((z * 4.0) * (a * t)))) / (z * c);
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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
    code = (b + ((y * (9.0d0 * x)) - ((z * 4.0d0) * (a * t)))) / (z * c)
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	return (b + ((y * (9.0 * x)) - ((z * 4.0) * (a * t)))) / (z * c);
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	return (b + ((y * (9.0 * x)) - ((z * 4.0) * (a * t)))) / (z * c)
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	return Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(Float64(z * 4.0) * Float64(a * t)))) / Float64(z * c))
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp = code(x, y, z, t, a, b, c)
	tmp = (b + ((y * (9.0 * x)) - ((z * 4.0) * (a * t)))) / (z * c);
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := N[(N[(b + N[(N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision] - N[(N[(z * 4.0), $MachinePrecision] * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\frac{b + \left(y \cdot \left(9 \cdot x\right) - \left(z \cdot 4\right) \cdot \left(a \cdot t\right)\right)}{z \cdot c}
\end{array}
Derivation
  1. Initial program 83.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. Step-by-step derivation
    1. associate-+l-83.9%

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

      \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
    3. associate-*r*85.3%

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

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

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

    \[\leadsto \color{blue}{\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}} \]
  4. Final simplification84.0%

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

Alternative 12: 80.0% accurate, 1.0× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (/ (+ b (- (* y (* 9.0 x)) (* a (* t (* z 4.0))))) (* z c)))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	return (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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
    code = (b + ((y * (9.0d0 * x)) - (a * (t * (z * 4.0d0))))) / (z * c)
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	return (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	return (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c)
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	return Float64(Float64(b + Float64(Float64(y * Float64(9.0 * x)) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c))
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp = code(x, y, z, t, a, b, c)
	tmp = (b + ((y * (9.0 * x)) - (a * (t * (z * 4.0))))) / (z * c);
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := N[(N[(b + N[(N[(y * N[(9.0 * x), $MachinePrecision]), $MachinePrecision] - N[(a * N[(t * N[(z * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\frac{b + \left(y \cdot \left(9 \cdot x\right) - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}
\end{array}
Derivation
  1. Initial program 83.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. Final simplification83.9%

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

Alternative 13: 50.6% accurate, 1.1× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} t_1 := -4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{if}\;z \leq -2.4 \cdot 10^{+45}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -5.2 \cdot 10^{-69}:\\ \;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\ \mathbf{elif}\;z \leq 1.65 \cdot 10^{-184}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{+83}:\\ \;\;\;\;9 \cdot \left(\frac{x}{z} \cdot \frac{y}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (* -4.0 (/ a (/ c t)))))
   (if (<= z -2.4e+45)
     t_1
     (if (<= z -5.2e-69)
       (* 9.0 (* (/ x c) (/ y z)))
       (if (<= z 1.65e-184)
         (/ b (* z c))
         (if (<= z 5e+83) (* 9.0 (* (/ x z) (/ y c))) t_1))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = -4.0 * (a / (c / t));
	double tmp;
	if (z <= -2.4e+45) {
		tmp = t_1;
	} else if (z <= -5.2e-69) {
		tmp = 9.0 * ((x / c) * (y / z));
	} else if (z <= 1.65e-184) {
		tmp = b / (z * c);
	} else if (z <= 5e+83) {
		tmp = 9.0 * ((x / z) * (y / c));
	} else {
		tmp = t_1;
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: t_1
    real(8) :: tmp
    t_1 = (-4.0d0) * (a / (c / t))
    if (z <= (-2.4d+45)) then
        tmp = t_1
    else if (z <= (-5.2d-69)) then
        tmp = 9.0d0 * ((x / c) * (y / z))
    else if (z <= 1.65d-184) then
        tmp = b / (z * c)
    else if (z <= 5d+83) then
        tmp = 9.0d0 * ((x / z) * (y / c))
    else
        tmp = t_1
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = -4.0 * (a / (c / t));
	double tmp;
	if (z <= -2.4e+45) {
		tmp = t_1;
	} else if (z <= -5.2e-69) {
		tmp = 9.0 * ((x / c) * (y / z));
	} else if (z <= 1.65e-184) {
		tmp = b / (z * c);
	} else if (z <= 5e+83) {
		tmp = 9.0 * ((x / z) * (y / c));
	} else {
		tmp = t_1;
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	t_1 = -4.0 * (a / (c / t))
	tmp = 0
	if z <= -2.4e+45:
		tmp = t_1
	elif z <= -5.2e-69:
		tmp = 9.0 * ((x / c) * (y / z))
	elif z <= 1.65e-184:
		tmp = b / (z * c)
	elif z <= 5e+83:
		tmp = 9.0 * ((x / z) * (y / c))
	else:
		tmp = t_1
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	t_1 = Float64(-4.0 * Float64(a / Float64(c / t)))
	tmp = 0.0
	if (z <= -2.4e+45)
		tmp = t_1;
	elseif (z <= -5.2e-69)
		tmp = Float64(9.0 * Float64(Float64(x / c) * Float64(y / z)));
	elseif (z <= 1.65e-184)
		tmp = Float64(b / Float64(z * c));
	elseif (z <= 5e+83)
		tmp = Float64(9.0 * Float64(Float64(x / z) * Float64(y / c)));
	else
		tmp = t_1;
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = -4.0 * (a / (c / t));
	tmp = 0.0;
	if (z <= -2.4e+45)
		tmp = t_1;
	elseif (z <= -5.2e-69)
		tmp = 9.0 * ((x / c) * (y / z));
	elseif (z <= 1.65e-184)
		tmp = b / (z * c);
	elseif (z <= 5e+83)
		tmp = 9.0 * ((x / z) * (y / c));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.4e+45], t$95$1, If[LessEqual[z, -5.2e-69], N[(9.0 * N[(N[(x / c), $MachinePrecision] * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.65e-184], N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5e+83], N[(9.0 * N[(N[(x / z), $MachinePrecision] * N[(y / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
t_1 := -4 \cdot \frac{a}{\frac{c}{t}}\\
\mathbf{if}\;z \leq -2.4 \cdot 10^{+45}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -5.2 \cdot 10^{-69}:\\
\;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\

\mathbf{elif}\;z \leq 1.65 \cdot 10^{-184}:\\
\;\;\;\;\frac{b}{z \cdot c}\\

\mathbf{elif}\;z \leq 5 \cdot 10^{+83}:\\
\;\;\;\;9 \cdot \left(\frac{x}{z} \cdot \frac{y}{c}\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -2.39999999999999989e45 or 5.00000000000000029e83 < z

    1. Initial program 64.7%

      \[\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. Step-by-step derivation
      1. associate-+l-64.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative64.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*70.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 62.0%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative62.0%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*63.1%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
    6. Simplified63.1%

      \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}} \cdot -4} \]

    if -2.39999999999999989e45 < z < -5.2000000000000004e-69

    1. Initial program 84.7%

      \[\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. Step-by-step derivation
      1. associate-+l-84.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative84.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*84.7%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. *-un-lft-identity84.6%

        \[\leadsto \frac{\color{blue}{1 \cdot \left(\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b\right)}}{z \cdot c} \]
      2. times-frac89.0%

        \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
      3. associate-+l-89.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{c} \]
      4. associate-*r*89.1%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{c} \]
      5. associate-+l-89.1%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{c} \]
      6. associate-*l*89.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{c} \]
      7. associate-*r*89.0%

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

      \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
    6. Taylor expanded in x around inf 52.8%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z}} \]
    7. Step-by-step derivation
      1. times-frac56.8%

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

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

    if -5.2000000000000004e-69 < z < 1.6499999999999999e-184

    1. Initial program 98.2%

      \[\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. Step-by-step derivation
      1. associate-+l-98.2%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*97.7%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 58.2%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative58.2%

        \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
    6. Simplified58.2%

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]

    if 1.6499999999999999e-184 < z < 5.00000000000000029e83

    1. Initial program 93.3%

      \[\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. Step-by-step derivation
      1. associate-+l-93.3%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative93.3%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*91.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. *-un-lft-identity93.3%

        \[\leadsto \frac{\color{blue}{1 \cdot \left(\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b\right)}}{z \cdot c} \]
      2. times-frac93.6%

        \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
      3. associate-+l-93.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{c} \]
      4. associate-*r*93.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{c} \]
      5. associate-+l-93.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{c} \]
      6. associate-*l*93.6%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{c} \]
      7. associate-*r*93.6%

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

      \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
    6. Step-by-step derivation
      1. div-inv93.5%

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

      \[\leadsto \frac{1}{z} \cdot \color{blue}{\left(\left(\left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b\right) \cdot \frac{1}{c}\right)} \]
    8. Taylor expanded in x around inf 53.1%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z}} \]
    9. Step-by-step derivation
      1. *-commutative53.1%

        \[\leadsto 9 \cdot \frac{x \cdot y}{\color{blue}{z \cdot c}} \]
      2. times-frac58.6%

        \[\leadsto 9 \cdot \color{blue}{\left(\frac{x}{z} \cdot \frac{y}{c}\right)} \]
    10. Simplified58.6%

      \[\leadsto \color{blue}{9 \cdot \left(\frac{x}{z} \cdot \frac{y}{c}\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification59.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.4 \cdot 10^{+45}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;z \leq -5.2 \cdot 10^{-69}:\\ \;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\ \mathbf{elif}\;z \leq 1.65 \cdot 10^{-184}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{+83}:\\ \;\;\;\;9 \cdot \left(\frac{x}{z} \cdot \frac{y}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \end{array} \]

Alternative 14: 48.8% accurate, 1.3× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;b \leq -1.85 \cdot 10^{-8}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;b \leq 1.12 \cdot 10^{-212}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;b \leq 4.5 \cdot 10^{+106}:\\ \;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (<= b -1.85e-8)
   (/ (/ b c) z)
   (if (<= b 1.12e-212)
     (* -4.0 (* t (/ a c)))
     (if (<= b 4.5e+106) (* 9.0 (* (/ x c) (/ y z))) (/ b (* z c))))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if (b <= -1.85e-8) {
		tmp = (b / c) / z;
	} else if (b <= 1.12e-212) {
		tmp = -4.0 * (t * (a / c));
	} else if (b <= 4.5e+106) {
		tmp = 9.0 * ((x / c) * (y / z));
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: tmp
    if (b <= (-1.85d-8)) then
        tmp = (b / c) / z
    else if (b <= 1.12d-212) then
        tmp = (-4.0d0) * (t * (a / c))
    else if (b <= 4.5d+106) then
        tmp = 9.0d0 * ((x / c) * (y / z))
    else
        tmp = b / (z * c)
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if (b <= -1.85e-8) {
		tmp = (b / c) / z;
	} else if (b <= 1.12e-212) {
		tmp = -4.0 * (t * (a / c));
	} else if (b <= 4.5e+106) {
		tmp = 9.0 * ((x / c) * (y / z));
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if b <= -1.85e-8:
		tmp = (b / c) / z
	elif b <= 1.12e-212:
		tmp = -4.0 * (t * (a / c))
	elif b <= 4.5e+106:
		tmp = 9.0 * ((x / c) * (y / z))
	else:
		tmp = b / (z * c)
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if (b <= -1.85e-8)
		tmp = Float64(Float64(b / c) / z);
	elseif (b <= 1.12e-212)
		tmp = Float64(-4.0 * Float64(t * Float64(a / c)));
	elseif (b <= 4.5e+106)
		tmp = Float64(9.0 * Float64(Float64(x / c) * Float64(y / z)));
	else
		tmp = Float64(b / Float64(z * c));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if (b <= -1.85e-8)
		tmp = (b / c) / z;
	elseif (b <= 1.12e-212)
		tmp = -4.0 * (t * (a / c));
	elseif (b <= 4.5e+106)
		tmp = 9.0 * ((x / c) * (y / z));
	else
		tmp = b / (z * c);
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[b, -1.85e-8], N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[b, 1.12e-212], N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 4.5e+106], N[(9.0 * N[(N[(x / c), $MachinePrecision] * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.85 \cdot 10^{-8}:\\
\;\;\;\;\frac{\frac{b}{c}}{z}\\

\mathbf{elif}\;b \leq 1.12 \cdot 10^{-212}:\\
\;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\

\mathbf{elif}\;b \leq 4.5 \cdot 10^{+106}:\\
\;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{b}{z \cdot c}\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -1.85e-8

    1. Initial program 82.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. Step-by-step derivation
      1. associate-+l-82.9%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*82.9%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 56.6%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. associate-/r*59.0%

        \[\leadsto \color{blue}{\frac{\frac{b}{c}}{z}} \]
    6. Simplified59.0%

      \[\leadsto \color{blue}{\frac{\frac{b}{c}}{z}} \]

    if -1.85e-8 < b < 1.12e-212

    1. Initial program 81.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. Step-by-step derivation
      1. associate-+l-81.9%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*82.7%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 48.5%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative48.5%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*52.6%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
      3. associate-/r/52.2%

        \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right)} \cdot -4 \]
    6. Simplified52.2%

      \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right) \cdot -4} \]

    if 1.12e-212 < b < 4.4999999999999997e106

    1. Initial program 90.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} \]
    2. Step-by-step derivation
      1. associate-+l-90.1%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative90.1%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*93.3%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Step-by-step derivation
      1. *-un-lft-identity93.4%

        \[\leadsto \frac{\color{blue}{1 \cdot \left(\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b\right)}}{z \cdot c} \]
      2. times-frac88.7%

        \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(\left(x \cdot 9\right) \cdot y - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
      3. associate-+l-88.7%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot \left(t \cdot a\right) - b\right)}}{c} \]
      4. associate-*r*87.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a} - b\right)}{c} \]
      5. associate-+l-87.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\color{blue}{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}}{c} \]
      6. associate-*l*87.0%

        \[\leadsto \frac{1}{z} \cdot \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{c} \]
      7. associate-*r*88.7%

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

      \[\leadsto \color{blue}{\frac{1}{z} \cdot \frac{\left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{c}} \]
    6. Taylor expanded in x around inf 59.0%

      \[\leadsto \color{blue}{9 \cdot \frac{x \cdot y}{c \cdot z}} \]
    7. Step-by-step derivation
      1. times-frac55.4%

        \[\leadsto 9 \cdot \color{blue}{\left(\frac{x}{c} \cdot \frac{y}{z}\right)} \]
    8. Simplified55.4%

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

    if 4.4999999999999997e106 < b

    1. Initial program 81.0%

      \[\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. Step-by-step derivation
      1. associate-+l-81.0%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative81.0%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*83.0%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 61.1%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative61.1%

        \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
    6. Simplified61.1%

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification56.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -1.85 \cdot 10^{-8}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;b \leq 1.12 \cdot 10^{-212}:\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{elif}\;b \leq 4.5 \cdot 10^{+106}:\\ \;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \end{array} \]

Alternative 15: 50.0% accurate, 1.7× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -1.05 \cdot 10^{+61} \lor \neg \left(z \leq 2.1 \cdot 10^{+67}\right):\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= z -1.05e+61) (not (<= z 2.1e+67)))
   (* -4.0 (/ (* a t) c))
   (/ b (* z c))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -1.05e+61) || !(z <= 2.1e+67)) {
		tmp = -4.0 * ((a * t) / c);
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: tmp
    if ((z <= (-1.05d+61)) .or. (.not. (z <= 2.1d+67))) then
        tmp = (-4.0d0) * ((a * t) / c)
    else
        tmp = b / (z * c)
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -1.05e+61) || !(z <= 2.1e+67)) {
		tmp = -4.0 * ((a * t) / c);
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (z <= -1.05e+61) or not (z <= 2.1e+67):
		tmp = -4.0 * ((a * t) / c)
	else:
		tmp = b / (z * c)
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((z <= -1.05e+61) || !(z <= 2.1e+67))
		tmp = Float64(-4.0 * Float64(Float64(a * t) / c));
	else
		tmp = Float64(b / Float64(z * c));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((z <= -1.05e+61) || ~((z <= 2.1e+67)))
		tmp = -4.0 * ((a * t) / c);
	else
		tmp = b / (z * c);
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -1.05e+61], N[Not[LessEqual[z, 2.1e+67]], $MachinePrecision]], N[(-4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision], N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.05 \cdot 10^{+61} \lor \neg \left(z \leq 2.1 \cdot 10^{+67}\right):\\
\;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\

\mathbf{else}:\\
\;\;\;\;\frac{b}{z \cdot c}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.0500000000000001e61 or 2.1000000000000001e67 < z

    1. Initial program 65.7%

      \[\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. Step-by-step derivation
      1. associate-+l-65.7%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative65.7%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*70.2%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 61.9%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]

    if -1.0500000000000001e61 < z < 2.1000000000000001e67

    1. Initial program 94.0%

      \[\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. Step-by-step derivation
      1. associate-+l-94.0%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative94.0%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*93.7%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 49.0%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative49.0%

        \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
    6. Simplified49.0%

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification53.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.05 \cdot 10^{+61} \lor \neg \left(z \leq 2.1 \cdot 10^{+67}\right):\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \end{array} \]

Alternative 16: 49.9% accurate, 1.7× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -1.1 \cdot 10^{+46} \lor \neg \left(z \leq 2.3 \cdot 10^{+67}\right):\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= z -1.1e+46) (not (<= z 2.3e+67)))
   (* -4.0 (* t (/ a c)))
   (/ b (* z c))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -1.1e+46) || !(z <= 2.3e+67)) {
		tmp = -4.0 * (t * (a / c));
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: tmp
    if ((z <= (-1.1d+46)) .or. (.not. (z <= 2.3d+67))) then
        tmp = (-4.0d0) * (t * (a / c))
    else
        tmp = b / (z * c)
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -1.1e+46) || !(z <= 2.3e+67)) {
		tmp = -4.0 * (t * (a / c));
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (z <= -1.1e+46) or not (z <= 2.3e+67):
		tmp = -4.0 * (t * (a / c))
	else:
		tmp = b / (z * c)
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((z <= -1.1e+46) || !(z <= 2.3e+67))
		tmp = Float64(-4.0 * Float64(t * Float64(a / c)));
	else
		tmp = Float64(b / Float64(z * c));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((z <= -1.1e+46) || ~((z <= 2.3e+67)))
		tmp = -4.0 * (t * (a / c));
	else
		tmp = b / (z * c);
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -1.1e+46], N[Not[LessEqual[z, 2.3e+67]], $MachinePrecision]], N[(-4.0 * N[(t * N[(a / c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.1 \cdot 10^{+46} \lor \neg \left(z \leq 2.3 \cdot 10^{+67}\right):\\
\;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{b}{z \cdot c}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.1e46 or 2.2999999999999999e67 < z

    1. Initial program 65.8%

      \[\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. Step-by-step derivation
      1. associate-+l-65.8%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative65.8%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*70.1%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 61.1%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative61.1%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*62.2%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
      3. associate-/r/63.9%

        \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right)} \cdot -4 \]
    6. Simplified63.9%

      \[\leadsto \color{blue}{\left(\frac{a}{c} \cdot t\right) \cdot -4} \]

    if -1.1e46 < z < 2.2999999999999999e67

    1. Initial program 94.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. Step-by-step derivation
      1. associate-+l-94.4%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*94.1%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 48.7%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative48.7%

        \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
    6. Simplified48.7%

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification54.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.1 \cdot 10^{+46} \lor \neg \left(z \leq 2.3 \cdot 10^{+67}\right):\\ \;\;\;\;-4 \cdot \left(t \cdot \frac{a}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \end{array} \]

Alternative 17: 49.9% accurate, 1.7× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \begin{array}{l} \mathbf{if}\;z \leq -7.5 \cdot 10^{+45} \lor \neg \left(z \leq 3.6 \cdot 10^{+67}\right):\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \end{array} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= z -7.5e+45) (not (<= z 3.6e+67)))
   (* -4.0 (/ a (/ c t)))
   (/ b (* z c))))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -7.5e+45) || !(z <= 3.6e+67)) {
		tmp = -4.0 * (a / (c / t));
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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) :: tmp
    if ((z <= (-7.5d+45)) .or. (.not. (z <= 3.6d+67))) then
        tmp = (-4.0d0) * (a / (c / t))
    else
        tmp = b / (z * c)
    end if
    code = tmp
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -7.5e+45) || !(z <= 3.6e+67)) {
		tmp = -4.0 * (a / (c / t));
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (z <= -7.5e+45) or not (z <= 3.6e+67):
		tmp = -4.0 * (a / (c / t))
	else:
		tmp = b / (z * c)
	return tmp
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((z <= -7.5e+45) || !(z <= 3.6e+67))
		tmp = Float64(-4.0 * Float64(a / Float64(c / t)));
	else
		tmp = Float64(b / Float64(z * c));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((z <= -7.5e+45) || ~((z <= 3.6e+67)))
		tmp = -4.0 * (a / (c / t));
	else
		tmp = b / (z * c);
	end
	tmp_2 = tmp;
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -7.5e+45], N[Not[LessEqual[z, 3.6e+67]], $MachinePrecision]], N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.5 \cdot 10^{+45} \lor \neg \left(z \leq 3.6 \cdot 10^{+67}\right):\\
\;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\

\mathbf{else}:\\
\;\;\;\;\frac{b}{z \cdot c}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -7.50000000000000058e45 or 3.5999999999999999e67 < z

    1. Initial program 65.8%

      \[\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. Step-by-step derivation
      1. associate-+l-65.8%

        \[\leadsto \frac{\color{blue}{\left(x \cdot 9\right) \cdot y - \left(\left(\left(z \cdot 4\right) \cdot t\right) \cdot a - b\right)}}{z \cdot c} \]
      2. *-commutative65.8%

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*70.1%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in z around inf 61.1%

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c}} \]
    5. Step-by-step derivation
      1. *-commutative61.1%

        \[\leadsto \color{blue}{\frac{a \cdot t}{c} \cdot -4} \]
      2. associate-/l*62.2%

        \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}}} \cdot -4 \]
    6. Simplified62.2%

      \[\leadsto \color{blue}{\frac{a}{\frac{c}{t}} \cdot -4} \]

    if -7.50000000000000058e45 < z < 3.5999999999999999e67

    1. Initial program 94.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. Step-by-step derivation
      1. associate-+l-94.4%

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

        \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
      3. associate-*r*94.1%

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

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

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

      \[\leadsto \color{blue}{\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}} \]
    4. Taylor expanded in b around inf 48.7%

      \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
    5. Step-by-step derivation
      1. *-commutative48.7%

        \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
    6. Simplified48.7%

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification53.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -7.5 \cdot 10^{+45} \lor \neg \left(z \leq 3.6 \cdot 10^{+67}\right):\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \end{array} \]

Alternative 18: 35.0% accurate, 3.8× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ [t, a] = \mathsf{sort}([t, a])\\ \\ \frac{b}{z \cdot c} \end{array} \]
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
(FPCore (x y z t a b c) :precision binary64 (/ b (* z c)))
assert(x < y);
assert(t < a);
double code(double x, double y, double z, double t, double a, double b, double c) {
	return b / (z * c);
}
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
real(8) function code(x, y, z, t, a, b, c)
    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
    code = b / (z * c)
end function
assert x < y;
assert t < a;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	return b / (z * c);
}
[x, y] = sort([x, y])
[t, a] = sort([t, a])
def code(x, y, z, t, a, b, c):
	return b / (z * c)
x, y = sort([x, y])
t, a = sort([t, a])
function code(x, y, z, t, a, b, c)
	return Float64(b / Float64(z * c))
end
x, y = num2cell(sort([x, y])){:}
t, a = num2cell(sort([t, a])){:}
function tmp = code(x, y, z, t, a, b, c)
	tmp = b / (z * c);
end
NOTE: x and y should be sorted in increasing order before calling this function.
NOTE: t and a should be sorted in increasing order before calling this function.
code[x_, y_, z_, t_, a_, b_, c_] := N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
[t, a] = \mathsf{sort}([t, a])\\
\\
\frac{b}{z \cdot c}
\end{array}
Derivation
  1. Initial program 83.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. Step-by-step derivation
    1. associate-+l-83.9%

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

      \[\leadsto \frac{\left(x \cdot 9\right) \cdot y - \left(\color{blue}{a \cdot \left(\left(z \cdot 4\right) \cdot t\right)} - b\right)}{z \cdot c} \]
    3. associate-*r*85.3%

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

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

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

    \[\leadsto \color{blue}{\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}} \]
  4. Taylor expanded in b around inf 40.4%

    \[\leadsto \color{blue}{\frac{b}{c \cdot z}} \]
  5. Step-by-step derivation
    1. *-commutative40.4%

      \[\leadsto \frac{b}{\color{blue}{z \cdot c}} \]
  6. Simplified40.4%

    \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]
  7. Final simplification40.4%

    \[\leadsto \frac{b}{z \cdot c} \]

Developer target: 81.6% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{b}{c \cdot z}\\ t_2 := 4 \cdot \frac{a \cdot t}{c}\\ t_3 := \left(x \cdot 9\right) \cdot y\\ t_4 := \left(t_3 - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b\\ t_5 := \frac{t_4}{z \cdot c}\\ t_6 := \frac{\left(t_3 - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{z \cdot c}\\ \mathbf{if}\;t_5 < -1.100156740804105 \cdot 10^{-171}:\\ \;\;\;\;t_6\\ \mathbf{elif}\;t_5 < 0:\\ \;\;\;\;\frac{\frac{t_4}{z}}{c}\\ \mathbf{elif}\;t_5 < 1.1708877911747488 \cdot 10^{-53}:\\ \;\;\;\;t_6\\ \mathbf{elif}\;t_5 < 2.876823679546137 \cdot 10^{+130}:\\ \;\;\;\;\left(\left(9 \cdot \frac{y}{c}\right) \cdot \frac{x}{z} + t_1\right) - t_2\\ \mathbf{elif}\;t_5 < 1.3838515042456319 \cdot 10^{+158}:\\ \;\;\;\;t_6\\ \mathbf{else}:\\ \;\;\;\;\left(9 \cdot \left(\frac{y}{c \cdot z} \cdot x\right) + t_1\right) - t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (/ b (* c z)))
        (t_2 (* 4.0 (/ (* a t) c)))
        (t_3 (* (* x 9.0) y))
        (t_4 (+ (- t_3 (* (* (* z 4.0) t) a)) b))
        (t_5 (/ t_4 (* z c)))
        (t_6 (/ (+ (- t_3 (* (* z 4.0) (* t a))) b) (* z c))))
   (if (< t_5 -1.100156740804105e-171)
     t_6
     (if (< t_5 0.0)
       (/ (/ t_4 z) c)
       (if (< t_5 1.1708877911747488e-53)
         t_6
         (if (< t_5 2.876823679546137e+130)
           (- (+ (* (* 9.0 (/ y c)) (/ x z)) t_1) t_2)
           (if (< t_5 1.3838515042456319e+158)
             t_6
             (- (+ (* 9.0 (* (/ y (* c z)) x)) t_1) t_2))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = b / (c * z);
	double t_2 = 4.0 * ((a * t) / c);
	double t_3 = (x * 9.0) * y;
	double t_4 = (t_3 - (((z * 4.0) * t) * a)) + b;
	double t_5 = t_4 / (z * c);
	double t_6 = ((t_3 - ((z * 4.0) * (t * a))) + b) / (z * c);
	double tmp;
	if (t_5 < -1.100156740804105e-171) {
		tmp = t_6;
	} else if (t_5 < 0.0) {
		tmp = (t_4 / z) / c;
	} else if (t_5 < 1.1708877911747488e-53) {
		tmp = t_6;
	} else if (t_5 < 2.876823679546137e+130) {
		tmp = (((9.0 * (y / c)) * (x / z)) + t_1) - t_2;
	} else if (t_5 < 1.3838515042456319e+158) {
		tmp = t_6;
	} else {
		tmp = ((9.0 * ((y / (c * z)) * x)) + t_1) - t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
    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) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: t_4
    real(8) :: t_5
    real(8) :: t_6
    real(8) :: tmp
    t_1 = b / (c * z)
    t_2 = 4.0d0 * ((a * t) / c)
    t_3 = (x * 9.0d0) * y
    t_4 = (t_3 - (((z * 4.0d0) * t) * a)) + b
    t_5 = t_4 / (z * c)
    t_6 = ((t_3 - ((z * 4.0d0) * (t * a))) + b) / (z * c)
    if (t_5 < (-1.100156740804105d-171)) then
        tmp = t_6
    else if (t_5 < 0.0d0) then
        tmp = (t_4 / z) / c
    else if (t_5 < 1.1708877911747488d-53) then
        tmp = t_6
    else if (t_5 < 2.876823679546137d+130) then
        tmp = (((9.0d0 * (y / c)) * (x / z)) + t_1) - t_2
    else if (t_5 < 1.3838515042456319d+158) then
        tmp = t_6
    else
        tmp = ((9.0d0 * ((y / (c * z)) * x)) + t_1) - t_2
    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 t_1 = b / (c * z);
	double t_2 = 4.0 * ((a * t) / c);
	double t_3 = (x * 9.0) * y;
	double t_4 = (t_3 - (((z * 4.0) * t) * a)) + b;
	double t_5 = t_4 / (z * c);
	double t_6 = ((t_3 - ((z * 4.0) * (t * a))) + b) / (z * c);
	double tmp;
	if (t_5 < -1.100156740804105e-171) {
		tmp = t_6;
	} else if (t_5 < 0.0) {
		tmp = (t_4 / z) / c;
	} else if (t_5 < 1.1708877911747488e-53) {
		tmp = t_6;
	} else if (t_5 < 2.876823679546137e+130) {
		tmp = (((9.0 * (y / c)) * (x / z)) + t_1) - t_2;
	} else if (t_5 < 1.3838515042456319e+158) {
		tmp = t_6;
	} else {
		tmp = ((9.0 * ((y / (c * z)) * x)) + t_1) - t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c):
	t_1 = b / (c * z)
	t_2 = 4.0 * ((a * t) / c)
	t_3 = (x * 9.0) * y
	t_4 = (t_3 - (((z * 4.0) * t) * a)) + b
	t_5 = t_4 / (z * c)
	t_6 = ((t_3 - ((z * 4.0) * (t * a))) + b) / (z * c)
	tmp = 0
	if t_5 < -1.100156740804105e-171:
		tmp = t_6
	elif t_5 < 0.0:
		tmp = (t_4 / z) / c
	elif t_5 < 1.1708877911747488e-53:
		tmp = t_6
	elif t_5 < 2.876823679546137e+130:
		tmp = (((9.0 * (y / c)) * (x / z)) + t_1) - t_2
	elif t_5 < 1.3838515042456319e+158:
		tmp = t_6
	else:
		tmp = ((9.0 * ((y / (c * z)) * x)) + t_1) - t_2
	return tmp
function code(x, y, z, t, a, b, c)
	t_1 = Float64(b / Float64(c * z))
	t_2 = Float64(4.0 * Float64(Float64(a * t) / c))
	t_3 = Float64(Float64(x * 9.0) * y)
	t_4 = Float64(Float64(t_3 - Float64(Float64(Float64(z * 4.0) * t) * a)) + b)
	t_5 = Float64(t_4 / Float64(z * c))
	t_6 = Float64(Float64(Float64(t_3 - Float64(Float64(z * 4.0) * Float64(t * a))) + b) / Float64(z * c))
	tmp = 0.0
	if (t_5 < -1.100156740804105e-171)
		tmp = t_6;
	elseif (t_5 < 0.0)
		tmp = Float64(Float64(t_4 / z) / c);
	elseif (t_5 < 1.1708877911747488e-53)
		tmp = t_6;
	elseif (t_5 < 2.876823679546137e+130)
		tmp = Float64(Float64(Float64(Float64(9.0 * Float64(y / c)) * Float64(x / z)) + t_1) - t_2);
	elseif (t_5 < 1.3838515042456319e+158)
		tmp = t_6;
	else
		tmp = Float64(Float64(Float64(9.0 * Float64(Float64(y / Float64(c * z)) * x)) + t_1) - t_2);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = b / (c * z);
	t_2 = 4.0 * ((a * t) / c);
	t_3 = (x * 9.0) * y;
	t_4 = (t_3 - (((z * 4.0) * t) * a)) + b;
	t_5 = t_4 / (z * c);
	t_6 = ((t_3 - ((z * 4.0) * (t * a))) + b) / (z * c);
	tmp = 0.0;
	if (t_5 < -1.100156740804105e-171)
		tmp = t_6;
	elseif (t_5 < 0.0)
		tmp = (t_4 / z) / c;
	elseif (t_5 < 1.1708877911747488e-53)
		tmp = t_6;
	elseif (t_5 < 2.876823679546137e+130)
		tmp = (((9.0 * (y / c)) * (x / z)) + t_1) - t_2;
	elseif (t_5 < 1.3838515042456319e+158)
		tmp = t_6;
	else
		tmp = ((9.0 * ((y / (c * z)) * x)) + t_1) - t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(b / N[(c * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(x * 9.0), $MachinePrecision] * y), $MachinePrecision]}, Block[{t$95$4 = N[(N[(t$95$3 - N[(N[(N[(z * 4.0), $MachinePrecision] * t), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision]}, Block[{t$95$5 = N[(t$95$4 / N[(z * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(N[(N[(t$95$3 - N[(N[(z * 4.0), $MachinePrecision] * N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]}, If[Less[t$95$5, -1.100156740804105e-171], t$95$6, If[Less[t$95$5, 0.0], N[(N[(t$95$4 / z), $MachinePrecision] / c), $MachinePrecision], If[Less[t$95$5, 1.1708877911747488e-53], t$95$6, If[Less[t$95$5, 2.876823679546137e+130], N[(N[(N[(N[(9.0 * N[(y / c), $MachinePrecision]), $MachinePrecision] * N[(x / z), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision], If[Less[t$95$5, 1.3838515042456319e+158], t$95$6, N[(N[(N[(9.0 * N[(N[(y / N[(c * z), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision] - t$95$2), $MachinePrecision]]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{b}{c \cdot z}\\
t_2 := 4 \cdot \frac{a \cdot t}{c}\\
t_3 := \left(x \cdot 9\right) \cdot y\\
t_4 := \left(t_3 - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b\\
t_5 := \frac{t_4}{z \cdot c}\\
t_6 := \frac{\left(t_3 - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right) + b}{z \cdot c}\\
\mathbf{if}\;t_5 < -1.100156740804105 \cdot 10^{-171}:\\
\;\;\;\;t_6\\

\mathbf{elif}\;t_5 < 0:\\
\;\;\;\;\frac{\frac{t_4}{z}}{c}\\

\mathbf{elif}\;t_5 < 1.1708877911747488 \cdot 10^{-53}:\\
\;\;\;\;t_6\\

\mathbf{elif}\;t_5 < 2.876823679546137 \cdot 10^{+130}:\\
\;\;\;\;\left(\left(9 \cdot \frac{y}{c}\right) \cdot \frac{x}{z} + t_1\right) - t_2\\

\mathbf{elif}\;t_5 < 1.3838515042456319 \cdot 10^{+158}:\\
\;\;\;\;t_6\\

\mathbf{else}:\\
\;\;\;\;\left(9 \cdot \left(\frac{y}{c \cdot z} \cdot x\right) + t_1\right) - t_2\\


\end{array}
\end{array}

Reproduce

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