Development.Shake.Progress:decay from shake-0.15.5

Percentage Accurate: 66.5% → 92.8%
Time: 20.9s
Alternatives: 22
Speedup: 0.8×

Specification

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

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

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

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

Alternative 1: 92.8% accurate, 0.1× speedup?

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

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

\mathbf{elif}\;t_4 \leq -5 \cdot 10^{-306}:\\
\;\;\;\;\frac{x \cdot y}{t_1} + \frac{t_3}{t_1}\\

\mathbf{elif}\;t_4 \leq 4 \cdot 10^{-303}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;t_4 \leq 2 \cdot 10^{+274}:\\
\;\;\;\;t_4\\

\mathbf{elif}\;t_4 \leq \infty:\\
\;\;\;\;t_5\\

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


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

    1. Initial program 28.8%

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

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

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

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

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

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

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

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

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

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

    if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -4.99999999999999998e-306

    1. Initial program 99.5%

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

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

    if -4.99999999999999998e-306 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 3.99999999999999972e-303 or +inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y))))

    1. Initial program 9.0%

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

      \[\leadsto \color{blue}{\left(\frac{t}{b - y} + \frac{x \cdot y}{z \cdot \left(b - y\right)}\right) - \left(\frac{a}{b - y} + \frac{y \cdot \left(t - a\right)}{z \cdot {\left(b - y\right)}^{2}}\right)} \]
    3. Step-by-step derivation
      1. associate--r+48.6%

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

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

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

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

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

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

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

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

    if 3.99999999999999972e-303 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 1.99999999999999984e274

    1. Initial program 99.8%

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

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

Alternative 2: 85.5% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\\ t_2 := \frac{a - t}{y} - \frac{x}{z + -1}\\ \mathbf{if}\;t_1 \leq -\infty:\\ \;\;\;\;t_2\\ \mathbf{elif}\;t_1 \leq -5 \cdot 10^{-306}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_1 \leq 4 \cdot 10^{-303}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;t_1 \leq 2 \cdot 10^{+274}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))))
        (t_2 (- (/ (- a t) y) (/ x (+ z -1.0)))))
   (if (<= t_1 (- INFINITY))
     t_2
     (if (<= t_1 -5e-306)
       t_1
       (if (<= t_1 4e-303)
         (/ (- t a) (- b y))
         (if (<= t_1 2e+274) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = ((x * y) + (z * (t - a))) / (y + (z * (b - y)));
	double t_2 = ((a - t) / y) - (x / (z + -1.0));
	double tmp;
	if (t_1 <= -((double) INFINITY)) {
		tmp = t_2;
	} else if (t_1 <= -5e-306) {
		tmp = t_1;
	} else if (t_1 <= 4e-303) {
		tmp = (t - a) / (b - y);
	} else if (t_1 <= 2e+274) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = ((x * y) + (z * (t - a))) / (y + (z * (b - y)));
	double t_2 = ((a - t) / y) - (x / (z + -1.0));
	double tmp;
	if (t_1 <= -Double.POSITIVE_INFINITY) {
		tmp = t_2;
	} else if (t_1 <= -5e-306) {
		tmp = t_1;
	} else if (t_1 <= 4e-303) {
		tmp = (t - a) / (b - y);
	} else if (t_1 <= 2e+274) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = ((x * y) + (z * (t - a))) / (y + (z * (b - y)))
	t_2 = ((a - t) / y) - (x / (z + -1.0))
	tmp = 0
	if t_1 <= -math.inf:
		tmp = t_2
	elif t_1 <= -5e-306:
		tmp = t_1
	elif t_1 <= 4e-303:
		tmp = (t - a) / (b - y)
	elif t_1 <= 2e+274:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(Float64(x * y) + Float64(z * Float64(t - a))) / Float64(y + Float64(z * Float64(b - y))))
	t_2 = Float64(Float64(Float64(a - t) / y) - Float64(x / Float64(z + -1.0)))
	tmp = 0.0
	if (t_1 <= Float64(-Inf))
		tmp = t_2;
	elseif (t_1 <= -5e-306)
		tmp = t_1;
	elseif (t_1 <= 4e-303)
		tmp = Float64(Float64(t - a) / Float64(b - y));
	elseif (t_1 <= 2e+274)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = ((x * y) + (z * (t - a))) / (y + (z * (b - y)));
	t_2 = ((a - t) / y) - (x / (z + -1.0));
	tmp = 0.0;
	if (t_1 <= -Inf)
		tmp = t_2;
	elseif (t_1 <= -5e-306)
		tmp = t_1;
	elseif (t_1 <= 4e-303)
		tmp = (t - a) / (b - y);
	elseif (t_1 <= 2e+274)
		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[(x * y), $MachinePrecision] + N[(z * N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y + N[(z * N[(b - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(a - t), $MachinePrecision] / y), $MachinePrecision] - N[(x / N[(z + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], t$95$2, If[LessEqual[t$95$1, -5e-306], t$95$1, If[LessEqual[t$95$1, 4e-303], N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2e+274], t$95$1, t$95$2]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t_1 \leq -5 \cdot 10^{-306}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;t_1 \leq 4 \cdot 10^{-303}:\\
\;\;\;\;\frac{t - a}{b - y}\\

\mathbf{elif}\;t_1 \leq 2 \cdot 10^{+274}:\\
\;\;\;\;t_1\\

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


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

    1. Initial program 18.2%

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

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

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

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

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

        \[\leadsto \frac{\color{blue}{-x}}{z - 1} - \frac{\frac{z \cdot \left(t - a\right)}{z - 1} - -1 \cdot \frac{b \cdot \left(x \cdot z\right)}{{\left(z - 1\right)}^{2}}}{y} \]
      5. sub-neg30.7%

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

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

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

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

    if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -4.99999999999999998e-306 or 3.99999999999999972e-303 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 1.99999999999999984e274

    1. Initial program 99.6%

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

    if -4.99999999999999998e-306 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 3.99999999999999972e-303

    1. Initial program 22.8%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification86.5%

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

Alternative 3: 85.5% accurate, 0.2× speedup?

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

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

\mathbf{elif}\;t_3 \leq -5 \cdot 10^{-306}:\\
\;\;\;\;\frac{x \cdot y}{t_1} + \frac{t_2}{t_1}\\

\mathbf{elif}\;t_3 \leq 4 \cdot 10^{-303}:\\
\;\;\;\;\frac{t - a}{b - y}\\

\mathbf{elif}\;t_3 \leq 2 \cdot 10^{+274}:\\
\;\;\;\;t_3\\

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


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

    1. Initial program 18.2%

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

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

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

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

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

        \[\leadsto \frac{\color{blue}{-x}}{z - 1} - \frac{\frac{z \cdot \left(t - a\right)}{z - 1} - -1 \cdot \frac{b \cdot \left(x \cdot z\right)}{{\left(z - 1\right)}^{2}}}{y} \]
      5. sub-neg30.7%

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

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

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

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

    if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -4.99999999999999998e-306

    1. Initial program 99.5%

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

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

    if -4.99999999999999998e-306 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 3.99999999999999972e-303

    1. Initial program 22.8%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]

    if 3.99999999999999972e-303 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 1.99999999999999984e274

    1. Initial program 99.8%

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

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

Alternative 4: 80.2% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{a - t}{y} - \frac{x}{z + -1}\\ t_2 := \frac{t - a}{b - y}\\ \mathbf{if}\;z \leq -5 \cdot 10^{+141}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -7.5 \cdot 10^{+19}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 1.42:\\ \;\;\;\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot b}\\ \mathbf{elif}\;z \leq 2 \cdot 10^{+64} \lor \neg \left(z \leq 3.9 \cdot 10^{+80}\right) \land z \leq 3 \cdot 10^{+101}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (- (/ (- a t) y) (/ x (+ z -1.0)))) (t_2 (/ (- t a) (- b y))))
   (if (<= z -5e+141)
     t_2
     (if (<= z -7.5e+19)
       t_1
       (if (<= z 1.42)
         (/ (+ (* x y) (* z (- t a))) (+ y (* z b)))
         (if (or (<= z 2e+64) (and (not (<= z 3.9e+80)) (<= z 3e+101)))
           t_1
           t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = ((a - t) / y) - (x / (z + -1.0));
	double t_2 = (t - a) / (b - y);
	double tmp;
	if (z <= -5e+141) {
		tmp = t_2;
	} else if (z <= -7.5e+19) {
		tmp = t_1;
	} else if (z <= 1.42) {
		tmp = ((x * y) + (z * (t - a))) / (y + (z * b));
	} else if ((z <= 2e+64) || (!(z <= 3.9e+80) && (z <= 3e+101))) {
		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 = ((a - t) / y) - (x / (z + (-1.0d0)))
    t_2 = (t - a) / (b - y)
    if (z <= (-5d+141)) then
        tmp = t_2
    else if (z <= (-7.5d+19)) then
        tmp = t_1
    else if (z <= 1.42d0) then
        tmp = ((x * y) + (z * (t - a))) / (y + (z * b))
    else if ((z <= 2d+64) .or. (.not. (z <= 3.9d+80)) .and. (z <= 3d+101)) 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 = ((a - t) / y) - (x / (z + -1.0));
	double t_2 = (t - a) / (b - y);
	double tmp;
	if (z <= -5e+141) {
		tmp = t_2;
	} else if (z <= -7.5e+19) {
		tmp = t_1;
	} else if (z <= 1.42) {
		tmp = ((x * y) + (z * (t - a))) / (y + (z * b));
	} else if ((z <= 2e+64) || (!(z <= 3.9e+80) && (z <= 3e+101))) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = ((a - t) / y) - (x / (z + -1.0))
	t_2 = (t - a) / (b - y)
	tmp = 0
	if z <= -5e+141:
		tmp = t_2
	elif z <= -7.5e+19:
		tmp = t_1
	elif z <= 1.42:
		tmp = ((x * y) + (z * (t - a))) / (y + (z * b))
	elif (z <= 2e+64) or (not (z <= 3.9e+80) and (z <= 3e+101)):
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(Float64(a - t) / y) - Float64(x / Float64(z + -1.0)))
	t_2 = Float64(Float64(t - a) / Float64(b - y))
	tmp = 0.0
	if (z <= -5e+141)
		tmp = t_2;
	elseif (z <= -7.5e+19)
		tmp = t_1;
	elseif (z <= 1.42)
		tmp = Float64(Float64(Float64(x * y) + Float64(z * Float64(t - a))) / Float64(y + Float64(z * b)));
	elseif ((z <= 2e+64) || (!(z <= 3.9e+80) && (z <= 3e+101)))
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = ((a - t) / y) - (x / (z + -1.0));
	t_2 = (t - a) / (b - y);
	tmp = 0.0;
	if (z <= -5e+141)
		tmp = t_2;
	elseif (z <= -7.5e+19)
		tmp = t_1;
	elseif (z <= 1.42)
		tmp = ((x * y) + (z * (t - a))) / (y + (z * b));
	elseif ((z <= 2e+64) || (~((z <= 3.9e+80)) && (z <= 3e+101)))
		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[(a - t), $MachinePrecision] / y), $MachinePrecision] - N[(x / N[(z + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -5e+141], t$95$2, If[LessEqual[z, -7.5e+19], t$95$1, If[LessEqual[z, 1.42], N[(N[(N[(x * y), $MachinePrecision] + N[(z * N[(t - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y + N[(z * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[z, 2e+64], And[N[Not[LessEqual[z, 3.9e+80]], $MachinePrecision], LessEqual[z, 3e+101]]], t$95$1, t$95$2]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{a - t}{y} - \frac{x}{z + -1}\\
t_2 := \frac{t - a}{b - y}\\
\mathbf{if}\;z \leq -5 \cdot 10^{+141}:\\
\;\;\;\;t_2\\

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

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

\mathbf{elif}\;z \leq 2 \cdot 10^{+64} \lor \neg \left(z \leq 3.9 \cdot 10^{+80}\right) \land z \leq 3 \cdot 10^{+101}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -5.00000000000000025e141 or 2.00000000000000004e64 < z < 3.89999999999999999e80 or 2.99999999999999993e101 < z

    1. Initial program 36.9%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]

    if -5.00000000000000025e141 < z < -7.5e19 or 1.4199999999999999 < z < 2.00000000000000004e64 or 3.89999999999999999e80 < z < 2.99999999999999993e101

    1. Initial program 50.5%

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

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

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

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

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

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

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

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

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

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

    if -7.5e19 < z < 1.4199999999999999

    1. Initial program 87.0%

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5 \cdot 10^{+141}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;z \leq -7.5 \cdot 10^{+19}:\\ \;\;\;\;\frac{a - t}{y} - \frac{x}{z + -1}\\ \mathbf{elif}\;z \leq 1.42:\\ \;\;\;\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot b}\\ \mathbf{elif}\;z \leq 2 \cdot 10^{+64} \lor \neg \left(z \leq 3.9 \cdot 10^{+80}\right) \land z \leq 3 \cdot 10^{+101}:\\ \;\;\;\;\frac{a - t}{y} - \frac{x}{z + -1}\\ \mathbf{else}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \end{array} \]

Alternative 5: 62.9% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t - a}{b - y}\\ t_2 := \frac{a - t}{y} - \frac{x}{z + -1}\\ \mathbf{if}\;y \leq -0.145:\\ \;\;\;\;t_2\\ \mathbf{elif}\;y \leq 6.2 \cdot 10^{-88}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 5.1 \cdot 10^{+28}:\\ \;\;\;\;\frac{x \cdot y}{y + z \cdot \left(b - y\right)}\\ \mathbf{elif}\;y \leq 7.5 \cdot 10^{+102}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 1.9 \cdot 10^{+120}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+148}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ (- t a) (- b y))) (t_2 (- (/ (- a t) y) (/ x (+ z -1.0)))))
   (if (<= y -0.145)
     t_2
     (if (<= y 6.2e-88)
       t_1
       (if (<= y 5.1e+28)
         (/ (* x y) (+ y (* z (- b y))))
         (if (<= y 7.5e+102)
           t_1
           (if (<= y 1.9e+120)
             (/ x (- 1.0 z))
             (if (<= y 9.8e+148) t_1 t_2))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (t - a) / (b - y);
	double t_2 = ((a - t) / y) - (x / (z + -1.0));
	double tmp;
	if (y <= -0.145) {
		tmp = t_2;
	} else if (y <= 6.2e-88) {
		tmp = t_1;
	} else if (y <= 5.1e+28) {
		tmp = (x * y) / (y + (z * (b - y)));
	} else if (y <= 7.5e+102) {
		tmp = t_1;
	} else if (y <= 1.9e+120) {
		tmp = x / (1.0 - z);
	} else if (y <= 9.8e+148) {
		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) / (b - y)
    t_2 = ((a - t) / y) - (x / (z + (-1.0d0)))
    if (y <= (-0.145d0)) then
        tmp = t_2
    else if (y <= 6.2d-88) then
        tmp = t_1
    else if (y <= 5.1d+28) then
        tmp = (x * y) / (y + (z * (b - y)))
    else if (y <= 7.5d+102) then
        tmp = t_1
    else if (y <= 1.9d+120) then
        tmp = x / (1.0d0 - z)
    else if (y <= 9.8d+148) 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) / (b - y);
	double t_2 = ((a - t) / y) - (x / (z + -1.0));
	double tmp;
	if (y <= -0.145) {
		tmp = t_2;
	} else if (y <= 6.2e-88) {
		tmp = t_1;
	} else if (y <= 5.1e+28) {
		tmp = (x * y) / (y + (z * (b - y)));
	} else if (y <= 7.5e+102) {
		tmp = t_1;
	} else if (y <= 1.9e+120) {
		tmp = x / (1.0 - z);
	} else if (y <= 9.8e+148) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = (t - a) / (b - y)
	t_2 = ((a - t) / y) - (x / (z + -1.0))
	tmp = 0
	if y <= -0.145:
		tmp = t_2
	elif y <= 6.2e-88:
		tmp = t_1
	elif y <= 5.1e+28:
		tmp = (x * y) / (y + (z * (b - y)))
	elif y <= 7.5e+102:
		tmp = t_1
	elif y <= 1.9e+120:
		tmp = x / (1.0 - z)
	elif y <= 9.8e+148:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(t - a) / Float64(b - y))
	t_2 = Float64(Float64(Float64(a - t) / y) - Float64(x / Float64(z + -1.0)))
	tmp = 0.0
	if (y <= -0.145)
		tmp = t_2;
	elseif (y <= 6.2e-88)
		tmp = t_1;
	elseif (y <= 5.1e+28)
		tmp = Float64(Float64(x * y) / Float64(y + Float64(z * Float64(b - y))));
	elseif (y <= 7.5e+102)
		tmp = t_1;
	elseif (y <= 1.9e+120)
		tmp = Float64(x / Float64(1.0 - z));
	elseif (y <= 9.8e+148)
		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) / (b - y);
	t_2 = ((a - t) / y) - (x / (z + -1.0));
	tmp = 0.0;
	if (y <= -0.145)
		tmp = t_2;
	elseif (y <= 6.2e-88)
		tmp = t_1;
	elseif (y <= 5.1e+28)
		tmp = (x * y) / (y + (z * (b - y)));
	elseif (y <= 7.5e+102)
		tmp = t_1;
	elseif (y <= 1.9e+120)
		tmp = x / (1.0 - z);
	elseif (y <= 9.8e+148)
		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[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(a - t), $MachinePrecision] / y), $MachinePrecision] - N[(x / N[(z + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -0.145], t$95$2, If[LessEqual[y, 6.2e-88], t$95$1, If[LessEqual[y, 5.1e+28], N[(N[(x * y), $MachinePrecision] / N[(y + N[(z * N[(b - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 7.5e+102], t$95$1, If[LessEqual[y, 1.9e+120], N[(x / N[(1.0 - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.8e+148], t$95$1, t$95$2]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{t - a}{b - y}\\
t_2 := \frac{a - t}{y} - \frac{x}{z + -1}\\
\mathbf{if}\;y \leq -0.145:\\
\;\;\;\;t_2\\

\mathbf{elif}\;y \leq 6.2 \cdot 10^{-88}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 5.1 \cdot 10^{+28}:\\
\;\;\;\;\frac{x \cdot y}{y + z \cdot \left(b - y\right)}\\

\mathbf{elif}\;y \leq 7.5 \cdot 10^{+102}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 1.9 \cdot 10^{+120}:\\
\;\;\;\;\frac{x}{1 - z}\\

\mathbf{elif}\;y \leq 9.8 \cdot 10^{+148}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -0.14499999999999999 or 9.8e148 < y

    1. Initial program 49.8%

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

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

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

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

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

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

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

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

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

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

    if -0.14499999999999999 < y < 6.1999999999999995e-88 or 5.1000000000000004e28 < y < 7.5e102 or 1.8999999999999999e120 < y < 9.8e148

    1. Initial program 71.5%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]

    if 6.1999999999999995e-88 < y < 5.1000000000000004e28

    1. Initial program 83.0%

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

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

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

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

    if 7.5e102 < y < 1.8999999999999999e120

    1. Initial program 83.3%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg83.7%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg83.7%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified83.7%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification68.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -0.145:\\ \;\;\;\;\frac{a - t}{y} - \frac{x}{z + -1}\\ \mathbf{elif}\;y \leq 6.2 \cdot 10^{-88}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;y \leq 5.1 \cdot 10^{+28}:\\ \;\;\;\;\frac{x \cdot y}{y + z \cdot \left(b - y\right)}\\ \mathbf{elif}\;y \leq 7.5 \cdot 10^{+102}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;y \leq 1.9 \cdot 10^{+120}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+148}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\frac{a - t}{y} - \frac{x}{z + -1}\\ \end{array} \]

Alternative 6: 60.0% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{t - a}{b - y}\\
\mathbf{if}\;y \leq -0.155:\\
\;\;\;\;\frac{a}{y} - \frac{x}{z + -1}\\

\mathbf{elif}\;y \leq 8.4 \cdot 10^{-88}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 4.2 \cdot 10^{+28}:\\
\;\;\;\;\frac{x \cdot y}{y + z \cdot \left(b - y\right)}\\

\mathbf{elif}\;y \leq 1.7 \cdot 10^{+103}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 1.1 \cdot 10^{+120}:\\
\;\;\;\;\frac{x}{1 - z}\\

\mathbf{elif}\;y \leq 4.6 \cdot 10^{+149}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;\frac{-x}{z + -1} - \frac{t}{y}\\


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

    1. Initial program 54.8%

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in t around 0 58.6%

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{z - 1} + \frac{a}{y}} \]
    7. Step-by-step derivation
      1. +-commutative58.6%

        \[\leadsto \color{blue}{\frac{a}{y} + -1 \cdot \frac{x}{z - 1}} \]
      2. sub-neg58.6%

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

        \[\leadsto \frac{a}{y} + -1 \cdot \frac{x}{z + \color{blue}{-1}} \]
      4. neg-mul-158.6%

        \[\leadsto \frac{a}{y} + \color{blue}{\left(-\frac{x}{z + -1}\right)} \]
      5. unsub-neg58.6%

        \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{z + -1}} \]
      6. +-commutative58.6%

        \[\leadsto \frac{a}{y} - \frac{x}{\color{blue}{-1 + z}} \]
    8. Simplified58.6%

      \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{-1 + z}} \]

    if -0.154999999999999999 < y < 8.3999999999999998e-88 or 4.19999999999999978e28 < y < 1.6999999999999999e103 or 1.1000000000000001e120 < y < 4.5999999999999997e149

    1. Initial program 71.5%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]

    if 8.3999999999999998e-88 < y < 4.19999999999999978e28

    1. Initial program 83.0%

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

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

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

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

    if 1.6999999999999999e103 < y < 1.1000000000000001e120

    1. Initial program 83.3%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg83.7%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg83.7%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified83.7%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]

    if 4.5999999999999997e149 < y

    1. Initial program 38.6%

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in t around inf 81.2%

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t}{y}} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification66.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -0.155:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z + -1}\\ \mathbf{elif}\;y \leq 8.4 \cdot 10^{-88}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;y \leq 4.2 \cdot 10^{+28}:\\ \;\;\;\;\frac{x \cdot y}{y + z \cdot \left(b - y\right)}\\ \mathbf{elif}\;y \leq 1.7 \cdot 10^{+103}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;y \leq 1.1 \cdot 10^{+120}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq 4.6 \cdot 10^{+149}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\frac{-x}{z + -1} - \frac{t}{y}\\ \end{array} \]

Alternative 7: 51.7% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{a}{y} - \frac{x}{z}\\ t_2 := \frac{x}{1 - z}\\ \mathbf{if}\;y \leq -1.65 \cdot 10^{+42}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;y \leq -3300000000:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq -4.6 \cdot 10^{-49}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;y \leq 3.4 \cdot 10^{+46}:\\ \;\;\;\;\frac{t - a}{b}\\ \mathbf{elif}\;y \leq 6.8 \cdot 10^{+102}:\\ \;\;\;\;\frac{t}{\frac{y}{z} - y}\\ \mathbf{elif}\;y \leq 3.9 \cdot 10^{+124} \lor \neg \left(y \leq 1.9 \cdot 10^{+141}\right):\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (- (/ a y) (/ x z))) (t_2 (/ x (- 1.0 z))))
   (if (<= y -1.65e+42)
     t_2
     (if (<= y -3300000000.0)
       t_1
       (if (<= y -4.6e-49)
         t_2
         (if (<= y 3.4e+46)
           (/ (- t a) b)
           (if (<= y 6.8e+102)
             (/ t (- (/ y z) y))
             (if (or (<= y 3.9e+124) (not (<= y 1.9e+141))) t_2 t_1))))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (a / y) - (x / z);
	double t_2 = x / (1.0 - z);
	double tmp;
	if (y <= -1.65e+42) {
		tmp = t_2;
	} else if (y <= -3300000000.0) {
		tmp = t_1;
	} else if (y <= -4.6e-49) {
		tmp = t_2;
	} else if (y <= 3.4e+46) {
		tmp = (t - a) / b;
	} else if (y <= 6.8e+102) {
		tmp = t / ((y / z) - y);
	} else if ((y <= 3.9e+124) || !(y <= 1.9e+141)) {
		tmp = t_2;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = (a / y) - (x / z)
    t_2 = x / (1.0d0 - z)
    if (y <= (-1.65d+42)) then
        tmp = t_2
    else if (y <= (-3300000000.0d0)) then
        tmp = t_1
    else if (y <= (-4.6d-49)) then
        tmp = t_2
    else if (y <= 3.4d+46) then
        tmp = (t - a) / b
    else if (y <= 6.8d+102) then
        tmp = t / ((y / z) - y)
    else if ((y <= 3.9d+124) .or. (.not. (y <= 1.9d+141))) then
        tmp = t_2
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (a / y) - (x / z);
	double t_2 = x / (1.0 - z);
	double tmp;
	if (y <= -1.65e+42) {
		tmp = t_2;
	} else if (y <= -3300000000.0) {
		tmp = t_1;
	} else if (y <= -4.6e-49) {
		tmp = t_2;
	} else if (y <= 3.4e+46) {
		tmp = (t - a) / b;
	} else if (y <= 6.8e+102) {
		tmp = t / ((y / z) - y);
	} else if ((y <= 3.9e+124) || !(y <= 1.9e+141)) {
		tmp = t_2;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = (a / y) - (x / z)
	t_2 = x / (1.0 - z)
	tmp = 0
	if y <= -1.65e+42:
		tmp = t_2
	elif y <= -3300000000.0:
		tmp = t_1
	elif y <= -4.6e-49:
		tmp = t_2
	elif y <= 3.4e+46:
		tmp = (t - a) / b
	elif y <= 6.8e+102:
		tmp = t / ((y / z) - y)
	elif (y <= 3.9e+124) or not (y <= 1.9e+141):
		tmp = t_2
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(a / y) - Float64(x / z))
	t_2 = Float64(x / Float64(1.0 - z))
	tmp = 0.0
	if (y <= -1.65e+42)
		tmp = t_2;
	elseif (y <= -3300000000.0)
		tmp = t_1;
	elseif (y <= -4.6e-49)
		tmp = t_2;
	elseif (y <= 3.4e+46)
		tmp = Float64(Float64(t - a) / b);
	elseif (y <= 6.8e+102)
		tmp = Float64(t / Float64(Float64(y / z) - y));
	elseif ((y <= 3.9e+124) || !(y <= 1.9e+141))
		tmp = t_2;
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = (a / y) - (x / z);
	t_2 = x / (1.0 - z);
	tmp = 0.0;
	if (y <= -1.65e+42)
		tmp = t_2;
	elseif (y <= -3300000000.0)
		tmp = t_1;
	elseif (y <= -4.6e-49)
		tmp = t_2;
	elseif (y <= 3.4e+46)
		tmp = (t - a) / b;
	elseif (y <= 6.8e+102)
		tmp = t / ((y / z) - y);
	elseif ((y <= 3.9e+124) || ~((y <= 1.9e+141)))
		tmp = t_2;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(a / y), $MachinePrecision] - N[(x / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(1.0 - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.65e+42], t$95$2, If[LessEqual[y, -3300000000.0], t$95$1, If[LessEqual[y, -4.6e-49], t$95$2, If[LessEqual[y, 3.4e+46], N[(N[(t - a), $MachinePrecision] / b), $MachinePrecision], If[LessEqual[y, 6.8e+102], N[(t / N[(N[(y / z), $MachinePrecision] - y), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[y, 3.9e+124], N[Not[LessEqual[y, 1.9e+141]], $MachinePrecision]], t$95$2, t$95$1]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{a}{y} - \frac{x}{z}\\
t_2 := \frac{x}{1 - z}\\
\mathbf{if}\;y \leq -1.65 \cdot 10^{+42}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;y \leq -3300000000:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq -4.6 \cdot 10^{-49}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;y \leq 3.4 \cdot 10^{+46}:\\
\;\;\;\;\frac{t - a}{b}\\

\mathbf{elif}\;y \leq 6.8 \cdot 10^{+102}:\\
\;\;\;\;\frac{t}{\frac{y}{z} - y}\\

\mathbf{elif}\;y \leq 3.9 \cdot 10^{+124} \lor \neg \left(y \leq 1.9 \cdot 10^{+141}\right):\\
\;\;\;\;t_2\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -1.6499999999999999e42 or -3.3e9 < y < -4.5999999999999998e-49 or 6.8000000000000001e102 < y < 3.9e124 or 1.89999999999999988e141 < y

    1. Initial program 51.7%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg62.4%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg62.4%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified62.4%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]

    if -1.6499999999999999e42 < y < -3.3e9 or 3.9e124 < y < 1.89999999999999988e141

    1. Initial program 56.0%

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in t around 0 76.9%

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{z - 1} + \frac{a}{y}} \]
    7. Step-by-step derivation
      1. +-commutative76.9%

        \[\leadsto \color{blue}{\frac{a}{y} + -1 \cdot \frac{x}{z - 1}} \]
      2. sub-neg76.9%

        \[\leadsto \frac{a}{y} + -1 \cdot \frac{x}{\color{blue}{z + \left(-1\right)}} \]
      3. metadata-eval76.9%

        \[\leadsto \frac{a}{y} + -1 \cdot \frac{x}{z + \color{blue}{-1}} \]
      4. neg-mul-176.9%

        \[\leadsto \frac{a}{y} + \color{blue}{\left(-\frac{x}{z + -1}\right)} \]
      5. unsub-neg76.9%

        \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{z + -1}} \]
      6. +-commutative76.9%

        \[\leadsto \frac{a}{y} - \frac{x}{\color{blue}{-1 + z}} \]
    8. Simplified76.9%

      \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{-1 + z}} \]
    9. Taylor expanded in z around inf 77.5%

      \[\leadsto \frac{a}{y} - \color{blue}{\frac{x}{z}} \]

    if -4.5999999999999998e-49 < y < 3.3999999999999998e46

    1. Initial program 76.7%

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

      \[\leadsto \color{blue}{\frac{t - a}{b}} \]

    if 3.3999999999999998e46 < y < 6.8000000000000001e102

    1. Initial program 61.4%

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

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

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

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

        \[\leadsto \frac{t}{\frac{\color{blue}{\mathsf{fma}\left(z, b - y, y\right)}}{z}} \]
    4. Simplified55.2%

      \[\leadsto \color{blue}{\frac{t}{\frac{\mathsf{fma}\left(z, b - y, y\right)}{z}}} \]
    5. Taylor expanded in z around 0 55.3%

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

      \[\leadsto \color{blue}{\frac{t}{\frac{y}{z} - y}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification59.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.65 \cdot 10^{+42}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq -3300000000:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z}\\ \mathbf{elif}\;y \leq -4.6 \cdot 10^{-49}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq 3.4 \cdot 10^{+46}:\\ \;\;\;\;\frac{t - a}{b}\\ \mathbf{elif}\;y \leq 6.8 \cdot 10^{+102}:\\ \;\;\;\;\frac{t}{\frac{y}{z} - y}\\ \mathbf{elif}\;y \leq 3.9 \cdot 10^{+124} \lor \neg \left(y \leq 1.9 \cdot 10^{+141}\right):\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z}\\ \end{array} \]

Alternative 8: 71.1% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{t - a}{b - y}\\
\mathbf{if}\;z \leq -2.7 \cdot 10^{+134}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;z \leq -7.5 \cdot 10^{+77}:\\
\;\;\;\;\frac{a}{y} - \frac{x}{z}\\

\mathbf{elif}\;z \leq -1.75 \cdot 10^{-9} \lor \neg \left(z \leq 230\right):\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;x - \frac{\frac{z}{\frac{y}{t - a}}}{z + -1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -2.7e134 or -7.49999999999999955e77 < z < -1.75e-9 or 230 < z

    1. Initial program 42.9%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]

    if -2.7e134 < z < -7.49999999999999955e77

    1. Initial program 44.1%

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

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

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

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

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

        \[\leadsto \frac{\color{blue}{-x}}{z - 1} - \frac{\frac{z \cdot \left(t - a\right)}{z - 1} - -1 \cdot \frac{b \cdot \left(x \cdot z\right)}{{\left(z - 1\right)}^{2}}}{y} \]
      5. sub-neg53.7%

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in t around 0 80.4%

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{z - 1} + \frac{a}{y}} \]
    7. Step-by-step derivation
      1. +-commutative80.4%

        \[\leadsto \color{blue}{\frac{a}{y} + -1 \cdot \frac{x}{z - 1}} \]
      2. sub-neg80.4%

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

        \[\leadsto \frac{a}{y} + -1 \cdot \frac{x}{z + \color{blue}{-1}} \]
      4. neg-mul-180.4%

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

        \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{z + -1}} \]
      6. +-commutative80.4%

        \[\leadsto \frac{a}{y} - \frac{x}{\color{blue}{-1 + z}} \]
    8. Simplified80.4%

      \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{-1 + z}} \]
    9. Taylor expanded in z around inf 80.4%

      \[\leadsto \frac{a}{y} - \color{blue}{\frac{x}{z}} \]

    if -1.75e-9 < z < 230

    1. Initial program 88.0%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \frac{-x}{z + -1} - \frac{\color{blue}{\frac{z}{\frac{y}{t - a}}}}{z - 1} \]
      3. sub-neg70.8%

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

        \[\leadsto \frac{-x}{z + -1} - \frac{\frac{z}{\frac{y}{t - a}}}{z + \color{blue}{-1}} \]
    7. Simplified70.8%

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{\frac{z}{\frac{y}{t - a}}}{z + -1}} \]
    8. Taylor expanded in z around 0 70.8%

      \[\leadsto \color{blue}{x} - \frac{\frac{z}{\frac{y}{t - a}}}{z + -1} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification74.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.7 \cdot 10^{+134}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;z \leq -7.5 \cdot 10^{+77}:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z}\\ \mathbf{elif}\;z \leq -1.75 \cdot 10^{-9} \lor \neg \left(z \leq 230\right):\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;x - \frac{\frac{z}{\frac{y}{t - a}}}{z + -1}\\ \end{array} \]

Alternative 9: 58.4% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -5 \cdot 10^{+49} \lor \neg \left(y \leq -4.2 \cdot 10^{+22} \lor \neg \left(y \leq -1.3 \cdot 10^{-49}\right) \land \left(y \leq 3 \cdot 10^{+103} \lor \neg \left(y \leq 3 \cdot 10^{+119}\right) \land y \leq 1.4 \cdot 10^{+149}\right)\right):\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (or (<= y -5e+49)
         (not
          (or (<= y -4.2e+22)
              (and (not (<= y -1.3e-49))
                   (or (<= y 3e+103)
                       (and (not (<= y 3e+119)) (<= y 1.4e+149)))))))
   (/ x (- 1.0 z))
   (/ (- t a) (- b y))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((y <= -5e+49) || !((y <= -4.2e+22) || (!(y <= -1.3e-49) && ((y <= 3e+103) || (!(y <= 3e+119) && (y <= 1.4e+149)))))) {
		tmp = x / (1.0 - z);
	} else {
		tmp = (t - a) / (b - y);
	}
	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 <= (-5d+49)) .or. (.not. (y <= (-4.2d+22)) .or. (.not. (y <= (-1.3d-49))) .and. (y <= 3d+103) .or. (.not. (y <= 3d+119)) .and. (y <= 1.4d+149))) then
        tmp = x / (1.0d0 - z)
    else
        tmp = (t - a) / (b - y)
    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 <= -5e+49) || !((y <= -4.2e+22) || (!(y <= -1.3e-49) && ((y <= 3e+103) || (!(y <= 3e+119) && (y <= 1.4e+149)))))) {
		tmp = x / (1.0 - z);
	} else {
		tmp = (t - a) / (b - y);
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (y <= -5e+49) or not ((y <= -4.2e+22) or (not (y <= -1.3e-49) and ((y <= 3e+103) or (not (y <= 3e+119) and (y <= 1.4e+149))))):
		tmp = x / (1.0 - z)
	else:
		tmp = (t - a) / (b - y)
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if ((y <= -5e+49) || !((y <= -4.2e+22) || (!(y <= -1.3e-49) && ((y <= 3e+103) || (!(y <= 3e+119) && (y <= 1.4e+149))))))
		tmp = Float64(x / Float64(1.0 - z));
	else
		tmp = Float64(Float64(t - a) / Float64(b - y));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if ((y <= -5e+49) || ~(((y <= -4.2e+22) || (~((y <= -1.3e-49)) && ((y <= 3e+103) || (~((y <= 3e+119)) && (y <= 1.4e+149)))))))
		tmp = x / (1.0 - z);
	else
		tmp = (t - a) / (b - y);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -5e+49], N[Not[Or[LessEqual[y, -4.2e+22], And[N[Not[LessEqual[y, -1.3e-49]], $MachinePrecision], Or[LessEqual[y, 3e+103], And[N[Not[LessEqual[y, 3e+119]], $MachinePrecision], LessEqual[y, 1.4e+149]]]]]], $MachinePrecision]], N[(x / N[(1.0 - z), $MachinePrecision]), $MachinePrecision], N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -5 \cdot 10^{+49} \lor \neg \left(y \leq -4.2 \cdot 10^{+22} \lor \neg \left(y \leq -1.3 \cdot 10^{-49}\right) \land \left(y \leq 3 \cdot 10^{+103} \lor \neg \left(y \leq 3 \cdot 10^{+119}\right) \land y \leq 1.4 \cdot 10^{+149}\right)\right):\\
\;\;\;\;\frac{x}{1 - z}\\

\mathbf{else}:\\
\;\;\;\;\frac{t - a}{b - y}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -5.0000000000000004e49 or -4.1999999999999996e22 < y < -1.29999999999999997e-49 or 3e103 < y < 3.00000000000000001e119 or 1.4e149 < y

    1. Initial program 51.6%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg64.2%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg64.2%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified64.2%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]

    if -5.0000000000000004e49 < y < -4.1999999999999996e22 or -1.29999999999999997e-49 < y < 3e103 or 3.00000000000000001e119 < y < 1.4e149

    1. Initial program 73.2%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification65.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5 \cdot 10^{+49} \lor \neg \left(y \leq -4.2 \cdot 10^{+22} \lor \neg \left(y \leq -1.3 \cdot 10^{-49}\right) \land \left(y \leq 3 \cdot 10^{+103} \lor \neg \left(y \leq 3 \cdot 10^{+119}\right) \land y \leq 1.4 \cdot 10^{+149}\right)\right):\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \end{array} \]

Alternative 10: 61.5% accurate, 0.9× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{t - a}{b - y}\\
\mathbf{if}\;y \leq -0.082:\\
\;\;\;\;\frac{a}{y} - \frac{x}{z + -1}\\

\mathbf{elif}\;y \leq 4 \cdot 10^{+103}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 1.06 \cdot 10^{+120}:\\
\;\;\;\;\frac{x}{1 - z}\\

\mathbf{elif}\;y \leq 1.6 \cdot 10^{+150}:\\
\;\;\;\;t_1\\

\mathbf{else}:\\
\;\;\;\;\frac{-x}{z + -1} - \frac{t}{y}\\


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

    1. Initial program 54.8%

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in t around 0 58.6%

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{z - 1} + \frac{a}{y}} \]
    7. Step-by-step derivation
      1. +-commutative58.6%

        \[\leadsto \color{blue}{\frac{a}{y} + -1 \cdot \frac{x}{z - 1}} \]
      2. sub-neg58.6%

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

        \[\leadsto \frac{a}{y} + -1 \cdot \frac{x}{z + \color{blue}{-1}} \]
      4. neg-mul-158.6%

        \[\leadsto \frac{a}{y} + \color{blue}{\left(-\frac{x}{z + -1}\right)} \]
      5. unsub-neg58.6%

        \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{z + -1}} \]
      6. +-commutative58.6%

        \[\leadsto \frac{a}{y} - \frac{x}{\color{blue}{-1 + z}} \]
    8. Simplified58.6%

      \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{-1 + z}} \]

    if -0.0820000000000000034 < y < 4e103 or 1.05999999999999994e120 < y < 1.60000000000000008e150

    1. Initial program 72.9%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]

    if 4e103 < y < 1.05999999999999994e120

    1. Initial program 83.3%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg83.7%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg83.7%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified83.7%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]

    if 1.60000000000000008e150 < y

    1. Initial program 38.6%

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in t around inf 81.2%

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t}{y}} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification64.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -0.082:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z + -1}\\ \mathbf{elif}\;y \leq 4 \cdot 10^{+103}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;y \leq 1.06 \cdot 10^{+120}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq 1.6 \cdot 10^{+150}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\frac{-x}{z + -1} - \frac{t}{y}\\ \end{array} \]

Alternative 11: 61.6% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t - a}{b - y}\\ t_2 := \frac{a}{y} - \frac{x}{z + -1}\\ \mathbf{if}\;y \leq -0.102:\\ \;\;\;\;t_2\\ \mathbf{elif}\;y \leq 8.8 \cdot 10^{+102}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 4.2 \cdot 10^{+119}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+148}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ (- t a) (- b y))) (t_2 (- (/ a y) (/ x (+ z -1.0)))))
   (if (<= y -0.102)
     t_2
     (if (<= y 8.8e+102)
       t_1
       (if (<= y 4.2e+119) (/ x (- 1.0 z)) (if (<= y 9.8e+148) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (t - a) / (b - y);
	double t_2 = (a / y) - (x / (z + -1.0));
	double tmp;
	if (y <= -0.102) {
		tmp = t_2;
	} else if (y <= 8.8e+102) {
		tmp = t_1;
	} else if (y <= 4.2e+119) {
		tmp = x / (1.0 - z);
	} else if (y <= 9.8e+148) {
		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) / (b - y)
    t_2 = (a / y) - (x / (z + (-1.0d0)))
    if (y <= (-0.102d0)) then
        tmp = t_2
    else if (y <= 8.8d+102) then
        tmp = t_1
    else if (y <= 4.2d+119) then
        tmp = x / (1.0d0 - z)
    else if (y <= 9.8d+148) 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) / (b - y);
	double t_2 = (a / y) - (x / (z + -1.0));
	double tmp;
	if (y <= -0.102) {
		tmp = t_2;
	} else if (y <= 8.8e+102) {
		tmp = t_1;
	} else if (y <= 4.2e+119) {
		tmp = x / (1.0 - z);
	} else if (y <= 9.8e+148) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = (t - a) / (b - y)
	t_2 = (a / y) - (x / (z + -1.0))
	tmp = 0
	if y <= -0.102:
		tmp = t_2
	elif y <= 8.8e+102:
		tmp = t_1
	elif y <= 4.2e+119:
		tmp = x / (1.0 - z)
	elif y <= 9.8e+148:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(t - a) / Float64(b - y))
	t_2 = Float64(Float64(a / y) - Float64(x / Float64(z + -1.0)))
	tmp = 0.0
	if (y <= -0.102)
		tmp = t_2;
	elseif (y <= 8.8e+102)
		tmp = t_1;
	elseif (y <= 4.2e+119)
		tmp = Float64(x / Float64(1.0 - z));
	elseif (y <= 9.8e+148)
		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) / (b - y);
	t_2 = (a / y) - (x / (z + -1.0));
	tmp = 0.0;
	if (y <= -0.102)
		tmp = t_2;
	elseif (y <= 8.8e+102)
		tmp = t_1;
	elseif (y <= 4.2e+119)
		tmp = x / (1.0 - z);
	elseif (y <= 9.8e+148)
		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[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(a / y), $MachinePrecision] - N[(x / N[(z + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -0.102], t$95$2, If[LessEqual[y, 8.8e+102], t$95$1, If[LessEqual[y, 4.2e+119], N[(x / N[(1.0 - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.8e+148], t$95$1, t$95$2]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{t - a}{b - y}\\
t_2 := \frac{a}{y} - \frac{x}{z + -1}\\
\mathbf{if}\;y \leq -0.102:\\
\;\;\;\;t_2\\

\mathbf{elif}\;y \leq 8.8 \cdot 10^{+102}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 4.2 \cdot 10^{+119}:\\
\;\;\;\;\frac{x}{1 - z}\\

\mathbf{elif}\;y \leq 9.8 \cdot 10^{+148}:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -0.101999999999999993 or 9.8e148 < y

    1. Initial program 49.8%

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in t around 0 64.9%

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{z - 1} + \frac{a}{y}} \]
    7. Step-by-step derivation
      1. +-commutative64.9%

        \[\leadsto \color{blue}{\frac{a}{y} + -1 \cdot \frac{x}{z - 1}} \]
      2. sub-neg64.9%

        \[\leadsto \frac{a}{y} + -1 \cdot \frac{x}{\color{blue}{z + \left(-1\right)}} \]
      3. metadata-eval64.9%

        \[\leadsto \frac{a}{y} + -1 \cdot \frac{x}{z + \color{blue}{-1}} \]
      4. neg-mul-164.9%

        \[\leadsto \frac{a}{y} + \color{blue}{\left(-\frac{x}{z + -1}\right)} \]
      5. unsub-neg64.9%

        \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{z + -1}} \]
      6. +-commutative64.9%

        \[\leadsto \frac{a}{y} - \frac{x}{\color{blue}{-1 + z}} \]
    8. Simplified64.9%

      \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{-1 + z}} \]

    if -0.101999999999999993 < y < 8.8000000000000003e102 or 4.19999999999999966e119 < y < 9.8e148

    1. Initial program 72.9%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]

    if 8.8000000000000003e102 < y < 4.19999999999999966e119

    1. Initial program 83.3%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg83.7%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg83.7%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified83.7%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification64.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -0.102:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z + -1}\\ \mathbf{elif}\;y \leq 8.8 \cdot 10^{+102}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;y \leq 4.2 \cdot 10^{+119}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+148}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z + -1}\\ \end{array} \]

Alternative 12: 53.0% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x}{1 - z}\\ \mathbf{if}\;y \leq -9.5 \cdot 10^{+40}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq -1420000000000:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z}\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-49} \lor \neg \left(y \leq 1.12 \cdot 10^{+55}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{t - a}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ x (- 1.0 z))))
   (if (<= y -9.5e+40)
     t_1
     (if (<= y -1420000000000.0)
       (- (/ a y) (/ x z))
       (if (or (<= y -5e-49) (not (<= y 1.12e+55))) t_1 (/ (- t a) b))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x / (1.0 - z);
	double tmp;
	if (y <= -9.5e+40) {
		tmp = t_1;
	} else if (y <= -1420000000000.0) {
		tmp = (a / y) - (x / z);
	} else if ((y <= -5e-49) || !(y <= 1.12e+55)) {
		tmp = t_1;
	} else {
		tmp = (t - a) / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: t_1
    real(8) :: tmp
    t_1 = x / (1.0d0 - z)
    if (y <= (-9.5d+40)) then
        tmp = t_1
    else if (y <= (-1420000000000.0d0)) then
        tmp = (a / y) - (x / z)
    else if ((y <= (-5d-49)) .or. (.not. (y <= 1.12d+55))) then
        tmp = t_1
    else
        tmp = (t - a) / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x / (1.0 - z);
	double tmp;
	if (y <= -9.5e+40) {
		tmp = t_1;
	} else if (y <= -1420000000000.0) {
		tmp = (a / y) - (x / z);
	} else if ((y <= -5e-49) || !(y <= 1.12e+55)) {
		tmp = t_1;
	} else {
		tmp = (t - a) / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x / (1.0 - z)
	tmp = 0
	if y <= -9.5e+40:
		tmp = t_1
	elif y <= -1420000000000.0:
		tmp = (a / y) - (x / z)
	elif (y <= -5e-49) or not (y <= 1.12e+55):
		tmp = t_1
	else:
		tmp = (t - a) / b
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x / Float64(1.0 - z))
	tmp = 0.0
	if (y <= -9.5e+40)
		tmp = t_1;
	elseif (y <= -1420000000000.0)
		tmp = Float64(Float64(a / y) - Float64(x / z));
	elseif ((y <= -5e-49) || !(y <= 1.12e+55))
		tmp = t_1;
	else
		tmp = Float64(Float64(t - a) / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = x / (1.0 - z);
	tmp = 0.0;
	if (y <= -9.5e+40)
		tmp = t_1;
	elseif (y <= -1420000000000.0)
		tmp = (a / y) - (x / z);
	elseif ((y <= -5e-49) || ~((y <= 1.12e+55)))
		tmp = t_1;
	else
		tmp = (t - a) / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(1.0 - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -9.5e+40], t$95$1, If[LessEqual[y, -1420000000000.0], N[(N[(a / y), $MachinePrecision] - N[(x / z), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[y, -5e-49], N[Not[LessEqual[y, 1.12e+55]], $MachinePrecision]], t$95$1, N[(N[(t - a), $MachinePrecision] / b), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{x}{1 - z}\\
\mathbf{if}\;y \leq -9.5 \cdot 10^{+40}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq -1420000000000:\\
\;\;\;\;\frac{a}{y} - \frac{x}{z}\\

\mathbf{elif}\;y \leq -5 \cdot 10^{-49} \lor \neg \left(y \leq 1.12 \cdot 10^{+55}\right):\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -9.5000000000000003e40 or -1.42e12 < y < -4.9999999999999999e-49 or 1.12000000000000006e55 < y

    1. Initial program 52.4%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg59.0%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg59.0%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified59.0%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]

    if -9.5000000000000003e40 < y < -1.42e12

    1. Initial program 63.6%

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in t around 0 75.8%

      \[\leadsto \color{blue}{-1 \cdot \frac{x}{z - 1} + \frac{a}{y}} \]
    7. Step-by-step derivation
      1. +-commutative75.8%

        \[\leadsto \color{blue}{\frac{a}{y} + -1 \cdot \frac{x}{z - 1}} \]
      2. sub-neg75.8%

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

        \[\leadsto \frac{a}{y} + -1 \cdot \frac{x}{z + \color{blue}{-1}} \]
      4. neg-mul-175.8%

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

        \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{z + -1}} \]
      6. +-commutative75.8%

        \[\leadsto \frac{a}{y} - \frac{x}{\color{blue}{-1 + z}} \]
    8. Simplified75.8%

      \[\leadsto \color{blue}{\frac{a}{y} - \frac{x}{-1 + z}} \]
    9. Taylor expanded in z around inf 76.6%

      \[\leadsto \frac{a}{y} - \color{blue}{\frac{x}{z}} \]

    if -4.9999999999999999e-49 < y < 1.12000000000000006e55

    1. Initial program 75.5%

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

      \[\leadsto \color{blue}{\frac{t - a}{b}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification57.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -9.5 \cdot 10^{+40}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq -1420000000000:\\ \;\;\;\;\frac{a}{y} - \frac{x}{z}\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-49} \lor \neg \left(y \leq 1.12 \cdot 10^{+55}\right):\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{t - a}{b}\\ \end{array} \]

Alternative 13: 41.7% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{-a}{b}\\
t_2 := \frac{x}{1 - z}\\
\mathbf{if}\;y \leq -2.5 \cdot 10^{-51}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;y \leq 2.5 \cdot 10^{-267}:\\
\;\;\;\;t_1\\

\mathbf{elif}\;y \leq 2 \cdot 10^{-170}:\\
\;\;\;\;\frac{t}{b - y}\\

\mathbf{elif}\;y \leq 7.8:\\
\;\;\;\;t_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -2.50000000000000002e-51 or 7.79999999999999982 < y

    1. Initial program 53.3%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg54.3%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg54.3%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified54.3%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]

    if -2.50000000000000002e-51 < y < 2.5e-267 or 1.99999999999999997e-170 < y < 7.79999999999999982

    1. Initial program 79.4%

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

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

        \[\leadsto \frac{\color{blue}{-a \cdot z}}{y + z \cdot \left(b - y\right)} \]
      2. distribute-lft-neg-out36.3%

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

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

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

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

        \[\leadsto \color{blue}{\frac{-1 \cdot a}{b}} \]
      2. neg-mul-137.4%

        \[\leadsto \frac{\color{blue}{-a}}{b} \]
    7. Simplified37.4%

      \[\leadsto \color{blue}{\frac{-a}{b}} \]

    if 2.5e-267 < y < 1.99999999999999997e-170

    1. Initial program 74.2%

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

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

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

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

        \[\leadsto \frac{t}{\frac{\color{blue}{\mathsf{fma}\left(z, b - y, y\right)}}{z}} \]
    4. Simplified55.8%

      \[\leadsto \color{blue}{\frac{t}{\frac{\mathsf{fma}\left(z, b - y, y\right)}{z}}} \]
    5. Taylor expanded in z around inf 51.6%

      \[\leadsto \frac{t}{\color{blue}{b - y}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification48.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.5 \cdot 10^{-51}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq 2.5 \cdot 10^{-267}:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{elif}\;y \leq 2 \cdot 10^{-170}:\\ \;\;\;\;\frac{t}{b - y}\\ \mathbf{elif}\;y \leq 7.8:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{1 - z}\\ \end{array} \]

Alternative 14: 53.4% accurate, 1.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;y \leq -4 \cdot 10^{-49} \lor \neg \left(y \leq 9.6 \cdot 10^{+54}\right):\\
\;\;\;\;\frac{x}{1 - z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -3.99999999999999975e-49 or 9.59999999999999993e54 < y

    1. Initial program 53.1%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg57.1%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg57.1%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified57.1%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]

    if -3.99999999999999975e-49 < y < 9.59999999999999993e54

    1. Initial program 75.5%

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

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

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

Alternative 15: 35.3% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -0.75:\\ \;\;\;\;\frac{-x}{z}\\ \mathbf{elif}\;z \leq 12:\\ \;\;\;\;x + x \cdot z\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= z -0.75) (/ (- x) z) (if (<= z 12.0) (+ x (* x z)) (/ t b))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (z <= -0.75) {
		tmp = -x / z;
	} else if (z <= 12.0) {
		tmp = x + (x * z);
	} else {
		tmp = t / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: tmp
    if (z <= (-0.75d0)) then
        tmp = -x / z
    else if (z <= 12.0d0) then
        tmp = x + (x * z)
    else
        tmp = t / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (z <= -0.75) {
		tmp = -x / z;
	} else if (z <= 12.0) {
		tmp = x + (x * z);
	} else {
		tmp = t / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if z <= -0.75:
		tmp = -x / z
	elif z <= 12.0:
		tmp = x + (x * z)
	else:
		tmp = t / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (z <= -0.75)
		tmp = Float64(Float64(-x) / z);
	elseif (z <= 12.0)
		tmp = Float64(x + Float64(x * z));
	else
		tmp = Float64(t / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (z <= -0.75)
		tmp = -x / z;
	elseif (z <= 12.0)
		tmp = x + (x * z);
	else
		tmp = t / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -0.75], N[((-x) / z), $MachinePrecision], If[LessEqual[z, 12.0], N[(x + N[(x * z), $MachinePrecision]), $MachinePrecision], N[(t / b), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.75:\\
\;\;\;\;\frac{-x}{z}\\

\mathbf{elif}\;z \leq 12:\\
\;\;\;\;x + x \cdot z\\

\mathbf{else}:\\
\;\;\;\;\frac{t}{b}\\


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

    1. Initial program 36.9%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg34.5%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg34.5%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified34.5%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]
    5. Taylor expanded in z around inf 32.0%

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

        \[\leadsto \color{blue}{\frac{-1 \cdot x}{z}} \]
      2. mul-1-neg32.0%

        \[\leadsto \frac{\color{blue}{-x}}{z} \]
    7. Simplified32.0%

      \[\leadsto \color{blue}{\frac{-x}{z}} \]

    if -0.75 < z < 12

    1. Initial program 88.1%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg44.9%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg44.9%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified44.9%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]
    5. Taylor expanded in z around 0 44.9%

      \[\leadsto \color{blue}{x + x \cdot z} \]
    6. Step-by-step derivation
      1. *-commutative44.9%

        \[\leadsto x + \color{blue}{z \cdot x} \]
    7. Simplified44.9%

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

    if 12 < z

    1. Initial program 47.4%

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{t}{\frac{\mathsf{fma}\left(z, b - y, y\right)}{z}}} \]
    5. Taylor expanded in b around inf 30.6%

      \[\leadsto \frac{t}{\color{blue}{b}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification37.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -0.75:\\ \;\;\;\;\frac{-x}{z}\\ \mathbf{elif}\;z \leq 12:\\ \;\;\;\;x + x \cdot z\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \]

Alternative 16: 39.4% accurate, 1.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.75:\\
\;\;\;\;\frac{-x}{z}\\

\mathbf{elif}\;z \leq 0.35:\\
\;\;\;\;x + x \cdot z\\

\mathbf{else}:\\
\;\;\;\;\frac{t}{b - y}\\


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

    1. Initial program 36.9%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg34.5%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg34.5%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified34.5%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]
    5. Taylor expanded in z around inf 32.0%

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

        \[\leadsto \color{blue}{\frac{-1 \cdot x}{z}} \]
      2. mul-1-neg32.0%

        \[\leadsto \frac{\color{blue}{-x}}{z} \]
    7. Simplified32.0%

      \[\leadsto \color{blue}{\frac{-x}{z}} \]

    if -0.75 < z < 0.34999999999999998

    1. Initial program 88.0%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg45.2%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg45.2%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified45.2%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]
    5. Taylor expanded in z around 0 45.2%

      \[\leadsto \color{blue}{x + x \cdot z} \]
    6. Step-by-step derivation
      1. *-commutative45.2%

        \[\leadsto x + \color{blue}{z \cdot x} \]
    7. Simplified45.2%

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

    if 0.34999999999999998 < z

    1. Initial program 48.1%

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

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

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

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

        \[\leadsto \frac{t}{\frac{\color{blue}{\mathsf{fma}\left(z, b - y, y\right)}}{z}} \]
    4. Simplified31.4%

      \[\leadsto \color{blue}{\frac{t}{\frac{\mathsf{fma}\left(z, b - y, y\right)}{z}}} \]
    5. Taylor expanded in z around inf 43.9%

      \[\leadsto \frac{t}{\color{blue}{b - y}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification41.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -0.75:\\ \;\;\;\;\frac{-x}{z}\\ \mathbf{elif}\;z \leq 0.35:\\ \;\;\;\;x + x \cdot z\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b - y}\\ \end{array} \]

Alternative 17: 42.8% accurate, 1.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.5 \cdot 10^{+111}:\\
\;\;\;\;\frac{a - t}{y}\\

\mathbf{elif}\;z \leq 4 \cdot 10^{+63}:\\
\;\;\;\;\frac{x}{1 - z}\\

\mathbf{else}:\\
\;\;\;\;\frac{t}{b - y}\\


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

    1. Initial program 31.6%

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

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

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

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

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

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

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in x around 0 40.5%

      \[\leadsto \color{blue}{\frac{a}{y} - \frac{t}{y}} \]
    7. Step-by-step derivation
      1. div-sub40.6%

        \[\leadsto \color{blue}{\frac{a - t}{y}} \]
    8. Simplified40.6%

      \[\leadsto \color{blue}{\frac{a - t}{y}} \]

    if -5.4999999999999998e111 < z < 4.00000000000000023e63

    1. Initial program 78.1%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg45.8%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg45.8%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified45.8%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]

    if 4.00000000000000023e63 < z

    1. Initial program 44.8%

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

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

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

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

        \[\leadsto \frac{t}{\frac{\color{blue}{\mathsf{fma}\left(z, b - y, y\right)}}{z}} \]
    4. Simplified32.1%

      \[\leadsto \color{blue}{\frac{t}{\frac{\mathsf{fma}\left(z, b - y, y\right)}{z}}} \]
    5. Taylor expanded in z around inf 49.0%

      \[\leadsto \frac{t}{\color{blue}{b - y}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification45.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.5 \cdot 10^{+111}:\\ \;\;\;\;\frac{a - t}{y}\\ \mathbf{elif}\;z \leq 4 \cdot 10^{+63}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b - y}\\ \end{array} \]

Alternative 18: 34.7% accurate, 2.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -650 \lor \neg \left(z \leq 12\right):\\ \;\;\;\;\frac{a}{y}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (or (<= z -650.0) (not (<= z 12.0))) (/ a y) x))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((z <= -650.0) || !(z <= 12.0)) {
		tmp = a / y;
	} else {
		tmp = 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 ((z <= (-650.0d0)) .or. (.not. (z <= 12.0d0))) then
        tmp = a / y
    else
        tmp = 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 ((z <= -650.0) || !(z <= 12.0)) {
		tmp = a / y;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (z <= -650.0) or not (z <= 12.0):
		tmp = a / y
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if ((z <= -650.0) || !(z <= 12.0))
		tmp = Float64(a / y);
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if ((z <= -650.0) || ~((z <= 12.0)))
		tmp = a / y;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -650.0], N[Not[LessEqual[z, 12.0]], $MachinePrecision]], N[(a / y), $MachinePrecision], x]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -650 \lor \neg \left(z \leq 12\right):\\
\;\;\;\;\frac{a}{y}\\

\mathbf{else}:\\
\;\;\;\;x\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -650 or 12 < z

    1. Initial program 42.5%

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

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

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

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

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

        \[\leadsto \frac{\color{blue}{-x}}{z - 1} - \frac{\frac{z \cdot \left(t - a\right)}{z - 1} - -1 \cdot \frac{b \cdot \left(x \cdot z\right)}{{\left(z - 1\right)}^{2}}}{y} \]
      5. sub-neg27.6%

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in a around inf 21.9%

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

    if -650 < z < 12

    1. Initial program 87.5%

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

      \[\leadsto \color{blue}{x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification32.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -650 \lor \neg \left(z \leq 12\right):\\ \;\;\;\;\frac{a}{y}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 19: 36.2% accurate, 2.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -32:\\ \;\;\;\;\frac{a}{y}\\ \mathbf{elif}\;z \leq 12:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= z -32.0) (/ a y) (if (<= z 12.0) x (/ t b))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (z <= -32.0) {
		tmp = a / y;
	} else if (z <= 12.0) {
		tmp = x;
	} else {
		tmp = t / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: tmp
    if (z <= (-32.0d0)) then
        tmp = a / y
    else if (z <= 12.0d0) then
        tmp = x
    else
        tmp = t / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (z <= -32.0) {
		tmp = a / y;
	} else if (z <= 12.0) {
		tmp = x;
	} else {
		tmp = t / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if z <= -32.0:
		tmp = a / y
	elif z <= 12.0:
		tmp = x
	else:
		tmp = t / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (z <= -32.0)
		tmp = Float64(a / y);
	elseif (z <= 12.0)
		tmp = x;
	else
		tmp = Float64(t / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (z <= -32.0)
		tmp = a / y;
	elseif (z <= 12.0)
		tmp = x;
	else
		tmp = t / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -32.0], N[(a / y), $MachinePrecision], If[LessEqual[z, 12.0], x, N[(t / b), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -32:\\
\;\;\;\;\frac{a}{y}\\

\mathbf{elif}\;z \leq 12:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;\frac{t}{b}\\


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

    1. Initial program 36.4%

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

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

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

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

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

        \[\leadsto \frac{\color{blue}{-x}}{z - 1} - \frac{\frac{z \cdot \left(t - a\right)}{z - 1} - -1 \cdot \frac{b \cdot \left(x \cdot z\right)}{{\left(z - 1\right)}^{2}}}{y} \]
      5. sub-neg24.9%

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

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

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

      \[\leadsto \frac{-x}{z + -1} - \color{blue}{\frac{t - a}{y}} \]
    6. Taylor expanded in a around inf 26.2%

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

    if -32 < z < 12

    1. Initial program 87.5%

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

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

    if 12 < z

    1. Initial program 47.4%

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{t}{\frac{\mathsf{fma}\left(z, b - y, y\right)}{z}}} \]
    5. Taylor expanded in b around inf 30.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -32:\\ \;\;\;\;\frac{a}{y}\\ \mathbf{elif}\;z \leq 12:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \]

Alternative 20: 37.5% accurate, 2.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -6 \cdot 10^{-11}:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{elif}\;z \leq 12:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= z -6e-11) (/ (- a) b) (if (<= z 12.0) x (/ t b))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (z <= -6e-11) {
		tmp = -a / b;
	} else if (z <= 12.0) {
		tmp = x;
	} else {
		tmp = t / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: tmp
    if (z <= (-6d-11)) then
        tmp = -a / b
    else if (z <= 12.0d0) then
        tmp = x
    else
        tmp = t / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (z <= -6e-11) {
		tmp = -a / b;
	} else if (z <= 12.0) {
		tmp = x;
	} else {
		tmp = t / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if z <= -6e-11:
		tmp = -a / b
	elif z <= 12.0:
		tmp = x
	else:
		tmp = t / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (z <= -6e-11)
		tmp = Float64(Float64(-a) / b);
	elseif (z <= 12.0)
		tmp = x;
	else
		tmp = Float64(t / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (z <= -6e-11)
		tmp = -a / b;
	elseif (z <= 12.0)
		tmp = x;
	else
		tmp = t / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -6e-11], N[((-a) / b), $MachinePrecision], If[LessEqual[z, 12.0], x, N[(t / b), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -6 \cdot 10^{-11}:\\
\;\;\;\;\frac{-a}{b}\\

\mathbf{elif}\;z \leq 12:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;\frac{t}{b}\\


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

    1. Initial program 37.9%

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

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

        \[\leadsto \frac{\color{blue}{-a \cdot z}}{y + z \cdot \left(b - y\right)} \]
      2. distribute-lft-neg-out27.6%

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

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

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

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

        \[\leadsto \color{blue}{\frac{-1 \cdot a}{b}} \]
      2. neg-mul-126.5%

        \[\leadsto \frac{\color{blue}{-a}}{b} \]
    7. Simplified26.5%

      \[\leadsto \color{blue}{\frac{-a}{b}} \]

    if -6e-11 < z < 12

    1. Initial program 88.0%

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

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

    if 12 < z

    1. Initial program 47.4%

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{t}{\frac{\mathsf{fma}\left(z, b - y, y\right)}{z}}} \]
    5. Taylor expanded in b around inf 30.6%

      \[\leadsto \frac{t}{\color{blue}{b}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification36.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -6 \cdot 10^{-11}:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{elif}\;z \leq 12:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \]

Alternative 21: 35.2% accurate, 2.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1:\\ \;\;\;\;\frac{-x}{z}\\ \mathbf{elif}\;z \leq 12:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= z -1.0) (/ (- x) z) (if (<= z 12.0) x (/ t b))))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (z <= -1.0) {
		tmp = -x / z;
	} else if (z <= 12.0) {
		tmp = x;
	} else {
		tmp = t / b;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: tmp
    if (z <= (-1.0d0)) then
        tmp = -x / z
    else if (z <= 12.0d0) then
        tmp = x
    else
        tmp = t / b
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if (z <= -1.0) {
		tmp = -x / z;
	} else if (z <= 12.0) {
		tmp = x;
	} else {
		tmp = t / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if z <= -1.0:
		tmp = -x / z
	elif z <= 12.0:
		tmp = x
	else:
		tmp = t / b
	return tmp
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (z <= -1.0)
		tmp = Float64(Float64(-x) / z);
	elseif (z <= 12.0)
		tmp = x;
	else
		tmp = Float64(t / b);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	tmp = 0.0;
	if (z <= -1.0)
		tmp = -x / z;
	elseif (z <= 12.0)
		tmp = x;
	else
		tmp = t / b;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -1.0], N[((-x) / z), $MachinePrecision], If[LessEqual[z, 12.0], x, N[(t / b), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1:\\
\;\;\;\;\frac{-x}{z}\\

\mathbf{elif}\;z \leq 12:\\
\;\;\;\;x\\

\mathbf{else}:\\
\;\;\;\;\frac{t}{b}\\


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

    1. Initial program 36.9%

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

      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
    3. Step-by-step derivation
      1. mul-1-neg34.5%

        \[\leadsto \frac{x}{1 + \color{blue}{\left(-z\right)}} \]
      2. unsub-neg34.5%

        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
    4. Simplified34.5%

      \[\leadsto \color{blue}{\frac{x}{1 - z}} \]
    5. Taylor expanded in z around inf 32.0%

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

        \[\leadsto \color{blue}{\frac{-1 \cdot x}{z}} \]
      2. mul-1-neg32.0%

        \[\leadsto \frac{\color{blue}{-x}}{z} \]
    7. Simplified32.0%

      \[\leadsto \color{blue}{\frac{-x}{z}} \]

    if -1 < z < 12

    1. Initial program 88.1%

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

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

    if 12 < z

    1. Initial program 47.4%

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{t}{\frac{\mathsf{fma}\left(z, b - y, y\right)}{z}}} \]
    5. Taylor expanded in b around inf 30.6%

      \[\leadsto \frac{t}{\color{blue}{b}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification37.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1:\\ \;\;\;\;\frac{-x}{z}\\ \mathbf{elif}\;z \leq 12:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \]

Alternative 22: 25.4% accurate, 17.0× speedup?

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

\\
x
\end{array}
Derivation
  1. Initial program 63.8%

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

    \[\leadsto \color{blue}{x} \]
  3. Final simplification22.7%

    \[\leadsto x \]

Developer target: 74.1% accurate, 0.7× speedup?

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

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

Reproduce

?
herbie shell --seed 2023336 
(FPCore (x y z t a b)
  :name "Development.Shake.Progress:decay from shake-0.15.5"
  :precision binary64

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

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