Development.Shake.Progress:decay from shake-0.15.5

Percentage Accurate: 67.0% → 89.2%
Time: 18.0s
Alternatives: 17
Speedup: 1.5×

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

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

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

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -16000000000000 \lor \neg \left(z \leq 4.8 \cdot 10^{+14}\right):\\
\;\;\;\;\frac{\frac{y}{\frac{b - y}{x}} + \frac{a - t}{\frac{{\left(b - y\right)}^{2}}{y}}}{z} + \frac{t - a}{b - y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.6e13 or 4.8e14 < z

    1. Initial program 42.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 65.6%

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

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

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

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

    if -1.6e13 < z < 4.8e14

    1. Initial program 90.1%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Step-by-step derivation
      1. fma-def90.1%

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

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

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

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

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

Alternative 2: 89.3% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y + z \cdot \left(b - y\right)\\ \mathbf{if}\;z \leq -1.25 \cdot 10^{+15} \lor \neg \left(z \leq 10000000000000\right):\\ \;\;\;\;\frac{\frac{y}{\frac{b - y}{x}} + \frac{a - t}{\frac{{\left(b - y\right)}^{2}}{y}}}{z} + \frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\frac{y \cdot x}{t_1} - \frac{z \cdot \left(a - t\right)}{t_1}\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ y (* z (- b y)))))
   (if (or (<= z -1.25e+15) (not (<= z 10000000000000.0)))
     (+
      (/ (+ (/ y (/ (- b y) x)) (/ (- a t) (/ (pow (- b y) 2.0) y))) z)
      (/ (- t a) (- b y)))
     (- (/ (* y x) t_1) (/ (* z (- a t)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = y + (z * (b - y));
	double tmp;
	if ((z <= -1.25e+15) || !(z <= 10000000000000.0)) {
		tmp = (((y / ((b - y) / x)) + ((a - t) / (pow((b - y), 2.0) / y))) / z) + ((t - a) / (b - y));
	} else {
		tmp = ((y * x) / t_1) - ((z * (a - t)) / t_1);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: t_1
    real(8) :: tmp
    t_1 = y + (z * (b - y))
    if ((z <= (-1.25d+15)) .or. (.not. (z <= 10000000000000.0d0))) then
        tmp = (((y / ((b - y) / x)) + ((a - t) / (((b - y) ** 2.0d0) / y))) / z) + ((t - a) / (b - y))
    else
        tmp = ((y * x) / t_1) - ((z * (a - t)) / 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 = y + (z * (b - y));
	double tmp;
	if ((z <= -1.25e+15) || !(z <= 10000000000000.0)) {
		tmp = (((y / ((b - y) / x)) + ((a - t) / (Math.pow((b - y), 2.0) / y))) / z) + ((t - a) / (b - y));
	} else {
		tmp = ((y * x) / t_1) - ((z * (a - t)) / t_1);
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = y + (z * (b - y))
	tmp = 0
	if (z <= -1.25e+15) or not (z <= 10000000000000.0):
		tmp = (((y / ((b - y) / x)) + ((a - t) / (math.pow((b - y), 2.0) / y))) / z) + ((t - a) / (b - y))
	else:
		tmp = ((y * x) / t_1) - ((z * (a - t)) / t_1)
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(y + Float64(z * Float64(b - y)))
	tmp = 0.0
	if ((z <= -1.25e+15) || !(z <= 10000000000000.0))
		tmp = Float64(Float64(Float64(Float64(y / Float64(Float64(b - y) / x)) + Float64(Float64(a - t) / Float64((Float64(b - y) ^ 2.0) / y))) / z) + Float64(Float64(t - a) / Float64(b - y)));
	else
		tmp = Float64(Float64(Float64(y * x) / t_1) - Float64(Float64(z * Float64(a - t)) / t_1));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = y + (z * (b - y));
	tmp = 0.0;
	if ((z <= -1.25e+15) || ~((z <= 10000000000000.0)))
		tmp = (((y / ((b - y) / x)) + ((a - t) / (((b - y) ^ 2.0) / y))) / z) + ((t - a) / (b - y));
	else
		tmp = ((y * x) / t_1) - ((z * (a - t)) / t_1);
	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]}, If[Or[LessEqual[z, -1.25e+15], N[Not[LessEqual[z, 10000000000000.0]], $MachinePrecision]], N[(N[(N[(N[(y / N[(N[(b - y), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision] + N[(N[(a - t), $MachinePrecision] / N[(N[Power[N[(b - y), $MachinePrecision], 2.0], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] + N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[(y * x), $MachinePrecision] / t$95$1), $MachinePrecision] - N[(N[(z * N[(a - t), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := y + z \cdot \left(b - y\right)\\
\mathbf{if}\;z \leq -1.25 \cdot 10^{+15} \lor \neg \left(z \leq 10000000000000\right):\\
\;\;\;\;\frac{\frac{y}{\frac{b - y}{x}} + \frac{a - t}{\frac{{\left(b - y\right)}^{2}}{y}}}{z} + \frac{t - a}{b - y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.25e15 or 1e13 < z

    1. Initial program 42.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 65.6%

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

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

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

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

    if -1.25e15 < z < 1e13

    1. Initial program 90.1%

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

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

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

Alternative 3: 80.3% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y + z \cdot \left(b - y\right)\\ t_2 := x - \frac{z \cdot \left(a - t\right)}{t_1}\\ t_3 := \frac{t - a}{b - y}\\ \mathbf{if}\;z \leq -270:\\ \;\;\;\;t_3\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-298}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq 1.3 \cdot 10^{-209}:\\ \;\;\;\;\frac{y \cdot x - z \cdot a}{t_1}\\ \mathbf{elif}\;z \leq 1.55:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;t_3\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (+ y (* z (- b y))))
        (t_2 (- x (/ (* z (- a t)) t_1)))
        (t_3 (/ (- t a) (- b y))))
   (if (<= z -270.0)
     t_3
     (if (<= z 3.8e-298)
       t_2
       (if (<= z 1.3e-209)
         (/ (- (* y x) (* z a)) t_1)
         (if (<= z 1.55) t_2 t_3))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = y + (z * (b - y));
	double t_2 = x - ((z * (a - t)) / t_1);
	double t_3 = (t - a) / (b - y);
	double tmp;
	if (z <= -270.0) {
		tmp = t_3;
	} else if (z <= 3.8e-298) {
		tmp = t_2;
	} else if (z <= 1.3e-209) {
		tmp = ((y * x) - (z * a)) / t_1;
	} else if (z <= 1.55) {
		tmp = t_2;
	} else {
		tmp = t_3;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_1 = y + (z * (b - y))
    t_2 = x - ((z * (a - t)) / t_1)
    t_3 = (t - a) / (b - y)
    if (z <= (-270.0d0)) then
        tmp = t_3
    else if (z <= 3.8d-298) then
        tmp = t_2
    else if (z <= 1.3d-209) then
        tmp = ((y * x) - (z * a)) / t_1
    else if (z <= 1.55d0) then
        tmp = t_2
    else
        tmp = t_3
    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 = y + (z * (b - y));
	double t_2 = x - ((z * (a - t)) / t_1);
	double t_3 = (t - a) / (b - y);
	double tmp;
	if (z <= -270.0) {
		tmp = t_3;
	} else if (z <= 3.8e-298) {
		tmp = t_2;
	} else if (z <= 1.3e-209) {
		tmp = ((y * x) - (z * a)) / t_1;
	} else if (z <= 1.55) {
		tmp = t_2;
	} else {
		tmp = t_3;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = y + (z * (b - y))
	t_2 = x - ((z * (a - t)) / t_1)
	t_3 = (t - a) / (b - y)
	tmp = 0
	if z <= -270.0:
		tmp = t_3
	elif z <= 3.8e-298:
		tmp = t_2
	elif z <= 1.3e-209:
		tmp = ((y * x) - (z * a)) / t_1
	elif z <= 1.55:
		tmp = t_2
	else:
		tmp = t_3
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(y + Float64(z * Float64(b - y)))
	t_2 = Float64(x - Float64(Float64(z * Float64(a - t)) / t_1))
	t_3 = Float64(Float64(t - a) / Float64(b - y))
	tmp = 0.0
	if (z <= -270.0)
		tmp = t_3;
	elseif (z <= 3.8e-298)
		tmp = t_2;
	elseif (z <= 1.3e-209)
		tmp = Float64(Float64(Float64(y * x) - Float64(z * a)) / t_1);
	elseif (z <= 1.55)
		tmp = t_2;
	else
		tmp = t_3;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b)
	t_1 = y + (z * (b - y));
	t_2 = x - ((z * (a - t)) / t_1);
	t_3 = (t - a) / (b - y);
	tmp = 0.0;
	if (z <= -270.0)
		tmp = t_3;
	elseif (z <= 3.8e-298)
		tmp = t_2;
	elseif (z <= 1.3e-209)
		tmp = ((y * x) - (z * a)) / t_1;
	elseif (z <= 1.55)
		tmp = t_2;
	else
		tmp = t_3;
	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[(x - N[(N[(z * N[(a - t), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -270.0], t$95$3, If[LessEqual[z, 3.8e-298], t$95$2, If[LessEqual[z, 1.3e-209], N[(N[(N[(y * x), $MachinePrecision] - N[(z * a), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision], If[LessEqual[z, 1.55], t$95$2, t$95$3]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;z \leq 3.8 \cdot 10^{-298}:\\
\;\;\;\;t_2\\

\mathbf{elif}\;z \leq 1.3 \cdot 10^{-209}:\\
\;\;\;\;\frac{y \cdot x - z \cdot a}{t_1}\\

\mathbf{elif}\;z \leq 1.55:\\
\;\;\;\;t_2\\

\mathbf{else}:\\
\;\;\;\;t_3\\


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

    1. Initial program 45.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 72.1%

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

    if -270 < z < 3.8e-298 or 1.29999999999999992e-209 < z < 1.55000000000000004

    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 x around inf 88.2%

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

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

    if 3.8e-298 < z < 1.29999999999999992e-209

    1. Initial program 99.7%

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -270:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;z \leq 3.8 \cdot 10^{-298}:\\ \;\;\;\;x - \frac{z \cdot \left(a - t\right)}{y + z \cdot \left(b - y\right)}\\ \mathbf{elif}\;z \leq 1.3 \cdot 10^{-209}:\\ \;\;\;\;\frac{y \cdot x - z \cdot a}{y + z \cdot \left(b - y\right)}\\ \mathbf{elif}\;z \leq 1.55:\\ \;\;\;\;x - \frac{z \cdot \left(a - t\right)}{y + z \cdot \left(b - y\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{t - a}{b - y}\\ \end{array} \]

Alternative 4: 84.2% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -8.6 \cdot 10^{+86} \lor \neg \left(z \leq 1.26 \cdot 10^{+84}\right):\\
\;\;\;\;\frac{t - a}{b - y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -8.6000000000000004e86 or 1.26000000000000007e84 < z

    1. Initial program 31.4%

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

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

    if -8.6000000000000004e86 < z < 1.26000000000000007e84

    1. Initial program 87.1%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Step-by-step derivation
      1. sub-neg87.1%

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

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

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

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

Alternative 5: 84.2% accurate, 0.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.9 \cdot 10^{+86} \lor \neg \left(z \leq 4.5 \cdot 10^{+84}\right):\\
\;\;\;\;\frac{t - a}{b - y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -7.90000000000000025e86 or 4.4999999999999997e84 < z

    1. Initial program 31.4%

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

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

    if -7.90000000000000025e86 < z < 4.4999999999999997e84

    1. Initial program 87.1%

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

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

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

Alternative 6: 84.2% accurate, 0.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -9.5 \cdot 10^{+86} \lor \neg \left(z \leq 1.1 \cdot 10^{+85}\right):\\
\;\;\;\;\frac{t - a}{b - y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -9.50000000000000028e86 or 1.1000000000000001e85 < z

    1. Initial program 31.4%

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

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

    if -9.50000000000000028e86 < z < 1.1000000000000001e85

    1. Initial program 87.1%

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

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

Alternative 7: 81.5% accurate, 0.9× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -125 \lor \neg \left(z \leq 1.05\right):\\
\;\;\;\;\frac{t - a}{b - y}\\

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


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

    1. Initial program 45.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 72.1%

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

    if -125 < z < 1.05000000000000004

    1. Initial program 89.6%

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

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

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

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

Alternative 8: 39.9% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -7.5 \cdot 10^{+90}:\\
\;\;\;\;\frac{-a}{b}\\

\mathbf{elif}\;z \leq -5.3 \cdot 10^{+41}:\\
\;\;\;\;-\frac{x}{z}\\

\mathbf{elif}\;z \leq -110000000000 \lor \neg \left(z \leq 5 \cdot 10^{-87}\right):\\
\;\;\;\;\frac{t}{b - y}\\

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


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

    1. Initial program 39.7%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{a}{b}} \]
    4. Step-by-step derivation
      1. mul-1-neg34.8%

        \[\leadsto \color{blue}{-\frac{a}{b}} \]
    5. Simplified34.8%

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

    if -7.50000000000000014e90 < z < -5.2999999999999997e41

    1. Initial program 41.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 54.8%

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

        \[\leadsto \frac{x}{\color{blue}{1 + -1 \cdot z}} \]
      2. mul-1-neg54.8%

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

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

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

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

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

        \[\leadsto \frac{\color{blue}{-x}}{z} \]
    7. Simplified54.8%

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

    if -5.2999999999999997e41 < z < -1.1e11 or 5.00000000000000042e-87 < z

    1. Initial program 54.3%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Step-by-step derivation
      1. sub-neg54.3%

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

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

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

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

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

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

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

    if -1.1e11 < z < 5.00000000000000042e-87

    1. Initial program 90.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 40.7%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -7.5 \cdot 10^{+90}:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{elif}\;z \leq -5.3 \cdot 10^{+41}:\\ \;\;\;\;-\frac{x}{z}\\ \mathbf{elif}\;z \leq -110000000000 \lor \neg \left(z \leq 5 \cdot 10^{-87}\right):\\ \;\;\;\;\frac{t}{b - y}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 9: 54.6% accurate, 1.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x}{1 - z}\\ \mathbf{if}\;y \leq -1.02 \cdot 10^{+30}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq -3900000:\\ \;\;\;\;\frac{y \cdot x}{z \cdot b}\\ \mathbf{elif}\;y \leq -7.5 \cdot 10^{-14}:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq 1.2 \cdot 10^{-7}:\\ \;\;\;\;\frac{t - a}{b}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ x (- 1.0 z))))
   (if (<= y -1.02e+30)
     t_1
     (if (<= y -3900000.0)
       (/ (* y x) (* z b))
       (if (<= y -7.5e-14) x (if (<= y 1.2e-7) (/ (- t a) b) t_1))))))
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 <= -1.02e+30) {
		tmp = t_1;
	} else if (y <= -3900000.0) {
		tmp = (y * x) / (z * b);
	} else if (y <= -7.5e-14) {
		tmp = x;
	} else if (y <= 1.2e-7) {
		tmp = (t - a) / b;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: t_1
    real(8) :: tmp
    t_1 = x / (1.0d0 - z)
    if (y <= (-1.02d+30)) then
        tmp = t_1
    else if (y <= (-3900000.0d0)) then
        tmp = (y * x) / (z * b)
    else if (y <= (-7.5d-14)) then
        tmp = x
    else if (y <= 1.2d-7) then
        tmp = (t - a) / b
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x / (1.0 - z);
	double tmp;
	if (y <= -1.02e+30) {
		tmp = t_1;
	} else if (y <= -3900000.0) {
		tmp = (y * x) / (z * b);
	} else if (y <= -7.5e-14) {
		tmp = x;
	} else if (y <= 1.2e-7) {
		tmp = (t - a) / b;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x / (1.0 - z)
	tmp = 0
	if y <= -1.02e+30:
		tmp = t_1
	elif y <= -3900000.0:
		tmp = (y * x) / (z * b)
	elif y <= -7.5e-14:
		tmp = x
	elif y <= 1.2e-7:
		tmp = (t - a) / b
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x / Float64(1.0 - z))
	tmp = 0.0
	if (y <= -1.02e+30)
		tmp = t_1;
	elseif (y <= -3900000.0)
		tmp = Float64(Float64(y * x) / Float64(z * b));
	elseif (y <= -7.5e-14)
		tmp = x;
	elseif (y <= 1.2e-7)
		tmp = Float64(Float64(t - a) / b);
	else
		tmp = t_1;
	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 <= -1.02e+30)
		tmp = t_1;
	elseif (y <= -3900000.0)
		tmp = (y * x) / (z * b);
	elseif (y <= -7.5e-14)
		tmp = x;
	elseif (y <= 1.2e-7)
		tmp = (t - a) / b;
	else
		tmp = t_1;
	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, -1.02e+30], t$95$1, If[LessEqual[y, -3900000.0], N[(N[(y * x), $MachinePrecision] / N[(z * b), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -7.5e-14], x, If[LessEqual[y, 1.2e-7], N[(N[(t - a), $MachinePrecision] / b), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}

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

\mathbf{elif}\;y \leq -3900000:\\
\;\;\;\;\frac{y \cdot x}{z \cdot b}\\

\mathbf{elif}\;y \leq -7.5 \cdot 10^{-14}:\\
\;\;\;\;x\\

\mathbf{elif}\;y \leq 1.2 \cdot 10^{-7}:\\
\;\;\;\;\frac{t - a}{b}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y < -1.02e30 or 1.19999999999999989e-7 < y

    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 55.5%

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

        \[\leadsto \frac{x}{\color{blue}{1 + -1 \cdot z}} \]
      2. mul-1-neg55.5%

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

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

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

    if -1.02e30 < y < -3.9e6

    1. Initial program 99.7%

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

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

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

    if -3.9e6 < y < -7.4999999999999996e-14

    1. Initial program 100.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 100.0%

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

    if -7.4999999999999996e-14 < y < 1.19999999999999989e-7

    1. Initial program 83.4%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.02 \cdot 10^{+30}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq -3900000:\\ \;\;\;\;\frac{y \cdot x}{z \cdot b}\\ \mathbf{elif}\;y \leq -7.5 \cdot 10^{-14}:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq 1.2 \cdot 10^{-7}:\\ \;\;\;\;\frac{t - a}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{1 - z}\\ \end{array} \]

Alternative 10: 75.0% accurate, 1.3× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.7 \lor \neg \left(z \leq 3.5 \cdot 10^{-6}\right):\\
\;\;\;\;\frac{t - a}{b - y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -0.69999999999999996 or 3.49999999999999995e-6 < z

    1. Initial program 45.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 72.1%

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

    if -0.69999999999999996 < z < 3.49999999999999995e-6

    1. Initial program 89.6%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Step-by-step derivation
      1. +-commutative89.6%

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

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

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

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

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

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

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

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

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

Alternative 11: 42.8% accurate, 1.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x}{1 - z}\\ \mathbf{if}\;y \leq -5.2 \cdot 10^{+40}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq -6 \cdot 10^{-178}:\\ \;\;\;\;\frac{t}{b - y}\\ \mathbf{elif}\;y \leq 6.8 \cdot 10^{-18}:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (/ x (- 1.0 z))))
   (if (<= y -5.2e+40)
     t_1
     (if (<= y -6e-178) (/ t (- b y)) (if (<= y 6.8e-18) (/ (- a) b) t_1)))))
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 <= -5.2e+40) {
		tmp = t_1;
	} else if (y <= -6e-178) {
		tmp = t / (b - y);
	} else if (y <= 6.8e-18) {
		tmp = -a / b;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a, b)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8) :: t_1
    real(8) :: tmp
    t_1 = x / (1.0d0 - z)
    if (y <= (-5.2d+40)) then
        tmp = t_1
    else if (y <= (-6d-178)) then
        tmp = t / (b - y)
    else if (y <= 6.8d-18) then
        tmp = -a / b
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = x / (1.0 - z);
	double tmp;
	if (y <= -5.2e+40) {
		tmp = t_1;
	} else if (y <= -6e-178) {
		tmp = t / (b - y);
	} else if (y <= 6.8e-18) {
		tmp = -a / b;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	t_1 = x / (1.0 - z)
	tmp = 0
	if y <= -5.2e+40:
		tmp = t_1
	elif y <= -6e-178:
		tmp = t / (b - y)
	elif y <= 6.8e-18:
		tmp = -a / b
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b)
	t_1 = Float64(x / Float64(1.0 - z))
	tmp = 0.0
	if (y <= -5.2e+40)
		tmp = t_1;
	elseif (y <= -6e-178)
		tmp = Float64(t / Float64(b - y));
	elseif (y <= 6.8e-18)
		tmp = Float64(Float64(-a) / b);
	else
		tmp = t_1;
	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 <= -5.2e+40)
		tmp = t_1;
	elseif (y <= -6e-178)
		tmp = t / (b - y);
	elseif (y <= 6.8e-18)
		tmp = -a / b;
	else
		tmp = t_1;
	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, -5.2e+40], t$95$1, If[LessEqual[y, -6e-178], N[(t / N[(b - y), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.8e-18], N[((-a) / b), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

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

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

\mathbf{elif}\;y \leq 6.8 \cdot 10^{-18}:\\
\;\;\;\;\frac{-a}{b}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -5.2000000000000001e40 or 6.80000000000000002e-18 < y

    1. Initial program 51.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 55.6%

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

        \[\leadsto \frac{x}{\color{blue}{1 + -1 \cdot z}} \]
      2. mul-1-neg55.6%

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

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

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

    if -5.2000000000000001e40 < y < -5.9999999999999997e-178

    1. Initial program 76.4%

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

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

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

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

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

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

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

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

    if -5.9999999999999997e-178 < y < 6.80000000000000002e-18

    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 b around inf 58.8%

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

      \[\leadsto \color{blue}{-1 \cdot \frac{a}{b}} \]
    4. Step-by-step derivation
      1. mul-1-neg37.9%

        \[\leadsto \color{blue}{-\frac{a}{b}} \]
    5. Simplified37.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5.2 \cdot 10^{+40}:\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{elif}\;y \leq -6 \cdot 10^{-178}:\\ \;\;\;\;\frac{t}{b - y}\\ \mathbf{elif}\;y \leq 6.8 \cdot 10^{-18}:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{1 - z}\\ \end{array} \]

Alternative 12: 68.8% accurate, 1.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.7 \lor \neg \left(z \leq 1.35 \cdot 10^{-69}\right):\\
\;\;\;\;\frac{t - a}{b - y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -0.69999999999999996 or 1.3499999999999999e-69 < z

    1. Initial program 48.3%

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

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

    if -0.69999999999999996 < z < 1.3499999999999999e-69

    1. Initial program 90.9%

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

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

      \[\leadsto \color{blue}{\frac{t \cdot z}{y}} + x \]
    4. Step-by-step derivation
      1. *-commutative59.3%

        \[\leadsto \frac{\color{blue}{z \cdot t}}{y} + x \]
    5. Simplified59.3%

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

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

Alternative 13: 34.3% accurate, 1.7× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.2 \cdot 10^{+90}:\\
\;\;\;\;\frac{-a}{b}\\

\mathbf{elif}\;z \leq -1 \lor \neg \left(z \leq 1.8 \cdot 10^{-7}\right):\\
\;\;\;\;-\frac{x}{z}\\

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


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

    1. Initial program 39.7%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{a}{b}} \]
    4. Step-by-step derivation
      1. mul-1-neg34.8%

        \[\leadsto \color{blue}{-\frac{a}{b}} \]
    5. Simplified34.8%

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

    if -2.1999999999999999e90 < z < -1 or 1.79999999999999997e-7 < z

    1. Initial program 48.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 25.5%

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

        \[\leadsto \frac{x}{\color{blue}{1 + -1 \cdot z}} \]
      2. mul-1-neg25.5%

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

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

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

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

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

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

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

    if -1 < z < 1.79999999999999997e-7

    1. Initial program 89.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 39.1%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.2 \cdot 10^{+90}:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{elif}\;z \leq -1 \lor \neg \left(z \leq 1.8 \cdot 10^{-7}\right):\\ \;\;\;\;-\frac{x}{z}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 14: 55.1% accurate, 1.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1.65 \cdot 10^{-5} \lor \neg \left(y \leq 1.1 \cdot 10^{-6}\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 -1.65e-5) (not (<= y 1.1e-6))) (/ 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 <= -1.65e-5) || !(y <= 1.1e-6)) {
		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 <= (-1.65d-5)) .or. (.not. (y <= 1.1d-6))) 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 <= -1.65e-5) || !(y <= 1.1e-6)) {
		tmp = x / (1.0 - z);
	} else {
		tmp = (t - a) / b;
	}
	return tmp;
}
def code(x, y, z, t, a, b):
	tmp = 0
	if (y <= -1.65e-5) or not (y <= 1.1e-6):
		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 <= -1.65e-5) || !(y <= 1.1e-6))
		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 <= -1.65e-5) || ~((y <= 1.1e-6)))
		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, -1.65e-5], N[Not[LessEqual[y, 1.1e-6]], $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 -1.65 \cdot 10^{-5} \lor \neg \left(y \leq 1.1 \cdot 10^{-6}\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 < -1.6500000000000001e-5 or 1.1000000000000001e-6 < 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 53.5%

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

        \[\leadsto \frac{x}{\color{blue}{1 + -1 \cdot z}} \]
      2. mul-1-neg53.5%

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

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

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

    if -1.6500000000000001e-5 < y < 1.1000000000000001e-6

    1. Initial program 83.4%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.65 \cdot 10^{-5} \lor \neg \left(y \leq 1.1 \cdot 10^{-6}\right):\\ \;\;\;\;\frac{x}{1 - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{t - a}{b}\\ \end{array} \]

Alternative 15: 35.0% accurate, 2.1× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.52 \cdot 10^{-9}:\\
\;\;\;\;x\\

\mathbf{elif}\;y \leq 140000000:\\
\;\;\;\;\frac{-a}{b}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -1.51999999999999992e-9 or 1.4e8 < 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 z around 0 32.8%

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

    if -1.51999999999999992e-9 < y < 1.4e8

    1. Initial program 83.9%

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

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

      \[\leadsto \color{blue}{-1 \cdot \frac{a}{b}} \]
    4. Step-by-step derivation
      1. mul-1-neg31.5%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.52 \cdot 10^{-9}:\\ \;\;\;\;x\\ \mathbf{elif}\;y \leq 140000000:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 16: 36.0% accurate, 2.4× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.8 \cdot 10^{+31}:\\
\;\;\;\;\frac{t}{b}\\

\mathbf{elif}\;z \leq 5 \cdot 10^{-87}:\\
\;\;\;\;x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.8000000000000001e31 or 5.00000000000000042e-87 < z

    1. Initial program 46.4%

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

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

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

    if -3.8000000000000001e31 < z < 5.00000000000000042e-87

    1. Initial program 91.2%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3.8 \cdot 10^{+31}:\\ \;\;\;\;\frac{t}{b}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{-87}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \]

Alternative 17: 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 67.9%

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

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

    \[\leadsto x \]

Developer target: 73.4% 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 2023196 
(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)))))