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

Percentage Accurate: 61.2% → 84.6%
Time: 14.6s
Alternatives: 17
Speedup: 1.0×

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 17 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 61.2% 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: 84.6% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := a + \left(z - b\right)\\ t_2 := t + \left(y + x\right)\\ t_3 := \frac{y}{t_2}\\ t_4 := \left(a \cdot \left(t_3 + \frac{t}{t_2}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t_2}\\ t_5 := t_3 \cdot t_1\\ \mathbf{if}\;y \leq -2.1 \cdot 10^{+120}:\\ \;\;\;\;t_5\\ \mathbf{elif}\;y \leq -1.12 \cdot 10^{-108}:\\ \;\;\;\;t_4\\ \mathbf{elif}\;y \leq -2.4 \cdot 10^{-129}:\\ \;\;\;\;\frac{1}{\frac{x + \left(y + t\right)}{\mathsf{fma}\left(a, t, \mathsf{fma}\left(y, t_1, x \cdot z\right)\right)}}\\ \mathbf{elif}\;y \leq 5.5 \cdot 10^{+110}:\\ \;\;\;\;t_4\\ \mathbf{else}:\\ \;\;\;\;t_5\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ a (- z b)))
        (t_2 (+ t (+ y x)))
        (t_3 (/ y t_2))
        (t_4
         (- (+ (* a (+ t_3 (/ t t_2))) (/ x (/ (+ t x) z))) (/ (* y b) t_2)))
        (t_5 (* t_3 t_1)))
   (if (<= y -2.1e+120)
     t_5
     (if (<= y -1.12e-108)
       t_4
       (if (<= y -2.4e-129)
         (/ 1.0 (/ (+ x (+ y t)) (fma a t (fma y t_1 (* x z)))))
         (if (<= y 5.5e+110) t_4 t_5))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = a + (z - b);
	double t_2 = t + (y + x);
	double t_3 = y / t_2;
	double t_4 = ((a * (t_3 + (t / t_2))) + (x / ((t + x) / z))) - ((y * b) / t_2);
	double t_5 = t_3 * t_1;
	double tmp;
	if (y <= -2.1e+120) {
		tmp = t_5;
	} else if (y <= -1.12e-108) {
		tmp = t_4;
	} else if (y <= -2.4e-129) {
		tmp = 1.0 / ((x + (y + t)) / fma(a, t, fma(y, t_1, (x * z))));
	} else if (y <= 5.5e+110) {
		tmp = t_4;
	} else {
		tmp = t_5;
	}
	return tmp;
}
function code(x, y, z, t, a, b)
	t_1 = Float64(a + Float64(z - b))
	t_2 = Float64(t + Float64(y + x))
	t_3 = Float64(y / t_2)
	t_4 = Float64(Float64(Float64(a * Float64(t_3 + Float64(t / t_2))) + Float64(x / Float64(Float64(t + x) / z))) - Float64(Float64(y * b) / t_2))
	t_5 = Float64(t_3 * t_1)
	tmp = 0.0
	if (y <= -2.1e+120)
		tmp = t_5;
	elseif (y <= -1.12e-108)
		tmp = t_4;
	elseif (y <= -2.4e-129)
		tmp = Float64(1.0 / Float64(Float64(x + Float64(y + t)) / fma(a, t, fma(y, t_1, Float64(x * z)))));
	elseif (y <= 5.5e+110)
		tmp = t_4;
	else
		tmp = t_5;
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(a + N[(z - b), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t + N[(y + x), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(y / t$95$2), $MachinePrecision]}, Block[{t$95$4 = N[(N[(N[(a * N[(t$95$3 + N[(t / t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x / N[(N[(t + x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y * b), $MachinePrecision] / t$95$2), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(t$95$3 * t$95$1), $MachinePrecision]}, If[LessEqual[y, -2.1e+120], t$95$5, If[LessEqual[y, -1.12e-108], t$95$4, If[LessEqual[y, -2.4e-129], N[(1.0 / N[(N[(x + N[(y + t), $MachinePrecision]), $MachinePrecision] / N[(a * t + N[(y * t$95$1 + N[(x * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.5e+110], t$95$4, t$95$5]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := a + \left(z - b\right)\\
t_2 := t + \left(y + x\right)\\
t_3 := \frac{y}{t_2}\\
t_4 := \left(a \cdot \left(t_3 + \frac{t}{t_2}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t_2}\\
t_5 := t_3 \cdot t_1\\
\mathbf{if}\;y \leq -2.1 \cdot 10^{+120}:\\
\;\;\;\;t_5\\

\mathbf{elif}\;y \leq -1.12 \cdot 10^{-108}:\\
\;\;\;\;t_4\\

\mathbf{elif}\;y \leq -2.4 \cdot 10^{-129}:\\
\;\;\;\;\frac{1}{\frac{x + \left(y + t\right)}{\mathsf{fma}\left(a, t, \mathsf{fma}\left(y, t_1, x \cdot z\right)\right)}}\\

\mathbf{elif}\;y \leq 5.5 \cdot 10^{+110}:\\
\;\;\;\;t_4\\

\mathbf{else}:\\
\;\;\;\;t_5\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.1e120 or 5.49999999999999996e110 < y

    1. Initial program 36.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. Taylor expanded in y around inf 35.7%

      \[\leadsto \frac{\color{blue}{y \cdot \left(\left(a + z\right) - b\right)}}{\left(x + t\right) + y} \]
    3. Step-by-step derivation
      1. *-un-lft-identity35.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -2.1e120 < y < -1.11999999999999992e-108 or -2.39999999999999989e-129 < y < 5.49999999999999996e110

    1. Initial program 69.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. Taylor expanded in a around 0 83.1%

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

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

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

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

    if -1.11999999999999992e-108 < y < -2.39999999999999989e-129

    1. Initial program 99.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. Step-by-step derivation
      1. clear-num99.8%

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

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

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

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

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

        \[\leadsto \frac{1}{\frac{x + \left(y + t\right)}{\color{blue}{\mathsf{fma}\left(x + y, z, \left(y + t\right) \cdot a - y \cdot b\right)}}} \]
      7. inv-pow99.8%

        \[\leadsto \color{blue}{{\left(\frac{x + \left(y + t\right)}{\mathsf{fma}\left(x + y, z, \left(y + t\right) \cdot a - y \cdot b\right)}\right)}^{-1}} \]
    3. Applied egg-rr99.8%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.1 \cdot 10^{+120}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{elif}\;y \leq -1.12 \cdot 10^{-108}:\\ \;\;\;\;\left(a \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{t}{t + \left(y + x\right)}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{elif}\;y \leq -2.4 \cdot 10^{-129}:\\ \;\;\;\;\frac{1}{\frac{x + \left(y + t\right)}{\mathsf{fma}\left(a, t, \mathsf{fma}\left(y, a + \left(z - b\right), x \cdot z\right)\right)}}\\ \mathbf{elif}\;y \leq 5.5 \cdot 10^{+110}:\\ \;\;\;\;\left(a \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{t}{t + \left(y + x\right)}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \end{array} \]

Alternative 2: 84.6% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t + \left(y + x\right)\\ t_2 := \frac{y}{t_1}\\ t_3 := \left(a \cdot \left(t_2 + \frac{t}{t_1}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t_1}\\ t_4 := t_2 \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{if}\;y \leq -8.5 \cdot 10^{+121}:\\ \;\;\;\;t_4\\ \mathbf{elif}\;y \leq -2.3 \cdot 10^{-108}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;y \leq -1.16 \cdot 10^{-128}:\\ \;\;\;\;\mathsf{fma}\left(a, y + t, \left(y + x\right) \cdot z - y \cdot b\right) \cdot \frac{1}{x + \left(y + t\right)}\\ \mathbf{elif}\;y \leq 3.5 \cdot 10^{+107}:\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;t_4\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ t (+ y x)))
        (t_2 (/ y t_1))
        (t_3
         (- (+ (* a (+ t_2 (/ t t_1))) (/ x (/ (+ t x) z))) (/ (* y b) t_1)))
        (t_4 (* t_2 (+ a (- z b)))))
   (if (<= y -8.5e+121)
     t_4
     (if (<= y -2.3e-108)
       t_3
       (if (<= y -1.16e-128)
         (* (fma a (+ y t) (- (* (+ y x) z) (* y b))) (/ 1.0 (+ x (+ y t))))
         (if (<= y 3.5e+107) t_3 t_4))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = t + (y + x);
	double t_2 = y / t_1;
	double t_3 = ((a * (t_2 + (t / t_1))) + (x / ((t + x) / z))) - ((y * b) / t_1);
	double t_4 = t_2 * (a + (z - b));
	double tmp;
	if (y <= -8.5e+121) {
		tmp = t_4;
	} else if (y <= -2.3e-108) {
		tmp = t_3;
	} else if (y <= -1.16e-128) {
		tmp = fma(a, (y + t), (((y + x) * z) - (y * b))) * (1.0 / (x + (y + t)));
	} else if (y <= 3.5e+107) {
		tmp = t_3;
	} else {
		tmp = t_4;
	}
	return tmp;
}
function code(x, y, z, t, a, b)
	t_1 = Float64(t + Float64(y + x))
	t_2 = Float64(y / t_1)
	t_3 = Float64(Float64(Float64(a * Float64(t_2 + Float64(t / t_1))) + Float64(x / Float64(Float64(t + x) / z))) - Float64(Float64(y * b) / t_1))
	t_4 = Float64(t_2 * Float64(a + Float64(z - b)))
	tmp = 0.0
	if (y <= -8.5e+121)
		tmp = t_4;
	elseif (y <= -2.3e-108)
		tmp = t_3;
	elseif (y <= -1.16e-128)
		tmp = Float64(fma(a, Float64(y + t), Float64(Float64(Float64(y + x) * z) - Float64(y * b))) * Float64(1.0 / Float64(x + Float64(y + t))));
	elseif (y <= 3.5e+107)
		tmp = t_3;
	else
		tmp = t_4;
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(t + N[(y + x), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y / t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[(a * N[(t$95$2 + N[(t / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x / N[(N[(t + x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y * b), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(t$95$2 * N[(a + N[(z - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -8.5e+121], t$95$4, If[LessEqual[y, -2.3e-108], t$95$3, If[LessEqual[y, -1.16e-128], N[(N[(a * N[(y + t), $MachinePrecision] + N[(N[(N[(y + x), $MachinePrecision] * z), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(1.0 / N[(x + N[(y + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.5e+107], t$95$3, t$95$4]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t + \left(y + x\right)\\
t_2 := \frac{y}{t_1}\\
t_3 := \left(a \cdot \left(t_2 + \frac{t}{t_1}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t_1}\\
t_4 := t_2 \cdot \left(a + \left(z - b\right)\right)\\
\mathbf{if}\;y \leq -8.5 \cdot 10^{+121}:\\
\;\;\;\;t_4\\

\mathbf{elif}\;y \leq -2.3 \cdot 10^{-108}:\\
\;\;\;\;t_3\\

\mathbf{elif}\;y \leq -1.16 \cdot 10^{-128}:\\
\;\;\;\;\mathsf{fma}\left(a, y + t, \left(y + x\right) \cdot z - y \cdot b\right) \cdot \frac{1}{x + \left(y + t\right)}\\

\mathbf{elif}\;y \leq 3.5 \cdot 10^{+107}:\\
\;\;\;\;t_3\\

\mathbf{else}:\\
\;\;\;\;t_4\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -8.5e121 or 3.4999999999999997e107 < y

    1. Initial program 36.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. Taylor expanded in y around inf 35.7%

      \[\leadsto \frac{\color{blue}{y \cdot \left(\left(a + z\right) - b\right)}}{\left(x + t\right) + y} \]
    3. Step-by-step derivation
      1. *-un-lft-identity35.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -8.5e121 < y < -2.29999999999999996e-108 or -1.16000000000000007e-128 < y < 3.4999999999999997e107

    1. Initial program 69.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. Taylor expanded in a around 0 83.1%

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

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

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

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

    if -2.29999999999999996e-108 < y < -1.16000000000000007e-128

    1. Initial program 99.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. Step-by-step derivation
      1. +-commutative99.5%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \mathsf{fma}\left(a, y + t, \left(x + y\right) \cdot z - y \cdot b\right) \cdot \frac{1}{\color{blue}{\left(x + t\right) + y}} \]
      6. associate-+l+99.7%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -8.5 \cdot 10^{+121}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{elif}\;y \leq -2.3 \cdot 10^{-108}:\\ \;\;\;\;\left(a \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{t}{t + \left(y + x\right)}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{elif}\;y \leq -1.16 \cdot 10^{-128}:\\ \;\;\;\;\mathsf{fma}\left(a, y + t, \left(y + x\right) \cdot z - y \cdot b\right) \cdot \frac{1}{x + \left(y + t\right)}\\ \mathbf{elif}\;y \leq 3.5 \cdot 10^{+107}:\\ \;\;\;\;\left(a \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{t}{t + \left(y + x\right)}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \end{array} \]

Alternative 3: 85.8% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\left(\left(y + x\right) \cdot z + a \cdot \left(y + t\right)\right) - y \cdot b}{y + \left(t + x\right)}\\ \mathbf{if}\;t_1 \leq -\infty:\\ \;\;\;\;\left(a + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{elif}\;t_1 \leq 5 \cdot 10^{+264}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\left(a + z\right) - b\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ (- (+ (* (+ y x) z) (* a (+ y t))) (* y b)) (+ y (+ t x)))))
   (if (<= t_1 (- INFINITY))
     (- (+ a (/ x (/ (+ t x) z))) (/ (* y b) (+ t (+ y x))))
     (if (<= t_1 5e+264) t_1 (- (+ a z) b)))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x));
	double tmp;
	if (t_1 <= -((double) INFINITY)) {
		tmp = (a + (x / ((t + x) / z))) - ((y * b) / (t + (y + x)));
	} else if (t_1 <= 5e+264) {
		tmp = t_1;
	} else {
		tmp = (a + z) - b;
	}
	return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x));
	double tmp;
	if (t_1 <= -Double.POSITIVE_INFINITY) {
		tmp = (a + (x / ((t + x) / z))) - ((y * b) / (t + (y + x)));
	} else if (t_1 <= 5e+264) {
		tmp = t_1;
	} else {
		tmp = (a + z) - b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x))
	tmp = 0
	if t_1 <= -math.inf:
		tmp = (a + (x / ((t + x) / z))) - ((y * b) / (t + (y + x)))
	elif t_1 <= 5e+264:
		tmp = t_1
	else:
		tmp = (a + z) - b
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(Float64(Float64(Float64(y + x) * z) + Float64(a * Float64(y + t))) - Float64(y * b)) / Float64(y + Float64(t + x)))
	tmp = 0.0
	if (t_1 <= Float64(-Inf))
		tmp = Float64(Float64(a + Float64(x / Float64(Float64(t + x) / z))) - Float64(Float64(y * b) / Float64(t + Float64(y + x))));
	elseif (t_1 <= 5e+264)
		tmp = t_1;
	else
		tmp = Float64(Float64(a + z) - b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x));
	tmp = 0.0;
	if (t_1 <= -Inf)
		tmp = (a + (x / ((t + x) / z))) - ((y * b) / (t + (y + x)));
	elseif (t_1 <= 5e+264)
		tmp = t_1;
	else
		tmp = (a + z) - b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(N[(N[(y + x), $MachinePrecision] * z), $MachinePrecision] + N[(a * N[(y + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision] / N[(y + N[(t + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(N[(a + N[(x / N[(N[(t + x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y * b), $MachinePrecision] / N[(t + N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 5e+264], t$95$1, N[(N[(a + z), $MachinePrecision] - b), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{\left(\left(y + x\right) \cdot z + a \cdot \left(y + t\right)\right) - y \cdot b}{y + \left(t + x\right)}\\
\mathbf{if}\;t_1 \leq -\infty:\\
\;\;\;\;\left(a + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\

\mathbf{elif}\;t_1 \leq 5 \cdot 10^{+264}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 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

    1. Initial program 5.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. Taylor expanded in a around 0 49.0%

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

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

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

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

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

    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.00000000000000033e264

    1. Initial program 98.7%

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

    if 5.00000000000000033e264 < (/.f64 (-.f64 (+.f64 (*.f64 (+.f64 x y) z) (*.f64 (+.f64 t y) a)) (*.f64 y b)) (+.f64 (+.f64 x t) y))

    1. Initial program 4.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. Taylor expanded in y around inf 70.3%

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

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

Alternative 4: 84.8% accurate, 0.5× speedup?

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

\\
\begin{array}{l}
t_1 := t + \left(y + x\right)\\
t_2 := \frac{y \cdot b}{t_1}\\
t_3 := \frac{y}{t_1}\\
t_4 := \left(a \cdot \left(t_3 + \frac{t}{t_1}\right) + \frac{x}{\frac{t + x}{z}}\right) - t_2\\
t_5 := t_3 \cdot \left(a + \left(z - b\right)\right)\\
\mathbf{if}\;y \leq -8.2 \cdot 10^{+121}:\\
\;\;\;\;t_5\\

\mathbf{elif}\;y \leq -7 \cdot 10^{-106}:\\
\;\;\;\;t_4\\

\mathbf{elif}\;y \leq -2 \cdot 10^{-129}:\\
\;\;\;\;\left(z \cdot \left(t_3 + \frac{x}{t_1}\right) + \frac{a \cdot \left(y + t\right)}{t_1}\right) - t_2\\

\mathbf{elif}\;y \leq 1.15 \cdot 10^{+111}:\\
\;\;\;\;t_4\\

\mathbf{else}:\\
\;\;\;\;t_5\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -8.2e121 or 1.15000000000000001e111 < y

    1. Initial program 36.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. Taylor expanded in y around inf 35.7%

      \[\leadsto \frac{\color{blue}{y \cdot \left(\left(a + z\right) - b\right)}}{\left(x + t\right) + y} \]
    3. Step-by-step derivation
      1. *-un-lft-identity35.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -8.2e121 < y < -7e-106 or -1.9999999999999999e-129 < y < 1.15000000000000001e111

    1. Initial program 69.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. Taylor expanded in a around 0 83.5%

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

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

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

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

    if -7e-106 < y < -1.9999999999999999e-129

    1. Initial program 90.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. Taylor expanded in z around 0 99.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -8.2 \cdot 10^{+121}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{elif}\;y \leq -7 \cdot 10^{-106}:\\ \;\;\;\;\left(a \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{t}{t + \left(y + x\right)}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{elif}\;y \leq -2 \cdot 10^{-129}:\\ \;\;\;\;\left(z \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{x}{t + \left(y + x\right)}\right) + \frac{a \cdot \left(y + t\right)}{t + \left(y + x\right)}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{elif}\;y \leq 1.15 \cdot 10^{+111}:\\ \;\;\;\;\left(a \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{t}{t + \left(y + x\right)}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \end{array} \]

Alternative 5: 84.6% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t + \left(y + x\right)\\ t_2 := \frac{y}{t_1}\\ t_3 := \left(a \cdot \left(t_2 + \frac{t}{t_1}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t_1}\\ t_4 := t_2 \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{if}\;y \leq -5.8 \cdot 10^{+122}:\\ \;\;\;\;t_4\\ \mathbf{elif}\;y \leq -4.3 \cdot 10^{-109}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;y \leq -2.45 \cdot 10^{-129}:\\ \;\;\;\;\frac{\left(\left(y + x\right) \cdot z + a \cdot \left(y + t\right)\right) - y \cdot b}{y + \left(t + x\right)}\\ \mathbf{elif}\;y \leq 2.2 \cdot 10^{+111}:\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;t_4\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ t (+ y x)))
        (t_2 (/ y t_1))
        (t_3
         (- (+ (* a (+ t_2 (/ t t_1))) (/ x (/ (+ t x) z))) (/ (* y b) t_1)))
        (t_4 (* t_2 (+ a (- z b)))))
   (if (<= y -5.8e+122)
     t_4
     (if (<= y -4.3e-109)
       t_3
       (if (<= y -2.45e-129)
         (/ (- (+ (* (+ y x) z) (* a (+ y t))) (* y b)) (+ y (+ t x)))
         (if (<= y 2.2e+111) t_3 t_4))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = t + (y + x);
	double t_2 = y / t_1;
	double t_3 = ((a * (t_2 + (t / t_1))) + (x / ((t + x) / z))) - ((y * b) / t_1);
	double t_4 = t_2 * (a + (z - b));
	double tmp;
	if (y <= -5.8e+122) {
		tmp = t_4;
	} else if (y <= -4.3e-109) {
		tmp = t_3;
	} else if (y <= -2.45e-129) {
		tmp = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x));
	} else if (y <= 2.2e+111) {
		tmp = t_3;
	} 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 = t + (y + x)
    t_2 = y / t_1
    t_3 = ((a * (t_2 + (t / t_1))) + (x / ((t + x) / z))) - ((y * b) / t_1)
    t_4 = t_2 * (a + (z - b))
    if (y <= (-5.8d+122)) then
        tmp = t_4
    else if (y <= (-4.3d-109)) then
        tmp = t_3
    else if (y <= (-2.45d-129)) then
        tmp = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x))
    else if (y <= 2.2d+111) then
        tmp = t_3
    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 = t + (y + x);
	double t_2 = y / t_1;
	double t_3 = ((a * (t_2 + (t / t_1))) + (x / ((t + x) / z))) - ((y * b) / t_1);
	double t_4 = t_2 * (a + (z - b));
	double tmp;
	if (y <= -5.8e+122) {
		tmp = t_4;
	} else if (y <= -4.3e-109) {
		tmp = t_3;
	} else if (y <= -2.45e-129) {
		tmp = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x));
	} else if (y <= 2.2e+111) {
		tmp = t_3;
	} else {
		tmp = t_4;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = t + (y + x)
	t_2 = y / t_1
	t_3 = ((a * (t_2 + (t / t_1))) + (x / ((t + x) / z))) - ((y * b) / t_1)
	t_4 = t_2 * (a + (z - b))
	tmp = 0
	if y <= -5.8e+122:
		tmp = t_4
	elif y <= -4.3e-109:
		tmp = t_3
	elif y <= -2.45e-129:
		tmp = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x))
	elif y <= 2.2e+111:
		tmp = t_3
	else:
		tmp = t_4
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(t + Float64(y + x))
	t_2 = Float64(y / t_1)
	t_3 = Float64(Float64(Float64(a * Float64(t_2 + Float64(t / t_1))) + Float64(x / Float64(Float64(t + x) / z))) - Float64(Float64(y * b) / t_1))
	t_4 = Float64(t_2 * Float64(a + Float64(z - b)))
	tmp = 0.0
	if (y <= -5.8e+122)
		tmp = t_4;
	elseif (y <= -4.3e-109)
		tmp = t_3;
	elseif (y <= -2.45e-129)
		tmp = Float64(Float64(Float64(Float64(Float64(y + x) * z) + Float64(a * Float64(y + t))) - Float64(y * b)) / Float64(y + Float64(t + x)));
	elseif (y <= 2.2e+111)
		tmp = t_3;
	else
		tmp = t_4;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = t + (y + x);
	t_2 = y / t_1;
	t_3 = ((a * (t_2 + (t / t_1))) + (x / ((t + x) / z))) - ((y * b) / t_1);
	t_4 = t_2 * (a + (z - b));
	tmp = 0.0;
	if (y <= -5.8e+122)
		tmp = t_4;
	elseif (y <= -4.3e-109)
		tmp = t_3;
	elseif (y <= -2.45e-129)
		tmp = ((((y + x) * z) + (a * (y + t))) - (y * b)) / (y + (t + x));
	elseif (y <= 2.2e+111)
		tmp = t_3;
	else
		tmp = t_4;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(t + N[(y + x), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y / t$95$1), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[(a * N[(t$95$2 + N[(t / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(x / N[(N[(t + x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y * b), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(t$95$2 * N[(a + N[(z - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -5.8e+122], t$95$4, If[LessEqual[y, -4.3e-109], t$95$3, If[LessEqual[y, -2.45e-129], N[(N[(N[(N[(N[(y + x), $MachinePrecision] * z), $MachinePrecision] + N[(a * N[(y + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision] / N[(y + N[(t + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.2e+111], t$95$3, t$95$4]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t + \left(y + x\right)\\
t_2 := \frac{y}{t_1}\\
t_3 := \left(a \cdot \left(t_2 + \frac{t}{t_1}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t_1}\\
t_4 := t_2 \cdot \left(a + \left(z - b\right)\right)\\
\mathbf{if}\;y \leq -5.8 \cdot 10^{+122}:\\
\;\;\;\;t_4\\

\mathbf{elif}\;y \leq -4.3 \cdot 10^{-109}:\\
\;\;\;\;t_3\\

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

\mathbf{elif}\;y \leq 2.2 \cdot 10^{+111}:\\
\;\;\;\;t_3\\

\mathbf{else}:\\
\;\;\;\;t_4\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -5.8000000000000002e122 or 2.19999999999999999e111 < y

    1. Initial program 36.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. Taylor expanded in y around inf 35.7%

      \[\leadsto \frac{\color{blue}{y \cdot \left(\left(a + z\right) - b\right)}}{\left(x + t\right) + y} \]
    3. Step-by-step derivation
      1. *-un-lft-identity35.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -5.8000000000000002e122 < y < -4.2999999999999997e-109 or -2.45000000000000001e-129 < y < 2.19999999999999999e111

    1. Initial program 69.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. Taylor expanded in a around 0 83.1%

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

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

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

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

    if -4.2999999999999997e-109 < y < -2.45000000000000001e-129

    1. Initial program 99.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5.8 \cdot 10^{+122}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{elif}\;y \leq -4.3 \cdot 10^{-109}:\\ \;\;\;\;\left(a \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{t}{t + \left(y + x\right)}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{elif}\;y \leq -2.45 \cdot 10^{-129}:\\ \;\;\;\;\frac{\left(\left(y + x\right) \cdot z + a \cdot \left(y + t\right)\right) - y \cdot b}{y + \left(t + x\right)}\\ \mathbf{elif}\;y \leq 2.2 \cdot 10^{+111}:\\ \;\;\;\;\left(a \cdot \left(\frac{y}{t + \left(y + x\right)} + \frac{t}{t + \left(y + x\right)}\right) + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \end{array} \]

Alternative 6: 64.4% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t \cdot a + x \cdot z}{t + x}\\ t_2 := \frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{if}\;y \leq -2.65 \cdot 10^{+36}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;y \leq -9 \cdot 10^{-158}:\\ \;\;\;\;\frac{\left(a \cdot \left(y + t\right) + y \cdot z\right) - y \cdot b}{y + t}\\ \mathbf{elif}\;y \leq -3.4 \cdot 10^{-218}:\\ \;\;\;\;\frac{z}{\frac{x + \left(y + t\right)}{y + x}}\\ \mathbf{elif}\;y \leq 1.22 \cdot 10^{-144}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 1.12 \cdot 10^{-66}:\\ \;\;\;\;\frac{y \cdot \left(\left(a + z\right) - b\right)}{y + \left(t + x\right)}\\ \mathbf{elif}\;y \leq 1.35 \cdot 10^{+44}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ (+ (* t a) (* x z)) (+ t x)))
        (t_2 (* (/ y (+ t (+ y x))) (+ a (- z b)))))
   (if (<= y -2.65e+36)
     t_2
     (if (<= y -9e-158)
       (/ (- (+ (* a (+ y t)) (* y z)) (* y b)) (+ y t))
       (if (<= y -3.4e-218)
         (/ z (/ (+ x (+ y t)) (+ y x)))
         (if (<= y 1.22e-144)
           t_1
           (if (<= y 1.12e-66)
             (/ (* y (- (+ a z) b)) (+ y (+ t x)))
             (if (<= y 1.35e+44) t_1 t_2))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = ((t * a) + (x * z)) / (t + x);
	double t_2 = (y / (t + (y + x))) * (a + (z - b));
	double tmp;
	if (y <= -2.65e+36) {
		tmp = t_2;
	} else if (y <= -9e-158) {
		tmp = (((a * (y + t)) + (y * z)) - (y * b)) / (y + t);
	} else if (y <= -3.4e-218) {
		tmp = z / ((x + (y + t)) / (y + x));
	} else if (y <= 1.22e-144) {
		tmp = t_1;
	} else if (y <= 1.12e-66) {
		tmp = (y * ((a + z) - b)) / (y + (t + x));
	} else if (y <= 1.35e+44) {
		tmp = t_1;
	} 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 = ((t * a) + (x * z)) / (t + x)
    t_2 = (y / (t + (y + x))) * (a + (z - b))
    if (y <= (-2.65d+36)) then
        tmp = t_2
    else if (y <= (-9d-158)) then
        tmp = (((a * (y + t)) + (y * z)) - (y * b)) / (y + t)
    else if (y <= (-3.4d-218)) then
        tmp = z / ((x + (y + t)) / (y + x))
    else if (y <= 1.22d-144) then
        tmp = t_1
    else if (y <= 1.12d-66) then
        tmp = (y * ((a + z) - b)) / (y + (t + x))
    else if (y <= 1.35d+44) then
        tmp = t_1
    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 = ((t * a) + (x * z)) / (t + x);
	double t_2 = (y / (t + (y + x))) * (a + (z - b));
	double tmp;
	if (y <= -2.65e+36) {
		tmp = t_2;
	} else if (y <= -9e-158) {
		tmp = (((a * (y + t)) + (y * z)) - (y * b)) / (y + t);
	} else if (y <= -3.4e-218) {
		tmp = z / ((x + (y + t)) / (y + x));
	} else if (y <= 1.22e-144) {
		tmp = t_1;
	} else if (y <= 1.12e-66) {
		tmp = (y * ((a + z) - b)) / (y + (t + x));
	} else if (y <= 1.35e+44) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = ((t * a) + (x * z)) / (t + x)
	t_2 = (y / (t + (y + x))) * (a + (z - b))
	tmp = 0
	if y <= -2.65e+36:
		tmp = t_2
	elif y <= -9e-158:
		tmp = (((a * (y + t)) + (y * z)) - (y * b)) / (y + t)
	elif y <= -3.4e-218:
		tmp = z / ((x + (y + t)) / (y + x))
	elif y <= 1.22e-144:
		tmp = t_1
	elif y <= 1.12e-66:
		tmp = (y * ((a + z) - b)) / (y + (t + x))
	elif y <= 1.35e+44:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(Float64(t * a) + Float64(x * z)) / Float64(t + x))
	t_2 = Float64(Float64(y / Float64(t + Float64(y + x))) * Float64(a + Float64(z - b)))
	tmp = 0.0
	if (y <= -2.65e+36)
		tmp = t_2;
	elseif (y <= -9e-158)
		tmp = Float64(Float64(Float64(Float64(a * Float64(y + t)) + Float64(y * z)) - Float64(y * b)) / Float64(y + t));
	elseif (y <= -3.4e-218)
		tmp = Float64(z / Float64(Float64(x + Float64(y + t)) / Float64(y + x)));
	elseif (y <= 1.22e-144)
		tmp = t_1;
	elseif (y <= 1.12e-66)
		tmp = Float64(Float64(y * Float64(Float64(a + z) - b)) / Float64(y + Float64(t + x)));
	elseif (y <= 1.35e+44)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = ((t * a) + (x * z)) / (t + x);
	t_2 = (y / (t + (y + x))) * (a + (z - b));
	tmp = 0.0;
	if (y <= -2.65e+36)
		tmp = t_2;
	elseif (y <= -9e-158)
		tmp = (((a * (y + t)) + (y * z)) - (y * b)) / (y + t);
	elseif (y <= -3.4e-218)
		tmp = z / ((x + (y + t)) / (y + x));
	elseif (y <= 1.22e-144)
		tmp = t_1;
	elseif (y <= 1.12e-66)
		tmp = (y * ((a + z) - b)) / (y + (t + x));
	elseif (y <= 1.35e+44)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(t * a), $MachinePrecision] + N[(x * z), $MachinePrecision]), $MachinePrecision] / N[(t + x), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(y / N[(t + N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(a + N[(z - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.65e+36], t$95$2, If[LessEqual[y, -9e-158], N[(N[(N[(N[(a * N[(y + t), $MachinePrecision]), $MachinePrecision] + N[(y * z), $MachinePrecision]), $MachinePrecision] - N[(y * b), $MachinePrecision]), $MachinePrecision] / N[(y + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -3.4e-218], N[(z / N[(N[(x + N[(y + t), $MachinePrecision]), $MachinePrecision] / N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.22e-144], t$95$1, If[LessEqual[y, 1.12e-66], N[(N[(y * N[(N[(a + z), $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision] / N[(y + N[(t + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.35e+44], t$95$1, t$95$2]]]]]]]]
\begin{array}{l}

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

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

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

\mathbf{elif}\;y \leq 1.22 \cdot 10^{-144}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;y \leq 1.35 \cdot 10^{+44}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y < -2.65e36 or 1.35e44 < y

    1. Initial program 39.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. Taylor expanded in y around inf 35.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -2.65e36 < y < -9e-158

    1. Initial program 78.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. Taylor expanded in x around 0 59.6%

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

    if -9e-158 < y < -3.39999999999999986e-218

    1. Initial program 65.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. Taylor expanded in z around inf 51.7%

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

        \[\leadsto \color{blue}{\frac{z}{\frac{t + \left(x + y\right)}{x + y}}} \]
      2. +-commutative79.0%

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

        \[\leadsto \frac{z}{\frac{\color{blue}{\left(t + y\right) + x}}{x + y}} \]
      4. +-commutative79.0%

        \[\leadsto \frac{z}{\frac{\left(t + y\right) + x}{\color{blue}{y + x}}} \]
    4. Simplified79.0%

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

    if -3.39999999999999986e-218 < y < 1.22e-144 or 1.12000000000000004e-66 < y < 1.35e44

    1. Initial program 73.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. Taylor expanded in y around 0 60.5%

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

    if 1.22e-144 < y < 1.12000000000000004e-66

    1. Initial program 77.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. Taylor expanded in y around inf 59.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.65 \cdot 10^{+36}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{elif}\;y \leq -9 \cdot 10^{-158}:\\ \;\;\;\;\frac{\left(a \cdot \left(y + t\right) + y \cdot z\right) - y \cdot b}{y + t}\\ \mathbf{elif}\;y \leq -3.4 \cdot 10^{-218}:\\ \;\;\;\;\frac{z}{\frac{x + \left(y + t\right)}{y + x}}\\ \mathbf{elif}\;y \leq 1.22 \cdot 10^{-144}:\\ \;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\ \mathbf{elif}\;y \leq 1.12 \cdot 10^{-66}:\\ \;\;\;\;\frac{y \cdot \left(\left(a + z\right) - b\right)}{y + \left(t + x\right)}\\ \mathbf{elif}\;y \leq 1.35 \cdot 10^{+44}:\\ \;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \end{array} \]

Alternative 7: 73.4% accurate, 0.9× speedup?

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

\\
\begin{array}{l}
t_1 := t + \left(y + x\right)\\
\mathbf{if}\;y \leq -2.8 \cdot 10^{+115} \lor \neg \left(y \leq 1.45 \cdot 10^{+75}\right):\\
\;\;\;\;\frac{y}{t_1} \cdot \left(a + \left(z - b\right)\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -2.8e115 or 1.4499999999999999e75 < y

    1. Initial program 36.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. Taylor expanded in y around inf 33.9%

      \[\leadsto \frac{\color{blue}{y \cdot \left(\left(a + z\right) - b\right)}}{\left(x + t\right) + y} \]
    3. Step-by-step derivation
      1. *-un-lft-identity33.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -2.8e115 < y < 1.4499999999999999e75

    1. Initial program 71.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. Taylor expanded in a around 0 83.4%

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.8 \cdot 10^{+115} \lor \neg \left(y \leq 1.45 \cdot 10^{+75}\right):\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(a + \frac{x}{\frac{t + x}{z}}\right) - \frac{y \cdot b}{t + \left(y + x\right)}\\ \end{array} \]

Alternative 8: 64.6% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -3.5 \cdot 10^{-11} \lor \neg \left(y \leq 1.22 \cdot 10^{-144}\right) \land \left(y \leq 2.9 \cdot 10^{-67} \lor \neg \left(y \leq 3.1 \cdot 10^{+44}\right)\right):\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (or (<= y -3.5e-11)
         (and (not (<= y 1.22e-144)) (or (<= y 2.9e-67) (not (<= y 3.1e+44)))))
   (* (/ y (+ t (+ y x))) (+ a (- z b)))
   (/ (+ (* t a) (* x z)) (+ t x))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -3.5e-11) || (!(y <= 1.22e-144) && ((y <= 2.9e-67) || !(y <= 3.1e+44)))) {
		tmp = (y / (t + (y + x))) * (a + (z - b));
	} else {
		tmp = ((t * a) + (x * z)) / (t + x);
	}
	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 ((y <= (-3.5d-11)) .or. (.not. (y <= 1.22d-144)) .and. (y <= 2.9d-67) .or. (.not. (y <= 3.1d+44))) then
        tmp = (y / (t + (y + x))) * (a + (z - b))
    else
        tmp = ((t * a) + (x * z)) / (t + x)
    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 ((y <= -3.5e-11) || (!(y <= 1.22e-144) && ((y <= 2.9e-67) || !(y <= 3.1e+44)))) {
		tmp = (y / (t + (y + x))) * (a + (z - b));
	} else {
		tmp = ((t * a) + (x * z)) / (t + x);
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (y <= -3.5e-11) or (not (y <= 1.22e-144) and ((y <= 2.9e-67) or not (y <= 3.1e+44))):
		tmp = (y / (t + (y + x))) * (a + (z - b))
	else:
		tmp = ((t * a) + (x * z)) / (t + x)
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if ((y <= -3.5e-11) || (!(y <= 1.22e-144) && ((y <= 2.9e-67) || !(y <= 3.1e+44))))
		tmp = Float64(Float64(y / Float64(t + Float64(y + x))) * Float64(a + Float64(z - b)));
	else
		tmp = Float64(Float64(Float64(t * a) + Float64(x * z)) / Float64(t + x));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if ((y <= -3.5e-11) || (~((y <= 1.22e-144)) && ((y <= 2.9e-67) || ~((y <= 3.1e+44)))))
		tmp = (y / (t + (y + x))) * (a + (z - b));
	else
		tmp = ((t * a) + (x * z)) / (t + x);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -3.5e-11], And[N[Not[LessEqual[y, 1.22e-144]], $MachinePrecision], Or[LessEqual[y, 2.9e-67], N[Not[LessEqual[y, 3.1e+44]], $MachinePrecision]]]], N[(N[(y / N[(t + N[(y + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(a + N[(z - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(t * a), $MachinePrecision] + N[(x * z), $MachinePrecision]), $MachinePrecision] / N[(t + x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.5 \cdot 10^{-11} \lor \neg \left(y \leq 1.22 \cdot 10^{-144}\right) \land \left(y \leq 2.9 \cdot 10^{-67} \lor \neg \left(y \leq 3.1 \cdot 10^{+44}\right)\right):\\
\;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -3.50000000000000019e-11 or 1.22e-144 < y < 2.90000000000000005e-67 or 3.09999999999999996e44 < y

    1. Initial program 46.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. Taylor expanded in y around inf 40.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -3.50000000000000019e-11 < y < 1.22e-144 or 2.90000000000000005e-67 < y < 3.09999999999999996e44

    1. Initial program 74.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. Taylor expanded in y around 0 57.9%

      \[\leadsto \color{blue}{\frac{a \cdot t + x \cdot z}{t + x}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification69.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -3.5 \cdot 10^{-11} \lor \neg \left(y \leq 1.22 \cdot 10^{-144}\right) \land \left(y \leq 2.9 \cdot 10^{-67} \lor \neg \left(y \leq 3.1 \cdot 10^{+44}\right)\right):\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\ \end{array} \]

Alternative 9: 64.6% accurate, 1.0× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{t \cdot a + x \cdot z}{t + x}\\
t_2 := \frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\
\mathbf{if}\;y \leq -0.0033:\\
\;\;\;\;t_2\\

\mathbf{elif}\;y \leq 1.22 \cdot 10^{-144}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;y \leq 1.25 \cdot 10^{+44}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -0.0033 or 1.2499999999999999e44 < y

    1. Initial program 42.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. Taylor expanded in y around inf 37.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -0.0033 < y < 1.22e-144 or 4.50000000000000015e-67 < y < 1.2499999999999999e44

    1. Initial program 74.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. Taylor expanded in y around 0 57.9%

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

    if 1.22e-144 < y < 4.50000000000000015e-67

    1. Initial program 77.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. Taylor expanded in y around inf 59.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -0.0033:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \mathbf{elif}\;y \leq 1.22 \cdot 10^{-144}:\\ \;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\ \mathbf{elif}\;y \leq 4.5 \cdot 10^{-67}:\\ \;\;\;\;\frac{y \cdot \left(\left(a + z\right) - b\right)}{y + \left(t + x\right)}\\ \mathbf{elif}\;y \leq 1.25 \cdot 10^{+44}:\\ \;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(a + \left(z - b\right)\right)\\ \end{array} \]

Alternative 10: 52.1% accurate, 1.1× speedup?

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

\\
\begin{array}{l}
t_1 := x + \left(y + t\right)\\
\mathbf{if}\;b \leq -2 \cdot 10^{+101}:\\
\;\;\;\;\frac{-b}{\frac{t_1}{y}}\\

\mathbf{elif}\;b \leq 9.5 \cdot 10^{-221}:\\
\;\;\;\;\left(a + \frac{x}{\frac{t + x}{z}}\right) - b\\

\mathbf{elif}\;b \leq 8.5 \cdot 10^{-109}:\\
\;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\

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

\mathbf{else}:\\
\;\;\;\;\frac{a}{\frac{t_1}{y + t}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if b < -2e101

    1. Initial program 50.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. Taylor expanded in y around inf 34.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto -\color{blue}{\frac{b}{\frac{t + \left(x + y\right)}{y}}} \]
      3. distribute-neg-frac60.1%

        \[\leadsto \color{blue}{\frac{-b}{\frac{t + \left(x + y\right)}{y}}} \]
      4. associate-+r+60.1%

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

        \[\leadsto \frac{-b}{\frac{\color{blue}{\left(x + t\right)} + y}{y}} \]
      6. associate-+r+60.1%

        \[\leadsto \frac{-b}{\frac{\color{blue}{x + \left(t + y\right)}}{y}} \]
    9. Simplified60.1%

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

    if -2e101 < b < 9.50000000000000022e-221

    1. Initial program 60.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. Taylor expanded in a around 0 72.5%

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

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

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

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

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

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

    if 9.50000000000000022e-221 < b < 8.50000000000000005e-109

    1. Initial program 95.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. Taylor expanded in y around 0 68.8%

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

    if 8.50000000000000005e-109 < b < 8.79999999999999996e188

    1. Initial program 61.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. Taylor expanded in y around inf 65.1%

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

    if 8.79999999999999996e188 < b

    1. Initial program 39.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. Taylor expanded in a around inf 8.4%

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

        \[\leadsto \color{blue}{\frac{a}{\frac{t + \left(x + y\right)}{t + y}}} \]
      2. +-commutative48.3%

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

        \[\leadsto \frac{a}{\frac{\color{blue}{\left(t + y\right) + x}}{t + y}} \]
    4. Simplified48.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -2 \cdot 10^{+101}:\\ \;\;\;\;\frac{-b}{\frac{x + \left(y + t\right)}{y}}\\ \mathbf{elif}\;b \leq 9.5 \cdot 10^{-221}:\\ \;\;\;\;\left(a + \frac{x}{\frac{t + x}{z}}\right) - b\\ \mathbf{elif}\;b \leq 8.5 \cdot 10^{-109}:\\ \;\;\;\;\frac{t \cdot a + x \cdot z}{t + x}\\ \mathbf{elif}\;b \leq 8.8 \cdot 10^{+188}:\\ \;\;\;\;\left(a + z\right) - b\\ \mathbf{else}:\\ \;\;\;\;\frac{a}{\frac{x + \left(y + t\right)}{y + t}}\\ \end{array} \]

Alternative 11: 54.6% accurate, 1.4× speedup?

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

\\
\begin{array}{l}
t_1 := x + \left(y + t\right)\\
\mathbf{if}\;b \leq -2 \cdot 10^{+101}:\\
\;\;\;\;\frac{-b}{\frac{t_1}{y}}\\

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

\mathbf{else}:\\
\;\;\;\;\frac{a}{\frac{t_1}{y + t}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if b < -2e101

    1. Initial program 50.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. Taylor expanded in y around inf 34.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto -\color{blue}{\frac{b}{\frac{t + \left(x + y\right)}{y}}} \]
      3. distribute-neg-frac60.1%

        \[\leadsto \color{blue}{\frac{-b}{\frac{t + \left(x + y\right)}{y}}} \]
      4. associate-+r+60.1%

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

        \[\leadsto \frac{-b}{\frac{\color{blue}{\left(x + t\right)} + y}{y}} \]
      6. associate-+r+60.1%

        \[\leadsto \frac{-b}{\frac{\color{blue}{x + \left(t + y\right)}}{y}} \]
    9. Simplified60.1%

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

    if -2e101 < b < 5.00000000000000036e190

    1. Initial program 65.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. Taylor expanded in y around inf 63.8%

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

    if 5.00000000000000036e190 < b

    1. Initial program 39.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. Taylor expanded in a around inf 8.4%

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

        \[\leadsto \color{blue}{\frac{a}{\frac{t + \left(x + y\right)}{t + y}}} \]
      2. +-commutative48.3%

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

        \[\leadsto \frac{a}{\frac{\color{blue}{\left(t + y\right) + x}}{t + y}} \]
    4. Simplified48.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -2 \cdot 10^{+101}:\\ \;\;\;\;\frac{-b}{\frac{x + \left(y + t\right)}{y}}\\ \mathbf{elif}\;b \leq 5 \cdot 10^{+190}:\\ \;\;\;\;\left(a + z\right) - b\\ \mathbf{else}:\\ \;\;\;\;\frac{a}{\frac{x + \left(y + t\right)}{y + t}}\\ \end{array} \]

Alternative 12: 53.7% accurate, 1.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;b \leq -2 \cdot 10^{+101}:\\
\;\;\;\;y \cdot \frac{-b}{t + \left(y + x\right)}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if b < -2e101

    1. Initial program 50.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. Taylor expanded in y around inf 34.6%

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

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

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

        \[\leadsto -\color{blue}{\frac{b}{\frac{t + \left(x + y\right)}{y}}} \]
      3. +-commutative60.1%

        \[\leadsto -\frac{b}{\frac{\color{blue}{\left(x + y\right) + t}}{y}} \]
      4. associate-+r+60.1%

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

        \[\leadsto -\color{blue}{\frac{b}{x + \left(y + t\right)} \cdot y} \]
      6. distribute-rgt-neg-in56.5%

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

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

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

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

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

    if -2e101 < b < 2.09999999999999992e189

    1. Initial program 65.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. Taylor expanded in y around inf 63.8%

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

    if 2.09999999999999992e189 < b

    1. Initial program 39.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. Taylor expanded in t around inf 45.8%

      \[\leadsto \color{blue}{a} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification60.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -2 \cdot 10^{+101}:\\ \;\;\;\;y \cdot \frac{-b}{t + \left(y + x\right)}\\ \mathbf{elif}\;b \leq 2.1 \cdot 10^{+189}:\\ \;\;\;\;\left(a + z\right) - b\\ \mathbf{else}:\\ \;\;\;\;a\\ \end{array} \]

Alternative 13: 54.1% accurate, 1.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;b \leq -3.35 \cdot 10^{+100}:\\
\;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(-b\right)\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if b < -3.3499999999999998e100

    1. Initial program 50.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. Taylor expanded in y around inf 34.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{y}{t + \left(y + x\right)} \cdot \color{blue}{\left(-b\right)} \]
    9. Simplified60.0%

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

    if -3.3499999999999998e100 < b < 2.0500000000000001e189

    1. Initial program 65.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. Taylor expanded in y around inf 63.8%

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

    if 2.0500000000000001e189 < b

    1. Initial program 39.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. Taylor expanded in t around inf 45.8%

      \[\leadsto \color{blue}{a} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification61.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -3.35 \cdot 10^{+100}:\\ \;\;\;\;\frac{y}{t + \left(y + x\right)} \cdot \left(-b\right)\\ \mathbf{elif}\;b \leq 2.05 \cdot 10^{+189}:\\ \;\;\;\;\left(a + z\right) - b\\ \mathbf{else}:\\ \;\;\;\;a\\ \end{array} \]

Alternative 14: 54.1% accurate, 1.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;b \leq -3.35 \cdot 10^{+100}:\\
\;\;\;\;\frac{-b}{\frac{x + \left(y + t\right)}{y}}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if b < -3.3499999999999998e100

    1. Initial program 50.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. Taylor expanded in y around inf 34.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto -\color{blue}{\frac{b}{\frac{t + \left(x + y\right)}{y}}} \]
      3. distribute-neg-frac60.1%

        \[\leadsto \color{blue}{\frac{-b}{\frac{t + \left(x + y\right)}{y}}} \]
      4. associate-+r+60.1%

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

        \[\leadsto \frac{-b}{\frac{\color{blue}{\left(x + t\right)} + y}{y}} \]
      6. associate-+r+60.1%

        \[\leadsto \frac{-b}{\frac{\color{blue}{x + \left(t + y\right)}}{y}} \]
    9. Simplified60.1%

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

    if -3.3499999999999998e100 < b < 2.0500000000000001e189

    1. Initial program 65.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. Taylor expanded in y around inf 63.8%

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

    if 2.0500000000000001e189 < b

    1. Initial program 39.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. Taylor expanded in t around inf 45.8%

      \[\leadsto \color{blue}{a} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification61.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq -3.35 \cdot 10^{+100}:\\ \;\;\;\;\frac{-b}{\frac{x + \left(y + t\right)}{y}}\\ \mathbf{elif}\;b \leq 2.05 \cdot 10^{+189}:\\ \;\;\;\;\left(a + z\right) - b\\ \mathbf{else}:\\ \;\;\;\;a\\ \end{array} \]

Alternative 15: 43.4% accurate, 2.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -9 \cdot 10^{-30}:\\ \;\;\;\;a\\ \mathbf{elif}\;a \leq 2.15 \cdot 10^{-35}:\\ \;\;\;\;z\\ \mathbf{elif}\;a \leq 2.9 \cdot 10^{+19}:\\ \;\;\;\;a\\ \mathbf{elif}\;a \leq 7.6 \cdot 10^{+79}:\\ \;\;\;\;z\\ \mathbf{else}:\\ \;\;\;\;a\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= a -9e-30)
   a
   (if (<= a 2.15e-35) z (if (<= a 2.9e+19) a (if (<= a 7.6e+79) z a)))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (a <= -9e-30) {
		tmp = a;
	} else if (a <= 2.15e-35) {
		tmp = z;
	} else if (a <= 2.9e+19) {
		tmp = a;
	} else if (a <= 7.6e+79) {
		tmp = z;
	} 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 (a <= (-9d-30)) then
        tmp = a
    else if (a <= 2.15d-35) then
        tmp = z
    else if (a <= 2.9d+19) then
        tmp = a
    else if (a <= 7.6d+79) then
        tmp = z
    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 (a <= -9e-30) {
		tmp = a;
	} else if (a <= 2.15e-35) {
		tmp = z;
	} else if (a <= 2.9e+19) {
		tmp = a;
	} else if (a <= 7.6e+79) {
		tmp = z;
	} else {
		tmp = a;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if a <= -9e-30:
		tmp = a
	elif a <= 2.15e-35:
		tmp = z
	elif a <= 2.9e+19:
		tmp = a
	elif a <= 7.6e+79:
		tmp = z
	else:
		tmp = a
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (a <= -9e-30)
		tmp = a;
	elseif (a <= 2.15e-35)
		tmp = z;
	elseif (a <= 2.9e+19)
		tmp = a;
	elseif (a <= 7.6e+79)
		tmp = z;
	else
		tmp = a;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (a <= -9e-30)
		tmp = a;
	elseif (a <= 2.15e-35)
		tmp = z;
	elseif (a <= 2.9e+19)
		tmp = a;
	elseif (a <= 7.6e+79)
		tmp = z;
	else
		tmp = a;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, -9e-30], a, If[LessEqual[a, 2.15e-35], z, If[LessEqual[a, 2.9e+19], a, If[LessEqual[a, 7.6e+79], z, a]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;a \leq -9 \cdot 10^{-30}:\\
\;\;\;\;a\\

\mathbf{elif}\;a \leq 2.15 \cdot 10^{-35}:\\
\;\;\;\;z\\

\mathbf{elif}\;a \leq 2.9 \cdot 10^{+19}:\\
\;\;\;\;a\\

\mathbf{elif}\;a \leq 7.6 \cdot 10^{+79}:\\
\;\;\;\;z\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -8.99999999999999935e-30 or 2.1500000000000001e-35 < a < 2.9e19 or 7.6000000000000005e79 < a

    1. Initial program 48.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. Taylor expanded in t around inf 53.3%

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

    if -8.99999999999999935e-30 < a < 2.1500000000000001e-35 or 2.9e19 < a < 7.6000000000000005e79

    1. Initial program 71.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. Taylor expanded in x around inf 44.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -9 \cdot 10^{-30}:\\ \;\;\;\;a\\ \mathbf{elif}\;a \leq 2.15 \cdot 10^{-35}:\\ \;\;\;\;z\\ \mathbf{elif}\;a \leq 2.9 \cdot 10^{+19}:\\ \;\;\;\;a\\ \mathbf{elif}\;a \leq 7.6 \cdot 10^{+79}:\\ \;\;\;\;z\\ \mathbf{else}:\\ \;\;\;\;a\\ \end{array} \]

Alternative 16: 53.7% accurate, 3.0× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;b \leq 3.2 \cdot 10^{+190}:\\
\;\;\;\;\left(a + z\right) - b\\

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


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

    1. Initial program 61.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. Taylor expanded in y around inf 58.8%

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

    if 3.2000000000000001e190 < b

    1. Initial program 39.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. Taylor expanded in t around inf 45.8%

      \[\leadsto \color{blue}{a} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification57.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;b \leq 3.2 \cdot 10^{+190}:\\ \;\;\;\;\left(a + z\right) - b\\ \mathbf{else}:\\ \;\;\;\;a\\ \end{array} \]

Alternative 17: 32.0% 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 60.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. Taylor expanded in t around inf 31.7%

    \[\leadsto \color{blue}{a} \]
  3. Final simplification31.7%

    \[\leadsto a \]

Developer target: 81.6% 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 2023293 
(FPCore (x y z t a b)
  :name "AI.Clustering.Hierarchical.Internal:ward from clustering-0.2.1"
  :precision binary64

  :herbie-target
  (if (< (/ (- (+ (* (+ x y) z) (* (+ t y) a)) (* y b)) (+ (+ x t) y)) -3.5813117084150564e+153) (- (+ z a) b) (if (< (/ (- (+ (* (+ x y) z) (* (+ t y) a)) (* y b)) (+ (+ x t) y)) 1.2285964308315609e+82) (/ 1.0 (/ (+ (+ 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)))