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

Percentage Accurate: 79.7% → 86.0%
Time: 18.0s
Alternatives: 15
Speedup: 0.7×

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 15 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: 79.7% 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: 86.0% accurate, 0.7× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_1 := t \cdot \left(a \cdot -4\right)\\ t_2 := \frac{t_1 + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{if}\;z \leq -1.46 \cdot 10^{+156}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -5.2 \cdot 10^{+98}:\\ \;\;\;\;\frac{t_1 + \frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -9.8 \cdot 10^{+72} \lor \neg \left(z \leq 1.95 \cdot 10^{+159}\right):\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;\frac{b + \left(\left(x \cdot 9\right) \cdot y - 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.
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (* t (* a -4.0))) (t_2 (/ (+ t_1 (* 9.0 (/ y (/ z x)))) c)))
   (if (<= z -1.46e+156)
     t_2
     (if (<= z -5.2e+98)
       (/ (+ t_1 (/ b z)) c)
       (if (or (<= z -9.8e+72) (not (<= z 1.95e+159)))
         t_2
         (/ (+ b (- (* (* x 9.0) y) (* a (* t (* z 4.0))))) (* z c)))))))
assert(x < y);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = t * (a * -4.0);
	double t_2 = (t_1 + (9.0 * (y / (z / x)))) / c;
	double tmp;
	if (z <= -1.46e+156) {
		tmp = t_2;
	} else if (z <= -5.2e+98) {
		tmp = (t_1 + (b / z)) / c;
	} else if ((z <= -9.8e+72) || !(z <= 1.95e+159)) {
		tmp = t_2;
	} else {
		tmp = (b + (((x * 9.0) * y) - (a * (t * (z * 4.0))))) / (z * c);
	}
	return tmp;
}
NOTE: x and y 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 = t * (a * (-4.0d0))
    t_2 = (t_1 + (9.0d0 * (y / (z / x)))) / c
    if (z <= (-1.46d+156)) then
        tmp = t_2
    else if (z <= (-5.2d+98)) then
        tmp = (t_1 + (b / z)) / c
    else if ((z <= (-9.8d+72)) .or. (.not. (z <= 1.95d+159))) then
        tmp = t_2
    else
        tmp = (b + (((x * 9.0d0) * y) - (a * (t * (z * 4.0d0))))) / (z * c)
    end if
    code = tmp
end function
assert x < y;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = t * (a * -4.0);
	double t_2 = (t_1 + (9.0 * (y / (z / x)))) / c;
	double tmp;
	if (z <= -1.46e+156) {
		tmp = t_2;
	} else if (z <= -5.2e+98) {
		tmp = (t_1 + (b / z)) / c;
	} else if ((z <= -9.8e+72) || !(z <= 1.95e+159)) {
		tmp = t_2;
	} else {
		tmp = (b + (((x * 9.0) * y) - (a * (t * (z * 4.0))))) / (z * c);
	}
	return tmp;
}
[x, y] = sort([x, y])
def code(x, y, z, t, a, b, c):
	t_1 = t * (a * -4.0)
	t_2 = (t_1 + (9.0 * (y / (z / x)))) / c
	tmp = 0
	if z <= -1.46e+156:
		tmp = t_2
	elif z <= -5.2e+98:
		tmp = (t_1 + (b / z)) / c
	elif (z <= -9.8e+72) or not (z <= 1.95e+159):
		tmp = t_2
	else:
		tmp = (b + (((x * 9.0) * y) - (a * (t * (z * 4.0))))) / (z * c)
	return tmp
x, y = sort([x, y])
function code(x, y, z, t, a, b, c)
	t_1 = Float64(t * Float64(a * -4.0))
	t_2 = Float64(Float64(t_1 + Float64(9.0 * Float64(y / Float64(z / x)))) / c)
	tmp = 0.0
	if (z <= -1.46e+156)
		tmp = t_2;
	elseif (z <= -5.2e+98)
		tmp = Float64(Float64(t_1 + Float64(b / z)) / c);
	elseif ((z <= -9.8e+72) || !(z <= 1.95e+159))
		tmp = t_2;
	else
		tmp = Float64(Float64(b + Float64(Float64(Float64(x * 9.0) * y) - Float64(a * Float64(t * Float64(z * 4.0))))) / Float64(z * c));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = t * (a * -4.0);
	t_2 = (t_1 + (9.0 * (y / (z / x)))) / c;
	tmp = 0.0;
	if (z <= -1.46e+156)
		tmp = t_2;
	elseif (z <= -5.2e+98)
		tmp = (t_1 + (b / z)) / c;
	elseif ((z <= -9.8e+72) || ~((z <= 1.95e+159)))
		tmp = t_2;
	else
		tmp = (b + (((x * 9.0) * y) - (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.
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(t$95$1 + N[(9.0 * N[(y / N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]}, If[LessEqual[z, -1.46e+156], t$95$2, If[LessEqual[z, -5.2e+98], N[(N[(t$95$1 + N[(b / z), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision], If[Or[LessEqual[z, -9.8e+72], N[Not[LessEqual[z, 1.95e+159]], $MachinePrecision]], t$95$2, N[(N[(b + N[(N[(N[(x * 9.0), $MachinePrecision] * y), $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])\\
\\
\begin{array}{l}
t_1 := t \cdot \left(a \cdot -4\right)\\
t_2 := \frac{t_1 + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\
\mathbf{if}\;z \leq -1.46 \cdot 10^{+156}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq -5.2 \cdot 10^{+98}:\\
\;\;\;\;\frac{t_1 + \frac{b}{z}}{c}\\

\mathbf{elif}\;z \leq -9.8 \cdot 10^{+72} \lor \neg \left(z \leq 1.95 \cdot 10^{+159}\right):\\
\;\;\;\;t_2\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.46000000000000007e156 or -5.1999999999999999e98 < z < -9.80000000000000012e72 or 1.95e159 < z

    1. Initial program 49.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-/r*59.7%

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

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

      \[\leadsto \frac{\color{blue}{9 \cdot \frac{y \cdot x}{z}} + t \cdot \left(a \cdot -4\right)}{c} \]
    5. Step-by-step derivation
      1. associate-/l*93.5%

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

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

    if -1.46000000000000007e156 < z < -5.1999999999999999e98

    1. Initial program 60.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-/r*75.8%

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

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

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

    if -9.80000000000000012e72 < z < 1.95e159

    1. Initial program 93.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} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification92.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.46 \cdot 10^{+156}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{elif}\;z \leq -5.2 \cdot 10^{+98}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + \frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -9.8 \cdot 10^{+72} \lor \neg \left(z \leq 1.95 \cdot 10^{+159}\right):\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{b + \left(\left(x \cdot 9\right) \cdot y - a \cdot \left(t \cdot \left(z \cdot 4\right)\right)\right)}{z \cdot c}\\ \end{array} \]

Alternative 2: 87.5% accurate, 0.1× speedup?

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 (*.f64 x 9) y) < 9.99999999999999974e232

    1. Initial program 85.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-/r*84.0%

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

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

    if 9.99999999999999974e232 < (*.f64 (*.f64 x 9) y)

    1. Initial program 51.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-/r*51.8%

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

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

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

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

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

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

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

Alternative 3: 87.0% accurate, 0.2× speedup?

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 (*.f64 x 9) y) < 9.99999999999999974e232

    1. Initial program 85.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-/r*84.0%

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

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

    if 9.99999999999999974e232 < (*.f64 (*.f64 x 9) y)

    1. Initial program 51.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-/r*51.8%

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

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

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

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

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

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

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

Alternative 4: 84.9% accurate, 0.7× speedup?

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

\mathbf{elif}\;z \leq -2.35 \cdot 10^{+98}:\\
\;\;\;\;\frac{t_1 + \frac{b}{z}}{c}\\

\mathbf{elif}\;z \leq -6.7 \cdot 10^{+72} \lor \neg \left(z \leq 3.5 \cdot 10^{+158}\right):\\
\;\;\;\;t_2\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.62000000000000006e156 or -2.34999999999999985e98 < z < -6.6999999999999998e72 or 3.5000000000000001e158 < z

    1. Initial program 49.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-/r*59.7%

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

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

      \[\leadsto \frac{\color{blue}{9 \cdot \frac{y \cdot x}{z}} + t \cdot \left(a \cdot -4\right)}{c} \]
    5. Step-by-step derivation
      1. associate-/l*93.5%

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

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

    if -1.62000000000000006e156 < z < -2.34999999999999985e98

    1. Initial program 60.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-/r*75.8%

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

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

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

    if -6.6999999999999998e72 < z < 3.5000000000000001e158

    1. Initial program 93.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*93.2%

        \[\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 c} \]
      2. associate-*l*91.7%

        \[\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 c} \]
    3. Simplified91.7%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.62 \cdot 10^{+156}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{elif}\;z \leq -2.35 \cdot 10^{+98}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + \frac{b}{z}}{c}\\ \mathbf{elif}\;z \leq -6.7 \cdot 10^{+72} \lor \neg \left(z \leq 3.5 \cdot 10^{+158}\right):\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - \left(z \cdot 4\right) \cdot \left(t \cdot a\right)\right)}{z \cdot c}\\ \end{array} \]

Alternative 5: 71.3% accurate, 0.9× speedup?

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

\mathbf{elif}\;y \leq 7.8 \cdot 10^{+105}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 1.04 \cdot 10^{+201}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;y \leq 10^{+208}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;\frac{9 \cdot \frac{y}{\frac{z}{x}} + \frac{b}{z}}{c}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -8.20000000000000074e-108 or 7.79999999999999957e105 < y < 1.0400000000000001e201

    1. Initial program 78.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-/r*72.4%

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

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

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

    if -8.20000000000000074e-108 < y < 7.79999999999999957e105 or 1.0400000000000001e201 < y < 9.9999999999999998e207

    1. Initial program 84.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-/r*84.0%

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

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

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

    if 9.9999999999999998e207 < y

    1. Initial program 79.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-/r*88.5%

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

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

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

        \[\leadsto \frac{\frac{b}{z} + 9 \cdot \color{blue}{\frac{y}{\frac{z}{x}}}}{c} \]
    6. Simplified88.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -8.2 \cdot 10^{-108}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{elif}\;y \leq 7.8 \cdot 10^{+105}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + \frac{b}{z}}{c}\\ \mathbf{elif}\;y \leq 1.04 \cdot 10^{+201}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{elif}\;y \leq 10^{+208}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + \frac{b}{z}}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{9 \cdot \frac{y}{\frac{z}{x}} + \frac{b}{z}}{c}\\ \end{array} \]

Alternative 6: 73.7% accurate, 1.0× speedup?

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

\mathbf{else}:\\
\;\;\;\;\frac{t_1 + 9 \cdot \frac{y}{\frac{z}{x}}}{c}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -1.7e33 or 2.3999999999999999e-138 < b

    1. Initial program 80.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-/r*78.7%

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

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

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

    if -1.7e33 < b < 2.3999999999999999e-138

    1. Initial program 82.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-/r*82.7%

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

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

      \[\leadsto \frac{\color{blue}{9 \cdot \frac{y \cdot x}{z}} + t \cdot \left(a \cdot -4\right)}{c} \]
    5. Step-by-step derivation
      1. associate-/l*89.8%

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

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

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

Alternative 7: 47.4% accurate, 1.1× speedup?

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

\mathbf{elif}\;t \leq -5.5 \cdot 10^{-130}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;t \leq 3.6 \cdot 10^{-267}:\\
\;\;\;\;\frac{1}{z \cdot \frac{c}{b}}\\

\mathbf{elif}\;t \leq 8 \cdot 10^{-155}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;t \leq 3.4 \cdot 10^{-124}:\\
\;\;\;\;\frac{b}{z \cdot c}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if t < -1.14999999999999997e77

    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-/r*67.4%

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

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

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

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

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

    if -1.14999999999999997e77 < t < -5.50000000000000007e-130 or 3.6000000000000001e-267 < t < 8.00000000000000011e-155

    1. Initial program 88.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-/r*77.9%

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

      \[\leadsto \color{blue}{\frac{\frac{\mathsf{fma}\left(x, 9 \cdot y, b\right)}{z} + t \cdot \left(a \cdot -4\right)}{c}} \]
    4. Step-by-step derivation
      1. clear-num82.1%

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

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

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

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

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

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

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

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

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

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

    if -5.50000000000000007e-130 < t < 3.6000000000000001e-267

    1. Initial program 80.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*80.9%

        \[\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 c} \]
      2. associate-*l*83.7%

        \[\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 c} \]
    3. Simplified83.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto {\color{blue}{\left(\frac{c}{\frac{b}{z}}\right)}}^{-1} \]
    8. Simplified53.4%

      \[\leadsto {\color{blue}{\left(\frac{c}{\frac{b}{z}}\right)}}^{-1} \]
    9. Step-by-step derivation
      1. unpow-153.4%

        \[\leadsto \color{blue}{\frac{1}{\frac{c}{\frac{b}{z}}}} \]
      2. associate-/r/55.9%

        \[\leadsto \frac{1}{\color{blue}{\frac{c}{b} \cdot z}} \]
    10. Applied egg-rr55.9%

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

    if 8.00000000000000011e-155 < t < 3.4000000000000001e-124

    1. Initial program 84.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-/r*100.0%

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

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

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

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

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

    if 3.4000000000000001e-124 < t

    1. Initial program 84.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-/r*84.3%

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

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

      \[\leadsto \frac{\color{blue}{-4 \cdot \left(a \cdot t\right)}}{c} \]
    5. Step-by-step derivation
      1. associate-*r*38.5%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.15 \cdot 10^{+77}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;t \leq -5.5 \cdot 10^{-130}:\\ \;\;\;\;9 \cdot \left(x \cdot \frac{\frac{y}{c}}{z}\right)\\ \mathbf{elif}\;t \leq 3.6 \cdot 10^{-267}:\\ \;\;\;\;\frac{1}{z \cdot \frac{c}{b}}\\ \mathbf{elif}\;t \leq 8 \cdot 10^{-155}:\\ \;\;\;\;9 \cdot \left(x \cdot \frac{\frac{y}{c}}{z}\right)\\ \mathbf{elif}\;t \leq 3.4 \cdot 10^{-124}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right)}{c}\\ \end{array} \]

Alternative 8: 71.1% accurate, 1.1× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} t_1 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{if}\;y \leq -1 \cdot 10^{-107}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 1.7 \cdot 10^{+102}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + \frac{b}{z}}{c}\\ \mathbf{elif}\;y \leq 6.5 \cdot 10^{+241}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;9 \cdot \frac{\frac{y}{\frac{z}{x}}}{c}\\ \end{array} \end{array} \]
NOTE: x and y 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))))
   (if (<= y -1e-107)
     t_1
     (if (<= y 1.7e+102)
       (/ (+ (* t (* a -4.0)) (/ b z)) c)
       (if (<= y 6.5e+241) t_1 (* 9.0 (/ (/ y (/ z x)) c)))))))
assert(x < y);
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 tmp;
	if (y <= -1e-107) {
		tmp = t_1;
	} else if (y <= 1.7e+102) {
		tmp = ((t * (a * -4.0)) + (b / z)) / c;
	} else if (y <= 6.5e+241) {
		tmp = t_1;
	} else {
		tmp = 9.0 * ((y / (z / x)) / c);
	}
	return tmp;
}
NOTE: x and y 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 = (b + (9.0d0 * (x * y))) / (z * c)
    if (y <= (-1d-107)) then
        tmp = t_1
    else if (y <= 1.7d+102) then
        tmp = ((t * (a * (-4.0d0))) + (b / z)) / c
    else if (y <= 6.5d+241) then
        tmp = t_1
    else
        tmp = 9.0d0 * ((y / (z / x)) / c)
    end if
    code = tmp
end function
assert x < y;
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 tmp;
	if (y <= -1e-107) {
		tmp = t_1;
	} else if (y <= 1.7e+102) {
		tmp = ((t * (a * -4.0)) + (b / z)) / c;
	} else if (y <= 6.5e+241) {
		tmp = t_1;
	} else {
		tmp = 9.0 * ((y / (z / x)) / c);
	}
	return tmp;
}
[x, y] = sort([x, y])
def code(x, y, z, t, a, b, c):
	t_1 = (b + (9.0 * (x * y))) / (z * c)
	tmp = 0
	if y <= -1e-107:
		tmp = t_1
	elif y <= 1.7e+102:
		tmp = ((t * (a * -4.0)) + (b / z)) / c
	elif y <= 6.5e+241:
		tmp = t_1
	else:
		tmp = 9.0 * ((y / (z / x)) / c)
	return tmp
x, y = sort([x, y])
function code(x, y, z, t, a, b, c)
	t_1 = Float64(Float64(b + Float64(9.0 * Float64(x * y))) / Float64(z * c))
	tmp = 0.0
	if (y <= -1e-107)
		tmp = t_1;
	elseif (y <= 1.7e+102)
		tmp = Float64(Float64(Float64(t * Float64(a * -4.0)) + Float64(b / z)) / c);
	elseif (y <= 6.5e+241)
		tmp = t_1;
	else
		tmp = Float64(9.0 * Float64(Float64(y / Float64(z / x)) / c));
	end
	return tmp
end
x, y = num2cell(sort([x, y])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = (b + (9.0 * (x * y))) / (z * c);
	tmp = 0.0;
	if (y <= -1e-107)
		tmp = t_1;
	elseif (y <= 1.7e+102)
		tmp = ((t * (a * -4.0)) + (b / z)) / c;
	elseif (y <= 6.5e+241)
		tmp = t_1;
	else
		tmp = 9.0 * ((y / (z / x)) / c);
	end
	tmp_2 = tmp;
end
NOTE: x and y 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]}, If[LessEqual[y, -1e-107], t$95$1, If[LessEqual[y, 1.7e+102], N[(N[(N[(t * N[(a * -4.0), $MachinePrecision]), $MachinePrecision] + N[(b / z), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision], If[LessEqual[y, 6.5e+241], t$95$1, N[(9.0 * N[(N[(y / N[(z / x), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
\\
\begin{array}{l}
t_1 := \frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\
\mathbf{if}\;y \leq -1 \cdot 10^{-107}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;y \leq 6.5 \cdot 10^{+241}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;9 \cdot \frac{\frac{y}{\frac{z}{x}}}{c}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -1e-107 or 1.7e102 < y < 6.4999999999999994e241

    1. Initial program 80.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-/r*74.9%

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

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

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

    if -1e-107 < y < 1.7e102

    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-/r*83.8%

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

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

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

    if 6.4999999999999994e241 < y

    1. Initial program 73.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-/r*84.8%

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

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

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

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

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

      \[\leadsto \color{blue}{9 \cdot \frac{y}{\frac{z \cdot c}{x}}} \]
    7. Taylor expanded in y around 0 57.6%

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

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

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

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

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

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

        \[\leadsto 9 \cdot \color{blue}{\frac{x \cdot \frac{y}{z}}{c}} \]
    11. Applied egg-rr80.3%

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

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

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

        \[\leadsto 9 \cdot \frac{\color{blue}{\frac{y}{\frac{z}{x}}}}{c} \]
    13. Simplified80.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1 \cdot 10^{-107}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{elif}\;y \leq 1.7 \cdot 10^{+102}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right) + \frac{b}{z}}{c}\\ \mathbf{elif}\;y \leq 6.5 \cdot 10^{+241}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;9 \cdot \frac{\frac{y}{\frac{z}{x}}}{c}\\ \end{array} \]

Alternative 9: 69.2% accurate, 1.3× speedup?

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -2.00000000000000014e174

    1. Initial program 38.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-/r*47.3%

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

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

      \[\leadsto \frac{\color{blue}{-4 \cdot \left(a \cdot t\right)}}{c} \]
    5. Step-by-step derivation
      1. associate-*r*70.3%

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

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

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

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

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

    if -2.00000000000000014e174 < z < 1.09999999999999997e71

    1. Initial program 90.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-/r*85.8%

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

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

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

    if 1.09999999999999997e71 < z

    1. Initial program 66.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-/r*74.5%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2 \cdot 10^{+174}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right)}{c}\\ \mathbf{elif}\;z \leq 1.1 \cdot 10^{+71}:\\ \;\;\;\;\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: 50.0% accurate, 1.4× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if b < -5.2e21

    1. Initial program 90.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-/r*84.8%

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

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

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

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

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

    if -5.2e21 < b < 1.9e-249

    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-/r*81.3%

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

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

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

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

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

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

    if 1.9e-249 < b < 1.02e77

    1. Initial program 80.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-/r*81.6%

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

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

      \[\leadsto \frac{\color{blue}{-4 \cdot \left(a \cdot t\right)}}{c} \]
    5. Step-by-step derivation
      1. associate-*r*53.4%

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

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

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

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

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

    if 1.02e77 < b

    1. Initial program 74.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*74.2%

        \[\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 c} \]
      2. associate-*l*72.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 c} \]
    3. Simplified72.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 c}} \]
    4. Step-by-step derivation
      1. clear-num72.4%

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto {\color{blue}{\left(\frac{c}{\frac{b}{z}}\right)}}^{-1} \]
    8. Simplified57.5%

      \[\leadsto {\color{blue}{\left(\frac{c}{\frac{b}{z}}\right)}}^{-1} \]
    9. Step-by-step derivation
      1. unpow-157.5%

        \[\leadsto \color{blue}{\frac{1}{\frac{c}{\frac{b}{z}}}} \]
      2. associate-/r/59.5%

        \[\leadsto \frac{1}{\color{blue}{\frac{c}{b} \cdot z}} \]
    10. Applied egg-rr59.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -5.2 \cdot 10^{+21}:\\ \;\;\;\;\frac{b}{z \cdot c}\\ \mathbf{elif}\;b \leq 1.9 \cdot 10^{-249}:\\ \;\;\;\;9 \cdot \left(\frac{y}{z} \cdot \frac{x}{c}\right)\\ \mathbf{elif}\;b \leq 1.02 \cdot 10^{+77}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{z \cdot \frac{c}{b}}\\ \end{array} \]

Alternative 11: 48.3% accurate, 1.7× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -4.4 \cdot 10^{+28} \lor \neg \left(t \leq 1.6 \cdot 10^{-124}\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.
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= t -4.4e+28) (not (<= t 1.6e-124)))
   (* -4.0 (* t (/ a c)))
   (/ b (* z c))))
assert(x < y);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((t <= -4.4e+28) || !(t <= 1.6e-124)) {
		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.
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 ((t <= (-4.4d+28)) .or. (.not. (t <= 1.6d-124))) then
        tmp = (-4.0d0) * (t * (a / c))
    else
        tmp = b / (z * c)
    end if
    code = tmp
end function
assert x < y;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((t <= -4.4e+28) || !(t <= 1.6e-124)) {
		tmp = -4.0 * (t * (a / c));
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
[x, y] = sort([x, y])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (t <= -4.4e+28) or not (t <= 1.6e-124):
		tmp = -4.0 * (t * (a / c))
	else:
		tmp = b / (z * c)
	return tmp
x, y = sort([x, y])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((t <= -4.4e+28) || !(t <= 1.6e-124))
		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])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((t <= -4.4e+28) || ~((t <= 1.6e-124)))
		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.
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[t, -4.4e+28], N[Not[LessEqual[t, 1.6e-124]], $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])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.4 \cdot 10^{+28} \lor \neg \left(t \leq 1.6 \cdot 10^{-124}\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 t < -4.39999999999999973e28 or 1.60000000000000002e-124 < t

    1. Initial program 78.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-/r*77.2%

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

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

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

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

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

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

    if -4.39999999999999973e28 < t < 1.60000000000000002e-124

    1. Initial program 85.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-/r*85.8%

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

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

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

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

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

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

Alternative 12: 48.9% accurate, 1.7× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \begin{array}{l} \mathbf{if}\;t \leq -1.22 \cdot 10^{+28} \lor \neg \left(t \leq 1.4 \cdot 10^{-124}\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.
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= t -1.22e+28) (not (<= t 1.4e-124)))
   (* -4.0 (/ a (/ c t)))
   (/ b (* z c))))
assert(x < y);
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((t <= -1.22e+28) || !(t <= 1.4e-124)) {
		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.
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 ((t <= (-1.22d+28)) .or. (.not. (t <= 1.4d-124))) then
        tmp = (-4.0d0) * (a / (c / t))
    else
        tmp = b / (z * c)
    end if
    code = tmp
end function
assert x < y;
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((t <= -1.22e+28) || !(t <= 1.4e-124)) {
		tmp = -4.0 * (a / (c / t));
	} else {
		tmp = b / (z * c);
	}
	return tmp;
}
[x, y] = sort([x, y])
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (t <= -1.22e+28) or not (t <= 1.4e-124):
		tmp = -4.0 * (a / (c / t))
	else:
		tmp = b / (z * c)
	return tmp
x, y = sort([x, y])
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((t <= -1.22e+28) || !(t <= 1.4e-124))
		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])){:}
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((t <= -1.22e+28) || ~((t <= 1.4e-124)))
		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.
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[t, -1.22e+28], N[Not[LessEqual[t, 1.4e-124]], $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])\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.22 \cdot 10^{+28} \lor \neg \left(t \leq 1.4 \cdot 10^{-124}\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 t < -1.2199999999999999e28 or 1.39999999999999999e-124 < t

    1. Initial program 78.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-/r*77.2%

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

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

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

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

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

    if -1.2199999999999999e28 < t < 1.39999999999999999e-124

    1. Initial program 85.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-/r*85.8%

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

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

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

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

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

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

Alternative 13: 48.9% accurate, 1.7× speedup?

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.3000000000000001e28 or 2.9000000000000002e-124 < t

    1. Initial program 78.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-/r*77.2%

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

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

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

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

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

    if -1.3000000000000001e28 < t < 2.9000000000000002e-124

    1. Initial program 85.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-/r*85.8%

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

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

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

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

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]
    7. Step-by-step derivation
      1. div-inv45.2%

        \[\leadsto \color{blue}{b \cdot \frac{1}{z \cdot c}} \]
    8. Applied egg-rr45.2%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.3 \cdot 10^{+28} \lor \neg \left(t \leq 2.9 \cdot 10^{-124}\right):\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;b \cdot \frac{1}{z \cdot c}\\ \end{array} \]

Alternative 14: 47.8% accurate, 1.7× speedup?

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

\mathbf{elif}\;t \leq 1.75 \cdot 10^{-124}:\\
\;\;\;\;b \cdot \frac{1}{z \cdot c}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -7.0000000000000004e27

    1. Initial program 71.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-/r*67.4%

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

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

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

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

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

    if -7.0000000000000004e27 < t < 1.7499999999999999e-124

    1. Initial program 85.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-/r*85.8%

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

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

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

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

      \[\leadsto \color{blue}{\frac{b}{z \cdot c}} \]
    7. Step-by-step derivation
      1. div-inv45.2%

        \[\leadsto \color{blue}{b \cdot \frac{1}{z \cdot c}} \]
    8. Applied egg-rr45.2%

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

    if 1.7499999999999999e-124 < t

    1. Initial program 84.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-/r*84.3%

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

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

      \[\leadsto \frac{\color{blue}{-4 \cdot \left(a \cdot t\right)}}{c} \]
    5. Step-by-step derivation
      1. associate-*r*38.5%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -7 \cdot 10^{+27}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{elif}\;t \leq 1.75 \cdot 10^{-124}:\\ \;\;\;\;b \cdot \frac{1}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot \left(a \cdot -4\right)}{c}\\ \end{array} \]

Alternative 15: 36.0% accurate, 3.8× speedup?

\[\begin{array}{l} [x, y] = \mathsf{sort}([x, y])\\ \\ \frac{b}{z \cdot c} \end{array} \]
NOTE: x and y 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);
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.
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;
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])
def code(x, y, z, t, a, b, c):
	return b / (z * c)
x, y = sort([x, y])
function code(x, y, z, t, a, b, c)
	return Float64(b / Float64(z * c))
end
x, y = num2cell(sort([x, y])){:}
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.
code[x_, y_, z_, t_, a_, b_, c_] := N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y] = \mathsf{sort}([x, y])\\
\\
\frac{b}{z \cdot c}
\end{array}
Derivation
  1. Initial program 81.5%

    \[\frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} \]
  2. Step-by-step derivation
    1. associate-/r*80.4%

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

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

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

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

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

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

Developer target: 80.3% 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 2023200 
(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)))