AI.Clustering.Hierarchical.Internal:ward from clustering-0.2.1

Percentage Accurate: 61.0% → 88.7%
Time: 32.2s
Alternatives: 13
Speedup: 1.1×

Specification

?
\[\begin{array}{l} \\ \frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (/ (- (+ (* (+ x y) z) (* (+ t y) a)) (* y b)) (+ (+ x t) y)))
double code(double x, double y, double z, double t, double a, double b) {
	return ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y);
}
real(8) function code(x, y, z, t, a, b)
    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
    code = ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y);
}
def code(x, y, z, t, a, b):
	return ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y)
function code(x, y, z, t, a, b)
	return Float64(Float64(Float64(Float64(Float64(x + y) * z) + Float64(Float64(t + y) * a)) - Float64(y * b)) / Float64(Float64(x + t) + y))
end
function tmp = code(x, y, z, t, a, b)
	tmp = ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y);
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(N[(N[(x + y), $MachinePrecision] * z), $MachinePrecision] + N[(N[(t + y), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision] / N[(N[(x + t), $MachinePrecision] + y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y}
\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 13 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: 61.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (/ (- (+ (* (+ x y) z) (* (+ t y) a)) (* y b)) (+ (+ x t) y)))
double code(double x, double y, double z, double t, double a, double b) {
	return ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y);
}
real(8) function code(x, y, z, t, a, b)
    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
    code = ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y);
}
def code(x, y, z, t, a, b):
	return ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y)
function code(x, y, z, t, a, b)
	return Float64(Float64(Float64(Float64(Float64(x + y) * z) + Float64(Float64(t + y) * a)) - Float64(y * b)) / Float64(Float64(x + t) + y))
end
function tmp = code(x, y, z, t, a, b)
	tmp = ((((x + y) * z) + ((t + y) * a)) - (y * b)) / ((x + t) + y);
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(N[(N[(x + y), $MachinePrecision] * z), $MachinePrecision] + N[(N[(t + y), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision] / N[(N[(x + t), $MachinePrecision] + y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

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

Alternative 1: 88.7% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y + \left(x + t\right)\\ t_2 := \frac{\left(\left(x + y\right) \cdot z + a \cdot \left(y + t\right)\right) - y \cdot b}{t\_1}\\ t_3 := \left(z + a\right) - b\\ \mathbf{if}\;t\_2 \leq -\infty \lor \neg \left(t\_2 \leq 5 \cdot 10^{+283}\right):\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot a + \left(x \cdot z + y \cdot t\_3\right)}{t\_1}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ y (+ x t)))
        (t_2 (/ (- (+ (* (+ x y) z) (* a (+ y t))) (* y b)) t_1))
        (t_3 (- (+ z a) b)))
   (if (or (<= t_2 (- INFINITY)) (not (<= t_2 5e+283)))
     t_3
     (/ (+ (* t a) (+ (* x z) (* y t_3))) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = y + (x + t);
	double t_2 = ((((x + y) * z) + (a * (y + t))) - (y * b)) / t_1;
	double t_3 = (z + a) - b;
	double tmp;
	if ((t_2 <= -((double) INFINITY)) || !(t_2 <= 5e+283)) {
		tmp = t_3;
	} else {
		tmp = ((t * a) + ((x * z) + (y * t_3))) / t_1;
	}
	return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = y + (x + t);
	double t_2 = ((((x + y) * z) + (a * (y + t))) - (y * b)) / t_1;
	double t_3 = (z + a) - b;
	double tmp;
	if ((t_2 <= -Double.POSITIVE_INFINITY) || !(t_2 <= 5e+283)) {
		tmp = t_3;
	} else {
		tmp = ((t * a) + ((x * z) + (y * t_3))) / t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = y + (x + t)
	t_2 = ((((x + y) * z) + (a * (y + t))) - (y * b)) / t_1
	t_3 = (z + a) - b
	tmp = 0
	if (t_2 <= -math.inf) or not (t_2 <= 5e+283):
		tmp = t_3
	else:
		tmp = ((t * a) + ((x * z) + (y * t_3))) / t_1
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(y + Float64(x + t))
	t_2 = Float64(Float64(Float64(Float64(Float64(x + y) * z) + Float64(a * Float64(y + t))) - Float64(y * b)) / t_1)
	t_3 = Float64(Float64(z + a) - b)
	tmp = 0.0
	if ((t_2 <= Float64(-Inf)) || !(t_2 <= 5e+283))
		tmp = t_3;
	else
		tmp = Float64(Float64(Float64(t * a) + Float64(Float64(x * z) + Float64(y * t_3))) / t_1);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = y + (x + t);
	t_2 = ((((x + y) * z) + (a * (y + t))) - (y * b)) / t_1;
	t_3 = (z + a) - b;
	tmp = 0.0;
	if ((t_2 <= -Inf) || ~((t_2 <= 5e+283)))
		tmp = t_3;
	else
		tmp = ((t * a) + ((x * z) + (y * t_3))) / t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(y + N[(x + t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(N[(N[(x + y), $MachinePrecision] * z), $MachinePrecision] + N[(a * N[(y + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(N[(z + a), $MachinePrecision] - b), $MachinePrecision]}, If[Or[LessEqual[t$95$2, (-Infinity)], N[Not[LessEqual[t$95$2, 5e+283]], $MachinePrecision]], t$95$3, N[(N[(N[(t * a), $MachinePrecision] + N[(N[(x * z), $MachinePrecision] + N[(y * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := y + \left(x + t\right)\\
t_2 := \frac{\left(\left(x + y\right) \cdot z + a \cdot \left(y + t\right)\right) - y \cdot b}{t\_1}\\
t_3 := \left(z + a\right) - b\\
\mathbf{if}\;t\_2 \leq -\infty \lor \neg \left(t\_2 \leq 5 \cdot 10^{+283}\right):\\
\;\;\;\;t\_3\\

\mathbf{else}:\\
\;\;\;\;\frac{t \cdot a + \left(x \cdot z + y \cdot t\_3\right)}{t\_1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (/.f64 (-.f64 (+.f64 (*.f64 (+.f64 x y) z) (*.f64 (+.f64 t y) a)) (*.f64 y b)) (+.f64 (+.f64 x t) y)) < -inf.0 or 5.0000000000000004e283 < (/.f64 (-.f64 (+.f64 (*.f64 (+.f64 x y) z) (*.f64 (+.f64 t y) a)) (*.f64 y b)) (+.f64 (+.f64 x t) y))

    1. Initial program 5.2%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 74.3%

      \[\leadsto \color{blue}{\left(a + z\right) - b} \]

    if -inf.0 < (/.f64 (-.f64 (+.f64 (*.f64 (+.f64 x y) z) (*.f64 (+.f64 t y) a)) (*.f64 y b)) (+.f64 (+.f64 x t) y)) < 5.0000000000000004e283

    1. Initial program 99.1%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0 99.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{\left(\left(x + y\right) \cdot z + a \cdot \left(y + t\right)\right) - y \cdot b}{y + \left(x + t\right)} \leq -\infty \lor \neg \left(\frac{\left(\left(x + y\right) \cdot z + a \cdot \left(y + t\right)\right) - y \cdot b}{y + \left(x + t\right)} \leq 5 \cdot 10^{+283}\right):\\ \;\;\;\;\left(z + a\right) - b\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot a + \left(x \cdot z + y \cdot \left(\left(z + a\right) - b\right)\right)}{y + \left(x + t\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 65.9% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \left(y + t\right)\\ t_2 := y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{t\_1}\right)\\ \mathbf{if}\;y \leq -6 \cdot 10^{+93}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -2.4 \cdot 10^{-125}:\\ \;\;\;\;\frac{a \cdot \left(y + t\right) - y \cdot b}{y + \left(x + t\right)}\\ \mathbf{elif}\;y \leq 8.2 \cdot 10^{-238}:\\ \;\;\;\;z \cdot \left(\frac{x}{x + t} + \frac{t \cdot a}{z \cdot \left(x + t\right)}\right)\\ \mathbf{elif}\;y \leq 6.5 \cdot 10^{-29}:\\ \;\;\;\;z \cdot \left(\frac{x}{t\_1} + \frac{a}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ x (+ y t))) (t_2 (* y (* (+ a (- z b)) (/ 1.0 t_1)))))
   (if (<= y -6e+93)
     t_2
     (if (<= y -2.4e-125)
       (/ (- (* a (+ y t)) (* y b)) (+ y (+ x t)))
       (if (<= y 8.2e-238)
         (* z (+ (/ x (+ x t)) (/ (* t a) (* z (+ x t)))))
         (if (<= y 6.5e-29) (* z (+ (/ x t_1) (/ a z))) t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x + (y + t);
	double t_2 = y * ((a + (z - b)) * (1.0 / t_1));
	double tmp;
	if (y <= -6e+93) {
		tmp = t_2;
	} else if (y <= -2.4e-125) {
		tmp = ((a * (y + t)) - (y * b)) / (y + (x + t));
	} else if (y <= 8.2e-238) {
		tmp = z * ((x / (x + t)) + ((t * a) / (z * (x + t))));
	} else if (y <= 6.5e-29) {
		tmp = z * ((x / t_1) + (a / z));
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = x + (y + t)
    t_2 = y * ((a + (z - b)) * (1.0d0 / t_1))
    if (y <= (-6d+93)) then
        tmp = t_2
    else if (y <= (-2.4d-125)) then
        tmp = ((a * (y + t)) - (y * b)) / (y + (x + t))
    else if (y <= 8.2d-238) then
        tmp = z * ((x / (x + t)) + ((t * a) / (z * (x + t))))
    else if (y <= 6.5d-29) then
        tmp = z * ((x / t_1) + (a / z))
    else
        tmp = 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 t_1 = x + (y + t);
	double t_2 = y * ((a + (z - b)) * (1.0 / t_1));
	double tmp;
	if (y <= -6e+93) {
		tmp = t_2;
	} else if (y <= -2.4e-125) {
		tmp = ((a * (y + t)) - (y * b)) / (y + (x + t));
	} else if (y <= 8.2e-238) {
		tmp = z * ((x / (x + t)) + ((t * a) / (z * (x + t))));
	} else if (y <= 6.5e-29) {
		tmp = z * ((x / t_1) + (a / z));
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x + (y + t)
	t_2 = y * ((a + (z - b)) * (1.0 / t_1))
	tmp = 0
	if y <= -6e+93:
		tmp = t_2
	elif y <= -2.4e-125:
		tmp = ((a * (y + t)) - (y * b)) / (y + (x + t))
	elif y <= 8.2e-238:
		tmp = z * ((x / (x + t)) + ((t * a) / (z * (x + t))))
	elif y <= 6.5e-29:
		tmp = z * ((x / t_1) + (a / z))
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x + Float64(y + t))
	t_2 = Float64(y * Float64(Float64(a + Float64(z - b)) * Float64(1.0 / t_1)))
	tmp = 0.0
	if (y <= -6e+93)
		tmp = t_2;
	elseif (y <= -2.4e-125)
		tmp = Float64(Float64(Float64(a * Float64(y + t)) - Float64(y * b)) / Float64(y + Float64(x + t)));
	elseif (y <= 8.2e-238)
		tmp = Float64(z * Float64(Float64(x / Float64(x + t)) + Float64(Float64(t * a) / Float64(z * Float64(x + t)))));
	elseif (y <= 6.5e-29)
		tmp = Float64(z * Float64(Float64(x / t_1) + Float64(a / z)));
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = x + (y + t);
	t_2 = y * ((a + (z - b)) * (1.0 / t_1));
	tmp = 0.0;
	if (y <= -6e+93)
		tmp = t_2;
	elseif (y <= -2.4e-125)
		tmp = ((a * (y + t)) - (y * b)) / (y + (x + t));
	elseif (y <= 8.2e-238)
		tmp = z * ((x / (x + t)) + ((t * a) / (z * (x + t))));
	elseif (y <= 6.5e-29)
		tmp = z * ((x / t_1) + (a / z));
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(y + t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(N[(a + N[(z - b), $MachinePrecision]), $MachinePrecision] * N[(1.0 / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6e+93], t$95$2, If[LessEqual[y, -2.4e-125], N[(N[(N[(a * N[(y + t), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision] / N[(y + N[(x + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 8.2e-238], N[(z * N[(N[(x / N[(x + t), $MachinePrecision]), $MachinePrecision] + N[(N[(t * a), $MachinePrecision] / N[(z * N[(x + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.5e-29], N[(z * N[(N[(x / t$95$1), $MachinePrecision] + N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + \left(y + t\right)\\
t_2 := y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{t\_1}\right)\\
\mathbf{if}\;y \leq -6 \cdot 10^{+93}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -2.4 \cdot 10^{-125}:\\
\;\;\;\;\frac{a \cdot \left(y + t\right) - y \cdot b}{y + \left(x + t\right)}\\

\mathbf{elif}\;y \leq 8.2 \cdot 10^{-238}:\\
\;\;\;\;z \cdot \left(\frac{x}{x + t} + \frac{t \cdot a}{z \cdot \left(x + t\right)}\right)\\

\mathbf{elif}\;y \leq 6.5 \cdot 10^{-29}:\\
\;\;\;\;z \cdot \left(\frac{x}{t\_1} + \frac{a}{z}\right)\\

\mathbf{else}:\\
\;\;\;\;t\_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -5.99999999999999957e93 or 6.5e-29 < y

    1. Initial program 35.3%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 30.4%

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

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

        \[\leadsto \left(y \cdot \left(\left(a + z\right) - b\right)\right) \cdot \frac{1}{\color{blue}{\left(t + x\right)} + y} \]
      3. associate-+r+30.3%

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

        \[\leadsto \left(y \cdot \color{blue}{\left(a + \left(z - b\right)\right)}\right) \cdot \frac{1}{t + \left(x + y\right)} \]
      5. associate-+r+30.3%

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

        \[\leadsto \left(y \cdot \left(a + \left(z - b\right)\right)\right) \cdot \frac{1}{\color{blue}{\left(x + t\right)} + y} \]
      7. associate-+l+30.3%

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

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

      \[\leadsto \color{blue}{\left(y \cdot \left(a + \left(z - b\right)\right)\right) \cdot \frac{1}{x + \left(y + t\right)}} \]
    6. Step-by-step derivation
      1. associate-*l*82.4%

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

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

    if -5.99999999999999957e93 < y < -2.4000000000000001e-125

    1. Initial program 77.0%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 70.2%

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

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

        \[\leadsto \frac{a \cdot \left(y + t\right) - \color{blue}{y \cdot b}}{\left(x + t\right) + y} \]
    5. Simplified70.2%

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

    if -2.4000000000000001e-125 < y < 8.2000000000000002e-238

    1. Initial program 79.7%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 90.1%

      \[\leadsto \color{blue}{z \cdot \left(\left(\frac{x}{t + \left(x + y\right)} + \left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)} \]
    4. Step-by-step derivation
      1. associate--l+90.1%

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

        \[\leadsto z \cdot \left(\frac{x}{\color{blue}{\left(x + y\right) + t}} + \left(\left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      3. associate-+r+90.1%

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{\color{blue}{\left(x + y\right) + t}} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      5. associate-+r+90.1%

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

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

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

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{x + \left(y + t\right)} + \frac{a}{z} \cdot \frac{y + t}{\color{blue}{x + \left(y + t\right)}}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      10. associate-/r*94.8%

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

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

      \[\leadsto \color{blue}{z \cdot \left(\frac{x}{t + x} + \frac{a \cdot t}{z \cdot \left(t + x\right)}\right)} \]

    if 8.2000000000000002e-238 < y < 6.5e-29

    1. Initial program 70.2%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 61.1%

      \[\leadsto \color{blue}{z \cdot \left(\left(\frac{x}{t + \left(x + y\right)} + \left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)} \]
    4. Step-by-step derivation
      1. associate--l+61.1%

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

        \[\leadsto z \cdot \left(\frac{x}{\color{blue}{\left(x + y\right) + t}} + \left(\left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      3. associate-+r+61.1%

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{\color{blue}{\left(x + y\right) + t}} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      5. associate-+r+61.1%

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -6 \cdot 10^{+93}:\\ \;\;\;\;y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{x + \left(y + t\right)}\right)\\ \mathbf{elif}\;y \leq -2.4 \cdot 10^{-125}:\\ \;\;\;\;\frac{a \cdot \left(y + t\right) - y \cdot b}{y + \left(x + t\right)}\\ \mathbf{elif}\;y \leq 8.2 \cdot 10^{-238}:\\ \;\;\;\;z \cdot \left(\frac{x}{x + t} + \frac{t \cdot a}{z \cdot \left(x + t\right)}\right)\\ \mathbf{elif}\;y \leq 6.5 \cdot 10^{-29}:\\ \;\;\;\;z \cdot \left(\frac{x}{x + \left(y + t\right)} + \frac{a}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{x + \left(y + t\right)}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 65.0% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \left(y + t\right)\\ t_2 := y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{t\_1}\right)\\ \mathbf{if}\;y \leq -6 \cdot 10^{+93}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq -7.9 \cdot 10^{-112}:\\ \;\;\;\;\frac{a \cdot \left(y + t\right) - y \cdot b}{y + \left(x + t\right)}\\ \mathbf{elif}\;y \leq 1.8 \cdot 10^{-29}:\\ \;\;\;\;z \cdot \left(\frac{x}{t\_1} + \frac{a}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ x (+ y t))) (t_2 (* y (* (+ a (- z b)) (/ 1.0 t_1)))))
   (if (<= y -6e+93)
     t_2
     (if (<= y -7.9e-112)
       (/ (- (* a (+ y t)) (* y b)) (+ y (+ x t)))
       (if (<= y 1.8e-29) (* z (+ (/ x t_1) (/ a z))) t_2)))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x + (y + t);
	double t_2 = y * ((a + (z - b)) * (1.0 / t_1));
	double tmp;
	if (y <= -6e+93) {
		tmp = t_2;
	} else if (y <= -7.9e-112) {
		tmp = ((a * (y + t)) - (y * b)) / (y + (x + t));
	} else if (y <= 1.8e-29) {
		tmp = z * ((x / t_1) + (a / z));
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = x + (y + t)
    t_2 = y * ((a + (z - b)) * (1.0d0 / t_1))
    if (y <= (-6d+93)) then
        tmp = t_2
    else if (y <= (-7.9d-112)) then
        tmp = ((a * (y + t)) - (y * b)) / (y + (x + t))
    else if (y <= 1.8d-29) then
        tmp = z * ((x / t_1) + (a / z))
    else
        tmp = 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 t_1 = x + (y + t);
	double t_2 = y * ((a + (z - b)) * (1.0 / t_1));
	double tmp;
	if (y <= -6e+93) {
		tmp = t_2;
	} else if (y <= -7.9e-112) {
		tmp = ((a * (y + t)) - (y * b)) / (y + (x + t));
	} else if (y <= 1.8e-29) {
		tmp = z * ((x / t_1) + (a / z));
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x + (y + t)
	t_2 = y * ((a + (z - b)) * (1.0 / t_1))
	tmp = 0
	if y <= -6e+93:
		tmp = t_2
	elif y <= -7.9e-112:
		tmp = ((a * (y + t)) - (y * b)) / (y + (x + t))
	elif y <= 1.8e-29:
		tmp = z * ((x / t_1) + (a / z))
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x + Float64(y + t))
	t_2 = Float64(y * Float64(Float64(a + Float64(z - b)) * Float64(1.0 / t_1)))
	tmp = 0.0
	if (y <= -6e+93)
		tmp = t_2;
	elseif (y <= -7.9e-112)
		tmp = Float64(Float64(Float64(a * Float64(y + t)) - Float64(y * b)) / Float64(y + Float64(x + t)));
	elseif (y <= 1.8e-29)
		tmp = Float64(z * Float64(Float64(x / t_1) + Float64(a / z)));
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = x + (y + t);
	t_2 = y * ((a + (z - b)) * (1.0 / t_1));
	tmp = 0.0;
	if (y <= -6e+93)
		tmp = t_2;
	elseif (y <= -7.9e-112)
		tmp = ((a * (y + t)) - (y * b)) / (y + (x + t));
	elseif (y <= 1.8e-29)
		tmp = z * ((x / t_1) + (a / z));
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(y + t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(N[(a + N[(z - b), $MachinePrecision]), $MachinePrecision] * N[(1.0 / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -6e+93], t$95$2, If[LessEqual[y, -7.9e-112], N[(N[(N[(a * N[(y + t), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision] / N[(y + N[(x + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.8e-29], N[(z * N[(N[(x / t$95$1), $MachinePrecision] + N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + \left(y + t\right)\\
t_2 := y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{t\_1}\right)\\
\mathbf{if}\;y \leq -6 \cdot 10^{+93}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y \leq -7.9 \cdot 10^{-112}:\\
\;\;\;\;\frac{a \cdot \left(y + t\right) - y \cdot b}{y + \left(x + t\right)}\\

\mathbf{elif}\;y \leq 1.8 \cdot 10^{-29}:\\
\;\;\;\;z \cdot \left(\frac{x}{t\_1} + \frac{a}{z}\right)\\

\mathbf{else}:\\
\;\;\;\;t\_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -5.99999999999999957e93 or 1.79999999999999987e-29 < y

    1. Initial program 35.3%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 30.4%

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

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

        \[\leadsto \left(y \cdot \left(\left(a + z\right) - b\right)\right) \cdot \frac{1}{\color{blue}{\left(t + x\right)} + y} \]
      3. associate-+r+30.3%

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

        \[\leadsto \left(y \cdot \color{blue}{\left(a + \left(z - b\right)\right)}\right) \cdot \frac{1}{t + \left(x + y\right)} \]
      5. associate-+r+30.3%

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

        \[\leadsto \left(y \cdot \left(a + \left(z - b\right)\right)\right) \cdot \frac{1}{\color{blue}{\left(x + t\right)} + y} \]
      7. associate-+l+30.3%

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

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

      \[\leadsto \color{blue}{\left(y \cdot \left(a + \left(z - b\right)\right)\right) \cdot \frac{1}{x + \left(y + t\right)}} \]
    6. Step-by-step derivation
      1. associate-*l*82.4%

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

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

    if -5.99999999999999957e93 < y < -7.8999999999999999e-112

    1. Initial program 77.0%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 70.2%

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

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

        \[\leadsto \frac{a \cdot \left(y + t\right) - \color{blue}{y \cdot b}}{\left(x + t\right) + y} \]
    5. Simplified70.2%

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

    if -7.8999999999999999e-112 < y < 1.79999999999999987e-29

    1. Initial program 75.1%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 76.1%

      \[\leadsto \color{blue}{z \cdot \left(\left(\frac{x}{t + \left(x + y\right)} + \left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)} \]
    4. Step-by-step derivation
      1. associate--l+76.1%

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

        \[\leadsto z \cdot \left(\frac{x}{\color{blue}{\left(x + y\right) + t}} + \left(\left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      3. associate-+r+76.1%

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{\color{blue}{\left(x + y\right) + t}} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      5. associate-+r+76.1%

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{\color{blue}{x + \left(y + t\right)}} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      6. times-frac90.5%

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{x + \left(y + t\right)} + \color{blue}{\frac{a}{z} \cdot \frac{t + y}{t + \left(x + y\right)}}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      7. +-commutative90.5%

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

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{x + \left(y + t\right)} + \frac{a}{z} \cdot \frac{y + t}{\color{blue}{x + \left(y + t\right)}}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      10. associate-/r*89.5%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -6 \cdot 10^{+93}:\\ \;\;\;\;y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{x + \left(y + t\right)}\right)\\ \mathbf{elif}\;y \leq -7.9 \cdot 10^{-112}:\\ \;\;\;\;\frac{a \cdot \left(y + t\right) - y \cdot b}{y + \left(x + t\right)}\\ \mathbf{elif}\;y \leq 1.8 \cdot 10^{-29}:\\ \;\;\;\;z \cdot \left(\frac{x}{x + \left(y + t\right)} + \frac{a}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{x + \left(y + t\right)}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 64.6% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
t_1 := \left(z + a\right) - b\\
\mathbf{if}\;y \leq -4.2 \cdot 10^{-37}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 5 \cdot 10^{-29}:\\
\;\;\;\;z \cdot \left(\frac{x}{x + \left(y + t\right)} + \frac{a}{z}\right)\\

\mathbf{elif}\;y \leq 6 \cdot 10^{+22}:\\
\;\;\;\;\frac{y \cdot t\_1}{y + \left(x + t\right)}\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -4.2000000000000002e-37 or 6e22 < y

    1. Initial program 38.6%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 73.1%

      \[\leadsto \color{blue}{\left(a + z\right) - b} \]

    if -4.2000000000000002e-37 < y < 4.99999999999999986e-29

    1. Initial program 76.5%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 75.6%

      \[\leadsto \color{blue}{z \cdot \left(\left(\frac{x}{t + \left(x + y\right)} + \left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)} \]
    4. Step-by-step derivation
      1. associate--l+75.6%

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

        \[\leadsto z \cdot \left(\frac{x}{\color{blue}{\left(x + y\right) + t}} + \left(\left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      3. associate-+r+75.6%

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{\color{blue}{\left(x + y\right) + t}} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      5. associate-+r+75.6%

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{\color{blue}{x + \left(y + t\right)}} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      6. times-frac87.8%

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

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

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{x + \left(y + t\right)} + \frac{a}{z} \cdot \frac{y + t}{\color{blue}{x + \left(y + t\right)}}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      10. associate-/r*87.8%

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

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

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

    if 4.99999999999999986e-29 < y < 6e22

    1. Initial program 83.5%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 75.4%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -4.2 \cdot 10^{-37}:\\ \;\;\;\;\left(z + a\right) - b\\ \mathbf{elif}\;y \leq 5 \cdot 10^{-29}:\\ \;\;\;\;z \cdot \left(\frac{x}{x + \left(y + t\right)} + \frac{a}{z}\right)\\ \mathbf{elif}\;y \leq 6 \cdot 10^{+22}:\\ \;\;\;\;\frac{y \cdot \left(\left(z + a\right) - b\right)}{y + \left(x + t\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(z + a\right) - b\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 65.5% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
t_1 := x + \left(y + t\right)\\
\mathbf{if}\;y \leq -4200000000000 \lor \neg \left(y \leq 2.9 \cdot 10^{-29}\right):\\
\;\;\;\;y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{t\_1}\right)\\

\mathbf{else}:\\
\;\;\;\;z \cdot \left(\frac{x}{t\_1} + \frac{a}{z}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -4.2e12 or 2.90000000000000024e-29 < y

    1. Initial program 40.7%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 32.1%

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

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

        \[\leadsto \left(y \cdot \left(\left(a + z\right) - b\right)\right) \cdot \frac{1}{\color{blue}{\left(t + x\right)} + y} \]
      3. associate-+r+32.0%

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

        \[\leadsto \left(y \cdot \color{blue}{\left(a + \left(z - b\right)\right)}\right) \cdot \frac{1}{t + \left(x + y\right)} \]
      5. associate-+r+32.0%

        \[\leadsto \left(y \cdot \left(a + \left(z - b\right)\right)\right) \cdot \frac{1}{\color{blue}{\left(t + x\right) + y}} \]
      6. +-commutative32.0%

        \[\leadsto \left(y \cdot \left(a + \left(z - b\right)\right)\right) \cdot \frac{1}{\color{blue}{\left(x + t\right)} + y} \]
      7. associate-+l+32.0%

        \[\leadsto \left(y \cdot \left(a + \left(z - b\right)\right)\right) \cdot \frac{1}{\color{blue}{x + \left(t + y\right)}} \]
      8. +-commutative32.0%

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

      \[\leadsto \color{blue}{\left(y \cdot \left(a + \left(z - b\right)\right)\right) \cdot \frac{1}{x + \left(y + t\right)}} \]
    6. Step-by-step derivation
      1. associate-*l*78.3%

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

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

    if -4.2e12 < y < 2.90000000000000024e-29

    1. Initial program 75.9%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 75.1%

      \[\leadsto \color{blue}{z \cdot \left(\left(\frac{x}{t + \left(x + y\right)} + \left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)} \]
    4. Step-by-step derivation
      1. associate--l+75.1%

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

        \[\leadsto z \cdot \left(\frac{x}{\color{blue}{\left(x + y\right) + t}} + \left(\left(\frac{y}{t + \left(x + y\right)} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      3. associate-+r+75.1%

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{\color{blue}{\left(x + y\right) + t}} + \frac{a \cdot \left(t + y\right)}{z \cdot \left(t + \left(x + y\right)\right)}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      5. associate-+r+75.1%

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{x + \left(y + t\right)} + \color{blue}{\frac{a}{z} \cdot \frac{t + y}{t + \left(x + y\right)}}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      7. +-commutative87.2%

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

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

        \[\leadsto z \cdot \left(\frac{x}{x + \left(y + t\right)} + \left(\left(\frac{y}{x + \left(y + t\right)} + \frac{a}{z} \cdot \frac{y + t}{\color{blue}{x + \left(y + t\right)}}\right) - \frac{b \cdot y}{z \cdot \left(t + \left(x + y\right)\right)}\right)\right) \]
      10. associate-/r*86.4%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -4200000000000 \lor \neg \left(y \leq 2.9 \cdot 10^{-29}\right):\\ \;\;\;\;y \cdot \left(\left(a + \left(z - b\right)\right) \cdot \frac{1}{x + \left(y + t\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;z \cdot \left(\frac{x}{x + \left(y + t\right)} + \frac{a}{z}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 61.5% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := a + z \cdot \frac{x + y}{t}\\ \mathbf{if}\;t \leq -2.1 \cdot 10^{+94}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq -2.35 \cdot 10^{-87}:\\ \;\;\;\;a \cdot \left(\frac{z}{a} + \frac{y}{x + y}\right)\\ \mathbf{elif}\;t \leq 3.8 \cdot 10^{+127}:\\ \;\;\;\;\left(z + a\right) - b\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ a (* z (/ (+ x y) t)))))
   (if (<= t -2.1e+94)
     t_1
     (if (<= t -2.35e-87)
       (* a (+ (/ z a) (/ y (+ x y))))
       (if (<= t 3.8e+127) (- (+ z a) b) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = a + (z * ((x + y) / t));
	double tmp;
	if (t <= -2.1e+94) {
		tmp = t_1;
	} else if (t <= -2.35e-87) {
		tmp = a * ((z / a) + (y / (x + y)));
	} else if (t <= 3.8e+127) {
		tmp = (z + a) - b;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: t_1
    real(8) :: tmp
    t_1 = a + (z * ((x + y) / t))
    if (t <= (-2.1d+94)) then
        tmp = t_1
    else if (t <= (-2.35d-87)) then
        tmp = a * ((z / a) + (y / (x + y)))
    else if (t <= 3.8d+127) then
        tmp = (z + a) - b
    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 t_1 = a + (z * ((x + y) / t));
	double tmp;
	if (t <= -2.1e+94) {
		tmp = t_1;
	} else if (t <= -2.35e-87) {
		tmp = a * ((z / a) + (y / (x + y)));
	} else if (t <= 3.8e+127) {
		tmp = (z + a) - b;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = a + (z * ((x + y) / t))
	tmp = 0
	if t <= -2.1e+94:
		tmp = t_1
	elif t <= -2.35e-87:
		tmp = a * ((z / a) + (y / (x + y)))
	elif t <= 3.8e+127:
		tmp = (z + a) - b
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(a + Float64(z * Float64(Float64(x + y) / t)))
	tmp = 0.0
	if (t <= -2.1e+94)
		tmp = t_1;
	elseif (t <= -2.35e-87)
		tmp = Float64(a * Float64(Float64(z / a) + Float64(y / Float64(x + y))));
	elseif (t <= 3.8e+127)
		tmp = Float64(Float64(z + a) - b);
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = a + (z * ((x + y) / t));
	tmp = 0.0;
	if (t <= -2.1e+94)
		tmp = t_1;
	elseif (t <= -2.35e-87)
		tmp = a * ((z / a) + (y / (x + y)));
	elseif (t <= 3.8e+127)
		tmp = (z + a) - b;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(a + N[(z * N[(N[(x + y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.1e+94], t$95$1, If[LessEqual[t, -2.35e-87], N[(a * N[(N[(z / a), $MachinePrecision] + N[(y / N[(x + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.8e+127], N[(N[(z + a), $MachinePrecision] - b), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := a + z \cdot \frac{x + y}{t}\\
\mathbf{if}\;t \leq -2.1 \cdot 10^{+94}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq -2.35 \cdot 10^{-87}:\\
\;\;\;\;a \cdot \left(\frac{z}{a} + \frac{y}{x + y}\right)\\

\mathbf{elif}\;t \leq 3.8 \cdot 10^{+127}:\\
\;\;\;\;\left(z + a\right) - b\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -2.09999999999999989e94 or 3.7999999999999998e127 < t

    1. Initial program 55.1%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in a around -inf 80.1%

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

        \[\leadsto \color{blue}{-a \cdot \left(-1 \cdot \frac{t + y}{t + \left(x + y\right)} + -1 \cdot \frac{\frac{z \cdot \left(x + y\right)}{t + \left(x + y\right)} - \frac{b \cdot y}{t + \left(x + y\right)}}{a}\right)} \]
      2. distribute-rgt-neg-in80.1%

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

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

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

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

      \[\leadsto \color{blue}{a + \frac{a \cdot \left(\frac{z \cdot \left(x + y\right)}{a} - \left(x + \frac{b \cdot y}{a}\right)\right)}{t}} \]
    7. Taylor expanded in z around -inf 64.2%

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

        \[\leadsto a + \color{blue}{z \cdot \frac{x + y}{t}} \]
    9. Simplified73.0%

      \[\leadsto a + \color{blue}{z \cdot \frac{x + y}{t}} \]

    if -2.09999999999999989e94 < t < -2.35e-87

    1. Initial program 63.3%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in a around -inf 70.5%

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

        \[\leadsto \color{blue}{-a \cdot \left(-1 \cdot \frac{t + y}{t + \left(x + y\right)} + -1 \cdot \frac{\frac{z \cdot \left(x + y\right)}{t + \left(x + y\right)} - \frac{b \cdot y}{t + \left(x + y\right)}}{a}\right)} \]
      2. distribute-rgt-neg-in70.5%

        \[\leadsto \color{blue}{a \cdot \left(-\left(-1 \cdot \frac{t + y}{t + \left(x + y\right)} + -1 \cdot \frac{\frac{z \cdot \left(x + y\right)}{t + \left(x + y\right)} - \frac{b \cdot y}{t + \left(x + y\right)}}{a}\right)\right)} \]
      3. mul-1-neg70.5%

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

        \[\leadsto a \cdot \left(-\color{blue}{\left(-1 \cdot \frac{t + y}{t + \left(x + y\right)} - \frac{\frac{z \cdot \left(x + y\right)}{t + \left(x + y\right)} - \frac{b \cdot y}{t + \left(x + y\right)}}{a}\right)}\right) \]
    5. Simplified70.5%

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

      \[\leadsto \color{blue}{a \cdot \left(\frac{z \cdot \left(x + y\right)}{a \cdot \left(t + \left(x + y\right)\right)} - -1 \cdot \frac{t + y}{t + \left(x + y\right)}\right)} \]
    7. Step-by-step derivation
      1. times-frac68.0%

        \[\leadsto a \cdot \left(\color{blue}{\frac{z}{a} \cdot \frac{x + y}{t + \left(x + y\right)}} - -1 \cdot \frac{t + y}{t + \left(x + y\right)}\right) \]
      2. mul-1-neg68.0%

        \[\leadsto a \cdot \left(\frac{z}{a} \cdot \frac{x + y}{t + \left(x + y\right)} - \color{blue}{\left(-\frac{t + y}{t + \left(x + y\right)}\right)}\right) \]
    8. Simplified68.0%

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

      \[\leadsto \color{blue}{a \cdot \left(\frac{y}{x + y} + \frac{z}{a}\right)} \]
    10. Step-by-step derivation
      1. +-commutative59.5%

        \[\leadsto a \cdot \color{blue}{\left(\frac{z}{a} + \frac{y}{x + y}\right)} \]
    11. Simplified59.5%

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

    if -2.35e-87 < t < 3.7999999999999998e127

    1. Initial program 58.4%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 68.3%

      \[\leadsto \color{blue}{\left(a + z\right) - b} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification68.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.1 \cdot 10^{+94}:\\ \;\;\;\;a + z \cdot \frac{x + y}{t}\\ \mathbf{elif}\;t \leq -2.35 \cdot 10^{-87}:\\ \;\;\;\;a \cdot \left(\frac{z}{a} + \frac{y}{x + y}\right)\\ \mathbf{elif}\;t \leq 3.8 \cdot 10^{+127}:\\ \;\;\;\;\left(z + a\right) - b\\ \mathbf{else}:\\ \;\;\;\;a + z \cdot \frac{x + y}{t}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 63.1% accurate, 1.1× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -8.6 \cdot 10^{+94} \lor \neg \left(t \leq 7.5 \cdot 10^{+127}\right):\\
\;\;\;\;a + z \cdot \frac{x + y}{t}\\

\mathbf{else}:\\
\;\;\;\;\left(z + a\right) - b\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -8.6e94 or 7.4999999999999996e127 < t

    1. Initial program 55.1%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in a around -inf 80.1%

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

        \[\leadsto \color{blue}{-a \cdot \left(-1 \cdot \frac{t + y}{t + \left(x + y\right)} + -1 \cdot \frac{\frac{z \cdot \left(x + y\right)}{t + \left(x + y\right)} - \frac{b \cdot y}{t + \left(x + y\right)}}{a}\right)} \]
      2. distribute-rgt-neg-in80.1%

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

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

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

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

      \[\leadsto \color{blue}{a + \frac{a \cdot \left(\frac{z \cdot \left(x + y\right)}{a} - \left(x + \frac{b \cdot y}{a}\right)\right)}{t}} \]
    7. Taylor expanded in z around -inf 64.2%

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

        \[\leadsto a + \color{blue}{z \cdot \frac{x + y}{t}} \]
    9. Simplified73.0%

      \[\leadsto a + \color{blue}{z \cdot \frac{x + y}{t}} \]

    if -8.6e94 < t < 7.4999999999999996e127

    1. Initial program 59.5%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 63.9%

      \[\leadsto \color{blue}{\left(a + z\right) - b} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification67.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8.6 \cdot 10^{+94} \lor \neg \left(t \leq 7.5 \cdot 10^{+127}\right):\\ \;\;\;\;a + z \cdot \frac{x + y}{t}\\ \mathbf{else}:\\ \;\;\;\;\left(z + a\right) - b\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 59.9% accurate, 1.2× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;t \leq -8.5 \cdot 10^{+94} \lor \neg \left(t \leq 1.15 \cdot 10^{+128}\right):\\
\;\;\;\;a - \frac{y \cdot b}{t}\\

\mathbf{else}:\\
\;\;\;\;\left(z + a\right) - b\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -8.50000000000000054e94 or 1.14999999999999999e128 < t

    1. Initial program 55.1%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in a around -inf 80.1%

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

        \[\leadsto \color{blue}{-a \cdot \left(-1 \cdot \frac{t + y}{t + \left(x + y\right)} + -1 \cdot \frac{\frac{z \cdot \left(x + y\right)}{t + \left(x + y\right)} - \frac{b \cdot y}{t + \left(x + y\right)}}{a}\right)} \]
      2. distribute-rgt-neg-in80.1%

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

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

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

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

      \[\leadsto \color{blue}{a + \frac{a \cdot \left(\frac{z \cdot \left(x + y\right)}{a} - \left(x + \frac{b \cdot y}{a}\right)\right)}{t}} \]
    7. Taylor expanded in b around inf 62.8%

      \[\leadsto a + \color{blue}{-1 \cdot \frac{b \cdot y}{t}} \]
    8. Step-by-step derivation
      1. associate-*r/62.8%

        \[\leadsto a + \color{blue}{\frac{-1 \cdot \left(b \cdot y\right)}{t}} \]
      2. associate-*r*62.8%

        \[\leadsto a + \frac{\color{blue}{\left(-1 \cdot b\right) \cdot y}}{t} \]
      3. neg-mul-162.8%

        \[\leadsto a + \frac{\color{blue}{\left(-b\right)} \cdot y}{t} \]
    9. Simplified62.8%

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

    if -8.50000000000000054e94 < t < 1.14999999999999999e128

    1. Initial program 59.5%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 63.9%

      \[\leadsto \color{blue}{\left(a + z\right) - b} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification63.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8.5 \cdot 10^{+94} \lor \neg \left(t \leq 1.15 \cdot 10^{+128}\right):\\ \;\;\;\;a - \frac{y \cdot b}{t}\\ \mathbf{else}:\\ \;\;\;\;\left(z + a\right) - b\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 58.8% accurate, 1.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3.1 \cdot 10^{+95}:\\ \;\;\;\;a\\ \mathbf{elif}\;t \leq 1.1 \cdot 10^{+171}:\\ \;\;\;\;\left(z + a\right) - b\\ \mathbf{else}:\\ \;\;\;\;a\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= t -3.1e+95) a (if (<= t 1.1e+171) (- (+ z a) b) a)))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (t <= -3.1e+95) {
		tmp = a;
	} else if (t <= 1.1e+171) {
		tmp = (z + a) - b;
	} else {
		tmp = a;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (t <= (-3.1d+95)) then
        tmp = a
    else if (t <= 1.1d+171) then
        tmp = (z + a) - b
    else
        tmp = a
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (t <= -3.1e+95) {
		tmp = a;
	} else if (t <= 1.1e+171) {
		tmp = (z + a) - b;
	} else {
		tmp = a;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if t <= -3.1e+95:
		tmp = a
	elif t <= 1.1e+171:
		tmp = (z + a) - b
	else:
		tmp = a
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (t <= -3.1e+95)
		tmp = a;
	elseif (t <= 1.1e+171)
		tmp = Float64(Float64(z + a) - b);
	else
		tmp = a;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (t <= -3.1e+95)
		tmp = a;
	elseif (t <= 1.1e+171)
		tmp = (z + a) - b;
	else
		tmp = a;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -3.1e+95], a, If[LessEqual[t, 1.1e+171], N[(N[(z + a), $MachinePrecision] - b), $MachinePrecision], a]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.1 \cdot 10^{+95}:\\
\;\;\;\;a\\

\mathbf{elif}\;t \leq 1.1 \cdot 10^{+171}:\\
\;\;\;\;\left(z + a\right) - b\\

\mathbf{else}:\\
\;\;\;\;a\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -3.1000000000000003e95 or 1.1e171 < t

    1. Initial program 57.8%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 55.7%

      \[\leadsto \color{blue}{a} \]

    if -3.1000000000000003e95 < t < 1.1e171

    1. Initial program 58.1%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 63.2%

      \[\leadsto \color{blue}{\left(a + z\right) - b} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification60.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -3.1 \cdot 10^{+95}:\\ \;\;\;\;a\\ \mathbf{elif}\;t \leq 1.1 \cdot 10^{+171}:\\ \;\;\;\;\left(z + a\right) - b\\ \mathbf{else}:\\ \;\;\;\;a\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 41.3% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -1.05 \cdot 10^{+115}:\\ \;\;\;\;z\\ \mathbf{elif}\;x \leq 4.5 \cdot 10^{+183}:\\ \;\;\;\;a\\ \mathbf{else}:\\ \;\;\;\;z\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= x -1.05e+115) z (if (<= x 4.5e+183) a z)))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (x <= -1.05e+115) {
		tmp = z;
	} else if (x <= 4.5e+183) {
		tmp = a;
	} else {
		tmp = z;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (x <= (-1.05d+115)) then
        tmp = z
    else if (x <= 4.5d+183) then
        tmp = a
    else
        tmp = z
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (x <= -1.05e+115) {
		tmp = z;
	} else if (x <= 4.5e+183) {
		tmp = a;
	} else {
		tmp = z;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if x <= -1.05e+115:
		tmp = z
	elif x <= 4.5e+183:
		tmp = a
	else:
		tmp = z
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (x <= -1.05e+115)
		tmp = z;
	elseif (x <= 4.5e+183)
		tmp = a;
	else
		tmp = z;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (x <= -1.05e+115)
		tmp = z;
	elseif (x <= 4.5e+183)
		tmp = a;
	else
		tmp = z;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, -1.05e+115], z, If[LessEqual[x, 4.5e+183], a, z]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.05 \cdot 10^{+115}:\\
\;\;\;\;z\\

\mathbf{elif}\;x \leq 4.5 \cdot 10^{+183}:\\
\;\;\;\;a\\

\mathbf{else}:\\
\;\;\;\;z\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < -1.05000000000000002e115 or 4.50000000000000017e183 < x

    1. Initial program 47.1%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 58.8%

      \[\leadsto \color{blue}{z} \]

    if -1.05000000000000002e115 < x < 4.50000000000000017e183

    1. Initial program 61.4%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf 45.6%

      \[\leadsto \color{blue}{a} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 11: 51.9% accurate, 2.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq 5 \cdot 10^{+153}:\\ \;\;\;\;z + a\\ \mathbf{else}:\\ \;\;\;\;a - b\\ \end{array} \end{array} \]
(FPCore (x y z t a b) :precision binary64 (if (<= b 5e+153) (+ z a) (- a b)))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (b <= 5e+153) {
		tmp = z + a;
	} else {
		tmp = a - b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (b <= 5d+153) then
        tmp = z + a
    else
        tmp = a - b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (b <= 5e+153) {
		tmp = z + a;
	} else {
		tmp = a - b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if b <= 5e+153:
		tmp = z + a
	else:
		tmp = a - b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (b <= 5e+153)
		tmp = Float64(z + a);
	else
		tmp = Float64(a - b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (b <= 5e+153)
		tmp = z + a;
	else
		tmp = a - b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, 5e+153], N[(z + a), $MachinePrecision], N[(a - b), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq 5 \cdot 10^{+153}:\\
\;\;\;\;z + a\\

\mathbf{else}:\\
\;\;\;\;a - b\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < 5.00000000000000018e153

    1. Initial program 59.5%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in b around 0 49.9%

      \[\leadsto \color{blue}{\frac{a \cdot \left(t + y\right) + z \cdot \left(x + y\right)}{t + \left(x + y\right)}} \]
    4. Taylor expanded in y around inf 54.8%

      \[\leadsto \color{blue}{a + z} \]

    if 5.00000000000000018e153 < b

    1. Initial program 48.7%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 59.9%

      \[\leadsto \color{blue}{\left(a + z\right) - b} \]
    4. Taylor expanded in z around 0 54.6%

      \[\leadsto \color{blue}{a - b} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification54.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 5 \cdot 10^{+153}:\\ \;\;\;\;z + a\\ \mathbf{else}:\\ \;\;\;\;a - b\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 51.1% accurate, 2.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;b \leq 1.15 \cdot 10^{+162}:\\ \;\;\;\;z + a\\ \mathbf{else}:\\ \;\;\;\;-b\\ \end{array} \end{array} \]
(FPCore (x y z t a b) :precision binary64 (if (<= b 1.15e+162) (+ z a) (- b)))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (b <= 1.15e+162) {
		tmp = z + a;
	} else {
		tmp = -b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: tmp
    if (b <= 1.15d+162) then
        tmp = z + a
    else
        tmp = -b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (b <= 1.15e+162) {
		tmp = z + a;
	} else {
		tmp = -b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if b <= 1.15e+162:
		tmp = z + a
	else:
		tmp = -b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (b <= 1.15e+162)
		tmp = Float64(z + a);
	else
		tmp = Float64(-b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (b <= 1.15e+162)
		tmp = z + a;
	else
		tmp = -b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, 1.15e+162], N[(z + a), $MachinePrecision], (-b)]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;b \leq 1.15 \cdot 10^{+162}:\\
\;\;\;\;z + a\\

\mathbf{else}:\\
\;\;\;\;-b\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if b < 1.14999999999999997e162

    1. Initial program 59.0%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in b around 0 49.5%

      \[\leadsto \color{blue}{\frac{a \cdot \left(t + y\right) + z \cdot \left(x + y\right)}{t + \left(x + y\right)}} \]
    4. Taylor expanded in y around inf 54.8%

      \[\leadsto \color{blue}{a + z} \]

    if 1.14999999999999997e162 < b

    1. Initial program 51.1%

      \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 56.5%

      \[\leadsto \color{blue}{\left(a + z\right) - b} \]
    4. Taylor expanded in b around inf 48.1%

      \[\leadsto \color{blue}{-1 \cdot b} \]
    5. Step-by-step derivation
      1. neg-mul-148.1%

        \[\leadsto \color{blue}{-b} \]
    6. Simplified48.1%

      \[\leadsto \color{blue}{-b} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification54.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 1.15 \cdot 10^{+162}:\\ \;\;\;\;z + a\\ \mathbf{else}:\\ \;\;\;\;-b\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 31.8% accurate, 21.0× speedup?

\[\begin{array}{l} \\ a \end{array} \]
(FPCore (x y z t a b) :precision binary64 a)
double code(double x, double y, double z, double t, double a, double b) {
	return a;
}
real(8) function code(x, y, z, t, a, b)
    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
    code = a
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	return a;
}
def code(x, y, z, t, a, b):
	return a
function code(x, y, z, t, a, b)
	return a
end
function tmp = code(x, y, z, t, a, b)
	tmp = a;
end
code[x_, y_, z_, t_, a_, b_] := a
\begin{array}{l}

\\
a
\end{array}
Derivation
  1. Initial program 58.0%

    \[\frac{\left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b}{\left(x + t\right) + y} \]
  2. Add Preprocessing
  3. Taylor expanded in t around inf 36.4%

    \[\leadsto \color{blue}{a} \]
  4. Add Preprocessing

Developer Target 1: 83.1% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(x + t\right) + y\\ t_2 := \left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b\\ t_3 := \frac{t\_2}{t\_1}\\ t_4 := \left(z + a\right) - b\\ \mathbf{if}\;t\_3 < -3.5813117084150564 \cdot 10^{+153}:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;t\_3 < 1.2285964308315609 \cdot 10^{+82}:\\ \;\;\;\;\frac{1}{\frac{t\_1}{t\_2}}\\ \mathbf{else}:\\ \;\;\;\;t\_4\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ (+ x t) y))
        (t_2 (- (+ (* (+ x y) z) (* (+ t y) a)) (* y b)))
        (t_3 (/ t_2 t_1))
        (t_4 (- (+ z a) b)))
   (if (< t_3 -3.5813117084150564e+153)
     t_4
     (if (< t_3 1.2285964308315609e+82) (/ 1.0 (/ t_1 t_2)) t_4))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (x + t) + y;
	double t_2 = (((x + y) * z) + ((t + y) * a)) - (y * b);
	double t_3 = t_2 / t_1;
	double t_4 = (z + a) - b;
	double tmp;
	if (t_3 < -3.5813117084150564e+153) {
		tmp = t_4;
	} else if (t_3 < 1.2285964308315609e+82) {
		tmp = 1.0 / (t_1 / t_2);
	} else {
		tmp = t_4;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    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) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: t_4
    real(8) :: tmp
    t_1 = (x + t) + y
    t_2 = (((x + y) * z) + ((t + y) * a)) - (y * b)
    t_3 = t_2 / t_1
    t_4 = (z + a) - b
    if (t_3 < (-3.5813117084150564d+153)) then
        tmp = t_4
    else if (t_3 < 1.2285964308315609d+82) then
        tmp = 1.0d0 / (t_1 / t_2)
    else
        tmp = t_4
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (x + t) + y;
	double t_2 = (((x + y) * z) + ((t + y) * a)) - (y * b);
	double t_3 = t_2 / t_1;
	double t_4 = (z + a) - b;
	double tmp;
	if (t_3 < -3.5813117084150564e+153) {
		tmp = t_4;
	} else if (t_3 < 1.2285964308315609e+82) {
		tmp = 1.0 / (t_1 / t_2);
	} else {
		tmp = t_4;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = (x + t) + y
	t_2 = (((x + y) * z) + ((t + y) * a)) - (y * b)
	t_3 = t_2 / t_1
	t_4 = (z + a) - b
	tmp = 0
	if t_3 < -3.5813117084150564e+153:
		tmp = t_4
	elif t_3 < 1.2285964308315609e+82:
		tmp = 1.0 / (t_1 / t_2)
	else:
		tmp = t_4
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(x + t) + y)
	t_2 = Float64(Float64(Float64(Float64(x + y) * z) + Float64(Float64(t + y) * a)) - Float64(y * b))
	t_3 = Float64(t_2 / t_1)
	t_4 = Float64(Float64(z + a) - b)
	tmp = 0.0
	if (t_3 < -3.5813117084150564e+153)
		tmp = t_4;
	elseif (t_3 < 1.2285964308315609e+82)
		tmp = Float64(1.0 / Float64(t_1 / t_2));
	else
		tmp = t_4;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = (x + t) + y;
	t_2 = (((x + y) * z) + ((t + y) * a)) - (y * b);
	t_3 = t_2 / t_1;
	t_4 = (z + a) - b;
	tmp = 0.0;
	if (t_3 < -3.5813117084150564e+153)
		tmp = t_4;
	elseif (t_3 < 1.2285964308315609e+82)
		tmp = 1.0 / (t_1 / t_2);
	else
		tmp = t_4;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + t), $MachinePrecision] + y), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(N[(x + y), $MachinePrecision] * z), $MachinePrecision] + N[(N[(t + y), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 / t$95$1), $MachinePrecision]}, Block[{t$95$4 = N[(N[(z + a), $MachinePrecision] - b), $MachinePrecision]}, If[Less[t$95$3, -3.5813117084150564e+153], t$95$4, If[Less[t$95$3, 1.2285964308315609e+82], N[(1.0 / N[(t$95$1 / t$95$2), $MachinePrecision]), $MachinePrecision], t$95$4]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left(x + t\right) + y\\
t_2 := \left(\left(x + y\right) \cdot z + \left(t + y\right) \cdot a\right) - y \cdot b\\
t_3 := \frac{t\_2}{t\_1}\\
t_4 := \left(z + a\right) - b\\
\mathbf{if}\;t\_3 < -3.5813117084150564 \cdot 10^{+153}:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;t\_3 < 1.2285964308315609 \cdot 10^{+82}:\\
\;\;\;\;\frac{1}{\frac{t\_1}{t\_2}}\\

\mathbf{else}:\\
\;\;\;\;t\_4\\


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2024143 
(FPCore (x y z t a b)
  :name "AI.Clustering.Hierarchical.Internal:ward from clustering-0.2.1"
  :precision binary64

  :alt
  (! :herbie-platform default (if (< (/ (- (+ (* (+ x y) z) (* (+ t y) a)) (* y b)) (+ (+ x t) y)) -3581311708415056400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- (+ z a) b) (if (< (/ (- (+ (* (+ x y) z) (* (+ t y) a)) (* y b)) (+ (+ x t) y)) 12285964308315609000000000000000000000000000000000000000000000000000000000000000000) (/ 1 (/ (+ (+ x t) y) (- (+ (* (+ x y) z) (* (+ t y) a)) (* y b)))) (- (+ z a) b))))

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