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

Percentage Accurate: 79.0% → 90.1%
Time: 18.2s
Alternatives: 17
Speedup: 0.8×

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 17 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.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{\left(\left(x \cdot 9\right) \cdot y - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (/ (+ (- (* (* x 9.0) y) (* (* (* z 4.0) t) a)) b) (* z c)))
double code(double x, double y, double z, double t, double a, double b, double c) {
	return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
real(8) function code(x, y, z, t, a, b, c)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    code = ((((x * 9.0d0) * y) - (((z * 4.0d0) * t) * a)) + b) / (z * c)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
}
def code(x, y, z, t, a, b, c):
	return ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c)
function code(x, y, z, t, a, b, c)
	return Float64(Float64(Float64(Float64(Float64(x * 9.0) * y) - Float64(Float64(Float64(z * 4.0) * t) * a)) + b) / Float64(z * c))
end
function tmp = code(x, y, z, t, a, b, c)
	tmp = ((((x * 9.0) * y) - (((z * 4.0) * t) * a)) + b) / (z * c);
end
code[x_, y_, z_, t_, a_, b_, c_] := N[(N[(N[(N[(N[(x * 9.0), $MachinePrecision] * y), $MachinePrecision] - N[(N[(N[(z * 4.0), $MachinePrecision] * t), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] + b), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

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

Alternative 1: 90.1% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.08 \cdot 10^{-14} \lor \neg \left(z \leq 8.8 \cdot 10^{+17}\right):\\ \;\;\;\;\mathsf{fma}\left(\frac{a}{c} \cdot t, -4, \frac{9 \cdot \frac{x \cdot y}{z} + \frac{b}{z}}{c}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - a \cdot \left(4 \cdot \left(z \cdot t\right)\right)\right)}{z \cdot c}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= z -1.08e-14) (not (<= z 8.8e+17)))
   (fma (* (/ a c) t) -4.0 (/ (+ (* 9.0 (/ (* x y) z)) (/ b z)) c))
   (/ (+ b (- (* x (* 9.0 y)) (* a (* 4.0 (* z t))))) (* z c))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -1.08e-14) || !(z <= 8.8e+17)) {
		tmp = fma(((a / c) * t), -4.0, (((9.0 * ((x * y) / z)) + (b / z)) / c));
	} else {
		tmp = (b + ((x * (9.0 * y)) - (a * (4.0 * (z * t))))) / (z * c);
	}
	return tmp;
}
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((z <= -1.08e-14) || !(z <= 8.8e+17))
		tmp = fma(Float64(Float64(a / c) * t), -4.0, Float64(Float64(Float64(9.0 * Float64(Float64(x * y) / z)) + Float64(b / z)) / c));
	else
		tmp = Float64(Float64(b + Float64(Float64(x * Float64(9.0 * y)) - Float64(a * Float64(4.0 * Float64(z * t))))) / Float64(z * c));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -1.08e-14], N[Not[LessEqual[z, 8.8e+17]], $MachinePrecision]], N[(N[(N[(a / c), $MachinePrecision] * t), $MachinePrecision] * -4.0 + N[(N[(N[(9.0 * N[(N[(x * y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision] + N[(b / z), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision], N[(N[(b + N[(N[(x * N[(9.0 * y), $MachinePrecision]), $MachinePrecision] - N[(a * N[(4.0 * N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.08 \cdot 10^{-14} \lor \neg \left(z \leq 8.8 \cdot 10^{+17}\right):\\
\;\;\;\;\mathsf{fma}\left(\frac{a}{c} \cdot t, -4, \frac{9 \cdot \frac{x \cdot y}{z} + \frac{b}{z}}{c}\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.08000000000000004e-14 or 8.8e17 < z

    1. Initial program 56.7%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*64.5%

        \[\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. Simplified64.5%

      \[\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. Taylor expanded in x around 0 78.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.08000000000000004e-14 < z < 8.8e17

    1. Initial program 98.4%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*93.2%

        \[\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. Simplified93.2%

      \[\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. Taylor expanded in z around 0 98.4%

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

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

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

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

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

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

Alternative 2: 86.9% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.8 \cdot 10^{+27}:\\
\;\;\;\;\left(\frac{b}{z \cdot c} + 9 \cdot \frac{x \cdot y}{z \cdot c}\right) - 4 \cdot \frac{a \cdot t}{c}\\

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

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


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

    1. Initial program 58.6%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*66.2%

        \[\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. Simplified66.2%

      \[\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. Taylor expanded in x around 0 81.4%

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

    if -3.80000000000000022e27 < z < 5.9999999999999999e83

    1. Initial program 96.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-96.2%

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\left(x \cdot 9\right) \cdot y - \color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a}\right) + b}{z \cdot c} \]
      9. associate-*l*96.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} \]
      10. associate-*l*91.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. Simplified91.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. Taylor expanded in z around 0 96.2%

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

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

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

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

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

    if 5.9999999999999999e83 < z

    1. Initial program 49.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-+l-49.5%

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*59.9%

        \[\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. Simplified59.9%

      \[\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. Applied egg-rr58.8%

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

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

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c} + \frac{b}{c \cdot z}} \]
    7. Taylor expanded in c around -inf 81.9%

      \[\leadsto \color{blue}{-1 \cdot \frac{-1 \cdot \frac{b}{z} + 4 \cdot \left(a \cdot t\right)}{c}} \]
    8. Step-by-step derivation
      1. associate-*r/81.9%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3.8 \cdot 10^{+27}:\\ \;\;\;\;\left(\frac{b}{z \cdot c} + 9 \cdot \frac{x \cdot y}{z \cdot c}\right) - 4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 6 \cdot 10^{+83}:\\ \;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - a \cdot \left(4 \cdot \left(z \cdot t\right)\right)\right)}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{z} - t \cdot \left(a \cdot 4\right)}{c}\\ \end{array} \]

Alternative 3: 85.6% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -8.8 \cdot 10^{+86}:\\
\;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\

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

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


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

    1. Initial program 51.1%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*60.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. Simplified60.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. Applied egg-rr58.6%

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

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

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c} + \frac{b}{c \cdot z}} \]
    7. Taylor expanded in c around 0 79.3%

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

    if -8.80000000000000013e86 < z < 7.4000000000000005e83

    1. Initial program 95.8%

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

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\left(x \cdot 9\right) \cdot y - \color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a}\right) + b}{z \cdot c} \]
      9. associate-*l*95.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} \]
      10. associate-*l*91.3%

        \[\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.3%

      \[\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. Taylor expanded in z around 0 95.9%

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

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

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

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

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

    if 7.4000000000000005e83 < z

    1. Initial program 49.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-+l-49.5%

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*59.9%

        \[\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. Simplified59.9%

      \[\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. Applied egg-rr58.8%

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

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

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c} + \frac{b}{c \cdot z}} \]
    7. Taylor expanded in c around -inf 81.9%

      \[\leadsto \color{blue}{-1 \cdot \frac{-1 \cdot \frac{b}{z} + 4 \cdot \left(a \cdot t\right)}{c}} \]
    8. Step-by-step derivation
      1. associate-*r/81.9%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -8.8 \cdot 10^{+86}:\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\ \mathbf{elif}\;z \leq 7.4 \cdot 10^{+83}:\\ \;\;\;\;\frac{b + \left(x \cdot \left(9 \cdot y\right) - a \cdot \left(4 \cdot \left(z \cdot t\right)\right)\right)}{z \cdot c}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{z} - t \cdot \left(a \cdot 4\right)}{c}\\ \end{array} \]

Alternative 4: 48.7% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := -4 \cdot \frac{a \cdot t}{c}\\ \mathbf{if}\;z \leq -1.3 \cdot 10^{+39}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 4 \cdot 10^{-29}:\\ \;\;\;\;b \cdot \frac{1}{z \cdot c}\\ \mathbf{elif}\;z \leq 5.5 \cdot 10^{+38} \lor \neg \left(z \leq 6 \cdot 10^{+118}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (* -4.0 (/ (* a t) c))))
   (if (<= z -1.3e+39)
     t_1
     (if (<= z 4e-29)
       (* b (/ 1.0 (* z c)))
       (if (or (<= z 5.5e+38) (not (<= z 6e+118))) t_1 (/ (/ b c) z))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = -4.0 * ((a * t) / c);
	double tmp;
	if (z <= -1.3e+39) {
		tmp = t_1;
	} else if (z <= 4e-29) {
		tmp = b * (1.0 / (z * c));
	} else if ((z <= 5.5e+38) || !(z <= 6e+118)) {
		tmp = t_1;
	} else {
		tmp = (b / c) / z;
	}
	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) :: tmp
    t_1 = (-4.0d0) * ((a * t) / c)
    if (z <= (-1.3d+39)) then
        tmp = t_1
    else if (z <= 4d-29) then
        tmp = b * (1.0d0 / (z * c))
    else if ((z <= 5.5d+38) .or. (.not. (z <= 6d+118))) then
        tmp = t_1
    else
        tmp = (b / c) / z
    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 = -4.0 * ((a * t) / c);
	double tmp;
	if (z <= -1.3e+39) {
		tmp = t_1;
	} else if (z <= 4e-29) {
		tmp = b * (1.0 / (z * c));
	} else if ((z <= 5.5e+38) || !(z <= 6e+118)) {
		tmp = t_1;
	} else {
		tmp = (b / c) / z;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c):
	t_1 = -4.0 * ((a * t) / c)
	tmp = 0
	if z <= -1.3e+39:
		tmp = t_1
	elif z <= 4e-29:
		tmp = b * (1.0 / (z * c))
	elif (z <= 5.5e+38) or not (z <= 6e+118):
		tmp = t_1
	else:
		tmp = (b / c) / z
	return tmp
function code(x, y, z, t, a, b, c)
	t_1 = Float64(-4.0 * Float64(Float64(a * t) / c))
	tmp = 0.0
	if (z <= -1.3e+39)
		tmp = t_1;
	elseif (z <= 4e-29)
		tmp = Float64(b * Float64(1.0 / Float64(z * c)));
	elseif ((z <= 5.5e+38) || !(z <= 6e+118))
		tmp = t_1;
	else
		tmp = Float64(Float64(b / c) / z);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = -4.0 * ((a * t) / c);
	tmp = 0.0;
	if (z <= -1.3e+39)
		tmp = t_1;
	elseif (z <= 4e-29)
		tmp = b * (1.0 / (z * c));
	elseif ((z <= 5.5e+38) || ~((z <= 6e+118)))
		tmp = t_1;
	else
		tmp = (b / c) / z;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(-4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.3e+39], t$95$1, If[LessEqual[z, 4e-29], N[(b * N[(1.0 / N[(z * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[z, 5.5e+38], N[Not[LessEqual[z, 6e+118]], $MachinePrecision]], t$95$1, N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := -4 \cdot \frac{a \cdot t}{c}\\
\mathbf{if}\;z \leq -1.3 \cdot 10^{+39}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq 4 \cdot 10^{-29}:\\
\;\;\;\;b \cdot \frac{1}{z \cdot c}\\

\mathbf{elif}\;z \leq 5.5 \cdot 10^{+38} \lor \neg \left(z \leq 6 \cdot 10^{+118}\right):\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.3e39 or 3.99999999999999977e-29 < z < 5.5000000000000003e38 or 6e118 < z

    1. Initial program 57.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-57.9%

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\left(x \cdot 9\right) \cdot y - \color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a}\right) + b}{z \cdot c} \]
      9. associate-*l*57.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} \]
      10. associate-*l*65.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. Simplified65.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. Taylor expanded in z around inf 64.7%

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

    if -1.3e39 < z < 3.99999999999999977e-29

    1. Initial program 96.5%

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

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

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

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

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

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

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

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

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

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

        \[\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.2%

      \[\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. 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-inv47.7%

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

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

    if 5.5000000000000003e38 < z < 6e118

    1. Initial program 71.4%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*78.9%

        \[\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. Simplified78.9%

      \[\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. Applied egg-rr78.6%

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

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

        \[\leadsto \color{blue}{\frac{\frac{b}{c}}{z}} \]
    7. Simplified65.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.3 \cdot 10^{+39}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 4 \cdot 10^{-29}:\\ \;\;\;\;b \cdot \frac{1}{z \cdot c}\\ \mathbf{elif}\;z \leq 5.5 \cdot 10^{+38} \lor \neg \left(z \leq 6 \cdot 10^{+118}\right):\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \end{array} \]

Alternative 5: 48.9% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := -4 \cdot \frac{a \cdot t}{c}\\ \mathbf{if}\;z \leq -2.1 \cdot 10^{+33}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 9.6 \cdot 10^{-31}:\\ \;\;\;\;b \cdot \frac{\frac{1}{c}}{z}\\ \mathbf{elif}\;z \leq 1.55 \cdot 10^{+33} \lor \neg \left(z \leq 2.15 \cdot 10^{+116}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (* -4.0 (/ (* a t) c))))
   (if (<= z -2.1e+33)
     t_1
     (if (<= z 9.6e-31)
       (* b (/ (/ 1.0 c) z))
       (if (or (<= z 1.55e+33) (not (<= z 2.15e+116))) t_1 (/ (/ b c) z))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = -4.0 * ((a * t) / c);
	double tmp;
	if (z <= -2.1e+33) {
		tmp = t_1;
	} else if (z <= 9.6e-31) {
		tmp = b * ((1.0 / c) / z);
	} else if ((z <= 1.55e+33) || !(z <= 2.15e+116)) {
		tmp = t_1;
	} else {
		tmp = (b / c) / z;
	}
	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) :: tmp
    t_1 = (-4.0d0) * ((a * t) / c)
    if (z <= (-2.1d+33)) then
        tmp = t_1
    else if (z <= 9.6d-31) then
        tmp = b * ((1.0d0 / c) / z)
    else if ((z <= 1.55d+33) .or. (.not. (z <= 2.15d+116))) then
        tmp = t_1
    else
        tmp = (b / c) / z
    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 = -4.0 * ((a * t) / c);
	double tmp;
	if (z <= -2.1e+33) {
		tmp = t_1;
	} else if (z <= 9.6e-31) {
		tmp = b * ((1.0 / c) / z);
	} else if ((z <= 1.55e+33) || !(z <= 2.15e+116)) {
		tmp = t_1;
	} else {
		tmp = (b / c) / z;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c):
	t_1 = -4.0 * ((a * t) / c)
	tmp = 0
	if z <= -2.1e+33:
		tmp = t_1
	elif z <= 9.6e-31:
		tmp = b * ((1.0 / c) / z)
	elif (z <= 1.55e+33) or not (z <= 2.15e+116):
		tmp = t_1
	else:
		tmp = (b / c) / z
	return tmp
function code(x, y, z, t, a, b, c)
	t_1 = Float64(-4.0 * Float64(Float64(a * t) / c))
	tmp = 0.0
	if (z <= -2.1e+33)
		tmp = t_1;
	elseif (z <= 9.6e-31)
		tmp = Float64(b * Float64(Float64(1.0 / c) / z));
	elseif ((z <= 1.55e+33) || !(z <= 2.15e+116))
		tmp = t_1;
	else
		tmp = Float64(Float64(b / c) / z);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = -4.0 * ((a * t) / c);
	tmp = 0.0;
	if (z <= -2.1e+33)
		tmp = t_1;
	elseif (z <= 9.6e-31)
		tmp = b * ((1.0 / c) / z);
	elseif ((z <= 1.55e+33) || ~((z <= 2.15e+116)))
		tmp = t_1;
	else
		tmp = (b / c) / z;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(-4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.1e+33], t$95$1, If[LessEqual[z, 9.6e-31], N[(b * N[(N[(1.0 / c), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[z, 1.55e+33], N[Not[LessEqual[z, 2.15e+116]], $MachinePrecision]], t$95$1, N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := -4 \cdot \frac{a \cdot t}{c}\\
\mathbf{if}\;z \leq -2.1 \cdot 10^{+33}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq 9.6 \cdot 10^{-31}:\\
\;\;\;\;b \cdot \frac{\frac{1}{c}}{z}\\

\mathbf{elif}\;z \leq 1.55 \cdot 10^{+33} \lor \neg \left(z \leq 2.15 \cdot 10^{+116}\right):\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -2.1000000000000001e33 or 9.6000000000000001e-31 < z < 1.55e33 or 2.15e116 < z

    1. Initial program 57.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-57.9%

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\left(x \cdot 9\right) \cdot y - \color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a}\right) + b}{z \cdot c} \]
      9. associate-*l*57.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} \]
      10. associate-*l*65.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. Simplified65.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. Taylor expanded in z around inf 64.7%

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

    if -2.1000000000000001e33 < z < 9.6000000000000001e-31

    1. Initial program 96.5%

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

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

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

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

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

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

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

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

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

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

        \[\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.2%

      \[\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. 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-inv47.7%

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

      \[\leadsto \color{blue}{b \cdot \frac{1}{z \cdot c}} \]
    9. Taylor expanded in z around 0 47.7%

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

        \[\leadsto b \cdot \color{blue}{\frac{\frac{1}{c}}{z}} \]
    11. Simplified47.7%

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

    if 1.55e33 < z < 2.15e116

    1. Initial program 71.4%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*78.9%

        \[\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. Simplified78.9%

      \[\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. Applied egg-rr78.6%

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

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

        \[\leadsto \color{blue}{\frac{\frac{b}{c}}{z}} \]
    7. Simplified65.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.1 \cdot 10^{+33}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 9.6 \cdot 10^{-31}:\\ \;\;\;\;b \cdot \frac{\frac{1}{c}}{z}\\ \mathbf{elif}\;z \leq 1.55 \cdot 10^{+33} \lor \neg \left(z \leq 2.15 \cdot 10^{+116}\right):\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \end{array} \]

Alternative 6: 49.2% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := -4 \cdot \frac{a \cdot t}{c}\\ \mathbf{if}\;z \leq -1.1 \cdot 10^{+33}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 5 \cdot 10^{-31}:\\ \;\;\;\;b \cdot \frac{\frac{1}{c}}{z}\\ \mathbf{elif}\;z \leq 2.3 \cdot 10^{+36}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 8 \cdot 10^{+99}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{else}:\\ \;\;\;\;\left(\frac{a}{c} \cdot t\right) \cdot -4\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (* -4.0 (/ (* a t) c))))
   (if (<= z -1.1e+33)
     t_1
     (if (<= z 5e-31)
       (* b (/ (/ 1.0 c) z))
       (if (<= z 2.3e+36)
         t_1
         (if (<= z 8e+99) (/ (/ b c) z) (* (* (/ a c) t) -4.0)))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = -4.0 * ((a * t) / c);
	double tmp;
	if (z <= -1.1e+33) {
		tmp = t_1;
	} else if (z <= 5e-31) {
		tmp = b * ((1.0 / c) / z);
	} else if (z <= 2.3e+36) {
		tmp = t_1;
	} else if (z <= 8e+99) {
		tmp = (b / c) / z;
	} else {
		tmp = ((a / c) * t) * -4.0;
	}
	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) :: tmp
    t_1 = (-4.0d0) * ((a * t) / c)
    if (z <= (-1.1d+33)) then
        tmp = t_1
    else if (z <= 5d-31) then
        tmp = b * ((1.0d0 / c) / z)
    else if (z <= 2.3d+36) then
        tmp = t_1
    else if (z <= 8d+99) then
        tmp = (b / c) / z
    else
        tmp = ((a / c) * t) * (-4.0d0)
    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 = -4.0 * ((a * t) / c);
	double tmp;
	if (z <= -1.1e+33) {
		tmp = t_1;
	} else if (z <= 5e-31) {
		tmp = b * ((1.0 / c) / z);
	} else if (z <= 2.3e+36) {
		tmp = t_1;
	} else if (z <= 8e+99) {
		tmp = (b / c) / z;
	} else {
		tmp = ((a / c) * t) * -4.0;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c):
	t_1 = -4.0 * ((a * t) / c)
	tmp = 0
	if z <= -1.1e+33:
		tmp = t_1
	elif z <= 5e-31:
		tmp = b * ((1.0 / c) / z)
	elif z <= 2.3e+36:
		tmp = t_1
	elif z <= 8e+99:
		tmp = (b / c) / z
	else:
		tmp = ((a / c) * t) * -4.0
	return tmp
function code(x, y, z, t, a, b, c)
	t_1 = Float64(-4.0 * Float64(Float64(a * t) / c))
	tmp = 0.0
	if (z <= -1.1e+33)
		tmp = t_1;
	elseif (z <= 5e-31)
		tmp = Float64(b * Float64(Float64(1.0 / c) / z));
	elseif (z <= 2.3e+36)
		tmp = t_1;
	elseif (z <= 8e+99)
		tmp = Float64(Float64(b / c) / z);
	else
		tmp = Float64(Float64(Float64(a / c) * t) * -4.0);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = -4.0 * ((a * t) / c);
	tmp = 0.0;
	if (z <= -1.1e+33)
		tmp = t_1;
	elseif (z <= 5e-31)
		tmp = b * ((1.0 / c) / z);
	elseif (z <= 2.3e+36)
		tmp = t_1;
	elseif (z <= 8e+99)
		tmp = (b / c) / z;
	else
		tmp = ((a / c) * t) * -4.0;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(-4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.1e+33], t$95$1, If[LessEqual[z, 5e-31], N[(b * N[(N[(1.0 / c), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.3e+36], t$95$1, If[LessEqual[z, 8e+99], N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision], N[(N[(N[(a / c), $MachinePrecision] * t), $MachinePrecision] * -4.0), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := -4 \cdot \frac{a \cdot t}{c}\\
\mathbf{if}\;z \leq -1.1 \cdot 10^{+33}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq 5 \cdot 10^{-31}:\\
\;\;\;\;b \cdot \frac{\frac{1}{c}}{z}\\

\mathbf{elif}\;z \leq 2.3 \cdot 10^{+36}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq 8 \cdot 10^{+99}:\\
\;\;\;\;\frac{\frac{b}{c}}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -1.09999999999999997e33 or 5e-31 < z < 2.29999999999999996e36

    1. Initial program 64.6%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*71.1%

        \[\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. Simplified71.1%

      \[\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. Taylor expanded in z around inf 61.7%

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

    if -1.09999999999999997e33 < z < 5e-31

    1. Initial program 96.5%

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

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

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

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

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

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

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

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

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

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

        \[\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.2%

      \[\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. 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-inv47.7%

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

      \[\leadsto \color{blue}{b \cdot \frac{1}{z \cdot c}} \]
    9. Taylor expanded in z around 0 47.7%

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

        \[\leadsto b \cdot \color{blue}{\frac{\frac{1}{c}}{z}} \]
    11. Simplified47.7%

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

    if 2.29999999999999996e36 < z < 7.9999999999999997e99

    1. Initial program 72.4%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*82.2%

        \[\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. Simplified82.2%

      \[\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. Applied egg-rr72.9%

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

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

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

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

    if 7.9999999999999997e99 < z

    1. Initial program 48.1%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*57.2%

        \[\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. Simplified57.2%

      \[\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. Taylor expanded in z around inf 67.2%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.1 \cdot 10^{+33}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{-31}:\\ \;\;\;\;b \cdot \frac{\frac{1}{c}}{z}\\ \mathbf{elif}\;z \leq 2.3 \cdot 10^{+36}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \mathbf{elif}\;z \leq 8 \cdot 10^{+99}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{else}:\\ \;\;\;\;\left(\frac{a}{c} \cdot t\right) \cdot -4\\ \end{array} \]

Alternative 7: 46.0% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := 9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\ \mathbf{if}\;y \leq -2.9 \cdot 10^{-152}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 1.12 \cdot 10^{-166}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;y \leq 1.05 \cdot 10^{+64}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (let* ((t_1 (* 9.0 (* (/ x c) (/ y z)))))
   (if (<= y -2.9e-152)
     t_1
     (if (<= y 1.12e-166)
       (/ (/ b c) z)
       (if (<= y 1.05e+64) (* -4.0 (/ a (/ c t))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double t_1 = 9.0 * ((x / c) * (y / z));
	double tmp;
	if (y <= -2.9e-152) {
		tmp = t_1;
	} else if (y <= 1.12e-166) {
		tmp = (b / c) / z;
	} else if (y <= 1.05e+64) {
		tmp = -4.0 * (a / (c / t));
	} else {
		tmp = t_1;
	}
	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) :: tmp
    t_1 = 9.0d0 * ((x / c) * (y / z))
    if (y <= (-2.9d-152)) then
        tmp = t_1
    else if (y <= 1.12d-166) then
        tmp = (b / c) / z
    else if (y <= 1.05d+64) then
        tmp = (-4.0d0) * (a / (c / t))
    else
        tmp = t_1
    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 = 9.0 * ((x / c) * (y / z));
	double tmp;
	if (y <= -2.9e-152) {
		tmp = t_1;
	} else if (y <= 1.12e-166) {
		tmp = (b / c) / z;
	} else if (y <= 1.05e+64) {
		tmp = -4.0 * (a / (c / t));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c):
	t_1 = 9.0 * ((x / c) * (y / z))
	tmp = 0
	if y <= -2.9e-152:
		tmp = t_1
	elif y <= 1.12e-166:
		tmp = (b / c) / z
	elif y <= 1.05e+64:
		tmp = -4.0 * (a / (c / t))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c)
	t_1 = Float64(9.0 * Float64(Float64(x / c) * Float64(y / z)))
	tmp = 0.0
	if (y <= -2.9e-152)
		tmp = t_1;
	elseif (y <= 1.12e-166)
		tmp = Float64(Float64(b / c) / z);
	elseif (y <= 1.05e+64)
		tmp = Float64(-4.0 * Float64(a / Float64(c / t)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c)
	t_1 = 9.0 * ((x / c) * (y / z));
	tmp = 0.0;
	if (y <= -2.9e-152)
		tmp = t_1;
	elseif (y <= 1.12e-166)
		tmp = (b / c) / z;
	elseif (y <= 1.05e+64)
		tmp = -4.0 * (a / (c / t));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(9.0 * N[(N[(x / c), $MachinePrecision] * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.9e-152], t$95$1, If[LessEqual[y, 1.12e-166], N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[y, 1.05e+64], N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := 9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\
\mathbf{if}\;y \leq -2.9 \cdot 10^{-152}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 1.12 \cdot 10^{-166}:\\
\;\;\;\;\frac{\frac{b}{c}}{z}\\

\mathbf{elif}\;y \leq 1.05 \cdot 10^{+64}:\\
\;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.9000000000000001e-152 or 1.05e64 < y

    1. Initial program 80.8%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*82.1%

        \[\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. Simplified82.1%

      \[\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. Applied egg-rr81.1%

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

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

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

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

    if -2.9000000000000001e-152 < y < 1.11999999999999994e-166

    1. Initial program 80.3%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*79.1%

        \[\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. Simplified79.1%

      \[\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. Applied egg-rr83.0%

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

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

        \[\leadsto \color{blue}{\frac{\frac{b}{c}}{z}} \]
    7. Simplified50.3%

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

    if 1.11999999999999994e-166 < y < 1.05e64

    1. Initial program 80.0%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*79.5%

        \[\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. Simplified79.5%

      \[\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. Taylor expanded in z around inf 48.2%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.9 \cdot 10^{-152}:\\ \;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\ \mathbf{elif}\;y \leq 1.12 \cdot 10^{-166}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;y \leq 1.05 \cdot 10^{+64}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\ \end{array} \]

Alternative 8: 45.6% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.2 \cdot 10^{-147}:\\
\;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\

\mathbf{elif}\;y \leq 2.4 \cdot 10^{-167}:\\
\;\;\;\;\frac{\frac{b}{c}}{z}\\

\mathbf{elif}\;y \leq 1.35 \cdot 10^{+60}:\\
\;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -6.2000000000000005e-147

    1. Initial program 82.6%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*86.9%

        \[\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. Simplified86.9%

      \[\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. Applied egg-rr80.7%

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

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

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

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

    if -6.2000000000000005e-147 < y < 2.39999999999999993e-167

    1. Initial program 80.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-+l-80.5%

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

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} \]
      10. associate-*l*79.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. Simplified79.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. Applied egg-rr83.2%

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

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

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

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

    if 2.39999999999999993e-167 < y < 1.35e60

    1. Initial program 80.0%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*79.5%

        \[\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. Simplified79.5%

      \[\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. Taylor expanded in z around inf 48.2%

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

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

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

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

    if 1.35e60 < y

    1. Initial program 77.4%

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

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

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

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

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

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

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

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

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

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

        \[\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. Simplified73.6%

      \[\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. Taylor expanded in x around inf 63.2%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -6.2 \cdot 10^{-147}:\\ \;\;\;\;9 \cdot \left(\frac{x}{c} \cdot \frac{y}{z}\right)\\ \mathbf{elif}\;y \leq 2.4 \cdot 10^{-167}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;y \leq 1.35 \cdot 10^{+60}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;9 \cdot \frac{x \cdot y}{z \cdot c}\\ \end{array} \]

Alternative 9: 45.5% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.4 \cdot 10^{-152}:\\
\;\;\;\;\frac{x}{c} \cdot \left(9 \cdot \frac{y}{z}\right)\\

\mathbf{elif}\;y \leq 7.5 \cdot 10^{-166}:\\
\;\;\;\;\frac{\frac{b}{c}}{z}\\

\mathbf{elif}\;y \leq 6.6 \cdot 10^{+62}:\\
\;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -3.39999999999999984e-152

    1. Initial program 82.8%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*87.1%

        \[\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. Simplified87.1%

      \[\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. Taylor expanded in x around inf 52.9%

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

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

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

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

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

    if -3.39999999999999984e-152 < y < 7.49999999999999947e-166

    1. Initial program 80.3%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*79.1%

        \[\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. Simplified79.1%

      \[\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. Applied egg-rr83.0%

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

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

        \[\leadsto \color{blue}{\frac{\frac{b}{c}}{z}} \]
    7. Simplified50.3%

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

    if 7.49999999999999947e-166 < y < 6.6e62

    1. Initial program 80.0%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*79.5%

        \[\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. Simplified79.5%

      \[\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. Taylor expanded in z around inf 48.2%

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

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

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

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

    if 6.6e62 < y

    1. Initial program 77.4%

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

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

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

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

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

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

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

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

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

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

        \[\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. Simplified73.6%

      \[\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. Taylor expanded in x around inf 63.2%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.4 \cdot 10^{-152}:\\ \;\;\;\;\frac{x}{c} \cdot \left(9 \cdot \frac{y}{z}\right)\\ \mathbf{elif}\;y \leq 7.5 \cdot 10^{-166}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;y \leq 6.6 \cdot 10^{+62}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;9 \cdot \frac{x \cdot y}{z \cdot c}\\ \end{array} \]

Alternative 10: 46.4% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.2 \cdot 10^{-147}:\\
\;\;\;\;\frac{x}{c} \cdot \left(9 \cdot \frac{y}{z}\right)\\

\mathbf{elif}\;y \leq 4.2 \cdot 10^{-167}:\\
\;\;\;\;\frac{\frac{b}{c}}{z}\\

\mathbf{elif}\;y \leq 3.4 \cdot 10^{+53}:\\
\;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -6.2000000000000005e-147

    1. Initial program 82.6%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*86.9%

        \[\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. Simplified86.9%

      \[\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. Taylor expanded in x around inf 53.5%

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

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

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

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

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

    if -6.2000000000000005e-147 < y < 4.20000000000000035e-167

    1. Initial program 80.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-+l-80.5%

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

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\color{blue}{x \cdot \left(9 \cdot y\right)} - \left(\left(z \cdot 4\right) \cdot t\right) \cdot a\right) + b}{z \cdot c} \]
      10. associate-*l*79.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. Simplified79.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. Applied egg-rr83.2%

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

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

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

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

    if 4.20000000000000035e-167 < y < 3.39999999999999998e53

    1. Initial program 80.0%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*79.5%

        \[\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. Simplified79.5%

      \[\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. Taylor expanded in z around inf 48.2%

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

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

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

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

    if 3.39999999999999998e53 < y

    1. Initial program 77.4%

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

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

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

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

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

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

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

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

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

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

        \[\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. Simplified73.6%

      \[\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. Applied egg-rr81.3%

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -6.2 \cdot 10^{-147}:\\ \;\;\;\;\frac{x}{c} \cdot \left(9 \cdot \frac{y}{z}\right)\\ \mathbf{elif}\;y \leq 4.2 \cdot 10^{-167}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{elif}\;y \leq 3.4 \cdot 10^{+53}:\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{\frac{c}{y}} \cdot \frac{9}{z}\\ \end{array} \]

Alternative 11: 75.3% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -5.6 \cdot 10^{+30} \lor \neg \left(z \leq 2.05 \cdot 10^{-41}\right):\\ \;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\ \mathbf{else}:\\ \;\;\;\;\frac{b + 9 \cdot \left(x \cdot y\right)}{z \cdot c}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= z -5.6e+30) (not (<= z 2.05e-41)))
   (/ (+ (/ b z) (* -4.0 (* a t))) c)
   (/ (+ b (* 9.0 (* x y))) (* z c))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((z <= -5.6e+30) || !(z <= 2.05e-41)) {
		tmp = ((b / z) + (-4.0 * (a * t))) / c;
	} else {
		tmp = (b + (9.0 * (x * y))) / (z * c);
	}
	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) :: tmp
    if ((z <= (-5.6d+30)) .or. (.not. (z <= 2.05d-41))) then
        tmp = ((b / z) + ((-4.0d0) * (a * t))) / c
    else
        tmp = (b + (9.0d0 * (x * y))) / (z * c)
    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 tmp;
	if ((z <= -5.6e+30) || !(z <= 2.05e-41)) {
		tmp = ((b / z) + (-4.0 * (a * t))) / c;
	} else {
		tmp = (b + (9.0 * (x * y))) / (z * c);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (z <= -5.6e+30) or not (z <= 2.05e-41):
		tmp = ((b / z) + (-4.0 * (a * t))) / c
	else:
		tmp = (b + (9.0 * (x * y))) / (z * c)
	return tmp
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((z <= -5.6e+30) || !(z <= 2.05e-41))
		tmp = Float64(Float64(Float64(b / z) + Float64(-4.0 * Float64(a * t))) / c);
	else
		tmp = Float64(Float64(b + Float64(9.0 * Float64(x * y))) / Float64(z * c));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((z <= -5.6e+30) || ~((z <= 2.05e-41)))
		tmp = ((b / z) + (-4.0 * (a * t))) / c;
	else
		tmp = (b + (9.0 * (x * y))) / (z * c);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[z, -5.6e+30], N[Not[LessEqual[z, 2.05e-41]], $MachinePrecision]], N[(N[(N[(b / z), $MachinePrecision] + N[(-4.0 * N[(a * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / c), $MachinePrecision], N[(N[(b + N[(9.0 * N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(z * c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.6 \cdot 10^{+30} \lor \neg \left(z \leq 2.05 \cdot 10^{-41}\right):\\
\;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -5.59999999999999966e30 or 2.05000000000000007e-41 < z

    1. Initial program 61.0%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*68.5%

        \[\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. Simplified68.5%

      \[\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. Applied egg-rr67.3%

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

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

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c} + \frac{b}{c \cdot z}} \]
    7. Taylor expanded in c around 0 78.8%

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

    if -5.59999999999999966e30 < z < 2.05000000000000007e-41

    1. Initial program 96.4%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*91.0%

        \[\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.0%

      \[\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. Taylor expanded in x around inf 82.3%

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

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

Alternative 12: 64.1% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.12 \cdot 10^{+193}:\\
\;\;\;\;\frac{x}{c} \cdot \left(9 \cdot \frac{y}{z}\right)\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if x < -1.1199999999999999e193

    1. Initial program 83.3%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*79.6%

        \[\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. Simplified79.6%

      \[\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. Taylor expanded in x around inf 72.1%

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

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

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

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

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

    if -1.1199999999999999e193 < x < 8.1999999999999999e-80

    1. Initial program 79.0%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*82.0%

        \[\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. Simplified82.0%

      \[\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. Applied egg-rr82.8%

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

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

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c} + \frac{b}{c \cdot z}} \]
    7. Taylor expanded in c around 0 72.9%

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

    if 8.1999999999999999e-80 < x

    1. Initial program 82.8%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*78.9%

        \[\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. Simplified78.9%

      \[\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. Applied egg-rr82.9%

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

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

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

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

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

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

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

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

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

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

Alternative 13: 75.3% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.8 \cdot 10^{+30}:\\
\;\;\;\;\frac{\frac{b}{z} + -4 \cdot \left(a \cdot t\right)}{c}\\

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

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


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

    1. Initial program 57.8%

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

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\left(x \cdot 9\right) \cdot y - \color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a}\right) + b}{z \cdot c} \]
      9. associate-*l*57.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} \]
      10. associate-*l*65.5%

        \[\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. Simplified65.5%

      \[\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. Applied egg-rr64.0%

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

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

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c} + \frac{b}{c \cdot z}} \]
    7. Taylor expanded in c around 0 79.3%

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

    if -3.8000000000000001e30 < z < 6.5000000000000004e-41

    1. Initial program 96.4%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*91.0%

        \[\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.0%

      \[\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. Taylor expanded in x around inf 82.3%

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

    if 6.5000000000000004e-41 < z

    1. Initial program 63.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-+l-63.5%

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

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

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

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

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

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

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

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

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

        \[\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. Simplified70.8%

      \[\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. Applied egg-rr70.0%

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

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

      \[\leadsto \color{blue}{-4 \cdot \frac{a \cdot t}{c} + \frac{b}{c \cdot z}} \]
    7. Taylor expanded in c around -inf 78.4%

      \[\leadsto \color{blue}{-1 \cdot \frac{-1 \cdot \frac{b}{z} + 4 \cdot \left(a \cdot t\right)}{c}} \]
    8. Step-by-step derivation
      1. associate-*r/78.4%

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

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

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

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

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

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

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

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

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

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

Alternative 14: 49.5% accurate, 1.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq -8.2 \cdot 10^{+34} \lor \neg \left(b \leq 8.5 \cdot 10^{-46}\right):\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \mathbf{else}:\\ \;\;\;\;-4 \cdot \frac{a \cdot t}{c}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= b -8.2e+34) (not (<= b 8.5e-46)))
   (/ (/ b c) z)
   (* -4.0 (/ (* a t) c))))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((b <= -8.2e+34) || !(b <= 8.5e-46)) {
		tmp = (b / c) / z;
	} else {
		tmp = -4.0 * ((a * t) / c);
	}
	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) :: tmp
    if ((b <= (-8.2d+34)) .or. (.not. (b <= 8.5d-46))) then
        tmp = (b / c) / z
    else
        tmp = (-4.0d0) * ((a * t) / c)
    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 tmp;
	if ((b <= -8.2e+34) || !(b <= 8.5e-46)) {
		tmp = (b / c) / z;
	} else {
		tmp = -4.0 * ((a * t) / c);
	}
	return tmp;
}
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (b <= -8.2e+34) or not (b <= 8.5e-46):
		tmp = (b / c) / z
	else:
		tmp = -4.0 * ((a * t) / c)
	return tmp
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((b <= -8.2e+34) || !(b <= 8.5e-46))
		tmp = Float64(Float64(b / c) / z);
	else
		tmp = Float64(-4.0 * Float64(Float64(a * t) / c));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((b <= -8.2e+34) || ~((b <= 8.5e-46)))
		tmp = (b / c) / z;
	else
		tmp = -4.0 * ((a * t) / c);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[b, -8.2e+34], N[Not[LessEqual[b, 8.5e-46]], $MachinePrecision]], N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision], N[(-4.0 * N[(N[(a * t), $MachinePrecision] / c), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq -8.2 \cdot 10^{+34} \lor \neg \left(b \leq 8.5 \cdot 10^{-46}\right):\\
\;\;\;\;\frac{\frac{b}{c}}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < -8.1999999999999997e34 or 8.5000000000000001e-46 < b

    1. Initial program 76.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-76.9%

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\left(x \cdot 9\right) \cdot y - \color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a}\right) + b}{z \cdot c} \]
      9. associate-*l*76.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} \]
      10. associate-*l*80.9%

        \[\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. Simplified80.9%

      \[\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. Applied egg-rr81.0%

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

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

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

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

    if -8.1999999999999997e34 < b < 8.5000000000000001e-46

    1. Initial program 83.8%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*80.8%

        \[\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. Simplified80.8%

      \[\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. Taylor expanded in z around inf 44.1%

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

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

Alternative 15: 48.5% accurate, 1.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3.8 \cdot 10^{+90} \lor \neg \left(t \leq 3800000\right):\\ \;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{b}{c}}{z}\\ \end{array} \end{array} \]
(FPCore (x y z t a b c)
 :precision binary64
 (if (or (<= t -3.8e+90) (not (<= t 3800000.0)))
   (* -4.0 (/ a (/ c t)))
   (/ (/ b c) z)))
double code(double x, double y, double z, double t, double a, double b, double c) {
	double tmp;
	if ((t <= -3.8e+90) || !(t <= 3800000.0)) {
		tmp = -4.0 * (a / (c / t));
	} else {
		tmp = (b / c) / z;
	}
	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) :: tmp
    if ((t <= (-3.8d+90)) .or. (.not. (t <= 3800000.0d0))) then
        tmp = (-4.0d0) * (a / (c / t))
    else
        tmp = (b / c) / z
    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 tmp;
	if ((t <= -3.8e+90) || !(t <= 3800000.0)) {
		tmp = -4.0 * (a / (c / t));
	} else {
		tmp = (b / c) / z;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c):
	tmp = 0
	if (t <= -3.8e+90) or not (t <= 3800000.0):
		tmp = -4.0 * (a / (c / t))
	else:
		tmp = (b / c) / z
	return tmp
function code(x, y, z, t, a, b, c)
	tmp = 0.0
	if ((t <= -3.8e+90) || !(t <= 3800000.0))
		tmp = Float64(-4.0 * Float64(a / Float64(c / t)));
	else
		tmp = Float64(Float64(b / c) / z);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c)
	tmp = 0.0;
	if ((t <= -3.8e+90) || ~((t <= 3800000.0)))
		tmp = -4.0 * (a / (c / t));
	else
		tmp = (b / c) / z;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[t, -3.8e+90], N[Not[LessEqual[t, 3800000.0]], $MachinePrecision]], N[(-4.0 * N[(a / N[(c / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.8 \cdot 10^{+90} \lor \neg \left(t \leq 3800000\right):\\
\;\;\;\;-4 \cdot \frac{a}{\frac{c}{t}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -3.8000000000000001e90 or 3.8e6 < t

    1. Initial program 75.6%

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

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

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

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

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

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

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

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

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

        \[\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} \]
      10. associate-*l*76.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. Simplified76.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. Taylor expanded in z around inf 45.0%

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

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

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

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

    if -3.8000000000000001e90 < t < 3.8e6

    1. Initial program 83.9%

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

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

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

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

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

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

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

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

        \[\leadsto \frac{\left(\left(x \cdot 9\right) \cdot y - \color{blue}{\left(\left(z \cdot 4\right) \cdot t\right) \cdot a}\right) + b}{z \cdot c} \]
      9. associate-*l*83.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} \]
      10. 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. Applied egg-rr87.2%

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

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

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

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

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

Alternative 16: 35.3% accurate, 3.8× speedup?

\[\begin{array}{l} \\ \frac{b}{z \cdot c} \end{array} \]
(FPCore (x y z t a b c) :precision binary64 (/ b (* z c)))
double code(double x, double y, double z, double t, double a, double b, double c) {
	return 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 = b / (z * c)
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	return b / (z * c);
}
def code(x, y, z, t, a, b, c):
	return b / (z * c)
function code(x, y, z, t, a, b, c)
	return Float64(b / Float64(z * c))
end
function tmp = code(x, y, z, t, a, b, c)
	tmp = b / (z * c);
end
code[x_, y_, z_, t_, a_, b_, c_] := N[(b / N[(z * c), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{b}{z \cdot c}
\end{array}
Derivation
  1. Initial program 80.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-+l-80.5%

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

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

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

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

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

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

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

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

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

      \[\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. Simplified80.9%

    \[\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. Taylor expanded in b around inf 36.0%

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

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

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

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

Alternative 17: 34.7% accurate, 3.8× speedup?

\[\begin{array}{l} \\ \frac{\frac{b}{c}}{z} \end{array} \]
(FPCore (x y z t a b c) :precision binary64 (/ (/ b c) z))
double code(double x, double y, double z, double t, double a, double b, double c) {
	return (b / c) / z;
}
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 / c) / z
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
	return (b / c) / z;
}
def code(x, y, z, t, a, b, c):
	return (b / c) / z
function code(x, y, z, t, a, b, c)
	return Float64(Float64(b / c) / z)
end
function tmp = code(x, y, z, t, a, b, c)
	tmp = (b / c) / z;
end
code[x_, y_, z_, t_, a_, b_, c_] := N[(N[(b / c), $MachinePrecision] / z), $MachinePrecision]
\begin{array}{l}

\\
\frac{\frac{b}{c}}{z}
\end{array}
Derivation
  1. Initial program 80.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-+l-80.5%

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

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

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

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

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

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

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

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

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

      \[\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. Simplified80.9%

    \[\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. Applied egg-rr83.0%

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

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

      \[\leadsto \color{blue}{\frac{\frac{b}{c}}{z}} \]
  7. Simplified37.0%

    \[\leadsto \color{blue}{\frac{\frac{b}{c}}{z}} \]
  8. Final simplification37.0%

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

Developer target: 80.5% 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 2023331 
(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)))