Diagrams.Trail:splitAtParam from diagrams-lib-1.3.0.3, A

Percentage Accurate: 89.8% → 94.8%
Time: 14.5s
Alternatives: 21
Speedup: 0.8×

Specification

?
\[\begin{array}{l} \\ \frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (/ (+ x (/ (- (* y z) x) (- (* t z) x))) (+ x 1.0)))
double code(double x, double y, double z, double t) {
	return (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0);
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0d0)
end function
public static double code(double x, double y, double z, double t) {
	return (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0);
}
def code(x, y, z, t):
	return (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0)
function code(x, y, z, t)
	return Float64(Float64(x + Float64(Float64(Float64(y * z) - x) / Float64(Float64(t * z) - x))) / Float64(x + 1.0))
end
function tmp = code(x, y, z, t)
	tmp = (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0);
end
code[x_, y_, z_, t_] := N[(N[(x + N[(N[(N[(y * z), $MachinePrecision] - x), $MachinePrecision] / N[(N[(t * z), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1}
\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 21 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: 89.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (/ (+ x (/ (- (* y z) x) (- (* t z) x))) (+ x 1.0)))
double code(double x, double y, double z, double t) {
	return (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0);
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0d0)
end function
public static double code(double x, double y, double z, double t) {
	return (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0);
}
def code(x, y, z, t):
	return (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0)
function code(x, y, z, t)
	return Float64(Float64(x + Float64(Float64(Float64(y * z) - x) / Float64(Float64(t * z) - x))) / Float64(x + 1.0))
end
function tmp = code(x, y, z, t)
	tmp = (x + (((y * z) - x) / ((t * z) - x))) / (x + 1.0);
end
code[x_, y_, z_, t_] := N[(N[(x + N[(N[(N[(y * z), $MachinePrecision] - x), $MachinePrecision] / N[(N[(t * z), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1}
\end{array}

Alternative 1: 94.8% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x}{x + 1} + \frac{\frac{y}{x + 1} - \frac{x}{\mathsf{fma}\left(x, z, z\right)}}{t}\\ \mathbf{if}\;z \leq -6.5 \cdot 10^{+173}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 3.9 \cdot 10^{+112}:\\ \;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (+ (/ x (+ x 1.0)) (/ (- (/ y (+ x 1.0)) (/ x (fma x z z))) t))))
   (if (<= z -6.5e+173)
     t_1
     (if (<= z 3.9e+112)
       (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))
       t_1))))
double code(double x, double y, double z, double t) {
	double t_1 = (x / (x + 1.0)) + (((y / (x + 1.0)) - (x / fma(x, z, z))) / t);
	double tmp;
	if (z <= -6.5e+173) {
		tmp = t_1;
	} else if (z <= 3.9e+112) {
		tmp = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(x, y, z, t)
	t_1 = Float64(Float64(x / Float64(x + 1.0)) + Float64(Float64(Float64(y / Float64(x + 1.0)) - Float64(x / fma(x, z, z))) / t))
	tmp = 0.0
	if (z <= -6.5e+173)
		tmp = t_1;
	elseif (z <= 3.9e+112)
		tmp = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0));
	else
		tmp = t_1;
	end
	return tmp
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x / N[(x + 1.0), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y / N[(x + 1.0), $MachinePrecision]), $MachinePrecision] - N[(x / N[(x * z + z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -6.5e+173], t$95$1, If[LessEqual[z, 3.9e+112], N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{x}{x + 1} + \frac{\frac{y}{x + 1} - \frac{x}{\mathsf{fma}\left(x, z, z\right)}}{t}\\
\mathbf{if}\;z \leq -6.5 \cdot 10^{+173}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 3.9 \cdot 10^{+112}:\\
\;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -6.4999999999999997e173 or 3.89999999999999968e112 < z

    1. Initial program 66.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in t around -inf

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

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

        \[\leadsto \frac{x}{1 + x} + \color{blue}{\left(\mathsf{neg}\left(\frac{-1 \cdot \frac{y}{1 + x} - -1 \cdot \frac{x}{z \cdot \left(1 + x\right)}}{t}\right)\right)} \]
      3. unsub-negN/A

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

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

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

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

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

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

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

    if -6.4999999999999997e173 < z < 3.89999999999999968e112

    1. Initial program 99.3%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
  3. Recombined 2 regimes into one program.
  4. Final simplification95.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -6.5 \cdot 10^{+173}:\\ \;\;\;\;\frac{x}{x + 1} + \frac{\frac{y}{x + 1} - \frac{x}{\mathsf{fma}\left(x, z, z\right)}}{t}\\ \mathbf{elif}\;z \leq 3.9 \cdot 10^{+112}:\\ \;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{x + 1} + \frac{\frac{y}{x + 1} - \frac{x}{\mathsf{fma}\left(x, z, z\right)}}{t}\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 93.1% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := z \cdot t - x\\ t_2 := \frac{x + \frac{z \cdot y - x}{t\_1}}{x + 1}\\ t_3 := \frac{z \cdot y}{\left(x + 1\right) \cdot t\_1}\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;t\_2 \leq -1000000000:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{-63}:\\ \;\;\;\;\frac{x + \frac{\mathsf{fma}\left(y, z, 0 - x\right)}{z \cdot t}}{x + 1}\\ \mathbf{elif}\;t\_2 \leq 2:\\ \;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\ \mathbf{elif}\;t\_2 \leq 10^{+205}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* z t) x))
        (t_2 (/ (+ x (/ (- (* z y) x) t_1)) (+ x 1.0)))
        (t_3 (/ (* z y) (* (+ x 1.0) t_1))))
   (if (<= t_2 -2e+254)
     (/ y (fma x t t))
     (if (<= t_2 -1000000000.0)
       t_3
       (if (<= t_2 2e-63)
         (/ (+ x (/ (fma y z (- 0.0 x)) (* z t))) (+ x 1.0))
         (if (<= t_2 2.0)
           (/ (- x (/ x (fma z t (- 0.0 x)))) (+ x 1.0))
           (if (<= t_2 1e+205) t_3 (/ (+ x (/ y t)) (+ x 1.0)))))))))
double code(double x, double y, double z, double t) {
	double t_1 = (z * t) - x;
	double t_2 = (x + (((z * y) - x) / t_1)) / (x + 1.0);
	double t_3 = (z * y) / ((x + 1.0) * t_1);
	double tmp;
	if (t_2 <= -2e+254) {
		tmp = y / fma(x, t, t);
	} else if (t_2 <= -1000000000.0) {
		tmp = t_3;
	} else if (t_2 <= 2e-63) {
		tmp = (x + (fma(y, z, (0.0 - x)) / (z * t))) / (x + 1.0);
	} else if (t_2 <= 2.0) {
		tmp = (x - (x / fma(z, t, (0.0 - x)))) / (x + 1.0);
	} else if (t_2 <= 1e+205) {
		tmp = t_3;
	} else {
		tmp = (x + (y / t)) / (x + 1.0);
	}
	return tmp;
}
function code(x, y, z, t)
	t_1 = Float64(Float64(z * t) - x)
	t_2 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / t_1)) / Float64(x + 1.0))
	t_3 = Float64(Float64(z * y) / Float64(Float64(x + 1.0) * t_1))
	tmp = 0.0
	if (t_2 <= -2e+254)
		tmp = Float64(y / fma(x, t, t));
	elseif (t_2 <= -1000000000.0)
		tmp = t_3;
	elseif (t_2 <= 2e-63)
		tmp = Float64(Float64(x + Float64(fma(y, z, Float64(0.0 - x)) / Float64(z * t))) / Float64(x + 1.0));
	elseif (t_2 <= 2.0)
		tmp = Float64(Float64(x - Float64(x / fma(z, t, Float64(0.0 - x)))) / Float64(x + 1.0));
	elseif (t_2 <= 1e+205)
		tmp = t_3;
	else
		tmp = Float64(Float64(x + Float64(y / t)) / Float64(x + 1.0));
	end
	return tmp
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(z * y), $MachinePrecision] / N[(N[(x + 1.0), $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+254], N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, -1000000000.0], t$95$3, If[LessEqual[t$95$2, 2e-63], N[(N[(x + N[(N[(y * z + N[(0.0 - x), $MachinePrecision]), $MachinePrecision] / N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 2.0], N[(N[(x - N[(x / N[(z * t + N[(0.0 - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 1e+205], t$95$3, N[(N[(x + N[(y / t), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t\_2 \leq -1000000000:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;t\_2 \leq 2 \cdot 10^{-63}:\\
\;\;\;\;\frac{x + \frac{\mathsf{fma}\left(y, z, 0 - x\right)}{z \cdot t}}{x + 1}\\

\mathbf{elif}\;t\_2 \leq 2:\\
\;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\

\mathbf{elif}\;t\_2 \leq 10^{+205}:\\
\;\;\;\;t\_3\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.9999999999999999e254

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6461.7

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified61.7%

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

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

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

        \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
      3. distribute-lft-inN/A

        \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
      4. *-commutativeN/A

        \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
      5. *-rgt-identityN/A

        \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
      6. accelerator-lowering-fma.f6474.1

        \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
    8. Simplified74.1%

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

    if -1.9999999999999999e254 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1e9 or 2 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000002e205

    1. Initial program 99.5%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf

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

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

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

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

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

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

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

        \[\leadsto \frac{y \cdot z}{\left(t \cdot z - x\right) \cdot \color{blue}{\left(x + 1\right)}} \]
      8. +-lowering-+.f6496.1

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

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

    if -1e9 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 2.00000000000000013e-63

    1. Initial program 93.6%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf

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

        \[\leadsto \frac{x + \color{blue}{\frac{y \cdot z - x}{t \cdot z}}}{x + 1} \]
      2. sub-negN/A

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

        \[\leadsto \frac{x + \frac{y \cdot z + \color{blue}{-1 \cdot x}}{t \cdot z}}{x + 1} \]
      4. accelerator-lowering-fma.f64N/A

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

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

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

        \[\leadsto \frac{x + \frac{\mathsf{fma}\left(y, z, \color{blue}{0 - x}\right)}{t \cdot z}}{x + 1} \]
      8. *-lowering-*.f6493.1

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

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

    if 2.00000000000000013e-63 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 2

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0

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

        \[\leadsto \color{blue}{\frac{x - \frac{x}{t \cdot z - x}}{1 + x}} \]
      2. --lowering--.f64N/A

        \[\leadsto \frac{\color{blue}{x - \frac{x}{t \cdot z - x}}}{1 + x} \]
      3. /-lowering-/.f64N/A

        \[\leadsto \frac{x - \color{blue}{\frac{x}{t \cdot z - x}}}{1 + x} \]
      4. --lowering--.f64N/A

        \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z - x}}}{1 + x} \]
      5. *-lowering-*.f64N/A

        \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z} - x}}{1 + x} \]
      6. +-commutativeN/A

        \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
      7. +-lowering-+.f6499.1

        \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
    5. Simplified99.1%

      \[\leadsto \color{blue}{\frac{x - \frac{x}{t \cdot z - x}}{x + 1}} \]
    6. Step-by-step derivation
      1. sub-negN/A

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

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

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

        \[\leadsto \frac{x - \frac{x}{\color{blue}{\mathsf{fma}\left(z, t, 0 - x\right)}}}{x + 1} \]
      5. --lowering--.f6499.1

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

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

    if 1.00000000000000002e205 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6478.3

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified78.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1000000000:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 2 \cdot 10^{-63}:\\ \;\;\;\;\frac{x + \frac{\mathsf{fma}\left(y, z, 0 - x\right)}{z \cdot t}}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 2:\\ \;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 10^{+205}:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 93.1% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := z \cdot y - x\\ t_2 := z \cdot t - x\\ t_3 := \frac{x + \frac{t\_1}{t\_2}}{x + 1}\\ t_4 := \frac{z \cdot y}{\left(x + 1\right) \cdot t\_2}\\ \mathbf{if}\;t\_3 \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;t\_3 \leq -1000000000:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;t\_3 \leq 2 \cdot 10^{-63}:\\ \;\;\;\;\frac{x + \frac{t\_1}{z \cdot t}}{x + 1}\\ \mathbf{elif}\;t\_3 \leq 2:\\ \;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\ \mathbf{elif}\;t\_3 \leq 10^{+205}:\\ \;\;\;\;t\_4\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* z y) x))
        (t_2 (- (* z t) x))
        (t_3 (/ (+ x (/ t_1 t_2)) (+ x 1.0)))
        (t_4 (/ (* z y) (* (+ x 1.0) t_2))))
   (if (<= t_3 -2e+254)
     (/ y (fma x t t))
     (if (<= t_3 -1000000000.0)
       t_4
       (if (<= t_3 2e-63)
         (/ (+ x (/ t_1 (* z t))) (+ x 1.0))
         (if (<= t_3 2.0)
           (/ (- x (/ x (fma z t (- 0.0 x)))) (+ x 1.0))
           (if (<= t_3 1e+205) t_4 (/ (+ x (/ y t)) (+ x 1.0)))))))))
double code(double x, double y, double z, double t) {
	double t_1 = (z * y) - x;
	double t_2 = (z * t) - x;
	double t_3 = (x + (t_1 / t_2)) / (x + 1.0);
	double t_4 = (z * y) / ((x + 1.0) * t_2);
	double tmp;
	if (t_3 <= -2e+254) {
		tmp = y / fma(x, t, t);
	} else if (t_3 <= -1000000000.0) {
		tmp = t_4;
	} else if (t_3 <= 2e-63) {
		tmp = (x + (t_1 / (z * t))) / (x + 1.0);
	} else if (t_3 <= 2.0) {
		tmp = (x - (x / fma(z, t, (0.0 - x)))) / (x + 1.0);
	} else if (t_3 <= 1e+205) {
		tmp = t_4;
	} else {
		tmp = (x + (y / t)) / (x + 1.0);
	}
	return tmp;
}
function code(x, y, z, t)
	t_1 = Float64(Float64(z * y) - x)
	t_2 = Float64(Float64(z * t) - x)
	t_3 = Float64(Float64(x + Float64(t_1 / t_2)) / Float64(x + 1.0))
	t_4 = Float64(Float64(z * y) / Float64(Float64(x + 1.0) * t_2))
	tmp = 0.0
	if (t_3 <= -2e+254)
		tmp = Float64(y / fma(x, t, t));
	elseif (t_3 <= -1000000000.0)
		tmp = t_4;
	elseif (t_3 <= 2e-63)
		tmp = Float64(Float64(x + Float64(t_1 / Float64(z * t))) / Float64(x + 1.0));
	elseif (t_3 <= 2.0)
		tmp = Float64(Float64(x - Float64(x / fma(z, t, Float64(0.0 - x)))) / Float64(x + 1.0));
	elseif (t_3 <= 1e+205)
		tmp = t_4;
	else
		tmp = Float64(Float64(x + Float64(y / t)) / Float64(x + 1.0));
	end
	return tmp
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision]}, Block[{t$95$2 = N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]}, Block[{t$95$3 = N[(N[(x + N[(t$95$1 / t$95$2), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(z * y), $MachinePrecision] / N[(N[(x + 1.0), $MachinePrecision] * t$95$2), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$3, -2e+254], N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, -1000000000.0], t$95$4, If[LessEqual[t$95$3, 2e-63], N[(N[(x + N[(t$95$1 / N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, 2.0], N[(N[(x - N[(x / N[(z * t + N[(0.0 - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, 1e+205], t$95$4, N[(N[(x + N[(y / t), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t\_3 \leq -1000000000:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;t\_3 \leq 2 \cdot 10^{-63}:\\
\;\;\;\;\frac{x + \frac{t\_1}{z \cdot t}}{x + 1}\\

\mathbf{elif}\;t\_3 \leq 2:\\
\;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\

\mathbf{elif}\;t\_3 \leq 10^{+205}:\\
\;\;\;\;t\_4\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.9999999999999999e254

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6461.7

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified61.7%

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

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

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

        \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
      3. distribute-lft-inN/A

        \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
      4. *-commutativeN/A

        \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
      5. *-rgt-identityN/A

        \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
      6. accelerator-lowering-fma.f6474.1

        \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
    8. Simplified74.1%

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

    if -1.9999999999999999e254 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1e9 or 2 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000002e205

    1. Initial program 99.5%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf

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

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

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

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

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

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

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

        \[\leadsto \frac{y \cdot z}{\left(t \cdot z - x\right) \cdot \color{blue}{\left(x + 1\right)}} \]
      8. +-lowering-+.f6496.1

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

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

    if -1e9 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 2.00000000000000013e-63

    1. Initial program 93.6%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in t around inf

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

        \[\leadsto \frac{x + \frac{y \cdot z - x}{\color{blue}{t \cdot z}}}{x + 1} \]
    5. Simplified92.9%

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

    if 2.00000000000000013e-63 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 2

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0

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

        \[\leadsto \color{blue}{\frac{x - \frac{x}{t \cdot z - x}}{1 + x}} \]
      2. --lowering--.f64N/A

        \[\leadsto \frac{\color{blue}{x - \frac{x}{t \cdot z - x}}}{1 + x} \]
      3. /-lowering-/.f64N/A

        \[\leadsto \frac{x - \color{blue}{\frac{x}{t \cdot z - x}}}{1 + x} \]
      4. --lowering--.f64N/A

        \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z - x}}}{1 + x} \]
      5. *-lowering-*.f64N/A

        \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z} - x}}{1 + x} \]
      6. +-commutativeN/A

        \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
      7. +-lowering-+.f6499.1

        \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
    5. Simplified99.1%

      \[\leadsto \color{blue}{\frac{x - \frac{x}{t \cdot z - x}}{x + 1}} \]
    6. Step-by-step derivation
      1. sub-negN/A

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

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

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

        \[\leadsto \frac{x - \frac{x}{\color{blue}{\mathsf{fma}\left(z, t, 0 - x\right)}}}{x + 1} \]
      5. --lowering--.f6499.1

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

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

    if 1.00000000000000002e205 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6478.3

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified78.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1000000000:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 2 \cdot 10^{-63}:\\ \;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t}}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 2:\\ \;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 10^{+205}:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 91.4% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := z \cdot t - x\\ t_2 := \frac{x + \frac{z \cdot y - x}{t\_1}}{x + 1}\\ t_3 := \frac{z \cdot y}{\left(x + 1\right) \cdot t\_1}\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;t\_2 \leq -1000000000:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{-63}:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;t\_2 \leq 2:\\ \;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\ \mathbf{elif}\;t\_2 \leq 10^{+205}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* z t) x))
        (t_2 (/ (+ x (/ (- (* z y) x) t_1)) (+ x 1.0)))
        (t_3 (/ (* z y) (* (+ x 1.0) t_1))))
   (if (<= t_2 -2e+254)
     (/ y (fma x t t))
     (if (<= t_2 -1000000000.0)
       t_3
       (if (<= t_2 2e-63)
         (fma (- 1.0 x) (/ y t) x)
         (if (<= t_2 2.0)
           (/ (- x (/ x (fma z t (- 0.0 x)))) (+ x 1.0))
           (if (<= t_2 1e+205) t_3 (/ (+ x (/ y t)) (+ x 1.0)))))))))
double code(double x, double y, double z, double t) {
	double t_1 = (z * t) - x;
	double t_2 = (x + (((z * y) - x) / t_1)) / (x + 1.0);
	double t_3 = (z * y) / ((x + 1.0) * t_1);
	double tmp;
	if (t_2 <= -2e+254) {
		tmp = y / fma(x, t, t);
	} else if (t_2 <= -1000000000.0) {
		tmp = t_3;
	} else if (t_2 <= 2e-63) {
		tmp = fma((1.0 - x), (y / t), x);
	} else if (t_2 <= 2.0) {
		tmp = (x - (x / fma(z, t, (0.0 - x)))) / (x + 1.0);
	} else if (t_2 <= 1e+205) {
		tmp = t_3;
	} else {
		tmp = (x + (y / t)) / (x + 1.0);
	}
	return tmp;
}
function code(x, y, z, t)
	t_1 = Float64(Float64(z * t) - x)
	t_2 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / t_1)) / Float64(x + 1.0))
	t_3 = Float64(Float64(z * y) / Float64(Float64(x + 1.0) * t_1))
	tmp = 0.0
	if (t_2 <= -2e+254)
		tmp = Float64(y / fma(x, t, t));
	elseif (t_2 <= -1000000000.0)
		tmp = t_3;
	elseif (t_2 <= 2e-63)
		tmp = fma(Float64(1.0 - x), Float64(y / t), x);
	elseif (t_2 <= 2.0)
		tmp = Float64(Float64(x - Float64(x / fma(z, t, Float64(0.0 - x)))) / Float64(x + 1.0));
	elseif (t_2 <= 1e+205)
		tmp = t_3;
	else
		tmp = Float64(Float64(x + Float64(y / t)) / Float64(x + 1.0));
	end
	return tmp
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(z * y), $MachinePrecision] / N[(N[(x + 1.0), $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+254], N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, -1000000000.0], t$95$3, If[LessEqual[t$95$2, 2e-63], N[(N[(1.0 - x), $MachinePrecision] * N[(y / t), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t$95$2, 2.0], N[(N[(x - N[(x / N[(z * t + N[(0.0 - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 1e+205], t$95$3, N[(N[(x + N[(y / t), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t\_2 \leq -1000000000:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;t\_2 \leq 2 \cdot 10^{-63}:\\
\;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\

\mathbf{elif}\;t\_2 \leq 2:\\
\;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\

\mathbf{elif}\;t\_2 \leq 10^{+205}:\\
\;\;\;\;t\_3\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.9999999999999999e254

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6461.7

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified61.7%

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

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

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

        \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
      3. distribute-lft-inN/A

        \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
      4. *-commutativeN/A

        \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
      5. *-rgt-identityN/A

        \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
      6. accelerator-lowering-fma.f6474.1

        \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
    8. Simplified74.1%

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

    if -1.9999999999999999e254 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1e9 or 2 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000002e205

    1. Initial program 99.5%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf

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

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

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

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

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

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

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

        \[\leadsto \frac{y \cdot z}{\left(t \cdot z - x\right) \cdot \color{blue}{\left(x + 1\right)}} \]
      8. +-lowering-+.f6496.1

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

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

    if -1e9 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 2.00000000000000013e-63

    1. Initial program 93.6%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6485.7

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified85.7%

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

      \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
    7. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
      3. associate-/l*N/A

        \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
      4. accelerator-lowering-fma.f64N/A

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

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

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

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
      8. /-lowering-/.f64N/A

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

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
      10. +-lowering-+.f6485.7

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
    8. Simplified85.7%

      \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}} \]
    9. Taylor expanded in x around 0

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

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

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

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

        \[\leadsto \frac{y}{t} + x \cdot \color{blue}{\left(-1 \cdot \frac{y}{t} + 1\right)} \]
      5. distribute-lft-inN/A

        \[\leadsto \frac{y}{t} + \color{blue}{\left(x \cdot \left(-1 \cdot \frac{y}{t}\right) + x \cdot 1\right)} \]
      6. mul-1-negN/A

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

        \[\leadsto \frac{y}{t} + \left(\color{blue}{\left(\mathsf{neg}\left(x \cdot \frac{y}{t}\right)\right)} + x \cdot 1\right) \]
      8. associate-/l*N/A

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

        \[\leadsto \frac{y}{t} + \left(\color{blue}{-1 \cdot \frac{x \cdot y}{t}} + x \cdot 1\right) \]
      10. *-rgt-identityN/A

        \[\leadsto \frac{y}{t} + \left(-1 \cdot \frac{x \cdot y}{t} + \color{blue}{x}\right) \]
      11. associate-+r+N/A

        \[\leadsto \color{blue}{\left(\frac{y}{t} + -1 \cdot \frac{x \cdot y}{t}\right) + x} \]
    11. Simplified85.7%

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

    if 2.00000000000000013e-63 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 2

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0

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

        \[\leadsto \color{blue}{\frac{x - \frac{x}{t \cdot z - x}}{1 + x}} \]
      2. --lowering--.f64N/A

        \[\leadsto \frac{\color{blue}{x - \frac{x}{t \cdot z - x}}}{1 + x} \]
      3. /-lowering-/.f64N/A

        \[\leadsto \frac{x - \color{blue}{\frac{x}{t \cdot z - x}}}{1 + x} \]
      4. --lowering--.f64N/A

        \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z - x}}}{1 + x} \]
      5. *-lowering-*.f64N/A

        \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z} - x}}{1 + x} \]
      6. +-commutativeN/A

        \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
      7. +-lowering-+.f6499.1

        \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
    5. Simplified99.1%

      \[\leadsto \color{blue}{\frac{x - \frac{x}{t \cdot z - x}}{x + 1}} \]
    6. Step-by-step derivation
      1. sub-negN/A

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

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

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

        \[\leadsto \frac{x - \frac{x}{\color{blue}{\mathsf{fma}\left(z, t, 0 - x\right)}}}{x + 1} \]
      5. --lowering--.f6499.1

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

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

    if 1.00000000000000002e205 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6478.3

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified78.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1000000000:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 2 \cdot 10^{-63}:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 2:\\ \;\;\;\;\frac{x - \frac{x}{\mathsf{fma}\left(z, t, 0 - x\right)}}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 10^{+205}:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 91.4% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := z \cdot t - x\\ t_2 := \frac{x + \frac{z \cdot y - x}{t\_1}}{x + 1}\\ t_3 := \frac{z \cdot y}{\left(x + 1\right) \cdot t\_1}\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;t\_2 \leq -1000000000:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t\_2 \leq 2 \cdot 10^{-63}:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;t\_2 \leq 2:\\ \;\;\;\;\frac{x + \frac{x}{x - z \cdot t}}{x + 1}\\ \mathbf{elif}\;t\_2 \leq 10^{+205}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* z t) x))
        (t_2 (/ (+ x (/ (- (* z y) x) t_1)) (+ x 1.0)))
        (t_3 (/ (* z y) (* (+ x 1.0) t_1))))
   (if (<= t_2 -2e+254)
     (/ y (fma x t t))
     (if (<= t_2 -1000000000.0)
       t_3
       (if (<= t_2 2e-63)
         (fma (- 1.0 x) (/ y t) x)
         (if (<= t_2 2.0)
           (/ (+ x (/ x (- x (* z t)))) (+ x 1.0))
           (if (<= t_2 1e+205) t_3 (/ (+ x (/ y t)) (+ x 1.0)))))))))
double code(double x, double y, double z, double t) {
	double t_1 = (z * t) - x;
	double t_2 = (x + (((z * y) - x) / t_1)) / (x + 1.0);
	double t_3 = (z * y) / ((x + 1.0) * t_1);
	double tmp;
	if (t_2 <= -2e+254) {
		tmp = y / fma(x, t, t);
	} else if (t_2 <= -1000000000.0) {
		tmp = t_3;
	} else if (t_2 <= 2e-63) {
		tmp = fma((1.0 - x), (y / t), x);
	} else if (t_2 <= 2.0) {
		tmp = (x + (x / (x - (z * t)))) / (x + 1.0);
	} else if (t_2 <= 1e+205) {
		tmp = t_3;
	} else {
		tmp = (x + (y / t)) / (x + 1.0);
	}
	return tmp;
}
function code(x, y, z, t)
	t_1 = Float64(Float64(z * t) - x)
	t_2 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / t_1)) / Float64(x + 1.0))
	t_3 = Float64(Float64(z * y) / Float64(Float64(x + 1.0) * t_1))
	tmp = 0.0
	if (t_2 <= -2e+254)
		tmp = Float64(y / fma(x, t, t));
	elseif (t_2 <= -1000000000.0)
		tmp = t_3;
	elseif (t_2 <= 2e-63)
		tmp = fma(Float64(1.0 - x), Float64(y / t), x);
	elseif (t_2 <= 2.0)
		tmp = Float64(Float64(x + Float64(x / Float64(x - Float64(z * t)))) / Float64(x + 1.0));
	elseif (t_2 <= 1e+205)
		tmp = t_3;
	else
		tmp = Float64(Float64(x + Float64(y / t)) / Float64(x + 1.0));
	end
	return tmp
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(z * y), $MachinePrecision] / N[(N[(x + 1.0), $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+254], N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, -1000000000.0], t$95$3, If[LessEqual[t$95$2, 2e-63], N[(N[(1.0 - x), $MachinePrecision] * N[(y / t), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t$95$2, 2.0], N[(N[(x + N[(x / N[(x - N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 1e+205], t$95$3, N[(N[(x + N[(y / t), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t\_2 \leq -1000000000:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;t\_2 \leq 2 \cdot 10^{-63}:\\
\;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\

\mathbf{elif}\;t\_2 \leq 2:\\
\;\;\;\;\frac{x + \frac{x}{x - z \cdot t}}{x + 1}\\

\mathbf{elif}\;t\_2 \leq 10^{+205}:\\
\;\;\;\;t\_3\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.9999999999999999e254

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6461.7

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified61.7%

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

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

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

        \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
      3. distribute-lft-inN/A

        \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
      4. *-commutativeN/A

        \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
      5. *-rgt-identityN/A

        \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
      6. accelerator-lowering-fma.f6474.1

        \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
    8. Simplified74.1%

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

    if -1.9999999999999999e254 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1e9 or 2 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000002e205

    1. Initial program 99.5%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf

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

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

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

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

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

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

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

        \[\leadsto \frac{y \cdot z}{\left(t \cdot z - x\right) \cdot \color{blue}{\left(x + 1\right)}} \]
      8. +-lowering-+.f6496.1

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

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

    if -1e9 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 2.00000000000000013e-63

    1. Initial program 93.6%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6485.7

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified85.7%

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

      \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
    7. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
      3. associate-/l*N/A

        \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
      4. accelerator-lowering-fma.f64N/A

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

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

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

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
      8. /-lowering-/.f64N/A

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

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
      10. +-lowering-+.f6485.7

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
    8. Simplified85.7%

      \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}} \]
    9. Taylor expanded in x around 0

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

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

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

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

        \[\leadsto \frac{y}{t} + x \cdot \color{blue}{\left(-1 \cdot \frac{y}{t} + 1\right)} \]
      5. distribute-lft-inN/A

        \[\leadsto \frac{y}{t} + \color{blue}{\left(x \cdot \left(-1 \cdot \frac{y}{t}\right) + x \cdot 1\right)} \]
      6. mul-1-negN/A

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

        \[\leadsto \frac{y}{t} + \left(\color{blue}{\left(\mathsf{neg}\left(x \cdot \frac{y}{t}\right)\right)} + x \cdot 1\right) \]
      8. associate-/l*N/A

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

        \[\leadsto \frac{y}{t} + \left(\color{blue}{-1 \cdot \frac{x \cdot y}{t}} + x \cdot 1\right) \]
      10. *-rgt-identityN/A

        \[\leadsto \frac{y}{t} + \left(-1 \cdot \frac{x \cdot y}{t} + \color{blue}{x}\right) \]
      11. associate-+r+N/A

        \[\leadsto \color{blue}{\left(\frac{y}{t} + -1 \cdot \frac{x \cdot y}{t}\right) + x} \]
    11. Simplified85.7%

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

    if 2.00000000000000013e-63 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 2

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around 0

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

        \[\leadsto \color{blue}{\frac{x - \frac{x}{t \cdot z - x}}{1 + x}} \]
      2. --lowering--.f64N/A

        \[\leadsto \frac{\color{blue}{x - \frac{x}{t \cdot z - x}}}{1 + x} \]
      3. /-lowering-/.f64N/A

        \[\leadsto \frac{x - \color{blue}{\frac{x}{t \cdot z - x}}}{1 + x} \]
      4. --lowering--.f64N/A

        \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z - x}}}{1 + x} \]
      5. *-lowering-*.f64N/A

        \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z} - x}}{1 + x} \]
      6. +-commutativeN/A

        \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
      7. +-lowering-+.f6499.1

        \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
    5. Simplified99.1%

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

    if 1.00000000000000002e205 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6478.3

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified78.3%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1000000000:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 2 \cdot 10^{-63}:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 2:\\ \;\;\;\;\frac{x + \frac{x}{x - z \cdot t}}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 10^{+205}:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 90.3% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := z \cdot t - x\\ t_2 := \frac{x + \frac{z \cdot y - x}{t\_1}}{x + 1}\\ t_3 := \frac{z \cdot y}{\left(x + 1\right) \cdot t\_1}\\ t_4 := \frac{x + \frac{y}{t}}{x + 1}\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;t\_2 \leq -1000000000:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t\_2 \leq 0.9999999999999853:\\ \;\;\;\;t\_4\\ \mathbf{elif}\;t\_2 \leq 20:\\ \;\;\;\;\mathsf{fma}\left(0 - y, \frac{z}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \mathbf{elif}\;t\_2 \leq 10^{+205}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;t\_4\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- (* z t) x))
        (t_2 (/ (+ x (/ (- (* z y) x) t_1)) (+ x 1.0)))
        (t_3 (/ (* z y) (* (+ x 1.0) t_1)))
        (t_4 (/ (+ x (/ y t)) (+ x 1.0))))
   (if (<= t_2 -2e+254)
     (/ y (fma x t t))
     (if (<= t_2 -1000000000.0)
       t_3
       (if (<= t_2 0.9999999999999853)
         t_4
         (if (<= t_2 20.0)
           (fma (- 0.0 y) (/ z (fma x x x)) 1.0)
           (if (<= t_2 1e+205) t_3 t_4)))))))
double code(double x, double y, double z, double t) {
	double t_1 = (z * t) - x;
	double t_2 = (x + (((z * y) - x) / t_1)) / (x + 1.0);
	double t_3 = (z * y) / ((x + 1.0) * t_1);
	double t_4 = (x + (y / t)) / (x + 1.0);
	double tmp;
	if (t_2 <= -2e+254) {
		tmp = y / fma(x, t, t);
	} else if (t_2 <= -1000000000.0) {
		tmp = t_3;
	} else if (t_2 <= 0.9999999999999853) {
		tmp = t_4;
	} else if (t_2 <= 20.0) {
		tmp = fma((0.0 - y), (z / fma(x, x, x)), 1.0);
	} else if (t_2 <= 1e+205) {
		tmp = t_3;
	} else {
		tmp = t_4;
	}
	return tmp;
}
function code(x, y, z, t)
	t_1 = Float64(Float64(z * t) - x)
	t_2 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / t_1)) / Float64(x + 1.0))
	t_3 = Float64(Float64(z * y) / Float64(Float64(x + 1.0) * t_1))
	t_4 = Float64(Float64(x + Float64(y / t)) / Float64(x + 1.0))
	tmp = 0.0
	if (t_2 <= -2e+254)
		tmp = Float64(y / fma(x, t, t));
	elseif (t_2 <= -1000000000.0)
		tmp = t_3;
	elseif (t_2 <= 0.9999999999999853)
		tmp = t_4;
	elseif (t_2 <= 20.0)
		tmp = fma(Float64(0.0 - y), Float64(z / fma(x, x, x)), 1.0);
	elseif (t_2 <= 1e+205)
		tmp = t_3;
	else
		tmp = t_4;
	end
	return tmp
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(z * y), $MachinePrecision] / N[(N[(x + 1.0), $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(x + N[(y / t), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+254], N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, -1000000000.0], t$95$3, If[LessEqual[t$95$2, 0.9999999999999853], t$95$4, If[LessEqual[t$95$2, 20.0], N[(N[(0.0 - y), $MachinePrecision] * N[(z / N[(x * x + x), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision], If[LessEqual[t$95$2, 1e+205], t$95$3, t$95$4]]]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;t\_2 \leq -1000000000:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;t\_2 \leq 0.9999999999999853:\\
\;\;\;\;t\_4\\

\mathbf{elif}\;t\_2 \leq 20:\\
\;\;\;\;\mathsf{fma}\left(0 - y, \frac{z}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\

\mathbf{elif}\;t\_2 \leq 10^{+205}:\\
\;\;\;\;t\_3\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.9999999999999999e254

    1. Initial program 31.1%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6461.7

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified61.7%

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

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

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

        \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
      3. distribute-lft-inN/A

        \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
      4. *-commutativeN/A

        \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
      5. *-rgt-identityN/A

        \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
      6. accelerator-lowering-fma.f6474.1

        \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
    8. Simplified74.1%

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

    if -1.9999999999999999e254 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1e9 or 20 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000002e205

    1. Initial program 99.5%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf

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

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

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

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

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

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

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

        \[\leadsto \frac{y \cdot z}{\left(t \cdot z - x\right) \cdot \color{blue}{\left(x + 1\right)}} \]
      8. +-lowering-+.f6497.8

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

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

    if -1e9 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 0.99999999999998535 or 1.00000000000000002e205 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

    1. Initial program 75.8%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6480.7

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified80.7%

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

    if 0.99999999999998535 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 20

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in t around 0

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

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

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

        \[\leadsto \frac{x + \color{blue}{\left(0 - \frac{y \cdot z - x}{x}\right)}}{x + 1} \]
      4. div-subN/A

        \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} - \frac{x}{x}\right)}\right)}{x + 1} \]
      5. sub-negN/A

        \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)}\right)}{x + 1} \]
      6. associate-/l*N/A

        \[\leadsto \frac{x + \left(0 - \left(\color{blue}{y \cdot \frac{z}{x}} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)\right)}{x + 1} \]
      7. *-inversesN/A

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

        \[\leadsto \frac{x + \left(0 - \left(y \cdot \frac{z}{x} + \color{blue}{-1}\right)\right)}{x + 1} \]
      9. accelerator-lowering-fma.f64N/A

        \[\leadsto \frac{x + \left(0 - \color{blue}{\mathsf{fma}\left(y, \frac{z}{x}, -1\right)}\right)}{x + 1} \]
      10. /-lowering-/.f6499.5

        \[\leadsto \frac{x + \left(0 - \mathsf{fma}\left(y, \color{blue}{\frac{z}{x}}, -1\right)\right)}{x + 1} \]
    5. Simplified99.5%

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

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

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

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

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

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

        \[\leadsto \color{blue}{\left(-1 \cdot y\right)} \cdot \frac{z}{x \cdot \left(1 + x\right)} + 1 \]
      6. accelerator-lowering-fma.f64N/A

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

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{neg}\left(y\right)}, \frac{z}{x \cdot \left(1 + x\right)}, 1\right) \]
      8. neg-sub0N/A

        \[\leadsto \mathsf{fma}\left(\color{blue}{0 - y}, \frac{z}{x \cdot \left(1 + x\right)}, 1\right) \]
      9. --lowering--.f64N/A

        \[\leadsto \mathsf{fma}\left(\color{blue}{0 - y}, \frac{z}{x \cdot \left(1 + x\right)}, 1\right) \]
      10. /-lowering-/.f64N/A

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

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

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

        \[\leadsto \mathsf{fma}\left(0 - y, \frac{z}{x \cdot x + \color{blue}{x}}, 1\right) \]
      14. accelerator-lowering-fma.f6499.5

        \[\leadsto \mathsf{fma}\left(0 - y, \frac{z}{\color{blue}{\mathsf{fma}\left(x, x, x\right)}}, 1\right) \]
    8. Simplified99.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1000000000:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 0.9999999999999853:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 20:\\ \;\;\;\;\mathsf{fma}\left(0 - y, \frac{z}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 10^{+205}:\\ \;\;\;\;\frac{z \cdot y}{\left(x + 1\right) \cdot \left(z \cdot t - x\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 82.9% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+100}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;t\_1 \leq 0.0001:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;t\_1 \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{y}{x + 1}}{t}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))))
   (if (<= t_1 -1e+100)
     (/ y (fma x t t))
     (if (<= t_1 0.0001)
       (fma (- 1.0 x) (/ y t) x)
       (if (<= t_1 20.0) 1.0 (/ (/ y (+ x 1.0)) t))))))
double code(double x, double y, double z, double t) {
	double t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
	double tmp;
	if (t_1 <= -1e+100) {
		tmp = y / fma(x, t, t);
	} else if (t_1 <= 0.0001) {
		tmp = fma((1.0 - x), (y / t), x);
	} else if (t_1 <= 20.0) {
		tmp = 1.0;
	} else {
		tmp = (y / (x + 1.0)) / t;
	}
	return tmp;
}
function code(x, y, z, t)
	t_1 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0))
	tmp = 0.0
	if (t_1 <= -1e+100)
		tmp = Float64(y / fma(x, t, t));
	elseif (t_1 <= 0.0001)
		tmp = fma(Float64(1.0 - x), Float64(y / t), x);
	elseif (t_1 <= 20.0)
		tmp = 1.0;
	else
		tmp = Float64(Float64(y / Float64(x + 1.0)) / t);
	end
	return tmp
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -1e+100], N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 0.0001], N[(N[(1.0 - x), $MachinePrecision] * N[(y / t), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t$95$1, 20.0], 1.0, N[(N[(y / N[(x + 1.0), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
\mathbf{if}\;t\_1 \leq -1 \cdot 10^{+100}:\\
\;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\

\mathbf{elif}\;t\_1 \leq 0.0001:\\
\;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\

\mathbf{elif}\;t\_1 \leq 20:\\
\;\;\;\;1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.00000000000000002e100

    1. Initial program 63.0%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6466.4

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified66.4%

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

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

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

        \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
      3. distribute-lft-inN/A

        \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
      4. *-commutativeN/A

        \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
      5. *-rgt-identityN/A

        \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
      6. accelerator-lowering-fma.f6473.1

        \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
    8. Simplified73.1%

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

    if -1.00000000000000002e100 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000005e-4

    1. Initial program 95.3%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf

      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
    4. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
      4. /-lowering-/.f64N/A

        \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
      5. +-commutativeN/A

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      6. +-lowering-+.f6476.3

        \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
    5. Simplified76.3%

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

      \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
    7. Step-by-step derivation
      1. /-lowering-/.f64N/A

        \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
      2. +-commutativeN/A

        \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
      3. associate-/l*N/A

        \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
      4. accelerator-lowering-fma.f64N/A

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

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

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

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
      8. /-lowering-/.f64N/A

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

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
      10. +-lowering-+.f6476.2

        \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
    8. Simplified76.2%

      \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}} \]
    9. Taylor expanded in x around 0

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

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

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

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

        \[\leadsto \frac{y}{t} + x \cdot \color{blue}{\left(-1 \cdot \frac{y}{t} + 1\right)} \]
      5. distribute-lft-inN/A

        \[\leadsto \frac{y}{t} + \color{blue}{\left(x \cdot \left(-1 \cdot \frac{y}{t}\right) + x \cdot 1\right)} \]
      6. mul-1-negN/A

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

        \[\leadsto \frac{y}{t} + \left(\color{blue}{\left(\mathsf{neg}\left(x \cdot \frac{y}{t}\right)\right)} + x \cdot 1\right) \]
      8. associate-/l*N/A

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

        \[\leadsto \frac{y}{t} + \left(\color{blue}{-1 \cdot \frac{x \cdot y}{t}} + x \cdot 1\right) \]
      10. *-rgt-identityN/A

        \[\leadsto \frac{y}{t} + \left(-1 \cdot \frac{x \cdot y}{t} + \color{blue}{x}\right) \]
      11. associate-+r+N/A

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

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

    if 1.00000000000000005e-4 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 20

    1. Initial program 100.0%

      \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf

      \[\leadsto \color{blue}{1} \]
    4. Step-by-step derivation
      1. Simplified97.3%

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

      if 20 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

      1. Initial program 59.5%

        \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
      2. Add Preprocessing
      3. Taylor expanded in z around inf

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      4. Step-by-step derivation
        1. /-lowering-/.f64N/A

          \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
        2. +-commutativeN/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
        3. +-lowering-+.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
        4. /-lowering-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
        5. +-commutativeN/A

          \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
        6. +-lowering-+.f6470.8

          \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      5. Simplified70.8%

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

        \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
      7. Step-by-step derivation
        1. /-lowering-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
        2. +-commutativeN/A

          \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
        3. associate-/l*N/A

          \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
        4. accelerator-lowering-fma.f64N/A

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

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

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

          \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
        8. /-lowering-/.f64N/A

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

          \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
        10. +-lowering-+.f6470.9

          \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
      8. Simplified70.9%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}} \]
      9. Taylor expanded in t around 0

        \[\leadsto \frac{\color{blue}{\frac{y}{1 + x}}}{t} \]
      10. Step-by-step derivation
        1. /-lowering-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{y}{1 + x}}}{t} \]
        2. +-lowering-+.f6457.8

          \[\leadsto \frac{\frac{y}{\color{blue}{1 + x}}}{t} \]
      11. Simplified57.8%

        \[\leadsto \frac{\color{blue}{\frac{y}{1 + x}}}{t} \]
    5. Recombined 4 regimes into one program.
    6. Final simplification82.7%

      \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1 \cdot 10^{+100}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 0.0001:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{y}{x + 1}}{t}\\ \end{array} \]
    7. Add Preprocessing

    Alternative 8: 82.8% accurate, 0.3× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+100}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;t\_1 \leq 0.0001:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;t\_1 \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{y}{t}}{x + 1}\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (let* ((t_1 (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))))
       (if (<= t_1 -1e+100)
         (/ y (fma x t t))
         (if (<= t_1 0.0001)
           (fma (- 1.0 x) (/ y t) x)
           (if (<= t_1 20.0) 1.0 (/ (/ y t) (+ x 1.0)))))))
    double code(double x, double y, double z, double t) {
    	double t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
    	double tmp;
    	if (t_1 <= -1e+100) {
    		tmp = y / fma(x, t, t);
    	} else if (t_1 <= 0.0001) {
    		tmp = fma((1.0 - x), (y / t), x);
    	} else if (t_1 <= 20.0) {
    		tmp = 1.0;
    	} else {
    		tmp = (y / t) / (x + 1.0);
    	}
    	return tmp;
    }
    
    function code(x, y, z, t)
    	t_1 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0))
    	tmp = 0.0
    	if (t_1 <= -1e+100)
    		tmp = Float64(y / fma(x, t, t));
    	elseif (t_1 <= 0.0001)
    		tmp = fma(Float64(1.0 - x), Float64(y / t), x);
    	elseif (t_1 <= 20.0)
    		tmp = 1.0;
    	else
    		tmp = Float64(Float64(y / t) / Float64(x + 1.0));
    	end
    	return tmp
    end
    
    code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -1e+100], N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 0.0001], N[(N[(1.0 - x), $MachinePrecision] * N[(y / t), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t$95$1, 20.0], 1.0, N[(N[(y / t), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]]]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
    \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+100}:\\
    \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\
    
    \mathbf{elif}\;t\_1 \leq 0.0001:\\
    \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\
    
    \mathbf{elif}\;t\_1 \leq 20:\\
    \;\;\;\;1\\
    
    \mathbf{else}:\\
    \;\;\;\;\frac{\frac{y}{t}}{x + 1}\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 4 regimes
    2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.00000000000000002e100

      1. Initial program 63.0%

        \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
      2. Add Preprocessing
      3. Taylor expanded in z around inf

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      4. Step-by-step derivation
        1. /-lowering-/.f64N/A

          \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
        2. +-commutativeN/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
        3. +-lowering-+.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
        4. /-lowering-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
        5. +-commutativeN/A

          \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
        6. +-lowering-+.f6466.4

          \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      5. Simplified66.4%

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

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

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

          \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
        3. distribute-lft-inN/A

          \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
        4. *-commutativeN/A

          \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
        5. *-rgt-identityN/A

          \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
        6. accelerator-lowering-fma.f6473.1

          \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
      8. Simplified73.1%

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

      if -1.00000000000000002e100 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000005e-4

      1. Initial program 95.3%

        \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
      2. Add Preprocessing
      3. Taylor expanded in z around inf

        \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
      4. Step-by-step derivation
        1. /-lowering-/.f64N/A

          \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
        2. +-commutativeN/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
        3. +-lowering-+.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
        4. /-lowering-/.f64N/A

          \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
        5. +-commutativeN/A

          \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
        6. +-lowering-+.f6476.3

          \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
      5. Simplified76.3%

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

        \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
      7. Step-by-step derivation
        1. /-lowering-/.f64N/A

          \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
        2. +-commutativeN/A

          \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
        3. associate-/l*N/A

          \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
        4. accelerator-lowering-fma.f64N/A

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

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

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

          \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
        8. /-lowering-/.f64N/A

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

          \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
        10. +-lowering-+.f6476.2

          \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
      8. Simplified76.2%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}} \]
      9. Taylor expanded in x around 0

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

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

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

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

          \[\leadsto \frac{y}{t} + x \cdot \color{blue}{\left(-1 \cdot \frac{y}{t} + 1\right)} \]
        5. distribute-lft-inN/A

          \[\leadsto \frac{y}{t} + \color{blue}{\left(x \cdot \left(-1 \cdot \frac{y}{t}\right) + x \cdot 1\right)} \]
        6. mul-1-negN/A

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

          \[\leadsto \frac{y}{t} + \left(\color{blue}{\left(\mathsf{neg}\left(x \cdot \frac{y}{t}\right)\right)} + x \cdot 1\right) \]
        8. associate-/l*N/A

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

          \[\leadsto \frac{y}{t} + \left(\color{blue}{-1 \cdot \frac{x \cdot y}{t}} + x \cdot 1\right) \]
        10. *-rgt-identityN/A

          \[\leadsto \frac{y}{t} + \left(-1 \cdot \frac{x \cdot y}{t} + \color{blue}{x}\right) \]
        11. associate-+r+N/A

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

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

      if 1.00000000000000005e-4 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 20

      1. Initial program 100.0%

        \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
      2. Add Preprocessing
      3. Taylor expanded in x around inf

        \[\leadsto \color{blue}{1} \]
      4. Step-by-step derivation
        1. Simplified97.3%

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

        if 20 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

        1. Initial program 59.5%

          \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
        2. Add Preprocessing
        3. Taylor expanded in x around 0

          \[\leadsto \frac{\color{blue}{\frac{y}{t}}}{x + 1} \]
        4. Step-by-step derivation
          1. /-lowering-/.f6457.6

            \[\leadsto \frac{\color{blue}{\frac{y}{t}}}{x + 1} \]
        5. Simplified57.6%

          \[\leadsto \frac{\color{blue}{\frac{y}{t}}}{x + 1} \]
      5. Recombined 4 regimes into one program.
      6. Final simplification82.7%

        \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1 \cdot 10^{+100}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 0.0001:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{y}{t}}{x + 1}\\ \end{array} \]
      7. Add Preprocessing

      Alternative 9: 82.9% accurate, 0.3× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ t_2 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{if}\;t\_2 \leq -1 \cdot 10^{+100}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 0.0001:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;t\_2 \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
      (FPCore (x y z t)
       :precision binary64
       (let* ((t_1 (/ y (fma x t t)))
              (t_2 (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))))
         (if (<= t_2 -1e+100)
           t_1
           (if (<= t_2 0.0001)
             (fma (- 1.0 x) (/ y t) x)
             (if (<= t_2 20.0) 1.0 t_1)))))
      double code(double x, double y, double z, double t) {
      	double t_1 = y / fma(x, t, t);
      	double t_2 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
      	double tmp;
      	if (t_2 <= -1e+100) {
      		tmp = t_1;
      	} else if (t_2 <= 0.0001) {
      		tmp = fma((1.0 - x), (y / t), x);
      	} else if (t_2 <= 20.0) {
      		tmp = 1.0;
      	} else {
      		tmp = t_1;
      	}
      	return tmp;
      }
      
      function code(x, y, z, t)
      	t_1 = Float64(y / fma(x, t, t))
      	t_2 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0))
      	tmp = 0.0
      	if (t_2 <= -1e+100)
      		tmp = t_1;
      	elseif (t_2 <= 0.0001)
      		tmp = fma(Float64(1.0 - x), Float64(y / t), x);
      	elseif (t_2 <= 20.0)
      		tmp = 1.0;
      	else
      		tmp = t_1;
      	end
      	return tmp
      end
      
      code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -1e+100], t$95$1, If[LessEqual[t$95$2, 0.0001], N[(N[(1.0 - x), $MachinePrecision] * N[(y / t), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t$95$2, 20.0], 1.0, t$95$1]]]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      t_1 := \frac{y}{\mathsf{fma}\left(x, t, t\right)}\\
      t_2 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
      \mathbf{if}\;t\_2 \leq -1 \cdot 10^{+100}:\\
      \;\;\;\;t\_1\\
      
      \mathbf{elif}\;t\_2 \leq 0.0001:\\
      \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\
      
      \mathbf{elif}\;t\_2 \leq 20:\\
      \;\;\;\;1\\
      
      \mathbf{else}:\\
      \;\;\;\;t\_1\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.00000000000000002e100 or 20 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

        1. Initial program 60.9%

          \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
        2. Add Preprocessing
        3. Taylor expanded in z around inf

          \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
        4. Step-by-step derivation
          1. /-lowering-/.f64N/A

            \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
          2. +-commutativeN/A

            \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
          3. +-lowering-+.f64N/A

            \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
          4. /-lowering-/.f64N/A

            \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
          5. +-commutativeN/A

            \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
          6. +-lowering-+.f6469.0

            \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
        5. Simplified69.0%

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

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

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

            \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
          3. distribute-lft-inN/A

            \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
          4. *-commutativeN/A

            \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
          5. *-rgt-identityN/A

            \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
          6. accelerator-lowering-fma.f6463.9

            \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
        8. Simplified63.9%

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

        if -1.00000000000000002e100 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000005e-4

        1. Initial program 95.3%

          \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
        2. Add Preprocessing
        3. Taylor expanded in z around inf

          \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
        4. Step-by-step derivation
          1. /-lowering-/.f64N/A

            \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
          2. +-commutativeN/A

            \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
          3. +-lowering-+.f64N/A

            \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
          4. /-lowering-/.f64N/A

            \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
          5. +-commutativeN/A

            \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
          6. +-lowering-+.f6476.3

            \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
        5. Simplified76.3%

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

          \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
        7. Step-by-step derivation
          1. /-lowering-/.f64N/A

            \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
          2. +-commutativeN/A

            \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
          3. associate-/l*N/A

            \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
          4. accelerator-lowering-fma.f64N/A

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

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

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

            \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
          8. /-lowering-/.f64N/A

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

            \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
          10. +-lowering-+.f6476.2

            \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
        8. Simplified76.2%

          \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}} \]
        9. Taylor expanded in x around 0

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

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

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

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

            \[\leadsto \frac{y}{t} + x \cdot \color{blue}{\left(-1 \cdot \frac{y}{t} + 1\right)} \]
          5. distribute-lft-inN/A

            \[\leadsto \frac{y}{t} + \color{blue}{\left(x \cdot \left(-1 \cdot \frac{y}{t}\right) + x \cdot 1\right)} \]
          6. mul-1-negN/A

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

            \[\leadsto \frac{y}{t} + \left(\color{blue}{\left(\mathsf{neg}\left(x \cdot \frac{y}{t}\right)\right)} + x \cdot 1\right) \]
          8. associate-/l*N/A

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

            \[\leadsto \frac{y}{t} + \left(\color{blue}{-1 \cdot \frac{x \cdot y}{t}} + x \cdot 1\right) \]
          10. *-rgt-identityN/A

            \[\leadsto \frac{y}{t} + \left(-1 \cdot \frac{x \cdot y}{t} + \color{blue}{x}\right) \]
          11. associate-+r+N/A

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

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

        if 1.00000000000000005e-4 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 20

        1. Initial program 100.0%

          \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
        2. Add Preprocessing
        3. Taylor expanded in x around inf

          \[\leadsto \color{blue}{1} \]
        4. Step-by-step derivation
          1. Simplified97.3%

            \[\leadsto \color{blue}{1} \]
        5. Recombined 3 regimes into one program.
        6. Final simplification82.7%

          \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1 \cdot 10^{+100}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 0.0001:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \end{array} \]
        7. Add Preprocessing

        Alternative 10: 78.8% accurate, 0.3× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ t_2 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{if}\;t\_2 \leq -1 \cdot 10^{-46}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 0.0001:\\ \;\;\;\;x - \frac{x}{z \cdot t}\\ \mathbf{elif}\;t\_2 \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
        (FPCore (x y z t)
         :precision binary64
         (let* ((t_1 (/ y (fma x t t)))
                (t_2 (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))))
           (if (<= t_2 -1e-46)
             t_1
             (if (<= t_2 0.0001) (- x (/ x (* z t))) (if (<= t_2 20.0) 1.0 t_1)))))
        double code(double x, double y, double z, double t) {
        	double t_1 = y / fma(x, t, t);
        	double t_2 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
        	double tmp;
        	if (t_2 <= -1e-46) {
        		tmp = t_1;
        	} else if (t_2 <= 0.0001) {
        		tmp = x - (x / (z * t));
        	} else if (t_2 <= 20.0) {
        		tmp = 1.0;
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        function code(x, y, z, t)
        	t_1 = Float64(y / fma(x, t, t))
        	t_2 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0))
        	tmp = 0.0
        	if (t_2 <= -1e-46)
        		tmp = t_1;
        	elseif (t_2 <= 0.0001)
        		tmp = Float64(x - Float64(x / Float64(z * t)));
        	elseif (t_2 <= 20.0)
        		tmp = 1.0;
        	else
        		tmp = t_1;
        	end
        	return tmp
        end
        
        code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -1e-46], t$95$1, If[LessEqual[t$95$2, 0.0001], N[(x - N[(x / N[(z * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 20.0], 1.0, t$95$1]]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \frac{y}{\mathsf{fma}\left(x, t, t\right)}\\
        t_2 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
        \mathbf{if}\;t\_2 \leq -1 \cdot 10^{-46}:\\
        \;\;\;\;t\_1\\
        
        \mathbf{elif}\;t\_2 \leq 0.0001:\\
        \;\;\;\;x - \frac{x}{z \cdot t}\\
        
        \mathbf{elif}\;t\_2 \leq 20:\\
        \;\;\;\;1\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_1\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.00000000000000002e-46 or 20 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

          1. Initial program 69.5%

            \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
          2. Add Preprocessing
          3. Taylor expanded in z around inf

            \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
          4. Step-by-step derivation
            1. /-lowering-/.f64N/A

              \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
            2. +-commutativeN/A

              \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
            3. +-lowering-+.f64N/A

              \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
            4. /-lowering-/.f64N/A

              \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
            5. +-commutativeN/A

              \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
            6. +-lowering-+.f6466.1

              \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
          5. Simplified66.1%

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

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

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

              \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
            3. distribute-lft-inN/A

              \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
            4. *-commutativeN/A

              \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
            5. *-rgt-identityN/A

              \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
            6. accelerator-lowering-fma.f6461.1

              \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
          8. Simplified61.1%

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

          if -1.00000000000000002e-46 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000005e-4

          1. Initial program 93.4%

            \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
          2. Add Preprocessing
          3. Taylor expanded in y around 0

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

              \[\leadsto \color{blue}{\frac{x - \frac{x}{t \cdot z - x}}{1 + x}} \]
            2. --lowering--.f64N/A

              \[\leadsto \frac{\color{blue}{x - \frac{x}{t \cdot z - x}}}{1 + x} \]
            3. /-lowering-/.f64N/A

              \[\leadsto \frac{x - \color{blue}{\frac{x}{t \cdot z - x}}}{1 + x} \]
            4. --lowering--.f64N/A

              \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z - x}}}{1 + x} \]
            5. *-lowering-*.f64N/A

              \[\leadsto \frac{x - \frac{x}{\color{blue}{t \cdot z} - x}}{1 + x} \]
            6. +-commutativeN/A

              \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
            7. +-lowering-+.f6468.4

              \[\leadsto \frac{x - \frac{x}{t \cdot z - x}}{\color{blue}{x + 1}} \]
          5. Simplified68.4%

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

            \[\leadsto \color{blue}{x \cdot \left(1 - \frac{1}{t \cdot z}\right)} \]
          7. Step-by-step derivation
            1. sub-negN/A

              \[\leadsto x \cdot \color{blue}{\left(1 + \left(\mathsf{neg}\left(\frac{1}{t \cdot z}\right)\right)\right)} \]
            2. distribute-lft-inN/A

              \[\leadsto \color{blue}{x \cdot 1 + x \cdot \left(\mathsf{neg}\left(\frac{1}{t \cdot z}\right)\right)} \]
            3. *-rgt-identityN/A

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

              \[\leadsto x + \color{blue}{\left(\mathsf{neg}\left(x \cdot \frac{1}{t \cdot z}\right)\right)} \]
            5. associate-*r/N/A

              \[\leadsto x + \left(\mathsf{neg}\left(\color{blue}{\frac{x \cdot 1}{t \cdot z}}\right)\right) \]
            6. *-rgt-identityN/A

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

              \[\leadsto x + \color{blue}{-1 \cdot \frac{x}{t \cdot z}} \]
            8. mul-1-negN/A

              \[\leadsto x + \color{blue}{\left(\mathsf{neg}\left(\frac{x}{t \cdot z}\right)\right)} \]
            9. unsub-negN/A

              \[\leadsto \color{blue}{x - \frac{x}{t \cdot z}} \]
            10. --lowering--.f64N/A

              \[\leadsto \color{blue}{x - \frac{x}{t \cdot z}} \]
            11. /-lowering-/.f64N/A

              \[\leadsto x - \color{blue}{\frac{x}{t \cdot z}} \]
            12. *-lowering-*.f6467.1

              \[\leadsto x - \frac{x}{\color{blue}{t \cdot z}} \]
          8. Simplified67.1%

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

          if 1.00000000000000005e-4 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 20

          1. Initial program 100.0%

            \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
          2. Add Preprocessing
          3. Taylor expanded in x around inf

            \[\leadsto \color{blue}{1} \]
          4. Step-by-step derivation
            1. Simplified97.3%

              \[\leadsto \color{blue}{1} \]
          5. Recombined 3 regimes into one program.
          6. Final simplification79.4%

            \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -1 \cdot 10^{-46}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 0.0001:\\ \;\;\;\;x - \frac{x}{z \cdot t}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \end{array} \]
          7. Add Preprocessing

          Alternative 11: 76.6% accurate, 0.3× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ t_2 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{-71}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq 0.999995:\\ \;\;\;\;\frac{x}{x + 1}\\ \mathbf{elif}\;t\_2 \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
          (FPCore (x y z t)
           :precision binary64
           (let* ((t_1 (/ y (fma x t t)))
                  (t_2 (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))))
             (if (<= t_2 -2e-71)
               t_1
               (if (<= t_2 0.999995) (/ x (+ x 1.0)) (if (<= t_2 20.0) 1.0 t_1)))))
          double code(double x, double y, double z, double t) {
          	double t_1 = y / fma(x, t, t);
          	double t_2 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
          	double tmp;
          	if (t_2 <= -2e-71) {
          		tmp = t_1;
          	} else if (t_2 <= 0.999995) {
          		tmp = x / (x + 1.0);
          	} else if (t_2 <= 20.0) {
          		tmp = 1.0;
          	} else {
          		tmp = t_1;
          	}
          	return tmp;
          }
          
          function code(x, y, z, t)
          	t_1 = Float64(y / fma(x, t, t))
          	t_2 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0))
          	tmp = 0.0
          	if (t_2 <= -2e-71)
          		tmp = t_1;
          	elseif (t_2 <= 0.999995)
          		tmp = Float64(x / Float64(x + 1.0));
          	elseif (t_2 <= 20.0)
          		tmp = 1.0;
          	else
          		tmp = t_1;
          	end
          	return tmp
          end
          
          code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e-71], t$95$1, If[LessEqual[t$95$2, 0.999995], N[(x / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 20.0], 1.0, t$95$1]]]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          t_1 := \frac{y}{\mathsf{fma}\left(x, t, t\right)}\\
          t_2 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
          \mathbf{if}\;t\_2 \leq -2 \cdot 10^{-71}:\\
          \;\;\;\;t\_1\\
          
          \mathbf{elif}\;t\_2 \leq 0.999995:\\
          \;\;\;\;\frac{x}{x + 1}\\
          
          \mathbf{elif}\;t\_2 \leq 20:\\
          \;\;\;\;1\\
          
          \mathbf{else}:\\
          \;\;\;\;t\_1\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.9999999999999998e-71 or 20 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

            1. Initial program 72.6%

              \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
            2. Add Preprocessing
            3. Taylor expanded in z around inf

              \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
            4. Step-by-step derivation
              1. /-lowering-/.f64N/A

                \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
              2. +-commutativeN/A

                \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
              3. +-lowering-+.f64N/A

                \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
              4. /-lowering-/.f64N/A

                \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
              5. +-commutativeN/A

                \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
              6. +-lowering-+.f6468.6

                \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
            5. Simplified68.6%

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

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

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

                \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
              3. distribute-lft-inN/A

                \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
              4. *-commutativeN/A

                \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
              5. *-rgt-identityN/A

                \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
              6. accelerator-lowering-fma.f6460.1

                \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
            8. Simplified60.1%

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

            if -1.9999999999999998e-71 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 0.99999499999999997

            1. Initial program 92.0%

              \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
            2. Add Preprocessing
            3. Taylor expanded in t around inf

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

                \[\leadsto \color{blue}{\frac{x}{1 + x}} \]
              2. +-commutativeN/A

                \[\leadsto \frac{x}{\color{blue}{x + 1}} \]
              3. +-lowering-+.f6460.5

                \[\leadsto \frac{x}{\color{blue}{x + 1}} \]
            5. Simplified60.5%

              \[\leadsto \color{blue}{\frac{x}{x + 1}} \]

            if 0.99999499999999997 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 20

            1. Initial program 100.0%

              \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
            2. Add Preprocessing
            3. Taylor expanded in x around inf

              \[\leadsto \color{blue}{1} \]
            4. Step-by-step derivation
              1. Simplified98.2%

                \[\leadsto \color{blue}{1} \]
            5. Recombined 3 regimes into one program.
            6. Final simplification78.0%

              \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -2 \cdot 10^{-71}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 0.999995:\\ \;\;\;\;\frac{x}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \end{array} \]
            7. Add Preprocessing

            Alternative 12: 74.6% accurate, 0.3× speedup?

            \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{-71}:\\ \;\;\;\;\frac{y}{t}\\ \mathbf{elif}\;t\_1 \leq 0.999995:\\ \;\;\;\;\frac{x}{x + 1}\\ \mathbf{elif}\;t\_1 \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t}\\ \end{array} \end{array} \]
            (FPCore (x y z t)
             :precision binary64
             (let* ((t_1 (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))))
               (if (<= t_1 -2e-71)
                 (/ y t)
                 (if (<= t_1 0.999995) (/ x (+ x 1.0)) (if (<= t_1 20.0) 1.0 (/ y t))))))
            double code(double x, double y, double z, double t) {
            	double t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
            	double tmp;
            	if (t_1 <= -2e-71) {
            		tmp = y / t;
            	} else if (t_1 <= 0.999995) {
            		tmp = x / (x + 1.0);
            	} else if (t_1 <= 20.0) {
            		tmp = 1.0;
            	} else {
            		tmp = y / t;
            	}
            	return tmp;
            }
            
            real(8) function code(x, y, z, t)
                real(8), intent (in) :: x
                real(8), intent (in) :: y
                real(8), intent (in) :: z
                real(8), intent (in) :: t
                real(8) :: t_1
                real(8) :: tmp
                t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0d0)
                if (t_1 <= (-2d-71)) then
                    tmp = y / t
                else if (t_1 <= 0.999995d0) then
                    tmp = x / (x + 1.0d0)
                else if (t_1 <= 20.0d0) then
                    tmp = 1.0d0
                else
                    tmp = y / t
                end if
                code = tmp
            end function
            
            public static double code(double x, double y, double z, double t) {
            	double t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
            	double tmp;
            	if (t_1 <= -2e-71) {
            		tmp = y / t;
            	} else if (t_1 <= 0.999995) {
            		tmp = x / (x + 1.0);
            	} else if (t_1 <= 20.0) {
            		tmp = 1.0;
            	} else {
            		tmp = y / t;
            	}
            	return tmp;
            }
            
            def code(x, y, z, t):
            	t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0)
            	tmp = 0
            	if t_1 <= -2e-71:
            		tmp = y / t
            	elif t_1 <= 0.999995:
            		tmp = x / (x + 1.0)
            	elif t_1 <= 20.0:
            		tmp = 1.0
            	else:
            		tmp = y / t
            	return tmp
            
            function code(x, y, z, t)
            	t_1 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0))
            	tmp = 0.0
            	if (t_1 <= -2e-71)
            		tmp = Float64(y / t);
            	elseif (t_1 <= 0.999995)
            		tmp = Float64(x / Float64(x + 1.0));
            	elseif (t_1 <= 20.0)
            		tmp = 1.0;
            	else
            		tmp = Float64(y / t);
            	end
            	return tmp
            end
            
            function tmp_2 = code(x, y, z, t)
            	t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
            	tmp = 0.0;
            	if (t_1 <= -2e-71)
            		tmp = y / t;
            	elseif (t_1 <= 0.999995)
            		tmp = x / (x + 1.0);
            	elseif (t_1 <= 20.0)
            		tmp = 1.0;
            	else
            		tmp = y / t;
            	end
            	tmp_2 = tmp;
            end
            
            code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -2e-71], N[(y / t), $MachinePrecision], If[LessEqual[t$95$1, 0.999995], N[(x / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 20.0], 1.0, N[(y / t), $MachinePrecision]]]]]
            
            \begin{array}{l}
            
            \\
            \begin{array}{l}
            t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
            \mathbf{if}\;t\_1 \leq -2 \cdot 10^{-71}:\\
            \;\;\;\;\frac{y}{t}\\
            
            \mathbf{elif}\;t\_1 \leq 0.999995:\\
            \;\;\;\;\frac{x}{x + 1}\\
            
            \mathbf{elif}\;t\_1 \leq 20:\\
            \;\;\;\;1\\
            
            \mathbf{else}:\\
            \;\;\;\;\frac{y}{t}\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 3 regimes
            2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.9999999999999998e-71 or 20 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

              1. Initial program 72.6%

                \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
              2. Add Preprocessing
              3. Taylor expanded in x around 0

                \[\leadsto \color{blue}{\frac{y}{t}} \]
              4. Step-by-step derivation
                1. /-lowering-/.f6452.7

                  \[\leadsto \color{blue}{\frac{y}{t}} \]
              5. Simplified52.7%

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

              if -1.9999999999999998e-71 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 0.99999499999999997

              1. Initial program 92.0%

                \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
              2. Add Preprocessing
              3. Taylor expanded in t around inf

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

                  \[\leadsto \color{blue}{\frac{x}{1 + x}} \]
                2. +-commutativeN/A

                  \[\leadsto \frac{x}{\color{blue}{x + 1}} \]
                3. +-lowering-+.f6460.5

                  \[\leadsto \frac{x}{\color{blue}{x + 1}} \]
              5. Simplified60.5%

                \[\leadsto \color{blue}{\frac{x}{x + 1}} \]

              if 0.99999499999999997 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 20

              1. Initial program 100.0%

                \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
              2. Add Preprocessing
              3. Taylor expanded in x around inf

                \[\leadsto \color{blue}{1} \]
              4. Step-by-step derivation
                1. Simplified98.2%

                  \[\leadsto \color{blue}{1} \]
              5. Recombined 3 regimes into one program.
              6. Final simplification75.1%

                \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -2 \cdot 10^{-71}:\\ \;\;\;\;\frac{y}{t}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 0.999995:\\ \;\;\;\;\frac{x}{x + 1}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t}\\ \end{array} \]
              7. Add Preprocessing

              Alternative 13: 95.1% accurate, 0.3× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;t\_1 \leq 10^{+205}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \end{array} \]
              (FPCore (x y z t)
               :precision binary64
               (let* ((t_1 (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))))
                 (if (<= t_1 -2e+254)
                   (/ y (fma x t t))
                   (if (<= t_1 1e+205) t_1 (/ (+ x (/ y t)) (+ x 1.0))))))
              double code(double x, double y, double z, double t) {
              	double t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
              	double tmp;
              	if (t_1 <= -2e+254) {
              		tmp = y / fma(x, t, t);
              	} else if (t_1 <= 1e+205) {
              		tmp = t_1;
              	} else {
              		tmp = (x + (y / t)) / (x + 1.0);
              	}
              	return tmp;
              }
              
              function code(x, y, z, t)
              	t_1 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0))
              	tmp = 0.0
              	if (t_1 <= -2e+254)
              		tmp = Float64(y / fma(x, t, t));
              	elseif (t_1 <= 1e+205)
              		tmp = t_1;
              	else
              		tmp = Float64(Float64(x + Float64(y / t)) / Float64(x + 1.0));
              	end
              	return tmp
              end
              
              code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, -2e+254], N[(y / N[(x * t + t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 1e+205], t$95$1, N[(N[(x + N[(y / t), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
              \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+254}:\\
              \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\
              
              \mathbf{elif}\;t\_1 \leq 10^{+205}:\\
              \;\;\;\;t\_1\\
              
              \mathbf{else}:\\
              \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < -1.9999999999999999e254

                1. Initial program 31.1%

                  \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                2. Add Preprocessing
                3. Taylor expanded in z around inf

                  \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                4. Step-by-step derivation
                  1. /-lowering-/.f64N/A

                    \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                  2. +-commutativeN/A

                    \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                  3. +-lowering-+.f64N/A

                    \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                  4. /-lowering-/.f64N/A

                    \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
                  5. +-commutativeN/A

                    \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                  6. +-lowering-+.f6461.7

                    \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                5. Simplified61.7%

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

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

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

                    \[\leadsto \frac{y}{t \cdot \color{blue}{\left(x + 1\right)}} \]
                  3. distribute-lft-inN/A

                    \[\leadsto \frac{y}{\color{blue}{t \cdot x + t \cdot 1}} \]
                  4. *-commutativeN/A

                    \[\leadsto \frac{y}{\color{blue}{x \cdot t} + t \cdot 1} \]
                  5. *-rgt-identityN/A

                    \[\leadsto \frac{y}{x \cdot t + \color{blue}{t}} \]
                  6. accelerator-lowering-fma.f6474.1

                    \[\leadsto \frac{y}{\color{blue}{\mathsf{fma}\left(x, t, t\right)}} \]
                8. Simplified74.1%

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

                if -1.9999999999999999e254 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 1.00000000000000002e205

                1. Initial program 98.5%

                  \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                2. Add Preprocessing

                if 1.00000000000000002e205 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

                1. Initial program 31.1%

                  \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                2. Add Preprocessing
                3. Taylor expanded in z around inf

                  \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                4. Step-by-step derivation
                  1. /-lowering-/.f64N/A

                    \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                  2. +-commutativeN/A

                    \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                  3. +-lowering-+.f64N/A

                    \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                  4. /-lowering-/.f64N/A

                    \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
                  5. +-commutativeN/A

                    \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                  6. +-lowering-+.f6478.3

                    \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                5. Simplified78.3%

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

                \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq -2 \cdot 10^{+254}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(x, t, t\right)}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 10^{+205}:\\ \;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \]
              5. Add Preprocessing

              Alternative 14: 70.0% accurate, 0.4× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{if}\;t\_1 \leq 5 \cdot 10^{-98}:\\ \;\;\;\;\frac{y}{t}\\ \mathbf{elif}\;t\_1 \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t}\\ \end{array} \end{array} \]
              (FPCore (x y z t)
               :precision binary64
               (let* ((t_1 (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))))
                 (if (<= t_1 5e-98) (/ y t) (if (<= t_1 20.0) 1.0 (/ y t)))))
              double code(double x, double y, double z, double t) {
              	double t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
              	double tmp;
              	if (t_1 <= 5e-98) {
              		tmp = y / t;
              	} else if (t_1 <= 20.0) {
              		tmp = 1.0;
              	} else {
              		tmp = y / t;
              	}
              	return tmp;
              }
              
              real(8) function code(x, y, z, t)
                  real(8), intent (in) :: x
                  real(8), intent (in) :: y
                  real(8), intent (in) :: z
                  real(8), intent (in) :: t
                  real(8) :: t_1
                  real(8) :: tmp
                  t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0d0)
                  if (t_1 <= 5d-98) then
                      tmp = y / t
                  else if (t_1 <= 20.0d0) then
                      tmp = 1.0d0
                  else
                      tmp = y / t
                  end if
                  code = tmp
              end function
              
              public static double code(double x, double y, double z, double t) {
              	double t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
              	double tmp;
              	if (t_1 <= 5e-98) {
              		tmp = y / t;
              	} else if (t_1 <= 20.0) {
              		tmp = 1.0;
              	} else {
              		tmp = y / t;
              	}
              	return tmp;
              }
              
              def code(x, y, z, t):
              	t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0)
              	tmp = 0
              	if t_1 <= 5e-98:
              		tmp = y / t
              	elif t_1 <= 20.0:
              		tmp = 1.0
              	else:
              		tmp = y / t
              	return tmp
              
              function code(x, y, z, t)
              	t_1 = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0))
              	tmp = 0.0
              	if (t_1 <= 5e-98)
              		tmp = Float64(y / t);
              	elseif (t_1 <= 20.0)
              		tmp = 1.0;
              	else
              		tmp = Float64(y / t);
              	end
              	return tmp
              end
              
              function tmp_2 = code(x, y, z, t)
              	t_1 = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
              	tmp = 0.0;
              	if (t_1 <= 5e-98)
              		tmp = y / t;
              	elseif (t_1 <= 20.0)
              		tmp = 1.0;
              	else
              		tmp = y / t;
              	end
              	tmp_2 = tmp;
              end
              
              code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 5e-98], N[(y / t), $MachinePrecision], If[LessEqual[t$95$1, 20.0], 1.0, N[(y / t), $MachinePrecision]]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_1 := \frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
              \mathbf{if}\;t\_1 \leq 5 \cdot 10^{-98}:\\
              \;\;\;\;\frac{y}{t}\\
              
              \mathbf{elif}\;t\_1 \leq 20:\\
              \;\;\;\;1\\
              
              \mathbf{else}:\\
              \;\;\;\;\frac{y}{t}\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 5.00000000000000018e-98 or 20 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64)))

                1. Initial program 76.3%

                  \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                2. Add Preprocessing
                3. Taylor expanded in x around 0

                  \[\leadsto \color{blue}{\frac{y}{t}} \]
                4. Step-by-step derivation
                  1. /-lowering-/.f6448.2

                    \[\leadsto \color{blue}{\frac{y}{t}} \]
                5. Simplified48.2%

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

                if 5.00000000000000018e-98 < (/.f64 (+.f64 x (/.f64 (-.f64 (*.f64 y z) x) (-.f64 (*.f64 t z) x))) (+.f64 x #s(literal 1 binary64))) < 20

                1. Initial program 100.0%

                  \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                2. Add Preprocessing
                3. Taylor expanded in x around inf

                  \[\leadsto \color{blue}{1} \]
                4. Step-by-step derivation
                  1. Simplified92.4%

                    \[\leadsto \color{blue}{1} \]
                5. Recombined 2 regimes into one program.
                6. Final simplification70.5%

                  \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 5 \cdot 10^{-98}:\\ \;\;\;\;\frac{y}{t}\\ \mathbf{elif}\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1} \leq 20:\\ \;\;\;\;1\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t}\\ \end{array} \]
                7. Add Preprocessing

                Alternative 15: 94.8% accurate, 0.6× speedup?

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

                  1. Initial program 62.4%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in z around inf

                    \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                  4. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    3. +-lowering-+.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    4. /-lowering-/.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
                    5. +-commutativeN/A

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                    6. +-lowering-+.f6480.2

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                  5. Simplified80.2%

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

                    \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
                  7. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
                    3. associate-/l*N/A

                      \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
                    4. accelerator-lowering-fma.f64N/A

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

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

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

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
                    8. /-lowering-/.f64N/A

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

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
                    10. +-lowering-+.f6480.3

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
                  8. Simplified80.3%

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

                  if -4.2e173 < z < 1.89999999999999994e110

                  1. Initial program 99.3%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing

                  if 1.89999999999999994e110 < z

                  1. Initial program 68.2%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in t around inf

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto \frac{y}{\mathsf{fma}\left(t, x, t\right)} + \left(\frac{x}{x + 1} - \frac{x}{t \cdot \left(x \cdot z + \color{blue}{z}\right)}\right) \]
                    18. accelerator-lowering-fma.f6493.3

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

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

                  \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4.2 \cdot 10^{+173}:\\ \;\;\;\;\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}\\ \mathbf{elif}\;z \leq 1.9 \cdot 10^{+110}:\\ \;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\mathsf{fma}\left(t, x, t\right)} + \left(\frac{x}{x + 1} - \frac{x}{\mathsf{fma}\left(x, z, z\right) \cdot t}\right)\\ \end{array} \]
                5. Add Preprocessing

                Alternative 16: 94.9% accurate, 0.8× speedup?

                \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}\\ \mathbf{if}\;z \leq -9.5 \cdot 10^{+174}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 1.25 \cdot 10^{+109}:\\ \;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                (FPCore (x y z t)
                 :precision binary64
                 (let* ((t_1 (/ (fma t (/ x (+ x 1.0)) (/ y (+ x 1.0))) t)))
                   (if (<= z -9.5e+174)
                     t_1
                     (if (<= z 1.25e+109)
                       (/ (+ x (/ (- (* z y) x) (- (* z t) x))) (+ x 1.0))
                       t_1))))
                double code(double x, double y, double z, double t) {
                	double t_1 = fma(t, (x / (x + 1.0)), (y / (x + 1.0))) / t;
                	double tmp;
                	if (z <= -9.5e+174) {
                		tmp = t_1;
                	} else if (z <= 1.25e+109) {
                		tmp = (x + (((z * y) - x) / ((z * t) - x))) / (x + 1.0);
                	} else {
                		tmp = t_1;
                	}
                	return tmp;
                }
                
                function code(x, y, z, t)
                	t_1 = Float64(fma(t, Float64(x / Float64(x + 1.0)), Float64(y / Float64(x + 1.0))) / t)
                	tmp = 0.0
                	if (z <= -9.5e+174)
                		tmp = t_1;
                	elseif (z <= 1.25e+109)
                		tmp = Float64(Float64(x + Float64(Float64(Float64(z * y) - x) / Float64(Float64(z * t) - x))) / Float64(x + 1.0));
                	else
                		tmp = t_1;
                	end
                	return tmp
                end
                
                code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(t * N[(x / N[(x + 1.0), $MachinePrecision]), $MachinePrecision] + N[(y / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]}, If[LessEqual[z, -9.5e+174], t$95$1, If[LessEqual[z, 1.25e+109], N[(N[(x + N[(N[(N[(z * y), $MachinePrecision] - x), $MachinePrecision] / N[(N[(z * t), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision], t$95$1]]]
                
                \begin{array}{l}
                
                \\
                \begin{array}{l}
                t_1 := \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}\\
                \mathbf{if}\;z \leq -9.5 \cdot 10^{+174}:\\
                \;\;\;\;t\_1\\
                
                \mathbf{elif}\;z \leq 1.25 \cdot 10^{+109}:\\
                \;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\
                
                \mathbf{else}:\\
                \;\;\;\;t\_1\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if z < -9.4999999999999992e174 or 1.25e109 < z

                  1. Initial program 66.1%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in z around inf

                    \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                  4. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    3. +-lowering-+.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    4. /-lowering-/.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
                    5. +-commutativeN/A

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                    6. +-lowering-+.f6486.3

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                  5. Simplified86.3%

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

                    \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
                  7. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
                    3. associate-/l*N/A

                      \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
                    4. accelerator-lowering-fma.f64N/A

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

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

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

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
                    8. /-lowering-/.f64N/A

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

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
                    10. +-lowering-+.f6488.6

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
                  8. Simplified88.6%

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

                  if -9.4999999999999992e174 < z < 1.25e109

                  1. Initial program 99.3%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                3. Recombined 2 regimes into one program.
                4. Final simplification95.7%

                  \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -9.5 \cdot 10^{+174}:\\ \;\;\;\;\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}\\ \mathbf{elif}\;z \leq 1.25 \cdot 10^{+109}:\\ \;\;\;\;\frac{x + \frac{z \cdot y - x}{z \cdot t - x}}{x + 1}\\ \mathbf{else}:\\ \;\;\;\;\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}\\ \end{array} \]
                5. Add Preprocessing

                Alternative 17: 81.0% accurate, 1.1× speedup?

                \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x + \frac{y}{t}}{x + 1}\\ \mathbf{if}\;t \leq -2.4 \cdot 10^{-99}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 1.55 \cdot 10^{-91}:\\ \;\;\;\;\mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                (FPCore (x y z t)
                 :precision binary64
                 (let* ((t_1 (/ (+ x (/ y t)) (+ x 1.0))))
                   (if (<= t -2.4e-99)
                     t_1
                     (if (<= t 1.55e-91) (fma z (- 0.0 (/ y (fma x x x))) 1.0) t_1))))
                double code(double x, double y, double z, double t) {
                	double t_1 = (x + (y / t)) / (x + 1.0);
                	double tmp;
                	if (t <= -2.4e-99) {
                		tmp = t_1;
                	} else if (t <= 1.55e-91) {
                		tmp = fma(z, (0.0 - (y / fma(x, x, x))), 1.0);
                	} else {
                		tmp = t_1;
                	}
                	return tmp;
                }
                
                function code(x, y, z, t)
                	t_1 = Float64(Float64(x + Float64(y / t)) / Float64(x + 1.0))
                	tmp = 0.0
                	if (t <= -2.4e-99)
                		tmp = t_1;
                	elseif (t <= 1.55e-91)
                		tmp = fma(z, Float64(0.0 - Float64(y / fma(x, x, x))), 1.0);
                	else
                		tmp = t_1;
                	end
                	return tmp
                end
                
                code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x + N[(y / t), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.4e-99], t$95$1, If[LessEqual[t, 1.55e-91], N[(z * N[(0.0 - N[(y / N[(x * x + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision], t$95$1]]]
                
                \begin{array}{l}
                
                \\
                \begin{array}{l}
                t_1 := \frac{x + \frac{y}{t}}{x + 1}\\
                \mathbf{if}\;t \leq -2.4 \cdot 10^{-99}:\\
                \;\;\;\;t\_1\\
                
                \mathbf{elif}\;t \leq 1.55 \cdot 10^{-91}:\\
                \;\;\;\;\mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\
                
                \mathbf{else}:\\
                \;\;\;\;t\_1\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if t < -2.4e-99 or 1.5499999999999999e-91 < t

                  1. Initial program 87.7%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in z around inf

                    \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                  4. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    3. +-lowering-+.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    4. /-lowering-/.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
                    5. +-commutativeN/A

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                    6. +-lowering-+.f6487.8

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                  5. Simplified87.8%

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

                  if -2.4e-99 < t < 1.5499999999999999e-91

                  1. Initial program 89.4%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in t around 0

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

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

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

                      \[\leadsto \frac{x + \color{blue}{\left(0 - \frac{y \cdot z - x}{x}\right)}}{x + 1} \]
                    4. div-subN/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} - \frac{x}{x}\right)}\right)}{x + 1} \]
                    5. sub-negN/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)}\right)}{x + 1} \]
                    6. associate-/l*N/A

                      \[\leadsto \frac{x + \left(0 - \left(\color{blue}{y \cdot \frac{z}{x}} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)\right)}{x + 1} \]
                    7. *-inversesN/A

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

                      \[\leadsto \frac{x + \left(0 - \left(y \cdot \frac{z}{x} + \color{blue}{-1}\right)\right)}{x + 1} \]
                    9. accelerator-lowering-fma.f64N/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\mathsf{fma}\left(y, \frac{z}{x}, -1\right)}\right)}{x + 1} \]
                    10. /-lowering-/.f6476.3

                      \[\leadsto \frac{x + \left(0 - \mathsf{fma}\left(y, \color{blue}{\frac{z}{x}}, -1\right)\right)}{x + 1} \]
                  5. Simplified76.3%

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

                    \[\leadsto \color{blue}{z \cdot \left(-1 \cdot \frac{y}{x \cdot \left(1 + x\right)} + \frac{1}{z}\right)} \]
                  7. Step-by-step derivation
                    1. distribute-lft-inN/A

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

                      \[\leadsto z \cdot \left(-1 \cdot \frac{y}{x \cdot \left(1 + x\right)}\right) + \color{blue}{1} \]
                    3. accelerator-lowering-fma.f64N/A

                      \[\leadsto \color{blue}{\mathsf{fma}\left(z, -1 \cdot \frac{y}{x \cdot \left(1 + x\right)}, 1\right)} \]
                    4. associate-*r/N/A

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

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

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{\mathsf{neg}\left(y\right)}}{x \cdot \left(1 + x\right)}, 1\right) \]
                    7. neg-sub0N/A

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{0 - y}}{x \cdot \left(1 + x\right)}, 1\right) \]
                    8. --lowering--.f64N/A

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

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

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

                      \[\leadsto \mathsf{fma}\left(z, \frac{0 - y}{x \cdot x + \color{blue}{x}}, 1\right) \]
                    12. accelerator-lowering-fma.f6478.6

                      \[\leadsto \mathsf{fma}\left(z, \frac{0 - y}{\color{blue}{\mathsf{fma}\left(x, x, x\right)}}, 1\right) \]
                  8. Simplified78.6%

                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{0 - y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)} \]
                  9. Step-by-step derivation
                    1. sub0-negN/A

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{\mathsf{neg}\left(y\right)}}{\mathsf{fma}\left(x, x, x\right)}, 1\right) \]
                    2. neg-lowering-neg.f6478.6

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{-y}}{\mathsf{fma}\left(x, x, x\right)}, 1\right) \]
                  10. Applied egg-rr78.6%

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

                  \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -2.4 \cdot 10^{-99}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \mathbf{elif}\;t \leq 1.55 \cdot 10^{-91}:\\ \;\;\;\;\mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{x + \frac{y}{t}}{x + 1}\\ \end{array} \]
                5. Add Preprocessing

                Alternative 18: 78.3% accurate, 1.2× speedup?

                \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -8.8 \cdot 10^{-26}:\\ \;\;\;\;\mathsf{fma}\left(0 - y, \frac{z}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \mathbf{elif}\;x \leq 2.15 \cdot 10^{-18}:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \end{array} \end{array} \]
                (FPCore (x y z t)
                 :precision binary64
                 (if (<= x -8.8e-26)
                   (fma (- 0.0 y) (/ z (fma x x x)) 1.0)
                   (if (<= x 2.15e-18)
                     (fma (- 1.0 x) (/ y t) x)
                     (fma z (- 0.0 (/ y (fma x x x))) 1.0))))
                double code(double x, double y, double z, double t) {
                	double tmp;
                	if (x <= -8.8e-26) {
                		tmp = fma((0.0 - y), (z / fma(x, x, x)), 1.0);
                	} else if (x <= 2.15e-18) {
                		tmp = fma((1.0 - x), (y / t), x);
                	} else {
                		tmp = fma(z, (0.0 - (y / fma(x, x, x))), 1.0);
                	}
                	return tmp;
                }
                
                function code(x, y, z, t)
                	tmp = 0.0
                	if (x <= -8.8e-26)
                		tmp = fma(Float64(0.0 - y), Float64(z / fma(x, x, x)), 1.0);
                	elseif (x <= 2.15e-18)
                		tmp = fma(Float64(1.0 - x), Float64(y / t), x);
                	else
                		tmp = fma(z, Float64(0.0 - Float64(y / fma(x, x, x))), 1.0);
                	end
                	return tmp
                end
                
                code[x_, y_, z_, t_] := If[LessEqual[x, -8.8e-26], N[(N[(0.0 - y), $MachinePrecision] * N[(z / N[(x * x + x), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision], If[LessEqual[x, 2.15e-18], N[(N[(1.0 - x), $MachinePrecision] * N[(y / t), $MachinePrecision] + x), $MachinePrecision], N[(z * N[(0.0 - N[(y / N[(x * x + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]]]
                
                \begin{array}{l}
                
                \\
                \begin{array}{l}
                \mathbf{if}\;x \leq -8.8 \cdot 10^{-26}:\\
                \;\;\;\;\mathsf{fma}\left(0 - y, \frac{z}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\
                
                \mathbf{elif}\;x \leq 2.15 \cdot 10^{-18}:\\
                \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\
                
                \mathbf{else}:\\
                \;\;\;\;\mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 3 regimes
                2. if x < -8.8000000000000003e-26

                  1. Initial program 83.9%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in t around 0

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

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

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

                      \[\leadsto \frac{x + \color{blue}{\left(0 - \frac{y \cdot z - x}{x}\right)}}{x + 1} \]
                    4. div-subN/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} - \frac{x}{x}\right)}\right)}{x + 1} \]
                    5. sub-negN/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)}\right)}{x + 1} \]
                    6. associate-/l*N/A

                      \[\leadsto \frac{x + \left(0 - \left(\color{blue}{y \cdot \frac{z}{x}} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)\right)}{x + 1} \]
                    7. *-inversesN/A

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

                      \[\leadsto \frac{x + \left(0 - \left(y \cdot \frac{z}{x} + \color{blue}{-1}\right)\right)}{x + 1} \]
                    9. accelerator-lowering-fma.f64N/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\mathsf{fma}\left(y, \frac{z}{x}, -1\right)}\right)}{x + 1} \]
                    10. /-lowering-/.f6488.0

                      \[\leadsto \frac{x + \left(0 - \mathsf{fma}\left(y, \color{blue}{\frac{z}{x}}, -1\right)\right)}{x + 1} \]
                  5. Simplified88.0%

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

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

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

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

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

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

                      \[\leadsto \color{blue}{\left(-1 \cdot y\right)} \cdot \frac{z}{x \cdot \left(1 + x\right)} + 1 \]
                    6. accelerator-lowering-fma.f64N/A

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

                      \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{neg}\left(y\right)}, \frac{z}{x \cdot \left(1 + x\right)}, 1\right) \]
                    8. neg-sub0N/A

                      \[\leadsto \mathsf{fma}\left(\color{blue}{0 - y}, \frac{z}{x \cdot \left(1 + x\right)}, 1\right) \]
                    9. --lowering--.f64N/A

                      \[\leadsto \mathsf{fma}\left(\color{blue}{0 - y}, \frac{z}{x \cdot \left(1 + x\right)}, 1\right) \]
                    10. /-lowering-/.f64N/A

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

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

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

                      \[\leadsto \mathsf{fma}\left(0 - y, \frac{z}{x \cdot x + \color{blue}{x}}, 1\right) \]
                    14. accelerator-lowering-fma.f6490.6

                      \[\leadsto \mathsf{fma}\left(0 - y, \frac{z}{\color{blue}{\mathsf{fma}\left(x, x, x\right)}}, 1\right) \]
                  8. Simplified90.6%

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

                  if -8.8000000000000003e-26 < x < 2.1500000000000001e-18

                  1. Initial program 89.5%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in z around inf

                    \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                  4. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    3. +-lowering-+.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    4. /-lowering-/.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
                    5. +-commutativeN/A

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                    6. +-lowering-+.f6472.6

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                  5. Simplified72.6%

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

                    \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
                  7. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
                    3. associate-/l*N/A

                      \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
                    4. accelerator-lowering-fma.f64N/A

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

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

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

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
                    8. /-lowering-/.f64N/A

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

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
                    10. +-lowering-+.f6472.6

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
                  8. Simplified72.6%

                    \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}} \]
                  9. Taylor expanded in x around 0

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

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

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

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

                      \[\leadsto \frac{y}{t} + x \cdot \color{blue}{\left(-1 \cdot \frac{y}{t} + 1\right)} \]
                    5. distribute-lft-inN/A

                      \[\leadsto \frac{y}{t} + \color{blue}{\left(x \cdot \left(-1 \cdot \frac{y}{t}\right) + x \cdot 1\right)} \]
                    6. mul-1-negN/A

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

                      \[\leadsto \frac{y}{t} + \left(\color{blue}{\left(\mathsf{neg}\left(x \cdot \frac{y}{t}\right)\right)} + x \cdot 1\right) \]
                    8. associate-/l*N/A

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

                      \[\leadsto \frac{y}{t} + \left(\color{blue}{-1 \cdot \frac{x \cdot y}{t}} + x \cdot 1\right) \]
                    10. *-rgt-identityN/A

                      \[\leadsto \frac{y}{t} + \left(-1 \cdot \frac{x \cdot y}{t} + \color{blue}{x}\right) \]
                    11. associate-+r+N/A

                      \[\leadsto \color{blue}{\left(\frac{y}{t} + -1 \cdot \frac{x \cdot y}{t}\right) + x} \]
                  11. Simplified72.6%

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

                  if 2.1500000000000001e-18 < x

                  1. Initial program 90.6%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in t around 0

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

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

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

                      \[\leadsto \frac{x + \color{blue}{\left(0 - \frac{y \cdot z - x}{x}\right)}}{x + 1} \]
                    4. div-subN/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} - \frac{x}{x}\right)}\right)}{x + 1} \]
                    5. sub-negN/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)}\right)}{x + 1} \]
                    6. associate-/l*N/A

                      \[\leadsto \frac{x + \left(0 - \left(\color{blue}{y \cdot \frac{z}{x}} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)\right)}{x + 1} \]
                    7. *-inversesN/A

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

                      \[\leadsto \frac{x + \left(0 - \left(y \cdot \frac{z}{x} + \color{blue}{-1}\right)\right)}{x + 1} \]
                    9. accelerator-lowering-fma.f64N/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\mathsf{fma}\left(y, \frac{z}{x}, -1\right)}\right)}{x + 1} \]
                    10. /-lowering-/.f6487.2

                      \[\leadsto \frac{x + \left(0 - \mathsf{fma}\left(y, \color{blue}{\frac{z}{x}}, -1\right)\right)}{x + 1} \]
                  5. Simplified87.2%

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

                    \[\leadsto \color{blue}{z \cdot \left(-1 \cdot \frac{y}{x \cdot \left(1 + x\right)} + \frac{1}{z}\right)} \]
                  7. Step-by-step derivation
                    1. distribute-lft-inN/A

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

                      \[\leadsto z \cdot \left(-1 \cdot \frac{y}{x \cdot \left(1 + x\right)}\right) + \color{blue}{1} \]
                    3. accelerator-lowering-fma.f64N/A

                      \[\leadsto \color{blue}{\mathsf{fma}\left(z, -1 \cdot \frac{y}{x \cdot \left(1 + x\right)}, 1\right)} \]
                    4. associate-*r/N/A

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

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

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{\mathsf{neg}\left(y\right)}}{x \cdot \left(1 + x\right)}, 1\right) \]
                    7. neg-sub0N/A

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{0 - y}}{x \cdot \left(1 + x\right)}, 1\right) \]
                    8. --lowering--.f64N/A

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

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

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

                      \[\leadsto \mathsf{fma}\left(z, \frac{0 - y}{x \cdot x + \color{blue}{x}}, 1\right) \]
                    12. accelerator-lowering-fma.f6487.2

                      \[\leadsto \mathsf{fma}\left(z, \frac{0 - y}{\color{blue}{\mathsf{fma}\left(x, x, x\right)}}, 1\right) \]
                  8. Simplified87.2%

                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{0 - y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)} \]
                  9. Step-by-step derivation
                    1. sub0-negN/A

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{\mathsf{neg}\left(y\right)}}{\mathsf{fma}\left(x, x, x\right)}, 1\right) \]
                    2. neg-lowering-neg.f6487.2

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{-y}}{\mathsf{fma}\left(x, x, x\right)}, 1\right) \]
                  10. Applied egg-rr87.2%

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

                  \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -8.8 \cdot 10^{-26}:\\ \;\;\;\;\mathsf{fma}\left(0 - y, \frac{z}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \mathbf{elif}\;x \leq 2.15 \cdot 10^{-18}:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \end{array} \]
                5. Add Preprocessing

                Alternative 19: 78.3% accurate, 1.2× speedup?

                \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \mathbf{if}\;x \leq -1.55 \cdot 10^{-23}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;x \leq 4.8 \cdot 10^{-19}:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                (FPCore (x y z t)
                 :precision binary64
                 (let* ((t_1 (fma z (- 0.0 (/ y (fma x x x))) 1.0)))
                   (if (<= x -1.55e-23)
                     t_1
                     (if (<= x 4.8e-19) (fma (- 1.0 x) (/ y t) x) t_1))))
                double code(double x, double y, double z, double t) {
                	double t_1 = fma(z, (0.0 - (y / fma(x, x, x))), 1.0);
                	double tmp;
                	if (x <= -1.55e-23) {
                		tmp = t_1;
                	} else if (x <= 4.8e-19) {
                		tmp = fma((1.0 - x), (y / t), x);
                	} else {
                		tmp = t_1;
                	}
                	return tmp;
                }
                
                function code(x, y, z, t)
                	t_1 = fma(z, Float64(0.0 - Float64(y / fma(x, x, x))), 1.0)
                	tmp = 0.0
                	if (x <= -1.55e-23)
                		tmp = t_1;
                	elseif (x <= 4.8e-19)
                		tmp = fma(Float64(1.0 - x), Float64(y / t), x);
                	else
                		tmp = t_1;
                	end
                	return tmp
                end
                
                code[x_, y_, z_, t_] := Block[{t$95$1 = N[(z * N[(0.0 - N[(y / N[(x * x + x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]}, If[LessEqual[x, -1.55e-23], t$95$1, If[LessEqual[x, 4.8e-19], N[(N[(1.0 - x), $MachinePrecision] * N[(y / t), $MachinePrecision] + x), $MachinePrecision], t$95$1]]]
                
                \begin{array}{l}
                
                \\
                \begin{array}{l}
                t_1 := \mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\
                \mathbf{if}\;x \leq -1.55 \cdot 10^{-23}:\\
                \;\;\;\;t\_1\\
                
                \mathbf{elif}\;x \leq 4.8 \cdot 10^{-19}:\\
                \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\
                
                \mathbf{else}:\\
                \;\;\;\;t\_1\\
                
                
                \end{array}
                \end{array}
                
                Derivation
                1. Split input into 2 regimes
                2. if x < -1.5499999999999999e-23 or 4.80000000000000046e-19 < x

                  1. Initial program 87.3%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in t around 0

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

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

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

                      \[\leadsto \frac{x + \color{blue}{\left(0 - \frac{y \cdot z - x}{x}\right)}}{x + 1} \]
                    4. div-subN/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} - \frac{x}{x}\right)}\right)}{x + 1} \]
                    5. sub-negN/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\left(\frac{y \cdot z}{x} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)}\right)}{x + 1} \]
                    6. associate-/l*N/A

                      \[\leadsto \frac{x + \left(0 - \left(\color{blue}{y \cdot \frac{z}{x}} + \left(\mathsf{neg}\left(\frac{x}{x}\right)\right)\right)\right)}{x + 1} \]
                    7. *-inversesN/A

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

                      \[\leadsto \frac{x + \left(0 - \left(y \cdot \frac{z}{x} + \color{blue}{-1}\right)\right)}{x + 1} \]
                    9. accelerator-lowering-fma.f64N/A

                      \[\leadsto \frac{x + \left(0 - \color{blue}{\mathsf{fma}\left(y, \frac{z}{x}, -1\right)}\right)}{x + 1} \]
                    10. /-lowering-/.f6487.6

                      \[\leadsto \frac{x + \left(0 - \mathsf{fma}\left(y, \color{blue}{\frac{z}{x}}, -1\right)\right)}{x + 1} \]
                  5. Simplified87.6%

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

                    \[\leadsto \color{blue}{z \cdot \left(-1 \cdot \frac{y}{x \cdot \left(1 + x\right)} + \frac{1}{z}\right)} \]
                  7. Step-by-step derivation
                    1. distribute-lft-inN/A

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

                      \[\leadsto z \cdot \left(-1 \cdot \frac{y}{x \cdot \left(1 + x\right)}\right) + \color{blue}{1} \]
                    3. accelerator-lowering-fma.f64N/A

                      \[\leadsto \color{blue}{\mathsf{fma}\left(z, -1 \cdot \frac{y}{x \cdot \left(1 + x\right)}, 1\right)} \]
                    4. associate-*r/N/A

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

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

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{\mathsf{neg}\left(y\right)}}{x \cdot \left(1 + x\right)}, 1\right) \]
                    7. neg-sub0N/A

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{0 - y}}{x \cdot \left(1 + x\right)}, 1\right) \]
                    8. --lowering--.f64N/A

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

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

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

                      \[\leadsto \mathsf{fma}\left(z, \frac{0 - y}{x \cdot x + \color{blue}{x}}, 1\right) \]
                    12. accelerator-lowering-fma.f6488.9

                      \[\leadsto \mathsf{fma}\left(z, \frac{0 - y}{\color{blue}{\mathsf{fma}\left(x, x, x\right)}}, 1\right) \]
                  8. Simplified88.9%

                    \[\leadsto \color{blue}{\mathsf{fma}\left(z, \frac{0 - y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)} \]
                  9. Step-by-step derivation
                    1. sub0-negN/A

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{\mathsf{neg}\left(y\right)}}{\mathsf{fma}\left(x, x, x\right)}, 1\right) \]
                    2. neg-lowering-neg.f6488.9

                      \[\leadsto \mathsf{fma}\left(z, \frac{\color{blue}{-y}}{\mathsf{fma}\left(x, x, x\right)}, 1\right) \]
                  10. Applied egg-rr88.9%

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

                  if -1.5499999999999999e-23 < x < 4.80000000000000046e-19

                  1. Initial program 89.5%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in z around inf

                    \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                  4. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    3. +-lowering-+.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    4. /-lowering-/.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
                    5. +-commutativeN/A

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                    6. +-lowering-+.f6472.6

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                  5. Simplified72.6%

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

                    \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
                  7. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{\frac{y}{1 + x} + \frac{t \cdot x}{1 + x}}{t}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{t \cdot x}{1 + x} + \frac{y}{1 + x}}}{t} \]
                    3. associate-/l*N/A

                      \[\leadsto \frac{\color{blue}{t \cdot \frac{x}{1 + x}} + \frac{y}{1 + x}}{t} \]
                    4. accelerator-lowering-fma.f64N/A

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

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

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

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{\color{blue}{x + 1}}, \frac{y}{1 + x}\right)}{t} \]
                    8. /-lowering-/.f64N/A

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

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
                    10. +-lowering-+.f6472.6

                      \[\leadsto \frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{\color{blue}{x + 1}}\right)}{t} \]
                  8. Simplified72.6%

                    \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(t, \frac{x}{x + 1}, \frac{y}{x + 1}\right)}{t}} \]
                  9. Taylor expanded in x around 0

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

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

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

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

                      \[\leadsto \frac{y}{t} + x \cdot \color{blue}{\left(-1 \cdot \frac{y}{t} + 1\right)} \]
                    5. distribute-lft-inN/A

                      \[\leadsto \frac{y}{t} + \color{blue}{\left(x \cdot \left(-1 \cdot \frac{y}{t}\right) + x \cdot 1\right)} \]
                    6. mul-1-negN/A

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

                      \[\leadsto \frac{y}{t} + \left(\color{blue}{\left(\mathsf{neg}\left(x \cdot \frac{y}{t}\right)\right)} + x \cdot 1\right) \]
                    8. associate-/l*N/A

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

                      \[\leadsto \frac{y}{t} + \left(\color{blue}{-1 \cdot \frac{x \cdot y}{t}} + x \cdot 1\right) \]
                    10. *-rgt-identityN/A

                      \[\leadsto \frac{y}{t} + \left(-1 \cdot \frac{x \cdot y}{t} + \color{blue}{x}\right) \]
                    11. associate-+r+N/A

                      \[\leadsto \color{blue}{\left(\frac{y}{t} + -1 \cdot \frac{x \cdot y}{t}\right) + x} \]
                  11. Simplified72.6%

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

                  \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -1.55 \cdot 10^{-23}:\\ \;\;\;\;\mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \mathbf{elif}\;x \leq 4.8 \cdot 10^{-19}:\\ \;\;\;\;\mathsf{fma}\left(1 - x, \frac{y}{t}, x\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(z, 0 - \frac{y}{\mathsf{fma}\left(x, x, x\right)}, 1\right)\\ \end{array} \]
                5. Add Preprocessing

                Alternative 20: 52.8% accurate, 45.0× speedup?

                \[\begin{array}{l} \\ 1 \end{array} \]
                (FPCore (x y z t) :precision binary64 1.0)
                double code(double x, double y, double z, double t) {
                	return 1.0;
                }
                
                real(8) function code(x, y, z, t)
                    real(8), intent (in) :: x
                    real(8), intent (in) :: y
                    real(8), intent (in) :: z
                    real(8), intent (in) :: t
                    code = 1.0d0
                end function
                
                public static double code(double x, double y, double z, double t) {
                	return 1.0;
                }
                
                def code(x, y, z, t):
                	return 1.0
                
                function code(x, y, z, t)
                	return 1.0
                end
                
                function tmp = code(x, y, z, t)
                	tmp = 1.0;
                end
                
                code[x_, y_, z_, t_] := 1.0
                
                \begin{array}{l}
                
                \\
                1
                \end{array}
                
                Derivation
                1. Initial program 88.2%

                  \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                2. Add Preprocessing
                3. Taylor expanded in x around inf

                  \[\leadsto \color{blue}{1} \]
                4. Step-by-step derivation
                  1. Simplified51.2%

                    \[\leadsto \color{blue}{1} \]
                  2. Add Preprocessing

                  Alternative 21: 2.6% accurate, 45.0× speedup?

                  \[\begin{array}{l} \\ -1 \end{array} \]
                  (FPCore (x y z t) :precision binary64 -1.0)
                  double code(double x, double y, double z, double t) {
                  	return -1.0;
                  }
                  
                  real(8) function code(x, y, z, t)
                      real(8), intent (in) :: x
                      real(8), intent (in) :: y
                      real(8), intent (in) :: z
                      real(8), intent (in) :: t
                      code = -1.0d0
                  end function
                  
                  public static double code(double x, double y, double z, double t) {
                  	return -1.0;
                  }
                  
                  def code(x, y, z, t):
                  	return -1.0
                  
                  function code(x, y, z, t)
                  	return -1.0
                  end
                  
                  function tmp = code(x, y, z, t)
                  	tmp = -1.0;
                  end
                  
                  code[x_, y_, z_, t_] := -1.0
                  
                  \begin{array}{l}
                  
                  \\
                  -1
                  \end{array}
                  
                  Derivation
                  1. Initial program 88.2%

                    \[\frac{x + \frac{y \cdot z - x}{t \cdot z - x}}{x + 1} \]
                  2. Add Preprocessing
                  3. Taylor expanded in z around inf

                    \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                  4. Step-by-step derivation
                    1. /-lowering-/.f64N/A

                      \[\leadsto \color{blue}{\frac{x + \frac{y}{t}}{1 + x}} \]
                    2. +-commutativeN/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    3. +-lowering-+.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} + x}}{1 + x} \]
                    4. /-lowering-/.f64N/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t}} + x}{1 + x} \]
                    5. +-commutativeN/A

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                    6. +-lowering-+.f6473.5

                      \[\leadsto \frac{\frac{y}{t} + x}{\color{blue}{x + 1}} \]
                  5. Simplified73.5%

                    \[\leadsto \color{blue}{\frac{\frac{y}{t} + x}{x + 1}} \]
                  6. Step-by-step derivation
                    1. unpow1N/A

                      \[\leadsto \frac{\frac{y}{t} + \color{blue}{{x}^{1}}}{x + 1} \]
                    2. metadata-evalN/A

                      \[\leadsto \frac{\frac{y}{t} + {x}^{\color{blue}{\left(3 - 2\right)}}}{x + 1} \]
                    3. pow-divN/A

                      \[\leadsto \frac{\frac{y}{t} + \color{blue}{\frac{{x}^{3}}{{x}^{2}}}}{x + 1} \]
                    4. sqr-powN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{\color{blue}{{x}^{\left(\frac{3}{2}\right)} \cdot {x}^{\left(\frac{3}{2}\right)}}}{{x}^{2}}}{x + 1} \]
                    5. unpow-prod-downN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{\color{blue}{{\left(x \cdot x\right)}^{\left(\frac{3}{2}\right)}}}{{x}^{2}}}{x + 1} \]
                    6. sqr-negN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{{\color{blue}{\left(\left(\mathsf{neg}\left(x\right)\right) \cdot \left(\mathsf{neg}\left(x\right)\right)\right)}}^{\left(\frac{3}{2}\right)}}{{x}^{2}}}{x + 1} \]
                    7. sub0-negN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{{\left(\color{blue}{\left(0 - x\right)} \cdot \left(\mathsf{neg}\left(x\right)\right)\right)}^{\left(\frac{3}{2}\right)}}{{x}^{2}}}{x + 1} \]
                    8. sub0-negN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{{\left(\left(0 - x\right) \cdot \color{blue}{\left(0 - x\right)}\right)}^{\left(\frac{3}{2}\right)}}{{x}^{2}}}{x + 1} \]
                    9. unpow-prod-downN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{\color{blue}{{\left(0 - x\right)}^{\left(\frac{3}{2}\right)} \cdot {\left(0 - x\right)}^{\left(\frac{3}{2}\right)}}}{{x}^{2}}}{x + 1} \]
                    10. sqr-powN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{\color{blue}{{\left(0 - x\right)}^{3}}}{{x}^{2}}}{x + 1} \]
                    11. pow2N/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{{\left(0 - x\right)}^{3}}{\color{blue}{x \cdot x}}}{x + 1} \]
                    12. sub0-negN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{{\color{blue}{\left(\mathsf{neg}\left(x\right)\right)}}^{3}}{x \cdot x}}{x + 1} \]
                    13. cube-negN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{\color{blue}{\mathsf{neg}\left({x}^{3}\right)}}{x \cdot x}}{x + 1} \]
                    14. sub0-negN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{\color{blue}{0 - {x}^{3}}}{x \cdot x}}{x + 1} \]
                    15. +-rgt-identityN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{0 - {x}^{3}}{x \cdot \color{blue}{\left(x + 0\right)}}}{x + 1} \]
                    16. distribute-rgt-outN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{0 - {x}^{3}}{\color{blue}{x \cdot x + 0 \cdot x}}}{x + 1} \]
                    17. +-lft-identityN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{0 - {x}^{3}}{\color{blue}{0 + \left(x \cdot x + 0 \cdot x\right)}}}{x + 1} \]
                    18. metadata-evalN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{0 - {x}^{3}}{\color{blue}{0 \cdot 0} + \left(x \cdot x + 0 \cdot x\right)}}{x + 1} \]
                    19. metadata-evalN/A

                      \[\leadsto \frac{\frac{y}{t} + \frac{\color{blue}{{0}^{3}} - {x}^{3}}{0 \cdot 0 + \left(x \cdot x + 0 \cdot x\right)}}{x + 1} \]
                    20. flip3--N/A

                      \[\leadsto \frac{\frac{y}{t} + \color{blue}{\left(0 - x\right)}}{x + 1} \]
                    21. sub0-negN/A

                      \[\leadsto \frac{\frac{y}{t} + \color{blue}{\left(\mathsf{neg}\left(x\right)\right)}}{x + 1} \]
                    22. sub-negN/A

                      \[\leadsto \frac{\color{blue}{\frac{y}{t} - x}}{x + 1} \]
                  7. Applied egg-rr27.0%

                    \[\leadsto \frac{\color{blue}{\frac{y}{t} - x}}{x + 1} \]
                  8. Taylor expanded in x around inf

                    \[\leadsto \color{blue}{-1} \]
                  9. Step-by-step derivation
                    1. Simplified2.8%

                      \[\leadsto \color{blue}{-1} \]
                    2. Add Preprocessing

                    Developer Target 1: 99.5% accurate, 0.7× speedup?

                    \[\begin{array}{l} \\ \frac{x + \left(\frac{y}{t - \frac{x}{z}} - \frac{x}{t \cdot z - x}\right)}{x + 1} \end{array} \]
                    (FPCore (x y z t)
                     :precision binary64
                     (/ (+ x (- (/ y (- t (/ x z))) (/ x (- (* t z) x)))) (+ x 1.0)))
                    double code(double x, double y, double z, double t) {
                    	return (x + ((y / (t - (x / z))) - (x / ((t * z) - x)))) / (x + 1.0);
                    }
                    
                    real(8) function code(x, y, z, t)
                        real(8), intent (in) :: x
                        real(8), intent (in) :: y
                        real(8), intent (in) :: z
                        real(8), intent (in) :: t
                        code = (x + ((y / (t - (x / z))) - (x / ((t * z) - x)))) / (x + 1.0d0)
                    end function
                    
                    public static double code(double x, double y, double z, double t) {
                    	return (x + ((y / (t - (x / z))) - (x / ((t * z) - x)))) / (x + 1.0);
                    }
                    
                    def code(x, y, z, t):
                    	return (x + ((y / (t - (x / z))) - (x / ((t * z) - x)))) / (x + 1.0)
                    
                    function code(x, y, z, t)
                    	return Float64(Float64(x + Float64(Float64(y / Float64(t - Float64(x / z))) - Float64(x / Float64(Float64(t * z) - x)))) / Float64(x + 1.0))
                    end
                    
                    function tmp = code(x, y, z, t)
                    	tmp = (x + ((y / (t - (x / z))) - (x / ((t * z) - x)))) / (x + 1.0);
                    end
                    
                    code[x_, y_, z_, t_] := N[(N[(x + N[(N[(y / N[(t - N[(x / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(x / N[(N[(t * z), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(x + 1.0), $MachinePrecision]), $MachinePrecision]
                    
                    \begin{array}{l}
                    
                    \\
                    \frac{x + \left(\frac{y}{t - \frac{x}{z}} - \frac{x}{t \cdot z - x}\right)}{x + 1}
                    \end{array}
                    

                    Reproduce

                    ?
                    herbie shell --seed 2024198 
                    (FPCore (x y z t)
                      :name "Diagrams.Trail:splitAtParam  from diagrams-lib-1.3.0.3, A"
                      :precision binary64
                    
                      :alt
                      (! :herbie-platform default (/ (+ x (- (/ y (- t (/ x z))) (/ x (- (* t z) x)))) (+ x 1)))
                    
                      (/ (+ x (/ (- (* y z) x) (- (* t z) x))) (+ x 1.0)))