Numeric.Signal:interpolate from hsignal-0.2.7.1

Percentage Accurate: 81.1% → 94.9%
Time: 13.7s
Alternatives: 15
Speedup: 0.3×

Specification

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

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

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

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

Alternative 1: 94.9% accurate, 0.3× speedup?

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -5.00000000000000028e-280 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z))))

    1. Initial program 88.4%

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
      9. lift--.f64N/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
      10. flip--N/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
      11. clear-numN/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
      12. clear-numN/A

        \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
      13. flip--N/A

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

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
      16. lower-/.f6492.5

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

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

    if -5.00000000000000028e-280 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0

    1. Initial program 3.7%

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
      9. lift--.f64N/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
      10. flip--N/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
      11. clear-numN/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
      12. clear-numN/A

        \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
      13. flip--N/A

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

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
      16. lower-/.f643.9

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 2: 67.6% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(y - z\right) \cdot \frac{t}{a - z}\\ t_2 := \mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\ \mathbf{if}\;a \leq -3.1 \cdot 10^{+24}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;a \leq -4.3 \cdot 10^{-32}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq 7.5 \cdot 10^{-133}:\\ \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;a \leq 1.16 \cdot 10^{-89}:\\ \;\;\;\;\frac{y \cdot \left(t - x\right)}{a - z}\\ \mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* (- y z) (/ t (- a z)))) (t_2 (fma (/ y a) (- t x) x)))
   (if (<= a -3.1e+24)
     t_2
     (if (<= a -4.3e-32)
       t_1
       (if (<= a 7.5e-133)
         (+ t (/ (* y (- x t)) z))
         (if (<= a 1.16e-89)
           (/ (* y (- t x)) (- a z))
           (if (<= a 7.7e+64) t_1 t_2)))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = (y - z) * (t / (a - z));
	double t_2 = fma((y / a), (t - x), x);
	double tmp;
	if (a <= -3.1e+24) {
		tmp = t_2;
	} else if (a <= -4.3e-32) {
		tmp = t_1;
	} else if (a <= 7.5e-133) {
		tmp = t + ((y * (x - t)) / z);
	} else if (a <= 1.16e-89) {
		tmp = (y * (t - x)) / (a - z);
	} else if (a <= 7.7e+64) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
function code(x, y, z, t, a)
	t_1 = Float64(Float64(y - z) * Float64(t / Float64(a - z)))
	t_2 = fma(Float64(y / a), Float64(t - x), x)
	tmp = 0.0
	if (a <= -3.1e+24)
		tmp = t_2;
	elseif (a <= -4.3e-32)
		tmp = t_1;
	elseif (a <= 7.5e-133)
		tmp = Float64(t + Float64(Float64(y * Float64(x - t)) / z));
	elseif (a <= 1.16e-89)
		tmp = Float64(Float64(y * Float64(t - x)) / Float64(a - z));
	elseif (a <= 7.7e+64)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(y - z), $MachinePrecision] * N[(t / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(y / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[a, -3.1e+24], t$95$2, If[LessEqual[a, -4.3e-32], t$95$1, If[LessEqual[a, 7.5e-133], N[(t + N[(N[(y * N[(x - t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.16e-89], N[(N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 7.7e+64], t$95$1, t$95$2]]]]]]]
\begin{array}{l}

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

\mathbf{elif}\;a \leq -4.3 \cdot 10^{-32}:\\
\;\;\;\;t\_1\\

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

\mathbf{elif}\;a \leq 1.16 \cdot 10^{-89}:\\
\;\;\;\;\frac{y \cdot \left(t - x\right)}{a - z}\\

\mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -3.10000000000000011e24 or 7.6999999999999999e64 < a

    1. Initial program 83.6%

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
      9. lift--.f64N/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
      10. flip--N/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
      11. clear-numN/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
      12. clear-numN/A

        \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
      13. flip--N/A

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

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

        \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
      16. lower-/.f6486.7

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

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

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

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

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

    if -3.10000000000000011e24 < a < -4.2999999999999999e-32 or 1.15999999999999993e-89 < a < 7.6999999999999999e64

    1. Initial program 80.3%

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
      9. lift--.f64N/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
      10. flip--N/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
      11. clear-numN/A

        \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
      12. clear-numN/A

        \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
      13. flip--N/A

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

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

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

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

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

      \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
    6. Step-by-step derivation
      1. div-subN/A

        \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
      2. associate-/l*N/A

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

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

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

        \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
      6. lower--.f6441.8

        \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
    7. Applied rewrites41.8%

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

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

      if -4.2999999999999999e-32 < a < 7.4999999999999999e-133

      1. Initial program 67.2%

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

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

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

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

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

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

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

        if 7.4999999999999999e-133 < a < 1.15999999999999993e-89

        1. Initial program 70.9%

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

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

            \[\leadsto y \cdot \color{blue}{\frac{t - x}{a - z}} \]
          2. associate-/l*N/A

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

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

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

            \[\leadsto \frac{y \cdot \color{blue}{\left(t - x\right)}}{a - z} \]
          6. lower--.f6490.0

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

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

        \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -3.1 \cdot 10^{+24}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\ \mathbf{elif}\;a \leq -4.3 \cdot 10^{-32}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{t}{a - z}\\ \mathbf{elif}\;a \leq 7.5 \cdot 10^{-133}:\\ \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;a \leq 1.16 \cdot 10^{-89}:\\ \;\;\;\;\frac{y \cdot \left(t - x\right)}{a - z}\\ \mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{t}{a - z}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\ \end{array} \]
      10. Add Preprocessing

      Alternative 3: 71.7% accurate, 0.6× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y - z}{a - z}\\ t_2 := \mathsf{fma}\left(y - z, \frac{t - x}{a}, x\right)\\ \mathbf{if}\;a \leq -1.45 \cdot 10^{+22}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;a \leq -4.4 \cdot 10^{-167}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq 1.15 \cdot 10^{-200}:\\ \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
      (FPCore (x y z t a)
       :precision binary64
       (let* ((t_1 (* t (/ (- y z) (- a z)))) (t_2 (fma (- y z) (/ (- t x) a) x)))
         (if (<= a -1.45e+22)
           t_2
           (if (<= a -4.4e-167)
             t_1
             (if (<= a 1.15e-200)
               (+ t (/ (* y (- x t)) z))
               (if (<= a 7.7e+64) t_1 t_2))))))
      double code(double x, double y, double z, double t, double a) {
      	double t_1 = t * ((y - z) / (a - z));
      	double t_2 = fma((y - z), ((t - x) / a), x);
      	double tmp;
      	if (a <= -1.45e+22) {
      		tmp = t_2;
      	} else if (a <= -4.4e-167) {
      		tmp = t_1;
      	} else if (a <= 1.15e-200) {
      		tmp = t + ((y * (x - t)) / z);
      	} else if (a <= 7.7e+64) {
      		tmp = t_1;
      	} else {
      		tmp = t_2;
      	}
      	return tmp;
      }
      
      function code(x, y, z, t, a)
      	t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z)))
      	t_2 = fma(Float64(y - z), Float64(Float64(t - x) / a), x)
      	tmp = 0.0
      	if (a <= -1.45e+22)
      		tmp = t_2;
      	elseif (a <= -4.4e-167)
      		tmp = t_1;
      	elseif (a <= 1.15e-200)
      		tmp = Float64(t + Float64(Float64(y * Float64(x - t)) / z));
      	elseif (a <= 7.7e+64)
      		tmp = t_1;
      	else
      		tmp = t_2;
      	end
      	return tmp
      end
      
      code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[a, -1.45e+22], t$95$2, If[LessEqual[a, -4.4e-167], t$95$1, If[LessEqual[a, 1.15e-200], N[(t + N[(N[(y * N[(x - t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 7.7e+64], t$95$1, t$95$2]]]]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      t_1 := t \cdot \frac{y - z}{a - z}\\
      t_2 := \mathsf{fma}\left(y - z, \frac{t - x}{a}, x\right)\\
      \mathbf{if}\;a \leq -1.45 \cdot 10^{+22}:\\
      \;\;\;\;t\_2\\
      
      \mathbf{elif}\;a \leq -4.4 \cdot 10^{-167}:\\
      \;\;\;\;t\_1\\
      
      \mathbf{elif}\;a \leq 1.15 \cdot 10^{-200}:\\
      \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\
      
      \mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\
      \;\;\;\;t\_1\\
      
      \mathbf{else}:\\
      \;\;\;\;t\_2\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if a < -1.45e22 or 7.6999999999999999e64 < a

        1. Initial program 83.6%

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

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

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

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

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

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

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

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

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

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

        if -1.45e22 < a < -4.3999999999999999e-167 or 1.15000000000000004e-200 < a < 7.6999999999999999e64

        1. Initial program 74.6%

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

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

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

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

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

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

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

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

            \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
          9. lift--.f64N/A

            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
          10. flip--N/A

            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
          11. clear-numN/A

            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
          12. clear-numN/A

            \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
          13. flip--N/A

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

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

            \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
          16. lower-/.f6478.5

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

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

          \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
        6. Step-by-step derivation
          1. div-subN/A

            \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
          2. associate-/l*N/A

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

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

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

            \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
          6. lower--.f6452.7

            \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
        7. Applied rewrites52.7%

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

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

          if -4.3999999999999999e-167 < a < 1.15000000000000004e-200

          1. Initial program 65.2%

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

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

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

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

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

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

              \[\leadsto t - \color{blue}{\frac{\left(t - x\right) \cdot y}{z}} \]
          8. Recombined 3 regimes into one program.
          9. Final simplification74.0%

            \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -1.45 \cdot 10^{+22}:\\ \;\;\;\;\mathsf{fma}\left(y - z, \frac{t - x}{a}, x\right)\\ \mathbf{elif}\;a \leq -4.4 \cdot 10^{-167}:\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{elif}\;a \leq 1.15 \cdot 10^{-200}:\\ \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(y - z, \frac{t - x}{a}, x\right)\\ \end{array} \]
          10. Add Preprocessing

          Alternative 4: 68.7% accurate, 0.6× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y - z}{a - z}\\ t_2 := \mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\ \mathbf{if}\;a \leq -3.1 \cdot 10^{+24}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;a \leq -4.4 \cdot 10^{-167}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq 1.15 \cdot 10^{-200}:\\ \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
          (FPCore (x y z t a)
           :precision binary64
           (let* ((t_1 (* t (/ (- y z) (- a z)))) (t_2 (fma (/ y a) (- t x) x)))
             (if (<= a -3.1e+24)
               t_2
               (if (<= a -4.4e-167)
                 t_1
                 (if (<= a 1.15e-200)
                   (+ t (/ (* y (- x t)) z))
                   (if (<= a 7.7e+64) t_1 t_2))))))
          double code(double x, double y, double z, double t, double a) {
          	double t_1 = t * ((y - z) / (a - z));
          	double t_2 = fma((y / a), (t - x), x);
          	double tmp;
          	if (a <= -3.1e+24) {
          		tmp = t_2;
          	} else if (a <= -4.4e-167) {
          		tmp = t_1;
          	} else if (a <= 1.15e-200) {
          		tmp = t + ((y * (x - t)) / z);
          	} else if (a <= 7.7e+64) {
          		tmp = t_1;
          	} else {
          		tmp = t_2;
          	}
          	return tmp;
          }
          
          function code(x, y, z, t, a)
          	t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z)))
          	t_2 = fma(Float64(y / a), Float64(t - x), x)
          	tmp = 0.0
          	if (a <= -3.1e+24)
          		tmp = t_2;
          	elseif (a <= -4.4e-167)
          		tmp = t_1;
          	elseif (a <= 1.15e-200)
          		tmp = Float64(t + Float64(Float64(y * Float64(x - t)) / z));
          	elseif (a <= 7.7e+64)
          		tmp = t_1;
          	else
          		tmp = t_2;
          	end
          	return tmp
          end
          
          code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(y / a), $MachinePrecision] * N[(t - x), $MachinePrecision] + x), $MachinePrecision]}, If[LessEqual[a, -3.1e+24], t$95$2, If[LessEqual[a, -4.4e-167], t$95$1, If[LessEqual[a, 1.15e-200], N[(t + N[(N[(y * N[(x - t), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 7.7e+64], t$95$1, t$95$2]]]]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          t_1 := t \cdot \frac{y - z}{a - z}\\
          t_2 := \mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\
          \mathbf{if}\;a \leq -3.1 \cdot 10^{+24}:\\
          \;\;\;\;t\_2\\
          
          \mathbf{elif}\;a \leq -4.4 \cdot 10^{-167}:\\
          \;\;\;\;t\_1\\
          
          \mathbf{elif}\;a \leq 1.15 \cdot 10^{-200}:\\
          \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\
          
          \mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\
          \;\;\;\;t\_1\\
          
          \mathbf{else}:\\
          \;\;\;\;t\_2\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if a < -3.10000000000000011e24 or 7.6999999999999999e64 < a

            1. Initial program 83.6%

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

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

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

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

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

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

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

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

                \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
              9. lift--.f64N/A

                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
              10. flip--N/A

                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
              11. clear-numN/A

                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
              12. clear-numN/A

                \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
              13. flip--N/A

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

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

                \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
              16. lower-/.f6486.7

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

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

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

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

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

            if -3.10000000000000011e24 < a < -4.3999999999999999e-167 or 1.15000000000000004e-200 < a < 7.6999999999999999e64

            1. Initial program 74.6%

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

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

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

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

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

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

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

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

                \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
              9. lift--.f64N/A

                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
              10. flip--N/A

                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
              11. clear-numN/A

                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
              12. clear-numN/A

                \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
              13. flip--N/A

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

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

                \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
              16. lower-/.f6478.5

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

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

              \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
            6. Step-by-step derivation
              1. div-subN/A

                \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
              2. associate-/l*N/A

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

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

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

                \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
              6. lower--.f6452.7

                \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
            7. Applied rewrites52.7%

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

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

              if -4.3999999999999999e-167 < a < 1.15000000000000004e-200

              1. Initial program 65.2%

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

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

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

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

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

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

                  \[\leadsto t - \color{blue}{\frac{\left(t - x\right) \cdot y}{z}} \]
              8. Recombined 3 regimes into one program.
              9. Final simplification71.1%

                \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -3.1 \cdot 10^{+24}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\ \mathbf{elif}\;a \leq -4.4 \cdot 10^{-167}:\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{elif}\;a \leq 1.15 \cdot 10^{-200}:\\ \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\ \mathbf{elif}\;a \leq 7.7 \cdot 10^{+64}:\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\ \end{array} \]
              10. Add Preprocessing

              Alternative 5: 80.5% accurate, 0.8× speedup?

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

                1. Initial program 54.5%

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

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

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

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

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

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

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

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

                    \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                  9. lift--.f64N/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                  10. flip--N/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                  11. clear-numN/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                  12. clear-numN/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                  13. flip--N/A

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                  16. lower-/.f6458.3

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                if -2.80000000000000002e71 < z < 5.7000000000000002e110

                1. Initial program 90.8%

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

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

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

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

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

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

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

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

                    \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                  9. lift--.f64N/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                  10. flip--N/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                  11. clear-numN/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                  12. clear-numN/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                  13. flip--N/A

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                  16. lower-/.f6494.2

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

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

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

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

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

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

              Alternative 6: 75.2% accurate, 0.8× speedup?

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

                1. Initial program 58.7%

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

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

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

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

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

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

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

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

                    \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                  9. lift--.f64N/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                  10. flip--N/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                  11. clear-numN/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                  12. clear-numN/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                  13. flip--N/A

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                  16. lower-/.f6462.8

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                if -3.4999999999999999e71 < z < 1.94999999999999996

                1. Initial program 91.7%

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

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

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

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

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

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

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

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

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

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

              Alternative 7: 68.3% accurate, 0.8× speedup?

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

                1. Initial program 84.7%

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

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

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

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

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

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

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

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

                    \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                  9. lift--.f64N/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                  10. flip--N/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                  11. clear-numN/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                  12. clear-numN/A

                    \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                  13. flip--N/A

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                  16. lower-/.f6490.4

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

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

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

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

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

                if -9.5e19 < a < 3.3999999999999998e-9

                1. Initial program 70.1%

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

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

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

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

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

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

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

                  if 3.3999999999999998e-9 < a

                  1. Initial program 81.8%

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

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

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

                      \[\leadsto \color{blue}{y \cdot \frac{t - x}{a}} + x \]
                    3. lower-fma.f64N/A

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

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

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

                    \[\leadsto \color{blue}{\mathsf{fma}\left(y, \frac{t - x}{a}, x\right)} \]
                8. Recombined 3 regimes into one program.
                9. Final simplification66.7%

                  \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -9.5 \cdot 10^{+19}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\ \mathbf{elif}\;a \leq 3.4 \cdot 10^{-9}:\\ \;\;\;\;t + \frac{y \cdot \left(x - t\right)}{z}\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(y, \frac{t - x}{a}, x\right)\\ \end{array} \]
                10. Add Preprocessing

                Alternative 8: 63.8% accurate, 0.9× speedup?

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

                  1. Initial program 59.5%

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

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

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

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

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

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

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

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

                      \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                    9. lift--.f64N/A

                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                    10. flip--N/A

                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                    11. clear-numN/A

                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                    12. clear-numN/A

                      \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                    13. flip--N/A

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

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

                      \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                    16. lower-/.f6465.0

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

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

                    \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                  6. Step-by-step derivation
                    1. div-subN/A

                      \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                    2. associate-/l*N/A

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

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

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

                      \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                    6. lower--.f6435.6

                      \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                  7. Applied rewrites35.6%

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

                    \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot \left(y - z\right)}{z}} \]
                  9. Step-by-step derivation
                    1. Applied rewrites56.3%

                      \[\leadsto -\mathsf{fma}\left(t, \frac{y}{z}, -t\right) \]
                    2. Step-by-step derivation
                      1. Applied rewrites56.3%

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

                      if -1.1500000000000001e78 < z < 5.7000000000000002e110

                      1. Initial program 90.3%

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

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

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

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

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

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

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

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

                          \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                        9. lift--.f64N/A

                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                        10. flip--N/A

                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                        11. clear-numN/A

                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                        12. clear-numN/A

                          \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                        13. flip--N/A

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

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

                          \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                        16. lower-/.f6493.7

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

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

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

                          \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{y}{a}}, t - x, x\right) \]
                      7. Applied rewrites69.3%

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

                      if 5.7000000000000002e110 < z

                      1. Initial program 48.9%

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

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

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

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

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

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

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

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

                          \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                        9. lift--.f64N/A

                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                        10. flip--N/A

                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                        11. clear-numN/A

                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                        12. clear-numN/A

                          \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                        13. flip--N/A

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

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

                          \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                        16. lower-/.f6450.9

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

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

                        \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                      6. Step-by-step derivation
                        1. div-subN/A

                          \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                        2. associate-/l*N/A

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

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

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

                          \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                        6. lower--.f6430.6

                          \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                      7. Applied rewrites30.6%

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

                        \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                      9. Step-by-step derivation
                        1. Applied rewrites53.0%

                          \[\leadsto -t \cdot \frac{z}{a - z} \]
                      10. Recombined 3 regimes into one program.
                      11. Final simplification64.0%

                        \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.15 \cdot 10^{+78}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{z}, -t, t\right)\\ \mathbf{elif}\;z \leq 5.7 \cdot 10^{+110}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y}{a}, t - x, x\right)\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{z}{z - a}\\ \end{array} \]
                      12. Add Preprocessing

                      Alternative 9: 64.0% accurate, 0.9× speedup?

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

                        1. Initial program 54.5%

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

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

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

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

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

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

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

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

                            \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                          9. lift--.f64N/A

                            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                          10. flip--N/A

                            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                          11. clear-numN/A

                            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                          12. clear-numN/A

                            \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                          13. flip--N/A

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

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

                            \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                          16. lower-/.f6458.4

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

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

                          \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                        6. Step-by-step derivation
                          1. div-subN/A

                            \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                          2. associate-/l*N/A

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

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

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

                            \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                          6. lower--.f6433.3

                            \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                        7. Applied rewrites33.3%

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

                          \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot \left(y - z\right)}{z}} \]
                        9. Step-by-step derivation
                          1. Applied rewrites53.3%

                            \[\leadsto -\mathsf{fma}\left(t, \frac{y}{z}, -t\right) \]
                          2. Step-by-step derivation
                            1. Applied rewrites53.3%

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

                            if -1.1500000000000001e78 < z < 5.7000000000000002e110

                            1. Initial program 90.3%

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

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

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

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

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

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

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

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

                                \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                              9. lift--.f64N/A

                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                              10. flip--N/A

                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                              11. clear-numN/A

                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                              12. clear-numN/A

                                \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                              13. flip--N/A

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

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

                                \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                              16. lower-/.f6493.7

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

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

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

                                \[\leadsto \mathsf{fma}\left(\color{blue}{\frac{y}{a}}, t - x, x\right) \]
                            7. Applied rewrites69.3%

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

                          Alternative 10: 63.0% accurate, 0.9× speedup?

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

                            1. Initial program 54.0%

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

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

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

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

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

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

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

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

                                \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                              9. lift--.f64N/A

                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                              10. flip--N/A

                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                              11. clear-numN/A

                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                              12. clear-numN/A

                                \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                              13. flip--N/A

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

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

                                \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                              16. lower-/.f6458.9

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

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

                              \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                            6. Step-by-step derivation
                              1. div-subN/A

                                \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                              2. associate-/l*N/A

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

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

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

                                \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                              6. lower--.f6434.0

                                \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                            7. Applied rewrites34.0%

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

                              \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot \left(y - z\right)}{z}} \]
                            9. Step-by-step derivation
                              1. Applied rewrites52.8%

                                \[\leadsto -\mathsf{fma}\left(t, \frac{y}{z}, -t\right) \]
                              2. Step-by-step derivation
                                1. Applied rewrites52.8%

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

                                if -1.1500000000000001e78 < z < 2.2e104

                                1. Initial program 90.8%

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

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

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

                                    \[\leadsto \color{blue}{y \cdot \frac{t - x}{a}} + x \]
                                  3. lower-fma.f64N/A

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

                                    \[\leadsto \mathsf{fma}\left(y, \color{blue}{\frac{t - x}{a}}, x\right) \]
                                  5. lower--.f6468.0

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

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

                              Alternative 11: 54.5% accurate, 0.9× speedup?

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

                                1. Initial program 83.3%

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

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

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

                                    \[\leadsto x + \frac{\color{blue}{y \cdot \left(t - x\right)}}{a} \]
                                  3. lower--.f6456.7

                                    \[\leadsto x + \frac{y \cdot \color{blue}{\left(t - x\right)}}{a} \]
                                5. Applied rewrites56.7%

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

                                  \[\leadsto x + \frac{t \cdot y}{a} \]
                                7. Step-by-step derivation
                                  1. Applied rewrites53.9%

                                    \[\leadsto x + \frac{t \cdot y}{a} \]

                                  if -1.3e20 < a < 3.7999999999999998e-10

                                  1. Initial program 70.1%

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

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

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

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

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

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

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

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

                                      \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                                    9. lift--.f64N/A

                                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                                    10. flip--N/A

                                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                                    11. clear-numN/A

                                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                                    12. clear-numN/A

                                      \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                                    13. flip--N/A

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

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

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                                    16. lower-/.f6475.2

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

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

                                    \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                                  6. Step-by-step derivation
                                    1. div-subN/A

                                      \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                                    2. associate-/l*N/A

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

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

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

                                      \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                                    6. lower--.f6448.0

                                      \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                                  7. Applied rewrites48.0%

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

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

                                      \[\leadsto -\mathsf{fma}\left(t, \frac{y}{z}, -t\right) \]
                                    2. Step-by-step derivation
                                      1. Applied rewrites54.9%

                                        \[\leadsto \mathsf{fma}\left(\frac{y}{z}, -t, t\right) \]
                                    3. Recombined 2 regimes into one program.
                                    4. Final simplification54.4%

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

                                    Alternative 12: 43.0% accurate, 0.9× speedup?

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

                                      1. Initial program 69.8%

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

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

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

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

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

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

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

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

                                          \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                                        9. lift--.f64N/A

                                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                                        10. flip--N/A

                                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                                        11. clear-numN/A

                                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                                        12. clear-numN/A

                                          \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                                        13. flip--N/A

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

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

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

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

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

                                        \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                                      6. Step-by-step derivation
                                        1. div-subN/A

                                          \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                                        2. associate-/l*N/A

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

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

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

                                          \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                                        6. lower--.f6435.7

                                          \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                                      7. Applied rewrites35.7%

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

                                        \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot \left(y - z\right)}{z}} \]
                                      9. Step-by-step derivation
                                        1. Applied rewrites42.8%

                                          \[\leadsto -\mathsf{fma}\left(t, \frac{y}{z}, -t\right) \]
                                        2. Step-by-step derivation
                                          1. Applied rewrites42.8%

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

                                          if -8.99999999999999935e-30 < z < 2.99999999999999996e-131

                                          1. Initial program 89.8%

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

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

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

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

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

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

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

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

                                              \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                                            9. lift--.f64N/A

                                              \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                                            10. flip--N/A

                                              \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                                            11. clear-numN/A

                                              \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                                            12. clear-numN/A

                                              \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                                            13. flip--N/A

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

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

                                              \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                                            16. lower-/.f6495.6

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

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

                                            \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                                          6. Step-by-step derivation
                                            1. div-subN/A

                                              \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                                            2. associate-/l*N/A

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

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

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

                                              \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                                            6. lower--.f6433.9

                                              \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                                          7. Applied rewrites33.9%

                                            \[\leadsto \color{blue}{\frac{t \cdot \left(y - z\right)}{a - z}} \]
                                          8. Taylor expanded in y around inf

                                            \[\leadsto \frac{t \cdot y}{\color{blue}{a - z}} \]
                                          9. Step-by-step derivation
                                            1. Applied rewrites35.1%

                                              \[\leadsto t \cdot \color{blue}{\frac{y}{a - z}} \]
                                          10. Recombined 2 regimes into one program.
                                          11. Add Preprocessing

                                          Alternative 13: 38.8% accurate, 0.9× speedup?

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

                                            1. Initial program 58.6%

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

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

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

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

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

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

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

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

                                                \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                                              9. lift--.f64N/A

                                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                                              10. flip--N/A

                                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                                              11. clear-numN/A

                                                \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                                              12. clear-numN/A

                                                \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                                              13. flip--N/A

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

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

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

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

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

                                              \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                                            6. Step-by-step derivation
                                              1. div-subN/A

                                                \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                                              2. associate-/l*N/A

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

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

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

                                                \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                                              6. lower--.f6435.6

                                                \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                                            7. Applied rewrites35.6%

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

                                              \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot \left(y - z\right)}{z}} \]
                                            9. Step-by-step derivation
                                              1. Applied rewrites50.4%

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

                                                \[\leadsto \mathsf{neg}\left(-1 \cdot t\right) \]
                                              3. Step-by-step derivation
                                                1. Applied rewrites46.3%

                                                  \[\leadsto -\left(-t\right) \]

                                                if -5e79 < z < 860

                                                1. Initial program 90.7%

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

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

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

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

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

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

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

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

                                                    \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                                                  9. lift--.f64N/A

                                                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                                                  10. flip--N/A

                                                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                                                  11. clear-numN/A

                                                    \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                                                  12. clear-numN/A

                                                    \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                                                  13. flip--N/A

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

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

                                                    \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                                                  16. lower-/.f6493.8

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

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

                                                  \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                                                6. Step-by-step derivation
                                                  1. div-subN/A

                                                    \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                                                  2. associate-/l*N/A

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

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

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

                                                    \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                                                  6. lower--.f6434.6

                                                    \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                                                7. Applied rewrites34.6%

                                                  \[\leadsto \color{blue}{\frac{t \cdot \left(y - z\right)}{a - z}} \]
                                                8. Taylor expanded in y around inf

                                                  \[\leadsto \frac{t \cdot y}{\color{blue}{a - z}} \]
                                                9. Step-by-step derivation
                                                  1. Applied rewrites29.9%

                                                    \[\leadsto t \cdot \color{blue}{\frac{y}{a - z}} \]
                                                10. Recombined 2 regimes into one program.
                                                11. Add Preprocessing

                                                Alternative 14: 36.1% accurate, 1.0× speedup?

                                                \[\begin{array}{l} \\ \begin{array}{l} t_1 := -\left(-t\right)\\ \mathbf{if}\;z \leq -3.1 \cdot 10^{-29}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 700:\\ \;\;\;\;t \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                                                (FPCore (x y z t a)
                                                 :precision binary64
                                                 (let* ((t_1 (- (- t))))
                                                   (if (<= z -3.1e-29) t_1 (if (<= z 700.0) (* t (/ y a)) t_1))))
                                                double code(double x, double y, double z, double t, double a) {
                                                	double t_1 = -(-t);
                                                	double tmp;
                                                	if (z <= -3.1e-29) {
                                                		tmp = t_1;
                                                	} else if (z <= 700.0) {
                                                		tmp = t * (y / a);
                                                	} else {
                                                		tmp = t_1;
                                                	}
                                                	return tmp;
                                                }
                                                
                                                real(8) function code(x, y, z, t, a)
                                                    real(8), intent (in) :: x
                                                    real(8), intent (in) :: y
                                                    real(8), intent (in) :: z
                                                    real(8), intent (in) :: t
                                                    real(8), intent (in) :: a
                                                    real(8) :: t_1
                                                    real(8) :: tmp
                                                    t_1 = -(-t)
                                                    if (z <= (-3.1d-29)) then
                                                        tmp = t_1
                                                    else if (z <= 700.0d0) then
                                                        tmp = t * (y / a)
                                                    else
                                                        tmp = t_1
                                                    end if
                                                    code = tmp
                                                end function
                                                
                                                public static double code(double x, double y, double z, double t, double a) {
                                                	double t_1 = -(-t);
                                                	double tmp;
                                                	if (z <= -3.1e-29) {
                                                		tmp = t_1;
                                                	} else if (z <= 700.0) {
                                                		tmp = t * (y / a);
                                                	} else {
                                                		tmp = t_1;
                                                	}
                                                	return tmp;
                                                }
                                                
                                                def code(x, y, z, t, a):
                                                	t_1 = -(-t)
                                                	tmp = 0
                                                	if z <= -3.1e-29:
                                                		tmp = t_1
                                                	elif z <= 700.0:
                                                		tmp = t * (y / a)
                                                	else:
                                                		tmp = t_1
                                                	return tmp
                                                
                                                function code(x, y, z, t, a)
                                                	t_1 = Float64(-Float64(-t))
                                                	tmp = 0.0
                                                	if (z <= -3.1e-29)
                                                		tmp = t_1;
                                                	elseif (z <= 700.0)
                                                		tmp = Float64(t * Float64(y / a));
                                                	else
                                                		tmp = t_1;
                                                	end
                                                	return tmp
                                                end
                                                
                                                function tmp_2 = code(x, y, z, t, a)
                                                	t_1 = -(-t);
                                                	tmp = 0.0;
                                                	if (z <= -3.1e-29)
                                                		tmp = t_1;
                                                	elseif (z <= 700.0)
                                                		tmp = t * (y / a);
                                                	else
                                                		tmp = t_1;
                                                	end
                                                	tmp_2 = tmp;
                                                end
                                                
                                                code[x_, y_, z_, t_, a_] := Block[{t$95$1 = (-(-t))}, If[LessEqual[z, -3.1e-29], t$95$1, If[LessEqual[z, 700.0], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], t$95$1]]]
                                                
                                                \begin{array}{l}
                                                
                                                \\
                                                \begin{array}{l}
                                                t_1 := -\left(-t\right)\\
                                                \mathbf{if}\;z \leq -3.1 \cdot 10^{-29}:\\
                                                \;\;\;\;t\_1\\
                                                
                                                \mathbf{elif}\;z \leq 700:\\
                                                \;\;\;\;t \cdot \frac{y}{a}\\
                                                
                                                \mathbf{else}:\\
                                                \;\;\;\;t\_1\\
                                                
                                                
                                                \end{array}
                                                \end{array}
                                                
                                                Derivation
                                                1. Split input into 2 regimes
                                                2. if z < -3.10000000000000026e-29 or 700 < z

                                                  1. Initial program 64.1%

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

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

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

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

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

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

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

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

                                                      \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                                                    9. lift--.f64N/A

                                                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                                                    10. flip--N/A

                                                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                                                    11. clear-numN/A

                                                      \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                                                    12. clear-numN/A

                                                      \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                                                    13. flip--N/A

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

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

                                                      \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                                                    16. lower-/.f6467.0

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

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

                                                    \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                                                  6. Step-by-step derivation
                                                    1. div-subN/A

                                                      \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                                                    2. associate-/l*N/A

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

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

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

                                                      \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                                                    6. lower--.f6434.5

                                                      \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                                                  7. Applied rewrites34.5%

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

                                                    \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot \left(y - z\right)}{z}} \]
                                                  9. Step-by-step derivation
                                                    1. Applied rewrites46.5%

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

                                                      \[\leadsto \mathsf{neg}\left(-1 \cdot t\right) \]
                                                    3. Step-by-step derivation
                                                      1. Applied rewrites40.7%

                                                        \[\leadsto -\left(-t\right) \]

                                                      if -3.10000000000000026e-29 < z < 700

                                                      1. Initial program 90.8%

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

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

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

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

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

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

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

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

                                                          \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                                                        9. lift--.f64N/A

                                                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                                                        10. flip--N/A

                                                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                                                        11. clear-numN/A

                                                          \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                                                        12. clear-numN/A

                                                          \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                                                        13. flip--N/A

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

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

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

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

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

                                                        \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                                                      6. Step-by-step derivation
                                                        1. div-subN/A

                                                          \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                                                        2. associate-/l*N/A

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

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

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

                                                          \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                                                        6. lower--.f6435.6

                                                          \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                                                      7. Applied rewrites35.6%

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

                                                        \[\leadsto \frac{t \cdot y}{\color{blue}{a}} \]
                                                      9. Step-by-step derivation
                                                        1. Applied rewrites21.7%

                                                          \[\leadsto \frac{y \cdot t}{\color{blue}{a}} \]
                                                        2. Step-by-step derivation
                                                          1. Applied rewrites25.8%

                                                            \[\leadsto t \cdot \frac{y}{\color{blue}{a}} \]
                                                        3. Recombined 2 regimes into one program.
                                                        4. Add Preprocessing

                                                        Alternative 15: 24.7% accurate, 5.8× speedup?

                                                        \[\begin{array}{l} \\ -\left(-t\right) \end{array} \]
                                                        (FPCore (x y z t a) :precision binary64 (- (- t)))
                                                        double code(double x, double y, double z, double t, double a) {
                                                        	return -(-t);
                                                        }
                                                        
                                                        real(8) function code(x, y, z, t, a)
                                                            real(8), intent (in) :: x
                                                            real(8), intent (in) :: y
                                                            real(8), intent (in) :: z
                                                            real(8), intent (in) :: t
                                                            real(8), intent (in) :: a
                                                            code = -(-t)
                                                        end function
                                                        
                                                        public static double code(double x, double y, double z, double t, double a) {
                                                        	return -(-t);
                                                        }
                                                        
                                                        def code(x, y, z, t, a):
                                                        	return -(-t)
                                                        
                                                        function code(x, y, z, t, a)
                                                        	return Float64(-Float64(-t))
                                                        end
                                                        
                                                        function tmp = code(x, y, z, t, a)
                                                        	tmp = -(-t);
                                                        end
                                                        
                                                        code[x_, y_, z_, t_, a_] := (-(-t))
                                                        
                                                        \begin{array}{l}
                                                        
                                                        \\
                                                        -\left(-t\right)
                                                        \end{array}
                                                        
                                                        Derivation
                                                        1. Initial program 77.1%

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

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

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

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

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

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

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

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

                                                            \[\leadsto \color{blue}{\frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{t - x}}} + x \]
                                                          9. lift--.f64N/A

                                                            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{t - x}}} + x \]
                                                          10. flip--N/A

                                                            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\frac{1}{\color{blue}{\frac{t \cdot t - x \cdot x}{t + x}}}} + x \]
                                                          11. clear-numN/A

                                                            \[\leadsto \frac{y - z}{a - z} \cdot \frac{1}{\color{blue}{\frac{t + x}{t \cdot t - x \cdot x}}} + x \]
                                                          12. clear-numN/A

                                                            \[\leadsto \frac{y - z}{a - z} \cdot \color{blue}{\frac{t \cdot t - x \cdot x}{t + x}} + x \]
                                                          13. flip--N/A

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

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

                                                            \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)} \]
                                                          16. lower-/.f6480.7

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

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

                                                          \[\leadsto \color{blue}{t \cdot \left(\frac{y}{a - z} - \frac{z}{a - z}\right)} \]
                                                        6. Step-by-step derivation
                                                          1. div-subN/A

                                                            \[\leadsto t \cdot \color{blue}{\frac{y - z}{a - z}} \]
                                                          2. associate-/l*N/A

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

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

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

                                                            \[\leadsto \frac{t \cdot \color{blue}{\left(y - z\right)}}{a - z} \]
                                                          6. lower--.f6435.0

                                                            \[\leadsto \frac{t \cdot \left(y - z\right)}{\color{blue}{a - z}} \]
                                                        7. Applied rewrites35.0%

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

                                                          \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot \left(y - z\right)}{z}} \]
                                                        9. Step-by-step derivation
                                                          1. Applied rewrites33.3%

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

                                                            \[\leadsto \mathsf{neg}\left(-1 \cdot t\right) \]
                                                          3. Step-by-step derivation
                                                            1. Applied rewrites24.0%

                                                              \[\leadsto -\left(-t\right) \]
                                                            2. Add Preprocessing

                                                            Reproduce

                                                            ?
                                                            herbie shell --seed 2024220 
                                                            (FPCore (x y z t a)
                                                              :name "Numeric.Signal:interpolate   from hsignal-0.2.7.1"
                                                              :precision binary64
                                                              (+ x (* (- y z) (/ (- t x) (- a z)))))