Development.Shake.Progress:decay from shake-0.15.5

Percentage Accurate: 66.6% → 98.0%
Time: 10.3s
Alternatives: 20
Speedup: 1.0×

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 20 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.6% 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: 98.0% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\mathsf{fma}\left(\frac{x}{z}, y, t - a\right)}{b - y} - \frac{y}{{\left(b - y\right)}^{2}} \cdot \frac{t - a}{z}\\ t_2 := \frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\\ t_3 := \mathsf{fma}\left(b - y, z, y\right)\\ t_4 := y \cdot \frac{x}{t\_3}\\ \mathbf{if}\;t\_2 \leq -\infty:\\ \;\;\;\;\mathsf{fma}\left(t - a, \frac{z}{t\_3}, t\_4\right)\\ \mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t\_2 \leq 0:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+306}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t\_2 \leq \infty:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, t\_4\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1
         (-
          (/ (fma (/ x z) y (- t a)) (- b y))
          (* (/ y (pow (- b y) 2.0)) (/ (- t a) z))))
        (t_2 (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))))
        (t_3 (fma (- b y) z y))
        (t_4 (* y (/ x t_3))))
   (if (<= t_2 (- INFINITY))
     (fma (- t a) (/ z t_3) t_4)
     (if (<= t_2 -5e-305)
       t_2
       (if (<= t_2 0.0)
         t_1
         (if (<= t_2 5e+306)
           t_2
           (if (<= t_2 INFINITY)
             (fma (- t a) (pow (- b y) -1.0) t_4)
             t_1)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = (fma((x / z), y, (t - a)) / (b - y)) - ((y / pow((b - y), 2.0)) * ((t - a) / z));
	double t_2 = ((x * y) + (z * (t - a))) / (y + (z * (b - y)));
	double t_3 = fma((b - y), z, y);
	double t_4 = y * (x / t_3);
	double tmp;
	if (t_2 <= -((double) INFINITY)) {
		tmp = fma((t - a), (z / t_3), t_4);
	} else if (t_2 <= -5e-305) {
		tmp = t_2;
	} else if (t_2 <= 0.0) {
		tmp = t_1;
	} else if (t_2 <= 5e+306) {
		tmp = t_2;
	} else if (t_2 <= ((double) INFINITY)) {
		tmp = fma((t - a), pow((b - y), -1.0), t_4);
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(x, y, z, t, a, b)
	t_1 = Float64(Float64(fma(Float64(x / z), y, Float64(t - a)) / Float64(b - y)) - Float64(Float64(y / (Float64(b - y) ^ 2.0)) * Float64(Float64(t - a) / z)))
	t_2 = Float64(Float64(Float64(x * y) + Float64(z * Float64(t - a))) / Float64(y + Float64(z * Float64(b - y))))
	t_3 = fma(Float64(b - y), z, y)
	t_4 = Float64(y * Float64(x / t_3))
	tmp = 0.0
	if (t_2 <= Float64(-Inf))
		tmp = fma(Float64(t - a), Float64(z / t_3), t_4);
	elseif (t_2 <= -5e-305)
		tmp = t_2;
	elseif (t_2 <= 0.0)
		tmp = t_1;
	elseif (t_2 <= 5e+306)
		tmp = t_2;
	elseif (t_2 <= Inf)
		tmp = fma(Float64(t - a), (Float64(b - y) ^ -1.0), t_4);
	else
		tmp = t_1;
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(N[(x / z), $MachinePrecision] * y + N[(t - a), $MachinePrecision]), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision] - N[(N[(y / N[Power[N[(b - y), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(N[(t - a), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = 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$3 = N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]}, Block[{t$95$4 = N[(y * N[(x / t$95$3), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], N[(N[(t - a), $MachinePrecision] * N[(z / t$95$3), $MachinePrecision] + t$95$4), $MachinePrecision], If[LessEqual[t$95$2, -5e-305], t$95$2, If[LessEqual[t$95$2, 0.0], t$95$1, If[LessEqual[t$95$2, 5e+306], t$95$2, If[LessEqual[t$95$2, Infinity], N[(N[(t - a), $MachinePrecision] * N[Power[N[(b - y), $MachinePrecision], -1.0], $MachinePrecision] + t$95$4), $MachinePrecision], t$95$1]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-305}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t\_2 \leq 0:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+306}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, t\_4\right)\\

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


\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

    1. Initial program 33.2%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}} \]
      2. lift-+.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + z \cdot \left(b - y\right)} \]
      4. div-addN/A

        \[\leadsto \color{blue}{\frac{z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
      5. lift-*.f64N/A

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

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z}}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      7. associate-/l*N/A

        \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      8. lower-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(t - a, \frac{z}{y + z \cdot \left(b - y\right)}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right)} \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      10. lift-+.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      11. +-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      12. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right)} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      13. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      14. lower-fma.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      15. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{x \cdot y}}{y + z \cdot \left(b - y\right)}\right) \]
      16. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{y \cdot x}}{y + z \cdot \left(b - y\right)}\right) \]
      17. associate-/l*N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      18. lower-*.f64N/A

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

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

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

    if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -4.99999999999999985e-305 or -0.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 4.99999999999999993e306

    1. Initial program 99.6%

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

    if -4.99999999999999985e-305 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -0.0 or +inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y))))

    1. Initial program 14.9%

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

      \[\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)} \]
    4. Step-by-step derivation
      1. associate--r+N/A

        \[\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. lower--.f64N/A

        \[\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}}} \]
      3. +-commutativeN/A

        \[\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}} \]
      4. associate--l+N/A

        \[\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}} \]
      5. times-fracN/A

        \[\leadsto \left(\color{blue}{\frac{x}{z} \cdot \frac{y}{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. associate-*r/N/A

        \[\leadsto \left(\color{blue}{\frac{\frac{x}{z} \cdot y}{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}} \]
      7. div-subN/A

        \[\leadsto \left(\frac{\frac{x}{z} \cdot y}{b - y} + \color{blue}{\frac{t - a}{b - y}}\right) - \frac{y \cdot \left(t - a\right)}{z \cdot {\left(b - y\right)}^{2}} \]
      8. div-add-revN/A

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

        \[\leadsto \color{blue}{\frac{\frac{x}{z} \cdot y + \left(t - a\right)}{b - y}} - \frac{y \cdot \left(t - a\right)}{z \cdot {\left(b - y\right)}^{2}} \]
      10. lower-fma.f64N/A

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(\frac{x}{z}, y, t - a\right)}}{b - y} - \frac{y \cdot \left(t - a\right)}{z \cdot {\left(b - y\right)}^{2}} \]
      11. lower-/.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{\frac{x}{z}}, y, t - a\right)}{b - y} - \frac{y \cdot \left(t - a\right)}{z \cdot {\left(b - y\right)}^{2}} \]
      12. lower--.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(\frac{x}{z}, y, \color{blue}{t - a}\right)}{b - y} - \frac{y \cdot \left(t - a\right)}{z \cdot {\left(b - y\right)}^{2}} \]
      13. lower--.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(\frac{x}{z}, y, t - a\right)}{\color{blue}{b - y}} - \frac{y \cdot \left(t - a\right)}{z \cdot {\left(b - y\right)}^{2}} \]
      14. *-commutativeN/A

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

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

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

    1. Initial program 29.7%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}} \]
      2. lift-+.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + z \cdot \left(b - y\right)} \]
      4. div-addN/A

        \[\leadsto \color{blue}{\frac{z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
      5. lift-*.f64N/A

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

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z}}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      7. associate-/l*N/A

        \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      8. lower-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(t - a, \frac{z}{y + z \cdot \left(b - y\right)}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right)} \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      10. lift-+.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      11. +-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      12. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right)} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      13. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      14. lower-fma.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      15. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{x \cdot y}}{y + z \cdot \left(b - y\right)}\right) \]
      16. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{y \cdot x}}{y + z \cdot \left(b - y\right)}\right) \]
      17. associate-/l*N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      18. lower-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      19. lower-/.f6499.6

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{1}{b - y}}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right) \]
    6. Step-by-step derivation
      1. lower-/.f64N/A

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

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

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

    \[\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:\\ \;\;\;\;\mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \mathbf{elif}\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \leq -5 \cdot 10^{-305}:\\ \;\;\;\;\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 0:\\ \;\;\;\;\frac{\mathsf{fma}\left(\frac{x}{z}, y, t - a\right)}{b - y} - \frac{y}{{\left(b - y\right)}^{2}} \cdot \frac{t - a}{z}\\ \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 \infty:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{\mathsf{fma}\left(\frac{x}{z}, y, t - a\right)}{b - y} - \frac{y}{{\left(b - y\right)}^{2}} \cdot \frac{t - a}{z}\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 93.5% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := {\left(b - y\right)}^{-1}\\ t_2 := \frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\\ t_3 := \mathsf{fma}\left(b - y, z, y\right)\\ t_4 := y \cdot \frac{x}{t\_3}\\ \mathbf{if}\;t\_2 \leq -\infty:\\ \;\;\;\;\mathsf{fma}\left(t - a, \frac{z}{t\_3}, t\_4\right)\\ \mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t\_2 \leq 0:\\ \;\;\;\;\mathsf{fma}\left(t - a, t\_1, \frac{x}{b} \cdot \frac{y}{z}\right)\\ \mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+306}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(t - a, t\_1, t\_4\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (pow (- b y) -1.0))
        (t_2 (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))))
        (t_3 (fma (- b y) z y))
        (t_4 (* y (/ x t_3))))
   (if (<= t_2 (- INFINITY))
     (fma (- t a) (/ z t_3) t_4)
     (if (<= t_2 -5e-305)
       t_2
       (if (<= t_2 0.0)
         (fma (- t a) t_1 (* (/ x b) (/ y z)))
         (if (<= t_2 5e+306) t_2 (fma (- t a) t_1 t_4)))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = pow((b - y), -1.0);
	double t_2 = ((x * y) + (z * (t - a))) / (y + (z * (b - y)));
	double t_3 = fma((b - y), z, y);
	double t_4 = y * (x / t_3);
	double tmp;
	if (t_2 <= -((double) INFINITY)) {
		tmp = fma((t - a), (z / t_3), t_4);
	} else if (t_2 <= -5e-305) {
		tmp = t_2;
	} else if (t_2 <= 0.0) {
		tmp = fma((t - a), t_1, ((x / b) * (y / z)));
	} else if (t_2 <= 5e+306) {
		tmp = t_2;
	} else {
		tmp = fma((t - a), t_1, t_4);
	}
	return tmp;
}
function code(x, y, z, t, a, b)
	t_1 = Float64(b - y) ^ -1.0
	t_2 = Float64(Float64(Float64(x * y) + Float64(z * Float64(t - a))) / Float64(y + Float64(z * Float64(b - y))))
	t_3 = fma(Float64(b - y), z, y)
	t_4 = Float64(y * Float64(x / t_3))
	tmp = 0.0
	if (t_2 <= Float64(-Inf))
		tmp = fma(Float64(t - a), Float64(z / t_3), t_4);
	elseif (t_2 <= -5e-305)
		tmp = t_2;
	elseif (t_2 <= 0.0)
		tmp = fma(Float64(t - a), t_1, Float64(Float64(x / b) * Float64(y / z)));
	elseif (t_2 <= 5e+306)
		tmp = t_2;
	else
		tmp = fma(Float64(t - a), t_1, t_4);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[Power[N[(b - y), $MachinePrecision], -1.0], $MachinePrecision]}, Block[{t$95$2 = 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$3 = N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]}, Block[{t$95$4 = N[(y * N[(x / t$95$3), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], N[(N[(t - a), $MachinePrecision] * N[(z / t$95$3), $MachinePrecision] + t$95$4), $MachinePrecision], If[LessEqual[t$95$2, -5e-305], t$95$2, If[LessEqual[t$95$2, 0.0], N[(N[(t - a), $MachinePrecision] * t$95$1 + N[(N[(x / b), $MachinePrecision] * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 5e+306], t$95$2, N[(N[(t - a), $MachinePrecision] * t$95$1 + t$95$4), $MachinePrecision]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-305}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t\_2 \leq 0:\\
\;\;\;\;\mathsf{fma}\left(t - a, t\_1, \frac{x}{b} \cdot \frac{y}{z}\right)\\

\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+306}:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(t - a, t\_1, t\_4\right)\\


\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

    1. Initial program 33.2%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}} \]
      2. lift-+.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + z \cdot \left(b - y\right)} \]
      4. div-addN/A

        \[\leadsto \color{blue}{\frac{z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
      5. lift-*.f64N/A

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

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z}}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      7. associate-/l*N/A

        \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      8. lower-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(t - a, \frac{z}{y + z \cdot \left(b - y\right)}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right)} \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      10. lift-+.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      11. +-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      12. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right)} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      13. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      14. lower-fma.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      15. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{x \cdot y}}{y + z \cdot \left(b - y\right)}\right) \]
      16. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{y \cdot x}}{y + z \cdot \left(b - y\right)}\right) \]
      17. associate-/l*N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      18. lower-*.f64N/A

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

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

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

    if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -4.99999999999999985e-305 or -0.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 4.99999999999999993e306

    1. Initial program 99.6%

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

    if -4.99999999999999985e-305 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -0.0

    1. Initial program 33.8%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}} \]
      2. lift-+.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + z \cdot \left(b - y\right)} \]
      4. div-addN/A

        \[\leadsto \color{blue}{\frac{z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
      5. lift-*.f64N/A

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

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z}}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      7. associate-/l*N/A

        \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      8. lower-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(t - a, \frac{z}{y + z \cdot \left(b - y\right)}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right)} \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      10. lift-+.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      11. +-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      12. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right)} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      13. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      14. lower-fma.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      15. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{x \cdot y}}{y + z \cdot \left(b - y\right)}\right) \]
      16. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{y \cdot x}}{y + z \cdot \left(b - y\right)}\right) \]
      17. associate-/l*N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      18. lower-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      19. lower-/.f6433.8

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{1}{b - y}}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right) \]
    6. Step-by-step derivation
      1. lower-/.f64N/A

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{1}{b - y}}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right) \]
    8. Taylor expanded in y around 0

      \[\leadsto \mathsf{fma}\left(t - a, \frac{1}{b - y}, \color{blue}{\frac{x \cdot y}{b \cdot z}}\right) \]
    9. Step-by-step derivation
      1. times-fracN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{1}{b - y}, \color{blue}{\frac{x}{b} \cdot \frac{y}{z}}\right) \]
      2. lower-*.f64N/A

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

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

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

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

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

    1. Initial program 15.1%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}} \]
      2. lift-+.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + z \cdot \left(b - y\right)} \]
      4. div-addN/A

        \[\leadsto \color{blue}{\frac{z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
      5. lift-*.f64N/A

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

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z}}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      7. associate-/l*N/A

        \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      8. lower-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(t - a, \frac{z}{y + z \cdot \left(b - y\right)}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right)} \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      10. lift-+.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      11. +-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      12. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right)} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      13. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      14. lower-fma.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      15. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{x \cdot y}}{y + z \cdot \left(b - y\right)}\right) \]
      16. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{y \cdot x}}{y + z \cdot \left(b - y\right)}\right) \]
      17. associate-/l*N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      18. lower-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      19. lower-/.f6452.3

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{1}{b - y}}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right) \]
    6. Step-by-step derivation
      1. lower-/.f64N/A

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

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

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

    \[\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:\\ \;\;\;\;\mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \mathbf{elif}\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \leq -5 \cdot 10^{-305}:\\ \;\;\;\;\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 0:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, \frac{x}{b} \cdot \frac{y}{z}\right)\\ \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{else}:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 93.3% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := {\left(b - y\right)}^{-1}\\ t_2 := \frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\\ t_3 := \mathsf{fma}\left(t - a, t\_1, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \mathbf{if}\;t\_2 \leq -\infty:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t\_2 \leq 0:\\ \;\;\;\;\mathsf{fma}\left(t - a, t\_1, \frac{x}{b} \cdot \frac{y}{z}\right)\\ \mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+306}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;t\_3\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (let* ((t_1 (pow (- b y) -1.0))
        (t_2 (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))))
        (t_3 (fma (- t a) t_1 (* y (/ x (fma (- b y) z y))))))
   (if (<= t_2 (- INFINITY))
     t_3
     (if (<= t_2 -5e-305)
       t_2
       (if (<= t_2 0.0)
         (fma (- t a) t_1 (* (/ x b) (/ y z)))
         (if (<= t_2 5e+306) t_2 t_3))))))
double code(double x, double y, double z, double t, double a, double b) {
	double t_1 = pow((b - y), -1.0);
	double t_2 = ((x * y) + (z * (t - a))) / (y + (z * (b - y)));
	double t_3 = fma((t - a), t_1, (y * (x / fma((b - y), z, y))));
	double tmp;
	if (t_2 <= -((double) INFINITY)) {
		tmp = t_3;
	} else if (t_2 <= -5e-305) {
		tmp = t_2;
	} else if (t_2 <= 0.0) {
		tmp = fma((t - a), t_1, ((x / b) * (y / z)));
	} else if (t_2 <= 5e+306) {
		tmp = t_2;
	} else {
		tmp = t_3;
	}
	return tmp;
}
function code(x, y, z, t, a, b)
	t_1 = Float64(b - y) ^ -1.0
	t_2 = Float64(Float64(Float64(x * y) + Float64(z * Float64(t - a))) / Float64(y + Float64(z * Float64(b - y))))
	t_3 = fma(Float64(t - a), t_1, Float64(y * Float64(x / fma(Float64(b - y), z, y))))
	tmp = 0.0
	if (t_2 <= Float64(-Inf))
		tmp = t_3;
	elseif (t_2 <= -5e-305)
		tmp = t_2;
	elseif (t_2 <= 0.0)
		tmp = fma(Float64(t - a), t_1, Float64(Float64(x / b) * Float64(y / z)));
	elseif (t_2 <= 5e+306)
		tmp = t_2;
	else
		tmp = t_3;
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[Power[N[(b - y), $MachinePrecision], -1.0], $MachinePrecision]}, Block[{t$95$2 = 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$3 = N[(N[(t - a), $MachinePrecision] * t$95$1 + N[(y * N[(x / N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], t$95$3, If[LessEqual[t$95$2, -5e-305], t$95$2, If[LessEqual[t$95$2, 0.0], N[(N[(t - a), $MachinePrecision] * t$95$1 + N[(N[(x / b), $MachinePrecision] * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 5e+306], t$95$2, t$95$3]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := {\left(b - y\right)}^{-1}\\
t_2 := \frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\\
t_3 := \mathsf{fma}\left(t - a, t\_1, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\
\mathbf{if}\;t\_2 \leq -\infty:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;t\_2 \leq -5 \cdot 10^{-305}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t\_2 \leq 0:\\
\;\;\;\;\mathsf{fma}\left(t - a, t\_1, \frac{x}{b} \cdot \frac{y}{z}\right)\\

\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+306}:\\
\;\;\;\;t\_2\\

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


\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 4.99999999999999993e306 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y))))

    1. Initial program 20.5%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}} \]
      2. lift-+.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + z \cdot \left(b - y\right)} \]
      4. div-addN/A

        \[\leadsto \color{blue}{\frac{z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
      5. lift-*.f64N/A

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

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z}}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      7. associate-/l*N/A

        \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      8. lower-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(t - a, \frac{z}{y + z \cdot \left(b - y\right)}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right)} \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      10. lift-+.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      11. +-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      12. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right)} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      13. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      14. lower-fma.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      15. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{x \cdot y}}{y + z \cdot \left(b - y\right)}\right) \]
      16. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{y \cdot x}}{y + z \cdot \left(b - y\right)}\right) \]
      17. associate-/l*N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      18. lower-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      19. lower-/.f6463.9

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{1}{b - y}}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right) \]
    6. Step-by-step derivation
      1. lower-/.f64N/A

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

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

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

    if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -4.99999999999999985e-305 or -0.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 4.99999999999999993e306

    1. Initial program 99.6%

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

    if -4.99999999999999985e-305 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -0.0

    1. Initial program 33.8%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}} \]
      2. lift-+.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + z \cdot \left(b - y\right)} \]
      4. div-addN/A

        \[\leadsto \color{blue}{\frac{z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
      5. lift-*.f64N/A

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

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z}}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      7. associate-/l*N/A

        \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      8. lower-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(t - a, \frac{z}{y + z \cdot \left(b - y\right)}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right)} \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      10. lift-+.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      11. +-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      12. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right)} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      13. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      14. lower-fma.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      15. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{x \cdot y}}{y + z \cdot \left(b - y\right)}\right) \]
      16. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{y \cdot x}}{y + z \cdot \left(b - y\right)}\right) \]
      17. associate-/l*N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      18. lower-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      19. lower-/.f6433.8

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{1}{b - y}}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right) \]
    6. Step-by-step derivation
      1. lower-/.f64N/A

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{1}{b - y}}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right) \]
    8. Taylor expanded in y around 0

      \[\leadsto \mathsf{fma}\left(t - a, \frac{1}{b - y}, \color{blue}{\frac{x \cdot y}{b \cdot z}}\right) \]
    9. Step-by-step derivation
      1. times-fracN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{1}{b - y}, \color{blue}{\frac{x}{b} \cdot \frac{y}{z}}\right) \]
      2. lower-*.f64N/A

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

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \frac{1}{b - y}, \color{blue}{\frac{x}{b} \cdot \frac{y}{z}}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification93.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:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \mathbf{elif}\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \leq -5 \cdot 10^{-305}:\\ \;\;\;\;\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 0:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, \frac{x}{b} \cdot \frac{y}{z}\right)\\ \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{else}:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 94.2% accurate, 0.1× 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 := \mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \mathbf{if}\;t\_1 \leq -\infty:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t\_1 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_1 \leq 0:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;t\_1 \leq 5 \cdot 10^{+306}:\\ \;\;\;\;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 (fma (- t a) (pow (- b y) -1.0) (* y (/ x (fma (- b y) z y))))))
   (if (<= t_1 (- INFINITY))
     t_2
     (if (<= t_1 -5e-305)
       t_1
       (if (<= t_1 0.0) (/ (- t a) (- b y)) (if (<= t_1 5e+306) 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 = fma((t - a), pow((b - y), -1.0), (y * (x / fma((b - y), z, y))));
	double tmp;
	if (t_1 <= -((double) INFINITY)) {
		tmp = t_2;
	} else if (t_1 <= -5e-305) {
		tmp = t_1;
	} else if (t_1 <= 0.0) {
		tmp = (t - a) / (b - y);
	} else if (t_1 <= 5e+306) {
		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 = fma(Float64(t - a), (Float64(b - y) ^ -1.0), Float64(y * Float64(x / fma(Float64(b - y), z, y))))
	tmp = 0.0
	if (t_1 <= Float64(-Inf))
		tmp = t_2;
	elseif (t_1 <= -5e-305)
		tmp = t_1;
	elseif (t_1 <= 0.0)
		tmp = Float64(Float64(t - a) / Float64(b - y));
	elseif (t_1 <= 5e+306)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return 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[(t - a), $MachinePrecision] * N[Power[N[(b - y), $MachinePrecision], -1.0], $MachinePrecision] + N[(y * N[(x / N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], t$95$2, If[LessEqual[t$95$1, -5e-305], t$95$1, If[LessEqual[t$95$1, 0.0], N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 5e+306], 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 := \mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t\_1 \leq -5 \cdot 10^{-305}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t\_1 \leq 0:\\
\;\;\;\;\frac{t - a}{b - y}\\

\mathbf{elif}\;t\_1 \leq 5 \cdot 10^{+306}:\\
\;\;\;\;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 4.99999999999999993e306 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y))))

    1. Initial program 20.5%

      \[\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. lift-/.f64N/A

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}} \]
      2. lift-+.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + z \cdot \left(b - y\right)} \]
      4. div-addN/A

        \[\leadsto \color{blue}{\frac{z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
      5. lift-*.f64N/A

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

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z}}{y + z \cdot \left(b - y\right)} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      7. associate-/l*N/A

        \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} + \frac{x \cdot y}{y + z \cdot \left(b - y\right)} \]
      8. lower-fma.f64N/A

        \[\leadsto \color{blue}{\mathsf{fma}\left(t - a, \frac{z}{y + z \cdot \left(b - y\right)}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right)} \]
      9. lower-/.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      10. lift-+.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{y + z \cdot \left(b - y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      11. +-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      12. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{z \cdot \left(b - y\right)} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      13. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      14. lower-fma.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}}, \frac{x \cdot y}{y + z \cdot \left(b - y\right)}\right) \]
      15. lift-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{x \cdot y}}{y + z \cdot \left(b - y\right)}\right) \]
      16. *-commutativeN/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \frac{\color{blue}{y \cdot x}}{y + z \cdot \left(b - y\right)}\right) \]
      17. associate-/l*N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      18. lower-*.f64N/A

        \[\leadsto \mathsf{fma}\left(t - a, \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}, \color{blue}{y \cdot \frac{x}{y + z \cdot \left(b - y\right)}}\right) \]
      19. lower-/.f6463.9

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

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

      \[\leadsto \mathsf{fma}\left(t - a, \color{blue}{\frac{1}{b - y}}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right) \]
    6. Step-by-step derivation
      1. lower-/.f64N/A

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

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

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

    if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -4.99999999999999985e-305 or -0.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 4.99999999999999993e306

    1. Initial program 99.6%

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

    if -4.99999999999999985e-305 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -0.0

    1. Initial program 33.8%

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

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
    4. Step-by-step derivation
      1. lower-/.f64N/A

        \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
      2. lower--.f64N/A

        \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
      3. lower--.f6478.9

        \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
    5. Applied rewrites78.9%

      \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification93.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:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \mathbf{elif}\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)} \leq -5 \cdot 10^{-305}:\\ \;\;\;\;\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 0:\\ \;\;\;\;\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 5 \cdot 10^{+306}:\\ \;\;\;\;\frac{x \cdot y + z \cdot \left(t - a\right)}{y + z \cdot \left(b - y\right)}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(t - a, {\left(b - y\right)}^{-1}, y \cdot \frac{x}{\mathsf{fma}\left(b - y, z, y\right)}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 83.8% 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{\mathsf{fma}\left(z, \frac{t - a}{y}, x\right)}{1 - z}\\ \mathbf{if}\;t\_1 \leq -\infty:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;t\_1 \leq -5 \cdot 10^{-305}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_1 \leq 0:\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{elif}\;t\_1 \leq 5 \cdot 10^{+306}:\\ \;\;\;\;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 (/ (fma z (/ (- t a) y) x) (- 1.0 z))))
   (if (<= t_1 (- INFINITY))
     t_2
     (if (<= t_1 -5e-305)
       t_1
       (if (<= t_1 0.0) (/ (- t a) (- b y)) (if (<= t_1 5e+306) 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 = fma(z, ((t - a) / y), x) / (1.0 - z);
	double tmp;
	if (t_1 <= -((double) INFINITY)) {
		tmp = t_2;
	} else if (t_1 <= -5e-305) {
		tmp = t_1;
	} else if (t_1 <= 0.0) {
		tmp = (t - a) / (b - y);
	} else if (t_1 <= 5e+306) {
		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(fma(z, Float64(Float64(t - a) / y), x) / Float64(1.0 - z))
	tmp = 0.0
	if (t_1 <= Float64(-Inf))
		tmp = t_2;
	elseif (t_1 <= -5e-305)
		tmp = t_1;
	elseif (t_1 <= 0.0)
		tmp = Float64(Float64(t - a) / Float64(b - y));
	elseif (t_1 <= 5e+306)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return 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[(z * N[(N[(t - a), $MachinePrecision] / y), $MachinePrecision] + x), $MachinePrecision] / N[(1.0 - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], t$95$2, If[LessEqual[t$95$1, -5e-305], t$95$1, If[LessEqual[t$95$1, 0.0], N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 5e+306], 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{\mathsf{fma}\left(z, \frac{t - a}{y}, x\right)}{1 - z}\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;t\_1 \leq -5 \cdot 10^{-305}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t\_1 \leq 0:\\
\;\;\;\;\frac{t - a}{b - y}\\

\mathbf{elif}\;t\_1 \leq 5 \cdot 10^{+306}:\\
\;\;\;\;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 4.99999999999999993e306 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y))))

    1. Initial program 20.5%

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

      \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + -1 \cdot \left(y \cdot z\right)}} \]
    4. Step-by-step derivation
      1. lower-/.f64N/A

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

        \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + -1 \cdot \left(y \cdot z\right)} \]
      3. *-commutativeN/A

        \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z} + x \cdot y}{y + -1 \cdot \left(y \cdot z\right)} \]
      4. lower-fma.f64N/A

        \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(t - a, z, x \cdot y\right)}}{y + -1 \cdot \left(y \cdot z\right)} \]
      5. lower--.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{t - a}, z, x \cdot y\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
      6. *-commutativeN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
      7. lower-*.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
      8. *-rgt-identityN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot 1} + -1 \cdot \left(y \cdot z\right)} \]
      9. mul-1-negN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{\left(\mathsf{neg}\left(y \cdot z\right)\right)}} \]
      10. distribute-rgt-neg-inN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{y \cdot \left(\mathsf{neg}\left(z\right)\right)}} \]
      11. mul-1-negN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + y \cdot \color{blue}{\left(-1 \cdot z\right)}} \]
      12. distribute-lft-inN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot \left(1 + -1 \cdot z\right)}} \]
      13. *-commutativeN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
      14. lower-*.f64N/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
      15. fp-cancel-sign-sub-invN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z\right)} \cdot y} \]
      16. metadata-evalN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{1} \cdot z\right) \cdot y} \]
      17. *-lft-identityN/A

        \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{z}\right) \cdot y} \]
      18. lower--.f6417.9

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

      \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - z\right) \cdot y}} \]
    6. Taylor expanded in x around 0

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

        \[\leadsto \frac{\mathsf{fma}\left(z, \frac{t - a}{y}, x\right)}{\color{blue}{1 - z}} \]

      if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -4.99999999999999985e-305 or -0.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 4.99999999999999993e306

      1. Initial program 99.6%

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

      if -4.99999999999999985e-305 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -0.0

      1. Initial program 33.8%

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

        \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
      4. Step-by-step derivation
        1. lower-/.f64N/A

          \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
        2. lower--.f64N/A

          \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
        3. lower--.f6478.9

          \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
      5. Applied rewrites78.9%

        \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
    8. Recombined 3 regimes into one program.
    9. Add Preprocessing

    Alternative 6: 72.1% accurate, 0.7× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(b - y, z, y\right)\\ t_2 := \frac{\mathsf{fma}\left(z, \frac{t - a}{y}, x\right)}{1 - z}\\ \mathbf{if}\;y \leq -2.1 \cdot 10^{+83}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y \leq 2 \cdot 10^{-139}:\\ \;\;\;\;\left(t - a\right) \cdot \frac{z}{t\_1}\\ \mathbf{elif}\;y \leq 4.2 \cdot 10^{-60}:\\ \;\;\;\;\frac{\mathsf{fma}\left(t, z, y \cdot x\right)}{t\_1}\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
    (FPCore (x y z t a b)
     :precision binary64
     (let* ((t_1 (fma (- b y) z y)) (t_2 (/ (fma z (/ (- t a) y) x) (- 1.0 z))))
       (if (<= y -2.1e+83)
         t_2
         (if (<= y 2e-139)
           (* (- t a) (/ z t_1))
           (if (<= y 4.2e-60) (/ (fma t z (* y x)) t_1) t_2)))))
    double code(double x, double y, double z, double t, double a, double b) {
    	double t_1 = fma((b - y), z, y);
    	double t_2 = fma(z, ((t - a) / y), x) / (1.0 - z);
    	double tmp;
    	if (y <= -2.1e+83) {
    		tmp = t_2;
    	} else if (y <= 2e-139) {
    		tmp = (t - a) * (z / t_1);
    	} else if (y <= 4.2e-60) {
    		tmp = fma(t, z, (y * x)) / t_1;
    	} else {
    		tmp = t_2;
    	}
    	return tmp;
    }
    
    function code(x, y, z, t, a, b)
    	t_1 = fma(Float64(b - y), z, y)
    	t_2 = Float64(fma(z, Float64(Float64(t - a) / y), x) / Float64(1.0 - z))
    	tmp = 0.0
    	if (y <= -2.1e+83)
    		tmp = t_2;
    	elseif (y <= 2e-139)
    		tmp = Float64(Float64(t - a) * Float64(z / t_1));
    	elseif (y <= 4.2e-60)
    		tmp = Float64(fma(t, z, Float64(y * x)) / t_1);
    	else
    		tmp = t_2;
    	end
    	return tmp
    end
    
    code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]}, Block[{t$95$2 = N[(N[(z * N[(N[(t - a), $MachinePrecision] / y), $MachinePrecision] + x), $MachinePrecision] / N[(1.0 - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.1e+83], t$95$2, If[LessEqual[y, 2e-139], N[(N[(t - a), $MachinePrecision] * N[(z / t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.2e-60], N[(N[(t * z + N[(y * x), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision], t$95$2]]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \mathsf{fma}\left(b - y, z, y\right)\\
    t_2 := \frac{\mathsf{fma}\left(z, \frac{t - a}{y}, x\right)}{1 - z}\\
    \mathbf{if}\;y \leq -2.1 \cdot 10^{+83}:\\
    \;\;\;\;t\_2\\
    
    \mathbf{elif}\;y \leq 2 \cdot 10^{-139}:\\
    \;\;\;\;\left(t - a\right) \cdot \frac{z}{t\_1}\\
    
    \mathbf{elif}\;y \leq 4.2 \cdot 10^{-60}:\\
    \;\;\;\;\frac{\mathsf{fma}\left(t, z, y \cdot x\right)}{t\_1}\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_2\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 3 regimes
    2. if y < -2.10000000000000002e83 or 4.19999999999999982e-60 < y

      1. Initial program 50.6%

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

        \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + -1 \cdot \left(y \cdot z\right)}} \]
      4. Step-by-step derivation
        1. lower-/.f64N/A

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

          \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + -1 \cdot \left(y \cdot z\right)} \]
        3. *-commutativeN/A

          \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z} + x \cdot y}{y + -1 \cdot \left(y \cdot z\right)} \]
        4. lower-fma.f64N/A

          \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(t - a, z, x \cdot y\right)}}{y + -1 \cdot \left(y \cdot z\right)} \]
        5. lower--.f64N/A

          \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{t - a}, z, x \cdot y\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
        6. *-commutativeN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
        7. lower-*.f64N/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
        8. *-rgt-identityN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot 1} + -1 \cdot \left(y \cdot z\right)} \]
        9. mul-1-negN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{\left(\mathsf{neg}\left(y \cdot z\right)\right)}} \]
        10. distribute-rgt-neg-inN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{y \cdot \left(\mathsf{neg}\left(z\right)\right)}} \]
        11. mul-1-negN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + y \cdot \color{blue}{\left(-1 \cdot z\right)}} \]
        12. distribute-lft-inN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot \left(1 + -1 \cdot z\right)}} \]
        13. *-commutativeN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
        14. lower-*.f64N/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
        15. fp-cancel-sign-sub-invN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z\right)} \cdot y} \]
        16. metadata-evalN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{1} \cdot z\right) \cdot y} \]
        17. *-lft-identityN/A

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{z}\right) \cdot y} \]
        18. lower--.f6446.6

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

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - z\right) \cdot y}} \]
      6. Taylor expanded in x around 0

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

          \[\leadsto \frac{\mathsf{fma}\left(z, \frac{t - a}{y}, x\right)}{\color{blue}{1 - z}} \]

        if -2.10000000000000002e83 < y < 2.00000000000000006e-139

        1. Initial program 82.7%

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

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

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

            \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
          3. lower-*.f64N/A

            \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
          4. lower--.f64N/A

            \[\leadsto \color{blue}{\left(t - a\right)} \cdot \frac{z}{y + z \cdot \left(b - y\right)} \]
          5. lower-/.f64N/A

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

            \[\leadsto \left(t - a\right) \cdot \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}} \]
          7. *-commutativeN/A

            \[\leadsto \left(t - a\right) \cdot \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y} \]
          8. lower-fma.f64N/A

            \[\leadsto \left(t - a\right) \cdot \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \]
          9. lower--.f6472.6

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

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

        if 2.00000000000000006e-139 < y < 4.19999999999999982e-60

        1. Initial program 97.2%

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

          \[\leadsto \color{blue}{\frac{t \cdot z + x \cdot y}{y + z \cdot \left(b - y\right)}} \]
        4. Step-by-step derivation
          1. lower-/.f64N/A

            \[\leadsto \color{blue}{\frac{t \cdot z + x \cdot y}{y + z \cdot \left(b - y\right)}} \]
          2. lower-fma.f64N/A

            \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(t, z, x \cdot y\right)}}{y + z \cdot \left(b - y\right)} \]
          3. *-commutativeN/A

            \[\leadsto \frac{\mathsf{fma}\left(t, z, \color{blue}{y \cdot x}\right)}{y + z \cdot \left(b - y\right)} \]
          4. lower-*.f64N/A

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

            \[\leadsto \frac{\mathsf{fma}\left(t, z, y \cdot x\right)}{\color{blue}{z \cdot \left(b - y\right) + y}} \]
          6. *-commutativeN/A

            \[\leadsto \frac{\mathsf{fma}\left(t, z, y \cdot x\right)}{\color{blue}{\left(b - y\right) \cdot z} + y} \]
          7. lower-fma.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(t, z, y \cdot x\right)}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \]
          8. lower--.f6483.0

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

          \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, z, y \cdot x\right)}{\mathsf{fma}\left(b - y, z, y\right)}} \]
      8. Recombined 3 regimes into one program.
      9. Add Preprocessing

      Alternative 7: 68.5% accurate, 0.8× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t - a}{b - y}\\ \mathbf{if}\;z \leq -1.7 \cdot 10^{-92}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -2.4 \cdot 10^{-241}:\\ \;\;\;\;\frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - z\right) \cdot y}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{-40}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
      (FPCore (x y z t a b)
       :precision binary64
       (let* ((t_1 (/ (- t a) (- b y))))
         (if (<= z -1.7e-92)
           t_1
           (if (<= z -2.4e-241)
             (/ (fma (- t a) z (* y x)) (* (- 1.0 z) y))
             (if (<= z 5e-40) (* (/ y (fma (- b y) z y)) x) t_1)))))
      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 <= -1.7e-92) {
      		tmp = t_1;
      	} else if (z <= -2.4e-241) {
      		tmp = fma((t - a), z, (y * x)) / ((1.0 - z) * y);
      	} else if (z <= 5e-40) {
      		tmp = (y / fma((b - y), z, y)) * x;
      	} else {
      		tmp = t_1;
      	}
      	return tmp;
      }
      
      function code(x, y, z, t, a, b)
      	t_1 = Float64(Float64(t - a) / Float64(b - y))
      	tmp = 0.0
      	if (z <= -1.7e-92)
      		tmp = t_1;
      	elseif (z <= -2.4e-241)
      		tmp = Float64(fma(Float64(t - a), z, Float64(y * x)) / Float64(Float64(1.0 - z) * y));
      	elseif (z <= 5e-40)
      		tmp = Float64(Float64(y / fma(Float64(b - y), z, y)) * x);
      	else
      		tmp = t_1;
      	end
      	return 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, -1.7e-92], t$95$1, If[LessEqual[z, -2.4e-241], N[(N[(N[(t - a), $MachinePrecision] * z + N[(y * x), $MachinePrecision]), $MachinePrecision] / N[(N[(1.0 - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5e-40], N[(N[(y / N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision], t$95$1]]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      t_1 := \frac{t - a}{b - y}\\
      \mathbf{if}\;z \leq -1.7 \cdot 10^{-92}:\\
      \;\;\;\;t\_1\\
      
      \mathbf{elif}\;z \leq -2.4 \cdot 10^{-241}:\\
      \;\;\;\;\frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - z\right) \cdot y}\\
      
      \mathbf{elif}\;z \leq 5 \cdot 10^{-40}:\\
      \;\;\;\;\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x\\
      
      \mathbf{else}:\\
      \;\;\;\;t\_1\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if z < -1.7000000000000001e-92 or 4.99999999999999965e-40 < z

        1. Initial program 57.7%

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

          \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
        4. Step-by-step derivation
          1. lower-/.f64N/A

            \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
          2. lower--.f64N/A

            \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
          3. lower--.f6475.1

            \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
        5. Applied rewrites75.1%

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

        if -1.7000000000000001e-92 < z < -2.4e-241

        1. Initial program 94.2%

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

          \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + -1 \cdot \left(y \cdot z\right)}} \]
        4. Step-by-step derivation
          1. lower-/.f64N/A

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

            \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + -1 \cdot \left(y \cdot z\right)} \]
          3. *-commutativeN/A

            \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z} + x \cdot y}{y + -1 \cdot \left(y \cdot z\right)} \]
          4. lower-fma.f64N/A

            \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(t - a, z, x \cdot y\right)}}{y + -1 \cdot \left(y \cdot z\right)} \]
          5. lower--.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{t - a}, z, x \cdot y\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
          6. *-commutativeN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
          7. lower-*.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
          8. *-rgt-identityN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot 1} + -1 \cdot \left(y \cdot z\right)} \]
          9. mul-1-negN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{\left(\mathsf{neg}\left(y \cdot z\right)\right)}} \]
          10. distribute-rgt-neg-inN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{y \cdot \left(\mathsf{neg}\left(z\right)\right)}} \]
          11. mul-1-negN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + y \cdot \color{blue}{\left(-1 \cdot z\right)}} \]
          12. distribute-lft-inN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot \left(1 + -1 \cdot z\right)}} \]
          13. *-commutativeN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
          14. lower-*.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
          15. fp-cancel-sign-sub-invN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z\right)} \cdot y} \]
          16. metadata-evalN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{1} \cdot z\right) \cdot y} \]
          17. *-lft-identityN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{z}\right) \cdot y} \]
          18. lower--.f6480.0

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

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

        if -2.4e-241 < z < 4.99999999999999965e-40

        1. Initial program 79.8%

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

          \[\leadsto \color{blue}{\frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
        4. Step-by-step derivation
          1. *-commutativeN/A

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

            \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
          3. lower-*.f64N/A

            \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
          4. lower-/.f64N/A

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

            \[\leadsto \frac{y}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot x \]
          6. *-commutativeN/A

            \[\leadsto \frac{y}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot x \]
          7. lower-fma.f64N/A

            \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot x \]
          8. lower--.f6475.9

            \[\leadsto \frac{y}{\mathsf{fma}\left(\color{blue}{b - y}, z, y\right)} \cdot x \]
        5. Applied rewrites75.9%

          \[\leadsto \color{blue}{\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x} \]
      3. Recombined 3 regimes into one program.
      4. Add Preprocessing

      Alternative 8: 68.5% accurate, 0.9× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t - a}{b - y}\\ \mathbf{if}\;z \leq -1.7 \cdot 10^{-92}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -2.4 \cdot 10^{-241}:\\ \;\;\;\;\frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{1 \cdot y}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{-40}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
      (FPCore (x y z t a b)
       :precision binary64
       (let* ((t_1 (/ (- t a) (- b y))))
         (if (<= z -1.7e-92)
           t_1
           (if (<= z -2.4e-241)
             (/ (fma (- t a) z (* y x)) (* 1.0 y))
             (if (<= z 5e-40) (* (/ y (fma (- b y) z y)) x) t_1)))))
      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 <= -1.7e-92) {
      		tmp = t_1;
      	} else if (z <= -2.4e-241) {
      		tmp = fma((t - a), z, (y * x)) / (1.0 * y);
      	} else if (z <= 5e-40) {
      		tmp = (y / fma((b - y), z, y)) * x;
      	} else {
      		tmp = t_1;
      	}
      	return tmp;
      }
      
      function code(x, y, z, t, a, b)
      	t_1 = Float64(Float64(t - a) / Float64(b - y))
      	tmp = 0.0
      	if (z <= -1.7e-92)
      		tmp = t_1;
      	elseif (z <= -2.4e-241)
      		tmp = Float64(fma(Float64(t - a), z, Float64(y * x)) / Float64(1.0 * y));
      	elseif (z <= 5e-40)
      		tmp = Float64(Float64(y / fma(Float64(b - y), z, y)) * x);
      	else
      		tmp = t_1;
      	end
      	return 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, -1.7e-92], t$95$1, If[LessEqual[z, -2.4e-241], N[(N[(N[(t - a), $MachinePrecision] * z + N[(y * x), $MachinePrecision]), $MachinePrecision] / N[(1.0 * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5e-40], N[(N[(y / N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision], t$95$1]]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      t_1 := \frac{t - a}{b - y}\\
      \mathbf{if}\;z \leq -1.7 \cdot 10^{-92}:\\
      \;\;\;\;t\_1\\
      
      \mathbf{elif}\;z \leq -2.4 \cdot 10^{-241}:\\
      \;\;\;\;\frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{1 \cdot y}\\
      
      \mathbf{elif}\;z \leq 5 \cdot 10^{-40}:\\
      \;\;\;\;\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x\\
      
      \mathbf{else}:\\
      \;\;\;\;t\_1\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if z < -1.7000000000000001e-92 or 4.99999999999999965e-40 < z

        1. Initial program 57.7%

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

          \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
        4. Step-by-step derivation
          1. lower-/.f64N/A

            \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
          2. lower--.f64N/A

            \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
          3. lower--.f6475.1

            \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
        5. Applied rewrites75.1%

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

        if -1.7000000000000001e-92 < z < -2.4e-241

        1. Initial program 94.2%

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

          \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + -1 \cdot \left(y \cdot z\right)}} \]
        4. Step-by-step derivation
          1. lower-/.f64N/A

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

            \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + -1 \cdot \left(y \cdot z\right)} \]
          3. *-commutativeN/A

            \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z} + x \cdot y}{y + -1 \cdot \left(y \cdot z\right)} \]
          4. lower-fma.f64N/A

            \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(t - a, z, x \cdot y\right)}}{y + -1 \cdot \left(y \cdot z\right)} \]
          5. lower--.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{t - a}, z, x \cdot y\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
          6. *-commutativeN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
          7. lower-*.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
          8. *-rgt-identityN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot 1} + -1 \cdot \left(y \cdot z\right)} \]
          9. mul-1-negN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{\left(\mathsf{neg}\left(y \cdot z\right)\right)}} \]
          10. distribute-rgt-neg-inN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{y \cdot \left(\mathsf{neg}\left(z\right)\right)}} \]
          11. mul-1-negN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + y \cdot \color{blue}{\left(-1 \cdot z\right)}} \]
          12. distribute-lft-inN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot \left(1 + -1 \cdot z\right)}} \]
          13. *-commutativeN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
          14. lower-*.f64N/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
          15. fp-cancel-sign-sub-invN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z\right)} \cdot y} \]
          16. metadata-evalN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{1} \cdot z\right) \cdot y} \]
          17. *-lft-identityN/A

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{z}\right) \cdot y} \]
          18. lower--.f6480.0

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

          \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - z\right) \cdot y}} \]
        6. Taylor expanded in z around 0

          \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{1 \cdot y} \]
        7. Step-by-step derivation
          1. Applied rewrites80.0%

            \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{1 \cdot y} \]

          if -2.4e-241 < z < 4.99999999999999965e-40

          1. Initial program 79.8%

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

            \[\leadsto \color{blue}{\frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
          4. Step-by-step derivation
            1. *-commutativeN/A

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

              \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
            3. lower-*.f64N/A

              \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
            4. lower-/.f64N/A

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

              \[\leadsto \frac{y}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot x \]
            6. *-commutativeN/A

              \[\leadsto \frac{y}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot x \]
            7. lower-fma.f64N/A

              \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot x \]
            8. lower--.f6475.9

              \[\leadsto \frac{y}{\mathsf{fma}\left(\color{blue}{b - y}, z, y\right)} \cdot x \]
          5. Applied rewrites75.9%

            \[\leadsto \color{blue}{\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x} \]
        8. Recombined 3 regimes into one program.
        9. Add Preprocessing

        Alternative 9: 68.2% accurate, 0.9× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(b - y, z, y\right)\\ t_2 := \frac{t - a}{b - y}\\ \mathbf{if}\;z \leq -5.2 \cdot 10^{+29}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;z \leq -1.12 \cdot 10^{-204}:\\ \;\;\;\;\left(t - a\right) \cdot \frac{z}{t\_1}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{-40}:\\ \;\;\;\;\frac{y}{t\_1} \cdot x\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
        (FPCore (x y z t a b)
         :precision binary64
         (let* ((t_1 (fma (- b y) z y)) (t_2 (/ (- t a) (- b y))))
           (if (<= z -5.2e+29)
             t_2
             (if (<= z -1.12e-204)
               (* (- t a) (/ z t_1))
               (if (<= z 5e-40) (* (/ y t_1) x) t_2)))))
        double code(double x, double y, double z, double t, double a, double b) {
        	double t_1 = fma((b - y), z, y);
        	double t_2 = (t - a) / (b - y);
        	double tmp;
        	if (z <= -5.2e+29) {
        		tmp = t_2;
        	} else if (z <= -1.12e-204) {
        		tmp = (t - a) * (z / t_1);
        	} else if (z <= 5e-40) {
        		tmp = (y / t_1) * x;
        	} else {
        		tmp = t_2;
        	}
        	return tmp;
        }
        
        function code(x, y, z, t, a, b)
        	t_1 = fma(Float64(b - y), z, y)
        	t_2 = Float64(Float64(t - a) / Float64(b - y))
        	tmp = 0.0
        	if (z <= -5.2e+29)
        		tmp = t_2;
        	elseif (z <= -1.12e-204)
        		tmp = Float64(Float64(t - a) * Float64(z / t_1));
        	elseif (z <= 5e-40)
        		tmp = Float64(Float64(y / t_1) * x);
        	else
        		tmp = t_2;
        	end
        	return tmp
        end
        
        code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]}, Block[{t$95$2 = N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -5.2e+29], t$95$2, If[LessEqual[z, -1.12e-204], N[(N[(t - a), $MachinePrecision] * N[(z / t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5e-40], N[(N[(y / t$95$1), $MachinePrecision] * x), $MachinePrecision], t$95$2]]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \mathsf{fma}\left(b - y, z, y\right)\\
        t_2 := \frac{t - a}{b - y}\\
        \mathbf{if}\;z \leq -5.2 \cdot 10^{+29}:\\
        \;\;\;\;t\_2\\
        
        \mathbf{elif}\;z \leq -1.12 \cdot 10^{-204}:\\
        \;\;\;\;\left(t - a\right) \cdot \frac{z}{t\_1}\\
        
        \mathbf{elif}\;z \leq 5 \cdot 10^{-40}:\\
        \;\;\;\;\frac{y}{t\_1} \cdot x\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_2\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if z < -5.2e29 or 4.99999999999999965e-40 < z

          1. Initial program 52.6%

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

            \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
          4. Step-by-step derivation
            1. lower-/.f64N/A

              \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
            2. lower--.f64N/A

              \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
            3. lower--.f6478.3

              \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
          5. Applied rewrites78.3%

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

          if -5.2e29 < z < -1.11999999999999997e-204

          1. Initial program 90.0%

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

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

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

              \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
            3. lower-*.f64N/A

              \[\leadsto \color{blue}{\left(t - a\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
            4. lower--.f64N/A

              \[\leadsto \color{blue}{\left(t - a\right)} \cdot \frac{z}{y + z \cdot \left(b - y\right)} \]
            5. lower-/.f64N/A

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

              \[\leadsto \left(t - a\right) \cdot \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}} \]
            7. *-commutativeN/A

              \[\leadsto \left(t - a\right) \cdot \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y} \]
            8. lower-fma.f64N/A

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

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

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

          if -1.11999999999999997e-204 < z < 4.99999999999999965e-40

          1. Initial program 80.9%

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

            \[\leadsto \color{blue}{\frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
          4. Step-by-step derivation
            1. *-commutativeN/A

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

              \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
            3. lower-*.f64N/A

              \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
            4. lower-/.f64N/A

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

              \[\leadsto \frac{y}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot x \]
            6. *-commutativeN/A

              \[\leadsto \frac{y}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot x \]
            7. lower-fma.f64N/A

              \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot x \]
            8. lower--.f6473.9

              \[\leadsto \frac{y}{\mathsf{fma}\left(\color{blue}{b - y}, z, y\right)} \cdot x \]
          5. Applied rewrites73.9%

            \[\leadsto \color{blue}{\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x} \]
        3. Recombined 3 regimes into one program.
        4. Add Preprocessing

        Alternative 10: 65.3% accurate, 0.9× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t - a}{b - y}\\ \mathbf{if}\;z \leq -6.8 \cdot 10^{-93}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -3.9 \cdot 10^{-216}:\\ \;\;\;\;\frac{\left(t - a\right) \cdot z}{\left(1 - z\right) \cdot y}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{-40}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
        (FPCore (x y z t a b)
         :precision binary64
         (let* ((t_1 (/ (- t a) (- b y))))
           (if (<= z -6.8e-93)
             t_1
             (if (<= z -3.9e-216)
               (/ (* (- t a) z) (* (- 1.0 z) y))
               (if (<= z 5e-40) (* (/ y (fma (- b y) z y)) x) t_1)))))
        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 <= -6.8e-93) {
        		tmp = t_1;
        	} else if (z <= -3.9e-216) {
        		tmp = ((t - a) * z) / ((1.0 - z) * y);
        	} else if (z <= 5e-40) {
        		tmp = (y / fma((b - y), z, y)) * x;
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        function code(x, y, z, t, a, b)
        	t_1 = Float64(Float64(t - a) / Float64(b - y))
        	tmp = 0.0
        	if (z <= -6.8e-93)
        		tmp = t_1;
        	elseif (z <= -3.9e-216)
        		tmp = Float64(Float64(Float64(t - a) * z) / Float64(Float64(1.0 - z) * y));
        	elseif (z <= 5e-40)
        		tmp = Float64(Float64(y / fma(Float64(b - y), z, y)) * x);
        	else
        		tmp = t_1;
        	end
        	return 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, -6.8e-93], t$95$1, If[LessEqual[z, -3.9e-216], N[(N[(N[(t - a), $MachinePrecision] * z), $MachinePrecision] / N[(N[(1.0 - z), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5e-40], N[(N[(y / N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision], t$95$1]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \frac{t - a}{b - y}\\
        \mathbf{if}\;z \leq -6.8 \cdot 10^{-93}:\\
        \;\;\;\;t\_1\\
        
        \mathbf{elif}\;z \leq -3.9 \cdot 10^{-216}:\\
        \;\;\;\;\frac{\left(t - a\right) \cdot z}{\left(1 - z\right) \cdot y}\\
        
        \mathbf{elif}\;z \leq 5 \cdot 10^{-40}:\\
        \;\;\;\;\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_1\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if z < -6.80000000000000002e-93 or 4.99999999999999965e-40 < z

          1. Initial program 57.7%

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

            \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
          4. Step-by-step derivation
            1. lower-/.f64N/A

              \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
            2. lower--.f64N/A

              \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
            3. lower--.f6475.1

              \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
          5. Applied rewrites75.1%

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

          if -6.80000000000000002e-93 < z < -3.9000000000000001e-216

          1. Initial program 95.9%

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

            \[\leadsto \color{blue}{\frac{x \cdot y + z \cdot \left(t - a\right)}{y + -1 \cdot \left(y \cdot z\right)}} \]
          4. Step-by-step derivation
            1. lower-/.f64N/A

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

              \[\leadsto \frac{\color{blue}{z \cdot \left(t - a\right) + x \cdot y}}{y + -1 \cdot \left(y \cdot z\right)} \]
            3. *-commutativeN/A

              \[\leadsto \frac{\color{blue}{\left(t - a\right) \cdot z} + x \cdot y}{y + -1 \cdot \left(y \cdot z\right)} \]
            4. lower-fma.f64N/A

              \[\leadsto \frac{\color{blue}{\mathsf{fma}\left(t - a, z, x \cdot y\right)}}{y + -1 \cdot \left(y \cdot z\right)} \]
            5. lower--.f64N/A

              \[\leadsto \frac{\mathsf{fma}\left(\color{blue}{t - a}, z, x \cdot y\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
            6. *-commutativeN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
            7. lower-*.f64N/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, \color{blue}{y \cdot x}\right)}{y + -1 \cdot \left(y \cdot z\right)} \]
            8. *-rgt-identityN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot 1} + -1 \cdot \left(y \cdot z\right)} \]
            9. mul-1-negN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{\left(\mathsf{neg}\left(y \cdot z\right)\right)}} \]
            10. distribute-rgt-neg-inN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + \color{blue}{y \cdot \left(\mathsf{neg}\left(z\right)\right)}} \]
            11. mul-1-negN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{y \cdot 1 + y \cdot \color{blue}{\left(-1 \cdot z\right)}} \]
            12. distribute-lft-inN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{y \cdot \left(1 + -1 \cdot z\right)}} \]
            13. *-commutativeN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
            14. lower-*.f64N/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 + -1 \cdot z\right) \cdot y}} \]
            15. fp-cancel-sign-sub-invN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\color{blue}{\left(1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z\right)} \cdot y} \]
            16. metadata-evalN/A

              \[\leadsto \frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - \color{blue}{1} \cdot z\right) \cdot y} \]
            17. *-lft-identityN/A

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

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

            \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t - a, z, y \cdot x\right)}{\left(1 - z\right) \cdot y}} \]
          6. Taylor expanded in x around 0

            \[\leadsto \frac{z \cdot \left(t - a\right)}{\color{blue}{\left(1 - z\right)} \cdot y} \]
          7. Step-by-step derivation
            1. Applied rewrites54.6%

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

            if -3.9000000000000001e-216 < z < 4.99999999999999965e-40

            1. Initial program 80.7%

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

              \[\leadsto \color{blue}{\frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
            4. Step-by-step derivation
              1. *-commutativeN/A

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

                \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
              3. lower-*.f64N/A

                \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
              4. lower-/.f64N/A

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

                \[\leadsto \frac{y}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot x \]
              6. *-commutativeN/A

                \[\leadsto \frac{y}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot x \]
              7. lower-fma.f64N/A

                \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot x \]
              8. lower--.f6474.7

                \[\leadsto \frac{y}{\mathsf{fma}\left(\color{blue}{b - y}, z, y\right)} \cdot x \]
            5. Applied rewrites74.7%

              \[\leadsto \color{blue}{\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x} \]
          8. Recombined 3 regimes into one program.
          9. Add Preprocessing

          Alternative 11: 68.0% accurate, 1.0× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3.8 \cdot 10^{-94} \lor \neg \left(z \leq 5 \cdot 10^{-40}\right):\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x\\ \end{array} \end{array} \]
          (FPCore (x y z t a b)
           :precision binary64
           (if (or (<= z -3.8e-94) (not (<= z 5e-40)))
             (/ (- t a) (- b y))
             (* (/ y (fma (- b y) z y)) x)))
          double code(double x, double y, double z, double t, double a, double b) {
          	double tmp;
          	if ((z <= -3.8e-94) || !(z <= 5e-40)) {
          		tmp = (t - a) / (b - y);
          	} else {
          		tmp = (y / fma((b - y), z, y)) * x;
          	}
          	return tmp;
          }
          
          function code(x, y, z, t, a, b)
          	tmp = 0.0
          	if ((z <= -3.8e-94) || !(z <= 5e-40))
          		tmp = Float64(Float64(t - a) / Float64(b - y));
          	else
          		tmp = Float64(Float64(y / fma(Float64(b - y), z, y)) * x);
          	end
          	return tmp
          end
          
          code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -3.8e-94], N[Not[LessEqual[z, 5e-40]], $MachinePrecision]], N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision], N[(N[(y / N[(N[(b - y), $MachinePrecision] * z + y), $MachinePrecision]), $MachinePrecision] * x), $MachinePrecision]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          \mathbf{if}\;z \leq -3.8 \cdot 10^{-94} \lor \neg \left(z \leq 5 \cdot 10^{-40}\right):\\
          \;\;\;\;\frac{t - a}{b - y}\\
          
          \mathbf{else}:\\
          \;\;\;\;\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if z < -3.79999999999999999e-94 or 4.99999999999999965e-40 < z

            1. Initial program 58.2%

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

              \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
            4. Step-by-step derivation
              1. lower-/.f64N/A

                \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
              2. lower--.f64N/A

                \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
              3. lower--.f6474.2

                \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
            5. Applied rewrites74.2%

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

            if -3.79999999999999999e-94 < z < 4.99999999999999965e-40

            1. Initial program 84.1%

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

              \[\leadsto \color{blue}{\frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
            4. Step-by-step derivation
              1. *-commutativeN/A

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

                \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
              3. lower-*.f64N/A

                \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
              4. lower-/.f64N/A

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

                \[\leadsto \frac{y}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot x \]
              6. *-commutativeN/A

                \[\leadsto \frac{y}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot x \]
              7. lower-fma.f64N/A

                \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot x \]
              8. lower--.f6466.8

                \[\leadsto \frac{y}{\mathsf{fma}\left(\color{blue}{b - y}, z, y\right)} \cdot x \]
            5. Applied rewrites66.8%

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

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

          Alternative 12: 64.6% accurate, 1.0× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.2 \cdot 10^{-110} \lor \neg \left(z \leq 4.8 \cdot 10^{-40}\right):\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(1 - \frac{b}{y}, z, 1\right) \cdot x\\ \end{array} \end{array} \]
          (FPCore (x y z t a b)
           :precision binary64
           (if (or (<= z -2.2e-110) (not (<= z 4.8e-40)))
             (/ (- t a) (- b y))
             (* (fma (- 1.0 (/ b y)) z 1.0) x)))
          double code(double x, double y, double z, double t, double a, double b) {
          	double tmp;
          	if ((z <= -2.2e-110) || !(z <= 4.8e-40)) {
          		tmp = (t - a) / (b - y);
          	} else {
          		tmp = fma((1.0 - (b / y)), z, 1.0) * x;
          	}
          	return tmp;
          }
          
          function code(x, y, z, t, a, b)
          	tmp = 0.0
          	if ((z <= -2.2e-110) || !(z <= 4.8e-40))
          		tmp = Float64(Float64(t - a) / Float64(b - y));
          	else
          		tmp = Float64(fma(Float64(1.0 - Float64(b / y)), z, 1.0) * x);
          	end
          	return tmp
          end
          
          code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -2.2e-110], N[Not[LessEqual[z, 4.8e-40]], $MachinePrecision]], N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision], N[(N[(N[(1.0 - N[(b / y), $MachinePrecision]), $MachinePrecision] * z + 1.0), $MachinePrecision] * x), $MachinePrecision]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          \mathbf{if}\;z \leq -2.2 \cdot 10^{-110} \lor \neg \left(z \leq 4.8 \cdot 10^{-40}\right):\\
          \;\;\;\;\frac{t - a}{b - y}\\
          
          \mathbf{else}:\\
          \;\;\;\;\mathsf{fma}\left(1 - \frac{b}{y}, z, 1\right) \cdot x\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if z < -2.1999999999999999e-110 or 4.79999999999999982e-40 < z

            1. Initial program 59.0%

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

              \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
            4. Step-by-step derivation
              1. lower-/.f64N/A

                \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
              2. lower--.f64N/A

                \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
              3. lower--.f6473.4

                \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
            5. Applied rewrites73.4%

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

            if -2.1999999999999999e-110 < z < 4.79999999999999982e-40

            1. Initial program 83.6%

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

              \[\leadsto \color{blue}{\frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
            4. Step-by-step derivation
              1. *-commutativeN/A

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

                \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
              3. lower-*.f64N/A

                \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
              4. lower-/.f64N/A

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

                \[\leadsto \frac{y}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot x \]
              6. *-commutativeN/A

                \[\leadsto \frac{y}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot x \]
              7. lower-fma.f64N/A

                \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot x \]
              8. lower--.f6467.7

                \[\leadsto \frac{y}{\mathsf{fma}\left(\color{blue}{b - y}, z, y\right)} \cdot x \]
            5. Applied rewrites67.7%

              \[\leadsto \color{blue}{\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x} \]
            6. Taylor expanded in z around 0

              \[\leadsto \left(1 + z \cdot \left(1 - \frac{b}{y}\right)\right) \cdot x \]
            7. Step-by-step derivation
              1. Applied rewrites57.9%

                \[\leadsto \mathsf{fma}\left(1 - \frac{b}{y}, z, 1\right) \cdot x \]
            8. Recombined 2 regimes into one program.
            9. Final simplification67.2%

              \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.2 \cdot 10^{-110} \lor \neg \left(z \leq 4.8 \cdot 10^{-40}\right):\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(1 - \frac{b}{y}, z, 1\right) \cdot x\\ \end{array} \]
            10. Add Preprocessing

            Alternative 13: 64.7% accurate, 1.3× speedup?

            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.2 \cdot 10^{-110} \lor \neg \left(z \leq 5 \cdot 10^{-40}\right):\\ \;\;\;\;\frac{t - a}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\ \end{array} \end{array} \]
            (FPCore (x y z t a b)
             :precision binary64
             (if (or (<= z -2.2e-110) (not (<= z 5e-40))) (/ (- t a) (- b y)) (fma x z x)))
            double code(double x, double y, double z, double t, double a, double b) {
            	double tmp;
            	if ((z <= -2.2e-110) || !(z <= 5e-40)) {
            		tmp = (t - a) / (b - y);
            	} else {
            		tmp = fma(x, z, x);
            	}
            	return tmp;
            }
            
            function code(x, y, z, t, a, b)
            	tmp = 0.0
            	if ((z <= -2.2e-110) || !(z <= 5e-40))
            		tmp = Float64(Float64(t - a) / Float64(b - y));
            	else
            		tmp = fma(x, z, x);
            	end
            	return tmp
            end
            
            code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -2.2e-110], N[Not[LessEqual[z, 5e-40]], $MachinePrecision]], N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision], N[(x * z + x), $MachinePrecision]]
            
            \begin{array}{l}
            
            \\
            \begin{array}{l}
            \mathbf{if}\;z \leq -2.2 \cdot 10^{-110} \lor \neg \left(z \leq 5 \cdot 10^{-40}\right):\\
            \;\;\;\;\frac{t - a}{b - y}\\
            
            \mathbf{else}:\\
            \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 2 regimes
            2. if z < -2.1999999999999999e-110 or 4.99999999999999965e-40 < z

              1. Initial program 59.0%

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

                \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
              4. Step-by-step derivation
                1. lower-/.f64N/A

                  \[\leadsto \color{blue}{\frac{t - a}{b - y}} \]
                2. lower--.f64N/A

                  \[\leadsto \frac{\color{blue}{t - a}}{b - y} \]
                3. lower--.f6473.4

                  \[\leadsto \frac{t - a}{\color{blue}{b - y}} \]
              5. Applied rewrites73.4%

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

              if -2.1999999999999999e-110 < z < 4.99999999999999965e-40

              1. Initial program 83.6%

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

                \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
              4. Step-by-step derivation
                1. lower-/.f64N/A

                  \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                2. fp-cancel-sign-sub-invN/A

                  \[\leadsto \frac{x}{\color{blue}{1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z}} \]
                3. metadata-evalN/A

                  \[\leadsto \frac{x}{1 - \color{blue}{1} \cdot z} \]
                4. *-lft-identityN/A

                  \[\leadsto \frac{x}{1 - \color{blue}{z}} \]
                5. lower--.f6457.7

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

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

                \[\leadsto x + \color{blue}{x \cdot z} \]
              7. Step-by-step derivation
                1. Applied rewrites57.7%

                  \[\leadsto \mathsf{fma}\left(x, \color{blue}{z}, x\right) \]
              8. Recombined 2 regimes into one program.
              9. Final simplification67.1%

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

              Alternative 14: 37.6% accurate, 1.3× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.35 \cdot 10^{+221}:\\ \;\;\;\;\frac{t}{b}\\ \mathbf{elif}\;z \leq -1.2 \cdot 10^{-5}:\\ \;\;\;\;\frac{-a}{b}\\ \mathbf{elif}\;z \leq 6 \cdot 10^{-40}:\\ \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{t}{b}\\ \end{array} \end{array} \]
              (FPCore (x y z t a b)
               :precision binary64
               (if (<= z -2.35e+221)
                 (/ t b)
                 (if (<= z -1.2e-5) (/ (- a) b) (if (<= z 6e-40) (fma x z x) (/ t b)))))
              double code(double x, double y, double z, double t, double a, double b) {
              	double tmp;
              	if (z <= -2.35e+221) {
              		tmp = t / b;
              	} else if (z <= -1.2e-5) {
              		tmp = -a / b;
              	} else if (z <= 6e-40) {
              		tmp = fma(x, z, x);
              	} else {
              		tmp = t / b;
              	}
              	return tmp;
              }
              
              function code(x, y, z, t, a, b)
              	tmp = 0.0
              	if (z <= -2.35e+221)
              		tmp = Float64(t / b);
              	elseif (z <= -1.2e-5)
              		tmp = Float64(Float64(-a) / b);
              	elseif (z <= 6e-40)
              		tmp = fma(x, z, x);
              	else
              		tmp = Float64(t / b);
              	end
              	return tmp
              end
              
              code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -2.35e+221], N[(t / b), $MachinePrecision], If[LessEqual[z, -1.2e-5], N[((-a) / b), $MachinePrecision], If[LessEqual[z, 6e-40], N[(x * z + x), $MachinePrecision], N[(t / b), $MachinePrecision]]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              \mathbf{if}\;z \leq -2.35 \cdot 10^{+221}:\\
              \;\;\;\;\frac{t}{b}\\
              
              \mathbf{elif}\;z \leq -1.2 \cdot 10^{-5}:\\
              \;\;\;\;\frac{-a}{b}\\
              
              \mathbf{elif}\;z \leq 6 \cdot 10^{-40}:\\
              \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\
              
              \mathbf{else}:\\
              \;\;\;\;\frac{t}{b}\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if z < -2.35000000000000003e221 or 6.00000000000000039e-40 < z

                1. Initial program 53.8%

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

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

                    \[\leadsto \color{blue}{t \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
                  2. *-commutativeN/A

                    \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)} \cdot t} \]
                  3. lower-*.f64N/A

                    \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)} \cdot t} \]
                  4. lower-/.f64N/A

                    \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}} \cdot t \]
                  5. +-commutativeN/A

                    \[\leadsto \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot t \]
                  6. *-commutativeN/A

                    \[\leadsto \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot t \]
                  7. lower-fma.f64N/A

                    \[\leadsto \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot t \]
                  8. lower--.f6435.5

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

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

                  \[\leadsto \frac{t}{\color{blue}{b}} \]
                7. Step-by-step derivation
                  1. Applied rewrites39.8%

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

                  if -2.35000000000000003e221 < z < -1.2e-5

                  1. Initial program 57.7%

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

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

                      \[\leadsto \color{blue}{\mathsf{neg}\left(\frac{a \cdot z}{y + z \cdot \left(b - y\right)}\right)} \]
                    2. associate-/l*N/A

                      \[\leadsto \mathsf{neg}\left(\color{blue}{a \cdot \frac{z}{y + z \cdot \left(b - y\right)}}\right) \]
                    3. distribute-lft-neg-inN/A

                      \[\leadsto \color{blue}{\left(\mathsf{neg}\left(a\right)\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
                    4. lower-*.f64N/A

                      \[\leadsto \color{blue}{\left(\mathsf{neg}\left(a\right)\right) \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
                    5. lower-neg.f64N/A

                      \[\leadsto \color{blue}{\left(-a\right)} \cdot \frac{z}{y + z \cdot \left(b - y\right)} \]
                    6. lower-/.f64N/A

                      \[\leadsto \left(-a\right) \cdot \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}} \]
                    7. +-commutativeN/A

                      \[\leadsto \left(-a\right) \cdot \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}} \]
                    8. *-commutativeN/A

                      \[\leadsto \left(-a\right) \cdot \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y} \]
                    9. lower-fma.f64N/A

                      \[\leadsto \left(-a\right) \cdot \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \]
                    10. lower--.f6428.4

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

                    \[\leadsto \color{blue}{\left(-a\right) \cdot \frac{z}{\mathsf{fma}\left(b - y, z, y\right)}} \]
                  6. Taylor expanded in y around 0

                    \[\leadsto -1 \cdot \color{blue}{\frac{a}{b}} \]
                  7. Step-by-step derivation
                    1. Applied rewrites27.8%

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

                    if -1.2e-5 < z < 6.00000000000000039e-40

                    1. Initial program 83.3%

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

                      \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                    4. Step-by-step derivation
                      1. lower-/.f64N/A

                        \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                      2. fp-cancel-sign-sub-invN/A

                        \[\leadsto \frac{x}{\color{blue}{1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z}} \]
                      3. metadata-evalN/A

                        \[\leadsto \frac{x}{1 - \color{blue}{1} \cdot z} \]
                      4. *-lft-identityN/A

                        \[\leadsto \frac{x}{1 - \color{blue}{z}} \]
                      5. lower--.f6452.6

                        \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
                    5. Applied rewrites52.6%

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

                      \[\leadsto x + \color{blue}{x \cdot z} \]
                    7. Step-by-step derivation
                      1. Applied rewrites52.6%

                        \[\leadsto \mathsf{fma}\left(x, \color{blue}{z}, x\right) \]
                    8. Recombined 3 regimes into one program.
                    9. Add Preprocessing

                    Alternative 15: 54.3% accurate, 1.4× speedup?

                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -3.8 \cdot 10^{+65} \lor \neg \left(y \leq 2.65 \cdot 10^{+25}\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 -3.8e+65) (not (<= y 2.65e+25))) (/ 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 <= -3.8e+65) || !(y <= 2.65e+25)) {
                    		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 <= (-3.8d+65)) .or. (.not. (y <= 2.65d+25))) 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 <= -3.8e+65) || !(y <= 2.65e+25)) {
                    		tmp = x / (1.0 - z);
                    	} else {
                    		tmp = (t - a) / b;
                    	}
                    	return tmp;
                    }
                    
                    def code(x, y, z, t, a, b):
                    	tmp = 0
                    	if (y <= -3.8e+65) or not (y <= 2.65e+25):
                    		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 <= -3.8e+65) || !(y <= 2.65e+25))
                    		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 <= -3.8e+65) || ~((y <= 2.65e+25)))
                    		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, -3.8e+65], N[Not[LessEqual[y, 2.65e+25]], $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 -3.8 \cdot 10^{+65} \lor \neg \left(y \leq 2.65 \cdot 10^{+25}\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.80000000000000011e65 or 2.64999999999999993e25 < y

                      1. Initial program 50.0%

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

                        \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                      4. Step-by-step derivation
                        1. lower-/.f64N/A

                          \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                        2. fp-cancel-sign-sub-invN/A

                          \[\leadsto \frac{x}{\color{blue}{1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z}} \]
                        3. metadata-evalN/A

                          \[\leadsto \frac{x}{1 - \color{blue}{1} \cdot z} \]
                        4. *-lft-identityN/A

                          \[\leadsto \frac{x}{1 - \color{blue}{z}} \]
                        5. lower--.f6456.6

                          \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
                      5. Applied rewrites56.6%

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

                      if -3.80000000000000011e65 < y < 2.64999999999999993e25

                      1. Initial program 83.1%

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

                        \[\leadsto \color{blue}{\frac{t - a}{b}} \]
                      4. Step-by-step derivation
                        1. lower-/.f64N/A

                          \[\leadsto \color{blue}{\frac{t - a}{b}} \]
                        2. lower--.f6452.3

                          \[\leadsto \frac{\color{blue}{t - a}}{b} \]
                      5. Applied rewrites52.3%

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

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

                    Alternative 16: 46.1% accurate, 1.4× speedup?

                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.42 \cdot 10^{-5} \lor \neg \left(z \leq 6 \cdot 10^{-40}\right):\\ \;\;\;\;\frac{t}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\ \end{array} \end{array} \]
                    (FPCore (x y z t a b)
                     :precision binary64
                     (if (or (<= z -1.42e-5) (not (<= z 6e-40))) (/ t (- b y)) (fma x z x)))
                    double code(double x, double y, double z, double t, double a, double b) {
                    	double tmp;
                    	if ((z <= -1.42e-5) || !(z <= 6e-40)) {
                    		tmp = t / (b - y);
                    	} else {
                    		tmp = fma(x, z, x);
                    	}
                    	return tmp;
                    }
                    
                    function code(x, y, z, t, a, b)
                    	tmp = 0.0
                    	if ((z <= -1.42e-5) || !(z <= 6e-40))
                    		tmp = Float64(t / Float64(b - y));
                    	else
                    		tmp = fma(x, z, x);
                    	end
                    	return tmp
                    end
                    
                    code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -1.42e-5], N[Not[LessEqual[z, 6e-40]], $MachinePrecision]], N[(t / N[(b - y), $MachinePrecision]), $MachinePrecision], N[(x * z + x), $MachinePrecision]]
                    
                    \begin{array}{l}
                    
                    \\
                    \begin{array}{l}
                    \mathbf{if}\;z \leq -1.42 \cdot 10^{-5} \lor \neg \left(z \leq 6 \cdot 10^{-40}\right):\\
                    \;\;\;\;\frac{t}{b - y}\\
                    
                    \mathbf{else}:\\
                    \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\
                    
                    
                    \end{array}
                    \end{array}
                    
                    Derivation
                    1. Split input into 2 regimes
                    2. if z < -1.42e-5 or 6.00000000000000039e-40 < z

                      1. Initial program 55.4%

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

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

                          \[\leadsto \color{blue}{t \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
                        2. *-commutativeN/A

                          \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)} \cdot t} \]
                        3. lower-*.f64N/A

                          \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)} \cdot t} \]
                        4. lower-/.f64N/A

                          \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}} \cdot t \]
                        5. +-commutativeN/A

                          \[\leadsto \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot t \]
                        6. *-commutativeN/A

                          \[\leadsto \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot t \]
                        7. lower-fma.f64N/A

                          \[\leadsto \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot t \]
                        8. lower--.f6435.9

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

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

                        \[\leadsto \frac{t}{\color{blue}{b - y}} \]
                      7. Step-by-step derivation
                        1. Applied rewrites48.3%

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

                        if -1.42e-5 < z < 6.00000000000000039e-40

                        1. Initial program 83.3%

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

                          \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                        4. Step-by-step derivation
                          1. lower-/.f64N/A

                            \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                          2. fp-cancel-sign-sub-invN/A

                            \[\leadsto \frac{x}{\color{blue}{1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z}} \]
                          3. metadata-evalN/A

                            \[\leadsto \frac{x}{1 - \color{blue}{1} \cdot z} \]
                          4. *-lft-identityN/A

                            \[\leadsto \frac{x}{1 - \color{blue}{z}} \]
                          5. lower--.f6452.6

                            \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
                        5. Applied rewrites52.6%

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

                          \[\leadsto x + \color{blue}{x \cdot z} \]
                        7. Step-by-step derivation
                          1. Applied rewrites52.6%

                            \[\leadsto \mathsf{fma}\left(x, \color{blue}{z}, x\right) \]
                        8. Recombined 2 regimes into one program.
                        9. Final simplification50.4%

                          \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.42 \cdot 10^{-5} \lor \neg \left(z \leq 6 \cdot 10^{-40}\right):\\ \;\;\;\;\frac{t}{b - y}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\ \end{array} \]
                        10. Add Preprocessing

                        Alternative 17: 37.8% accurate, 1.6× speedup?

                        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.42 \cdot 10^{-5} \lor \neg \left(z \leq 6 \cdot 10^{-40}\right):\\ \;\;\;\;\frac{t}{b}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\ \end{array} \end{array} \]
                        (FPCore (x y z t a b)
                         :precision binary64
                         (if (or (<= z -1.42e-5) (not (<= z 6e-40))) (/ t b) (fma x z x)))
                        double code(double x, double y, double z, double t, double a, double b) {
                        	double tmp;
                        	if ((z <= -1.42e-5) || !(z <= 6e-40)) {
                        		tmp = t / b;
                        	} else {
                        		tmp = fma(x, z, x);
                        	}
                        	return tmp;
                        }
                        
                        function code(x, y, z, t, a, b)
                        	tmp = 0.0
                        	if ((z <= -1.42e-5) || !(z <= 6e-40))
                        		tmp = Float64(t / b);
                        	else
                        		tmp = fma(x, z, x);
                        	end
                        	return tmp
                        end
                        
                        code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -1.42e-5], N[Not[LessEqual[z, 6e-40]], $MachinePrecision]], N[(t / b), $MachinePrecision], N[(x * z + x), $MachinePrecision]]
                        
                        \begin{array}{l}
                        
                        \\
                        \begin{array}{l}
                        \mathbf{if}\;z \leq -1.42 \cdot 10^{-5} \lor \neg \left(z \leq 6 \cdot 10^{-40}\right):\\
                        \;\;\;\;\frac{t}{b}\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 2 regimes
                        2. if z < -1.42e-5 or 6.00000000000000039e-40 < z

                          1. Initial program 55.4%

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

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

                              \[\leadsto \color{blue}{t \cdot \frac{z}{y + z \cdot \left(b - y\right)}} \]
                            2. *-commutativeN/A

                              \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)} \cdot t} \]
                            3. lower-*.f64N/A

                              \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)} \cdot t} \]
                            4. lower-/.f64N/A

                              \[\leadsto \color{blue}{\frac{z}{y + z \cdot \left(b - y\right)}} \cdot t \]
                            5. +-commutativeN/A

                              \[\leadsto \frac{z}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot t \]
                            6. *-commutativeN/A

                              \[\leadsto \frac{z}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot t \]
                            7. lower-fma.f64N/A

                              \[\leadsto \frac{z}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot t \]
                            8. lower--.f6435.9

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

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

                            \[\leadsto \frac{t}{\color{blue}{b}} \]
                          7. Step-by-step derivation
                            1. Applied rewrites31.0%

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

                            if -1.42e-5 < z < 6.00000000000000039e-40

                            1. Initial program 83.3%

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

                              \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                            4. Step-by-step derivation
                              1. lower-/.f64N/A

                                \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                              2. fp-cancel-sign-sub-invN/A

                                \[\leadsto \frac{x}{\color{blue}{1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z}} \]
                              3. metadata-evalN/A

                                \[\leadsto \frac{x}{1 - \color{blue}{1} \cdot z} \]
                              4. *-lft-identityN/A

                                \[\leadsto \frac{x}{1 - \color{blue}{z}} \]
                              5. lower--.f6452.6

                                \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
                            5. Applied rewrites52.6%

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

                              \[\leadsto x + \color{blue}{x \cdot z} \]
                            7. Step-by-step derivation
                              1. Applied rewrites52.6%

                                \[\leadsto \mathsf{fma}\left(x, \color{blue}{z}, x\right) \]
                            8. Recombined 2 regimes into one program.
                            9. Final simplification41.5%

                              \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.42 \cdot 10^{-5} \lor \neg \left(z \leq 6 \cdot 10^{-40}\right):\\ \;\;\;\;\frac{t}{b}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(x, z, x\right)\\ \end{array} \]
                            10. Add Preprocessing

                            Alternative 18: 25.8% accurate, 5.6× speedup?

                            \[\begin{array}{l} \\ \mathsf{fma}\left(x, z, x\right) \end{array} \]
                            (FPCore (x y z t a b) :precision binary64 (fma x z x))
                            double code(double x, double y, double z, double t, double a, double b) {
                            	return fma(x, z, x);
                            }
                            
                            function code(x, y, z, t, a, b)
                            	return fma(x, z, x)
                            end
                            
                            code[x_, y_, z_, t_, a_, b_] := N[(x * z + x), $MachinePrecision]
                            
                            \begin{array}{l}
                            
                            \\
                            \mathsf{fma}\left(x, z, x\right)
                            \end{array}
                            
                            Derivation
                            1. Initial program 68.9%

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

                              \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                            4. Step-by-step derivation
                              1. lower-/.f64N/A

                                \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                              2. fp-cancel-sign-sub-invN/A

                                \[\leadsto \frac{x}{\color{blue}{1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z}} \]
                              3. metadata-evalN/A

                                \[\leadsto \frac{x}{1 - \color{blue}{1} \cdot z} \]
                              4. *-lft-identityN/A

                                \[\leadsto \frac{x}{1 - \color{blue}{z}} \]
                              5. lower--.f6435.0

                                \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
                            5. Applied rewrites35.0%

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

                              \[\leadsto x + \color{blue}{x \cdot z} \]
                            7. Step-by-step derivation
                              1. Applied rewrites28.5%

                                \[\leadsto \mathsf{fma}\left(x, \color{blue}{z}, x\right) \]
                              2. Add Preprocessing

                              Alternative 19: 25.6% accurate, 6.5× speedup?

                              \[\begin{array}{l} \\ 1 \cdot x \end{array} \]
                              (FPCore (x y z t a b) :precision binary64 (* 1.0 x))
                              double code(double x, double y, double z, double t, double a, double b) {
                              	return 1.0 * 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 = 1.0d0 * x
                              end function
                              
                              public static double code(double x, double y, double z, double t, double a, double b) {
                              	return 1.0 * x;
                              }
                              
                              def code(x, y, z, t, a, b):
                              	return 1.0 * x
                              
                              function code(x, y, z, t, a, b)
                              	return Float64(1.0 * x)
                              end
                              
                              function tmp = code(x, y, z, t, a, b)
                              	tmp = 1.0 * x;
                              end
                              
                              code[x_, y_, z_, t_, a_, b_] := N[(1.0 * x), $MachinePrecision]
                              
                              \begin{array}{l}
                              
                              \\
                              1 \cdot x
                              \end{array}
                              
                              Derivation
                              1. Initial program 68.9%

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

                                \[\leadsto \color{blue}{\frac{x \cdot y}{y + z \cdot \left(b - y\right)}} \]
                              4. Step-by-step derivation
                                1. *-commutativeN/A

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

                                  \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
                                3. lower-*.f64N/A

                                  \[\leadsto \color{blue}{\frac{y}{y + z \cdot \left(b - y\right)} \cdot x} \]
                                4. lower-/.f64N/A

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

                                  \[\leadsto \frac{y}{\color{blue}{z \cdot \left(b - y\right) + y}} \cdot x \]
                                6. *-commutativeN/A

                                  \[\leadsto \frac{y}{\color{blue}{\left(b - y\right) \cdot z} + y} \cdot x \]
                                7. lower-fma.f64N/A

                                  \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(b - y, z, y\right)}} \cdot x \]
                                8. lower--.f6438.5

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

                                \[\leadsto \color{blue}{\frac{y}{\mathsf{fma}\left(b - y, z, y\right)} \cdot x} \]
                              6. Taylor expanded in z around 0

                                \[\leadsto 1 \cdot x \]
                              7. Step-by-step derivation
                                1. Applied rewrites27.9%

                                  \[\leadsto 1 \cdot x \]
                                2. Add Preprocessing

                                Alternative 20: 3.7% accurate, 6.5× speedup?

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

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

                                  \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                                4. Step-by-step derivation
                                  1. lower-/.f64N/A

                                    \[\leadsto \color{blue}{\frac{x}{1 + -1 \cdot z}} \]
                                  2. fp-cancel-sign-sub-invN/A

                                    \[\leadsto \frac{x}{\color{blue}{1 - \left(\mathsf{neg}\left(-1\right)\right) \cdot z}} \]
                                  3. metadata-evalN/A

                                    \[\leadsto \frac{x}{1 - \color{blue}{1} \cdot z} \]
                                  4. *-lft-identityN/A

                                    \[\leadsto \frac{x}{1 - \color{blue}{z}} \]
                                  5. lower--.f6435.0

                                    \[\leadsto \frac{x}{\color{blue}{1 - z}} \]
                                5. Applied rewrites35.0%

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

                                  \[\leadsto x + \color{blue}{x \cdot z} \]
                                7. Step-by-step derivation
                                  1. Applied rewrites28.5%

                                    \[\leadsto \mathsf{fma}\left(x, \color{blue}{z}, x\right) \]
                                  2. Taylor expanded in z around inf

                                    \[\leadsto x \cdot z \]
                                  3. Step-by-step derivation
                                    1. Applied rewrites3.9%

                                      \[\leadsto x \cdot z \]
                                    2. Add Preprocessing

                                    Developer Target 1: 73.9% accurate, 0.6× 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 2024326 
                                    (FPCore (x y z t a b)
                                      :name "Development.Shake.Progress:decay from shake-0.15.5"
                                      :precision binary64
                                    
                                      :alt
                                      (! :herbie-platform default (- (/ (+ (* z t) (* y x)) (+ y (* z (- b y)))) (/ a (+ (- b y) (/ y z)))))
                                    
                                      (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))))