Numeric.Signal:interpolate from hsignal-0.2.7.1

Percentage Accurate: 80.0% → 95.2%
Time: 8.4s
Alternatives: 19
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 19 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: 80.0% 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: 95.2% accurate, 0.3× speedup?

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

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

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


\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)))) < -9.99999999999999938e-279 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z))))

    1. Initial program 91.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. *-commutativeN/A

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

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

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

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

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

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

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

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

    1. Initial program 3.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. *-commutativeN/A

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

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

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

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

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

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(t - x, \frac{y - z}{a - z}, 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. fp-cancel-sign-sub-invN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 2: 45.1% accurate, 0.2× speedup?

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

\\
\begin{array}{l}
t_1 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
\mathbf{if}\;t\_1 \leq -2 \cdot 10^{+300} \lor \neg \left(t\_1 \leq -2 \cdot 10^{-274} \lor \neg \left(t\_1 \leq 0 \lor \neg \left(t\_1 \leq 10^{+306}\right)\right)\right):\\
\;\;\;\;\frac{x - t}{z} \cdot y\\

\mathbf{else}:\\
\;\;\;\;x + 1 \cdot t\\


\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)))) < -2.0000000000000001e300 or -1.99999999999999993e-274 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 0.0 or 1.00000000000000002e306 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z))))

    1. Initial program 44.0%

      \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -2.0000000000000001e300 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -1.99999999999999993e-274 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 1.00000000000000002e306

      1. Initial program 94.1%

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

        \[\leadsto x + \color{blue}{\left(t - x\right)} \]
      4. Step-by-step derivation
        1. lower--.f6428.8

          \[\leadsto x + \color{blue}{\left(t - x\right)} \]
      5. Applied rewrites28.8%

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

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

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

          \[\leadsto x + 1 \cdot t \]
        3. Step-by-step derivation
          1. Applied rewrites51.0%

            \[\leadsto x + 1 \cdot t \]
        4. Recombined 2 regimes into one program.
        5. Final simplification51.1%

          \[\leadsto \begin{array}{l} \mathbf{if}\;x + \left(y - z\right) \cdot \frac{t - x}{a - z} \leq -2 \cdot 10^{+300} \lor \neg \left(x + \left(y - z\right) \cdot \frac{t - x}{a - z} \leq -2 \cdot 10^{-274} \lor \neg \left(x + \left(y - z\right) \cdot \frac{t - x}{a - z} \leq 0 \lor \neg \left(x + \left(y - z\right) \cdot \frac{t - x}{a - z} \leq 10^{+306}\right)\right)\right):\\ \;\;\;\;\frac{x - t}{z} \cdot y\\ \mathbf{else}:\\ \;\;\;\;x + 1 \cdot t\\ \end{array} \]
        6. Add Preprocessing

        Alternative 3: 47.4% accurate, 0.2× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{x - t}{z} \cdot y\\ t_2 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\ t_3 := x + 1 \cdot t\\ \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+300}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_2 \leq -2 \cdot 10^{-274}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;t\_2 \leq 0:\\ \;\;\;\;\frac{\left(y - a\right) \cdot x}{z}\\ \mathbf{elif}\;t\_2 \leq 10^{+306}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
        (FPCore (x y z t a)
         :precision binary64
         (let* ((t_1 (* (/ (- x t) z) y))
                (t_2 (+ x (* (- y z) (/ (- t x) (- a z)))))
                (t_3 (+ x (* 1.0 t))))
           (if (<= t_2 -2e+300)
             t_1
             (if (<= t_2 -2e-274)
               t_3
               (if (<= t_2 0.0) (/ (* (- y a) x) z) (if (<= t_2 1e+306) t_3 t_1))))))
        double code(double x, double y, double z, double t, double a) {
        	double t_1 = ((x - t) / z) * y;
        	double t_2 = x + ((y - z) * ((t - x) / (a - z)));
        	double t_3 = x + (1.0 * t);
        	double tmp;
        	if (t_2 <= -2e+300) {
        		tmp = t_1;
        	} else if (t_2 <= -2e-274) {
        		tmp = t_3;
        	} else if (t_2 <= 0.0) {
        		tmp = ((y - a) * x) / z;
        	} else if (t_2 <= 1e+306) {
        		tmp = t_3;
        	} 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) :: t_2
            real(8) :: t_3
            real(8) :: tmp
            t_1 = ((x - t) / z) * y
            t_2 = x + ((y - z) * ((t - x) / (a - z)))
            t_3 = x + (1.0d0 * t)
            if (t_2 <= (-2d+300)) then
                tmp = t_1
            else if (t_2 <= (-2d-274)) then
                tmp = t_3
            else if (t_2 <= 0.0d0) then
                tmp = ((y - a) * x) / z
            else if (t_2 <= 1d+306) then
                tmp = t_3
            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 = ((x - t) / z) * y;
        	double t_2 = x + ((y - z) * ((t - x) / (a - z)));
        	double t_3 = x + (1.0 * t);
        	double tmp;
        	if (t_2 <= -2e+300) {
        		tmp = t_1;
        	} else if (t_2 <= -2e-274) {
        		tmp = t_3;
        	} else if (t_2 <= 0.0) {
        		tmp = ((y - a) * x) / z;
        	} else if (t_2 <= 1e+306) {
        		tmp = t_3;
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        def code(x, y, z, t, a):
        	t_1 = ((x - t) / z) * y
        	t_2 = x + ((y - z) * ((t - x) / (a - z)))
        	t_3 = x + (1.0 * t)
        	tmp = 0
        	if t_2 <= -2e+300:
        		tmp = t_1
        	elif t_2 <= -2e-274:
        		tmp = t_3
        	elif t_2 <= 0.0:
        		tmp = ((y - a) * x) / z
        	elif t_2 <= 1e+306:
        		tmp = t_3
        	else:
        		tmp = t_1
        	return tmp
        
        function code(x, y, z, t, a)
        	t_1 = Float64(Float64(Float64(x - t) / z) * y)
        	t_2 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z))))
        	t_3 = Float64(x + Float64(1.0 * t))
        	tmp = 0.0
        	if (t_2 <= -2e+300)
        		tmp = t_1;
        	elseif (t_2 <= -2e-274)
        		tmp = t_3;
        	elseif (t_2 <= 0.0)
        		tmp = Float64(Float64(Float64(y - a) * x) / z);
        	elseif (t_2 <= 1e+306)
        		tmp = t_3;
        	else
        		tmp = t_1;
        	end
        	return tmp
        end
        
        function tmp_2 = code(x, y, z, t, a)
        	t_1 = ((x - t) / z) * y;
        	t_2 = x + ((y - z) * ((t - x) / (a - z)));
        	t_3 = x + (1.0 * t);
        	tmp = 0.0;
        	if (t_2 <= -2e+300)
        		tmp = t_1;
        	elseif (t_2 <= -2e-274)
        		tmp = t_3;
        	elseif (t_2 <= 0.0)
        		tmp = ((y - a) * x) / z;
        	elseif (t_2 <= 1e+306)
        		tmp = t_3;
        	else
        		tmp = t_1;
        	end
        	tmp_2 = tmp;
        end
        
        code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision] * y), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x + N[(1.0 * t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -2e+300], t$95$1, If[LessEqual[t$95$2, -2e-274], t$95$3, If[LessEqual[t$95$2, 0.0], N[(N[(N[(y - a), $MachinePrecision] * x), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[t$95$2, 1e+306], t$95$3, t$95$1]]]]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \frac{x - t}{z} \cdot y\\
        t_2 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
        t_3 := x + 1 \cdot t\\
        \mathbf{if}\;t\_2 \leq -2 \cdot 10^{+300}:\\
        \;\;\;\;t\_1\\
        
        \mathbf{elif}\;t\_2 \leq -2 \cdot 10^{-274}:\\
        \;\;\;\;t\_3\\
        
        \mathbf{elif}\;t\_2 \leq 0:\\
        \;\;\;\;\frac{\left(y - a\right) \cdot x}{z}\\
        
        \mathbf{elif}\;t\_2 \leq 10^{+306}:\\
        \;\;\;\;t\_3\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_1\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -2.0000000000000001e300 or 1.00000000000000002e306 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z))))

          1. Initial program 79.5%

            \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

            if -2.0000000000000001e300 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -1.99999999999999993e-274 or 0.0 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 1.00000000000000002e306

            1. Initial program 94.1%

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

              \[\leadsto x + \color{blue}{\left(t - x\right)} \]
            4. Step-by-step derivation
              1. lower--.f6428.8

                \[\leadsto x + \color{blue}{\left(t - x\right)} \]
            5. Applied rewrites28.8%

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

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

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

                \[\leadsto x + 1 \cdot t \]
              3. Step-by-step derivation
                1. Applied rewrites51.0%

                  \[\leadsto x + 1 \cdot t \]

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

                1. Initial program 3.4%

                  \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                Alternative 4: 38.8% accurate, 0.3× speedup?

                \[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+300} \lor \neg \left(t\_1 \leq 10^{+298}\right):\\ \;\;\;\;\frac{t \cdot y}{a}\\ \mathbf{else}:\\ \;\;\;\;x + 1 \cdot t\\ \end{array} \end{array} \]
                (FPCore (x y z t a)
                 :precision binary64
                 (let* ((t_1 (+ x (* (- y z) (/ (- t x) (- a z))))))
                   (if (or (<= t_1 -2e+300) (not (<= t_1 1e+298)))
                     (/ (* t y) a)
                     (+ x (* 1.0 t)))))
                double code(double x, double y, double z, double t, double a) {
                	double t_1 = x + ((y - z) * ((t - x) / (a - z)));
                	double tmp;
                	if ((t_1 <= -2e+300) || !(t_1 <= 1e+298)) {
                		tmp = (t * y) / a;
                	} else {
                		tmp = x + (1.0 * t);
                	}
                	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 = x + ((y - z) * ((t - x) / (a - z)))
                    if ((t_1 <= (-2d+300)) .or. (.not. (t_1 <= 1d+298))) then
                        tmp = (t * y) / a
                    else
                        tmp = x + (1.0d0 * t)
                    end if
                    code = tmp
                end function
                
                public static double code(double x, double y, double z, double t, double a) {
                	double t_1 = x + ((y - z) * ((t - x) / (a - z)));
                	double tmp;
                	if ((t_1 <= -2e+300) || !(t_1 <= 1e+298)) {
                		tmp = (t * y) / a;
                	} else {
                		tmp = x + (1.0 * t);
                	}
                	return tmp;
                }
                
                def code(x, y, z, t, a):
                	t_1 = x + ((y - z) * ((t - x) / (a - z)))
                	tmp = 0
                	if (t_1 <= -2e+300) or not (t_1 <= 1e+298):
                		tmp = (t * y) / a
                	else:
                		tmp = x + (1.0 * t)
                	return tmp
                
                function code(x, y, z, t, a)
                	t_1 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z))))
                	tmp = 0.0
                	if ((t_1 <= -2e+300) || !(t_1 <= 1e+298))
                		tmp = Float64(Float64(t * y) / a);
                	else
                		tmp = Float64(x + Float64(1.0 * t));
                	end
                	return tmp
                end
                
                function tmp_2 = code(x, y, z, t, a)
                	t_1 = x + ((y - z) * ((t - x) / (a - z)));
                	tmp = 0.0;
                	if ((t_1 <= -2e+300) || ~((t_1 <= 1e+298)))
                		tmp = (t * y) / a;
                	else
                		tmp = x + (1.0 * t);
                	end
                	tmp_2 = tmp;
                end
                
                code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -2e+300], N[Not[LessEqual[t$95$1, 1e+298]], $MachinePrecision]], N[(N[(t * y), $MachinePrecision] / a), $MachinePrecision], N[(x + N[(1.0 * t), $MachinePrecision]), $MachinePrecision]]]
                
                \begin{array}{l}
                
                \\
                \begin{array}{l}
                t_1 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
                \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+300} \lor \neg \left(t\_1 \leq 10^{+298}\right):\\
                \;\;\;\;\frac{t \cdot y}{a}\\
                
                \mathbf{else}:\\
                \;\;\;\;x + 1 \cdot t\\
                
                
                \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)))) < -2.0000000000000001e300 or 9.9999999999999996e297 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z))))

                  1. Initial program 80.0%

                    \[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--.f6458.4

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

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

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

                      \[\leadsto \frac{t - x}{a} \cdot \color{blue}{y} \]
                    2. Taylor expanded in x around 0

                      \[\leadsto \frac{t \cdot y}{a} \]
                    3. Step-by-step derivation
                      1. Applied rewrites47.6%

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

                      if -2.0000000000000001e300 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 9.9999999999999996e297

                      1. Initial program 78.9%

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

                        \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                      4. Step-by-step derivation
                        1. lower--.f6424.6

                          \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                      5. Applied rewrites24.6%

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

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

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

                          \[\leadsto x + 1 \cdot t \]
                        3. Step-by-step derivation
                          1. Applied rewrites43.1%

                            \[\leadsto x + 1 \cdot t \]
                        4. Recombined 2 regimes into one program.
                        5. Final simplification43.9%

                          \[\leadsto \begin{array}{l} \mathbf{if}\;x + \left(y - z\right) \cdot \frac{t - x}{a - z} \leq -2 \cdot 10^{+300} \lor \neg \left(x + \left(y - z\right) \cdot \frac{t - x}{a - z} \leq 10^{+298}\right):\\ \;\;\;\;\frac{t \cdot y}{a}\\ \mathbf{else}:\\ \;\;\;\;x + 1 \cdot t\\ \end{array} \]
                        6. Add Preprocessing

                        Alternative 5: 75.7% accurate, 0.8× speedup?

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

                          1. Initial program 91.8%

                            \[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--.f6483.2

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

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

                          if -1.35000000000000002e-4 < a < 4.00000000000000021e32

                          1. Initial program 66.9%

                            \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        Alternative 6: 43.9% accurate, 0.8× speedup?

                        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.1 \cdot 10^{+165}:\\ \;\;\;\;t \cdot \frac{y}{a - z}\\ \mathbf{elif}\;y \leq -9.5 \cdot 10^{+71}:\\ \;\;\;\;\frac{x - t}{z} \cdot y\\ \mathbf{elif}\;y \leq 6 \cdot 10^{+123}:\\ \;\;\;\;x + 1 \cdot t\\ \mathbf{else}:\\ \;\;\;\;\frac{t - x}{a} \cdot y\\ \end{array} \end{array} \]
                        (FPCore (x y z t a)
                         :precision binary64
                         (if (<= y -2.1e+165)
                           (* t (/ y (- a z)))
                           (if (<= y -9.5e+71)
                             (* (/ (- x t) z) y)
                             (if (<= y 6e+123) (+ x (* 1.0 t)) (* (/ (- t x) a) y)))))
                        double code(double x, double y, double z, double t, double a) {
                        	double tmp;
                        	if (y <= -2.1e+165) {
                        		tmp = t * (y / (a - z));
                        	} else if (y <= -9.5e+71) {
                        		tmp = ((x - t) / z) * y;
                        	} else if (y <= 6e+123) {
                        		tmp = x + (1.0 * t);
                        	} else {
                        		tmp = ((t - x) / a) * y;
                        	}
                        	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) :: tmp
                            if (y <= (-2.1d+165)) then
                                tmp = t * (y / (a - z))
                            else if (y <= (-9.5d+71)) then
                                tmp = ((x - t) / z) * y
                            else if (y <= 6d+123) then
                                tmp = x + (1.0d0 * t)
                            else
                                tmp = ((t - x) / a) * y
                            end if
                            code = tmp
                        end function
                        
                        public static double code(double x, double y, double z, double t, double a) {
                        	double tmp;
                        	if (y <= -2.1e+165) {
                        		tmp = t * (y / (a - z));
                        	} else if (y <= -9.5e+71) {
                        		tmp = ((x - t) / z) * y;
                        	} else if (y <= 6e+123) {
                        		tmp = x + (1.0 * t);
                        	} else {
                        		tmp = ((t - x) / a) * y;
                        	}
                        	return tmp;
                        }
                        
                        def code(x, y, z, t, a):
                        	tmp = 0
                        	if y <= -2.1e+165:
                        		tmp = t * (y / (a - z))
                        	elif y <= -9.5e+71:
                        		tmp = ((x - t) / z) * y
                        	elif y <= 6e+123:
                        		tmp = x + (1.0 * t)
                        	else:
                        		tmp = ((t - x) / a) * y
                        	return tmp
                        
                        function code(x, y, z, t, a)
                        	tmp = 0.0
                        	if (y <= -2.1e+165)
                        		tmp = Float64(t * Float64(y / Float64(a - z)));
                        	elseif (y <= -9.5e+71)
                        		tmp = Float64(Float64(Float64(x - t) / z) * y);
                        	elseif (y <= 6e+123)
                        		tmp = Float64(x + Float64(1.0 * t));
                        	else
                        		tmp = Float64(Float64(Float64(t - x) / a) * y);
                        	end
                        	return tmp
                        end
                        
                        function tmp_2 = code(x, y, z, t, a)
                        	tmp = 0.0;
                        	if (y <= -2.1e+165)
                        		tmp = t * (y / (a - z));
                        	elseif (y <= -9.5e+71)
                        		tmp = ((x - t) / z) * y;
                        	elseif (y <= 6e+123)
                        		tmp = x + (1.0 * t);
                        	else
                        		tmp = ((t - x) / a) * y;
                        	end
                        	tmp_2 = tmp;
                        end
                        
                        code[x_, y_, z_, t_, a_] := If[LessEqual[y, -2.1e+165], N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -9.5e+71], N[(N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision] * y), $MachinePrecision], If[LessEqual[y, 6e+123], N[(x + N[(1.0 * t), $MachinePrecision]), $MachinePrecision], N[(N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision] * y), $MachinePrecision]]]]
                        
                        \begin{array}{l}
                        
                        \\
                        \begin{array}{l}
                        \mathbf{if}\;y \leq -2.1 \cdot 10^{+165}:\\
                        \;\;\;\;t \cdot \frac{y}{a - z}\\
                        
                        \mathbf{elif}\;y \leq -9.5 \cdot 10^{+71}:\\
                        \;\;\;\;\frac{x - t}{z} \cdot y\\
                        
                        \mathbf{elif}\;y \leq 6 \cdot 10^{+123}:\\
                        \;\;\;\;x + 1 \cdot t\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;\frac{t - x}{a} \cdot y\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 4 regimes
                        2. if y < -2.1000000000000001e165

                          1. Initial program 93.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. *-commutativeN/A

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

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

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

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

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

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

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

                            \[\leadsto \color{blue}{y \cdot \left(\frac{t}{a - z} - \frac{x}{a - z}\right)} \]
                          6. 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. *-commutativeN/A

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

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

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

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

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

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

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

                            if -2.1000000000000001e165 < y < -9.50000000000000015e71

                            1. Initial program 74.7%

                              \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                              if -9.50000000000000015e71 < y < 6.00000000000000016e123

                              1. Initial program 74.2%

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

                                \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                              4. Step-by-step derivation
                                1. lower--.f6427.9

                                  \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                              5. Applied rewrites27.9%

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

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

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

                                  \[\leadsto x + 1 \cdot t \]
                                3. Step-by-step derivation
                                  1. Applied rewrites46.7%

                                    \[\leadsto x + 1 \cdot t \]

                                  if 6.00000000000000016e123 < y

                                  1. Initial program 92.4%

                                    \[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--.f6472.6

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

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

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

                                      \[\leadsto \frac{t - x}{a} \cdot \color{blue}{y} \]
                                  8. Recombined 4 regimes into one program.
                                  9. Final simplification51.8%

                                    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.1 \cdot 10^{+165}:\\ \;\;\;\;t \cdot \frac{y}{a - z}\\ \mathbf{elif}\;y \leq -9.5 \cdot 10^{+71}:\\ \;\;\;\;\frac{x - t}{z} \cdot y\\ \mathbf{elif}\;y \leq 6 \cdot 10^{+123}:\\ \;\;\;\;x + 1 \cdot t\\ \mathbf{else}:\\ \;\;\;\;\frac{t - x}{a} \cdot y\\ \end{array} \]
                                  10. Add Preprocessing

                                  Alternative 7: 45.4% accurate, 0.8× speedup?

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

                                    1. Initial program 91.3%

                                      \[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--.f6484.4

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

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

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

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

                                        \[\leadsto \mathsf{fma}\left(-1 \cdot z, \frac{\color{blue}{t}}{a}, x\right) \]
                                      3. Step-by-step derivation
                                        1. Applied rewrites61.8%

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

                                        if -9.00000000000000023e-6 < a < 3.4000000000000001e-12

                                        1. Initial program 66.6%

                                          \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                          if 3.4000000000000001e-12 < a < 6.5999999999999997e168

                                          1. Initial program 87.6%

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

                                            \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                          4. Step-by-step derivation
                                            1. lower--.f6425.0

                                              \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                          5. Applied rewrites25.0%

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

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

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

                                              \[\leadsto x + 1 \cdot t \]
                                            3. Step-by-step derivation
                                              1. Applied rewrites49.4%

                                                \[\leadsto x + 1 \cdot t \]
                                            4. Recombined 3 regimes into one program.
                                            5. Add Preprocessing

                                            Alternative 8: 43.9% accurate, 0.8× speedup?

                                            \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t - x}{a} \cdot y\\ \mathbf{if}\;y \leq -5.2 \cdot 10^{+158}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq -9.5 \cdot 10^{+71}:\\ \;\;\;\;\frac{x - t}{z} \cdot y\\ \mathbf{elif}\;y \leq 6 \cdot 10^{+123}:\\ \;\;\;\;x + 1 \cdot t\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                                            (FPCore (x y z t a)
                                             :precision binary64
                                             (let* ((t_1 (* (/ (- t x) a) y)))
                                               (if (<= y -5.2e+158)
                                                 t_1
                                                 (if (<= y -9.5e+71)
                                                   (* (/ (- x t) z) y)
                                                   (if (<= y 6e+123) (+ x (* 1.0 t)) t_1)))))
                                            double code(double x, double y, double z, double t, double a) {
                                            	double t_1 = ((t - x) / a) * y;
                                            	double tmp;
                                            	if (y <= -5.2e+158) {
                                            		tmp = t_1;
                                            	} else if (y <= -9.5e+71) {
                                            		tmp = ((x - t) / z) * y;
                                            	} else if (y <= 6e+123) {
                                            		tmp = x + (1.0 * t);
                                            	} 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 - x) / a) * y
                                                if (y <= (-5.2d+158)) then
                                                    tmp = t_1
                                                else if (y <= (-9.5d+71)) then
                                                    tmp = ((x - t) / z) * y
                                                else if (y <= 6d+123) then
                                                    tmp = x + (1.0d0 * t)
                                                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 - x) / a) * y;
                                            	double tmp;
                                            	if (y <= -5.2e+158) {
                                            		tmp = t_1;
                                            	} else if (y <= -9.5e+71) {
                                            		tmp = ((x - t) / z) * y;
                                            	} else if (y <= 6e+123) {
                                            		tmp = x + (1.0 * t);
                                            	} else {
                                            		tmp = t_1;
                                            	}
                                            	return tmp;
                                            }
                                            
                                            def code(x, y, z, t, a):
                                            	t_1 = ((t - x) / a) * y
                                            	tmp = 0
                                            	if y <= -5.2e+158:
                                            		tmp = t_1
                                            	elif y <= -9.5e+71:
                                            		tmp = ((x - t) / z) * y
                                            	elif y <= 6e+123:
                                            		tmp = x + (1.0 * t)
                                            	else:
                                            		tmp = t_1
                                            	return tmp
                                            
                                            function code(x, y, z, t, a)
                                            	t_1 = Float64(Float64(Float64(t - x) / a) * y)
                                            	tmp = 0.0
                                            	if (y <= -5.2e+158)
                                            		tmp = t_1;
                                            	elseif (y <= -9.5e+71)
                                            		tmp = Float64(Float64(Float64(x - t) / z) * y);
                                            	elseif (y <= 6e+123)
                                            		tmp = Float64(x + Float64(1.0 * t));
                                            	else
                                            		tmp = t_1;
                                            	end
                                            	return tmp
                                            end
                                            
                                            function tmp_2 = code(x, y, z, t, a)
                                            	t_1 = ((t - x) / a) * y;
                                            	tmp = 0.0;
                                            	if (y <= -5.2e+158)
                                            		tmp = t_1;
                                            	elseif (y <= -9.5e+71)
                                            		tmp = ((x - t) / z) * y;
                                            	elseif (y <= 6e+123)
                                            		tmp = x + (1.0 * t);
                                            	else
                                            		tmp = t_1;
                                            	end
                                            	tmp_2 = tmp;
                                            end
                                            
                                            code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision] * y), $MachinePrecision]}, If[LessEqual[y, -5.2e+158], t$95$1, If[LessEqual[y, -9.5e+71], N[(N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision] * y), $MachinePrecision], If[LessEqual[y, 6e+123], N[(x + N[(1.0 * t), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
                                            
                                            \begin{array}{l}
                                            
                                            \\
                                            \begin{array}{l}
                                            t_1 := \frac{t - x}{a} \cdot y\\
                                            \mathbf{if}\;y \leq -5.2 \cdot 10^{+158}:\\
                                            \;\;\;\;t\_1\\
                                            
                                            \mathbf{elif}\;y \leq -9.5 \cdot 10^{+71}:\\
                                            \;\;\;\;\frac{x - t}{z} \cdot y\\
                                            
                                            \mathbf{elif}\;y \leq 6 \cdot 10^{+123}:\\
                                            \;\;\;\;x + 1 \cdot t\\
                                            
                                            \mathbf{else}:\\
                                            \;\;\;\;t\_1\\
                                            
                                            
                                            \end{array}
                                            \end{array}
                                            
                                            Derivation
                                            1. Split input into 3 regimes
                                            2. if y < -5.2e158 or 6.00000000000000016e123 < y

                                              1. Initial program 92.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--.f6472.3

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

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

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

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

                                                if -5.2e158 < y < -9.50000000000000015e71

                                                1. Initial program 74.7%

                                                  \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                  if -9.50000000000000015e71 < y < 6.00000000000000016e123

                                                  1. Initial program 74.2%

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

                                                    \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                  4. Step-by-step derivation
                                                    1. lower--.f6427.9

                                                      \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                  5. Applied rewrites27.9%

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

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

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

                                                      \[\leadsto x + 1 \cdot t \]
                                                    3. Step-by-step derivation
                                                      1. Applied rewrites46.7%

                                                        \[\leadsto x + 1 \cdot t \]
                                                    4. Recombined 3 regimes into one program.
                                                    5. Add Preprocessing

                                                    Alternative 9: 75.9% accurate, 0.8× speedup?

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

                                                      1. Initial program 89.3%

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

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

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

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

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

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

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

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

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

                                                      if -1.35000000000000002e-4 < a < 4.00000000000000021e32

                                                      1. Initial program 66.9%

                                                        \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                      if 4.00000000000000021e32 < a

                                                      1. Initial program 94.4%

                                                        \[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--.f6483.2

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

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

                                                    Alternative 10: 72.8% accurate, 0.8× speedup?

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

                                                      1. Initial program 91.8%

                                                        \[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--.f6483.2

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

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

                                                      if -1.21999999999999997e-4 < a < 2.6000000000000002e32

                                                      1. Initial program 66.9%

                                                        \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                      Alternative 11: 69.6% accurate, 0.9× speedup?

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

                                                        1. Initial program 91.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. *-commutativeN/A

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

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

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

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

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

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

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

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

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

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

                                                        if -1.29999999999999989e-4 < a < 6e32

                                                        1. Initial program 66.9%

                                                          \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                        Alternative 12: 69.0% accurate, 0.9× speedup?

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

                                                          1. Initial program 91.8%

                                                            \[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--.f6483.2

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

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

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

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

                                                            if -2.1000000000000001e-4 < a < 8.1999999999999997e34

                                                            1. Initial program 66.9%

                                                              \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                            Alternative 13: 61.8% accurate, 0.9× speedup?

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

                                                              1. Initial program 91.9%

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

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

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

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

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

                                                                  \[\leadsto \mathsf{fma}\left(-1 \cdot z, \frac{\color{blue}{t}}{a}, x\right) \]
                                                                3. Step-by-step derivation
                                                                  1. Applied rewrites57.2%

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

                                                                  if -5.5999999999999996e49 < a < 1.40000000000000001e39

                                                                  1. Initial program 68.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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                                    \[\leadsto \begin{array}{l} \mathbf{if}\;a \leq -5.6 \cdot 10^{+49} \lor \neg \left(a \leq 1.4 \cdot 10^{+39}\right):\\ \;\;\;\;\mathsf{fma}\left(-z, \frac{t}{a}, x\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(\frac{x - t}{z}, y, t\right)\\ \end{array} \]
                                                                  10. Add Preprocessing

                                                                  Alternative 14: 68.7% accurate, 0.9× speedup?

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

                                                                    1. Initial program 89.3%

                                                                      \[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--.f6483.2

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

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

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

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

                                                                      if -2.1000000000000001e-4 < a < 6e32

                                                                      1. Initial program 66.9%

                                                                        \[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 + -1 \cdot \frac{y \cdot \left(t - x\right)}{z}\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(-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. +-commutativeN/A

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                                        if 6e32 < a

                                                                        1. Initial program 94.4%

                                                                          \[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. *-commutativeN/A

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

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

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

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

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

                                                                      Alternative 15: 38.7% accurate, 0.9× speedup?

                                                                      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -5.4 \cdot 10^{+140}:\\ \;\;\;\;\frac{t}{a} \cdot y\\ \mathbf{elif}\;y \leq 9.5 \cdot 10^{+164}:\\ \;\;\;\;x + 1 \cdot t\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{-a} \cdot x\\ \end{array} \end{array} \]
                                                                      (FPCore (x y z t a)
                                                                       :precision binary64
                                                                       (if (<= y -5.4e+140)
                                                                         (* (/ t a) y)
                                                                         (if (<= y 9.5e+164) (+ x (* 1.0 t)) (* (/ y (- a)) x))))
                                                                      double code(double x, double y, double z, double t, double a) {
                                                                      	double tmp;
                                                                      	if (y <= -5.4e+140) {
                                                                      		tmp = (t / a) * y;
                                                                      	} else if (y <= 9.5e+164) {
                                                                      		tmp = x + (1.0 * t);
                                                                      	} else {
                                                                      		tmp = (y / -a) * x;
                                                                      	}
                                                                      	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) :: tmp
                                                                          if (y <= (-5.4d+140)) then
                                                                              tmp = (t / a) * y
                                                                          else if (y <= 9.5d+164) then
                                                                              tmp = x + (1.0d0 * t)
                                                                          else
                                                                              tmp = (y / -a) * x
                                                                          end if
                                                                          code = tmp
                                                                      end function
                                                                      
                                                                      public static double code(double x, double y, double z, double t, double a) {
                                                                      	double tmp;
                                                                      	if (y <= -5.4e+140) {
                                                                      		tmp = (t / a) * y;
                                                                      	} else if (y <= 9.5e+164) {
                                                                      		tmp = x + (1.0 * t);
                                                                      	} else {
                                                                      		tmp = (y / -a) * x;
                                                                      	}
                                                                      	return tmp;
                                                                      }
                                                                      
                                                                      def code(x, y, z, t, a):
                                                                      	tmp = 0
                                                                      	if y <= -5.4e+140:
                                                                      		tmp = (t / a) * y
                                                                      	elif y <= 9.5e+164:
                                                                      		tmp = x + (1.0 * t)
                                                                      	else:
                                                                      		tmp = (y / -a) * x
                                                                      	return tmp
                                                                      
                                                                      function code(x, y, z, t, a)
                                                                      	tmp = 0.0
                                                                      	if (y <= -5.4e+140)
                                                                      		tmp = Float64(Float64(t / a) * y);
                                                                      	elseif (y <= 9.5e+164)
                                                                      		tmp = Float64(x + Float64(1.0 * t));
                                                                      	else
                                                                      		tmp = Float64(Float64(y / Float64(-a)) * x);
                                                                      	end
                                                                      	return tmp
                                                                      end
                                                                      
                                                                      function tmp_2 = code(x, y, z, t, a)
                                                                      	tmp = 0.0;
                                                                      	if (y <= -5.4e+140)
                                                                      		tmp = (t / a) * y;
                                                                      	elseif (y <= 9.5e+164)
                                                                      		tmp = x + (1.0 * t);
                                                                      	else
                                                                      		tmp = (y / -a) * x;
                                                                      	end
                                                                      	tmp_2 = tmp;
                                                                      end
                                                                      
                                                                      code[x_, y_, z_, t_, a_] := If[LessEqual[y, -5.4e+140], N[(N[(t / a), $MachinePrecision] * y), $MachinePrecision], If[LessEqual[y, 9.5e+164], N[(x + N[(1.0 * t), $MachinePrecision]), $MachinePrecision], N[(N[(y / (-a)), $MachinePrecision] * x), $MachinePrecision]]]
                                                                      
                                                                      \begin{array}{l}
                                                                      
                                                                      \\
                                                                      \begin{array}{l}
                                                                      \mathbf{if}\;y \leq -5.4 \cdot 10^{+140}:\\
                                                                      \;\;\;\;\frac{t}{a} \cdot y\\
                                                                      
                                                                      \mathbf{elif}\;y \leq 9.5 \cdot 10^{+164}:\\
                                                                      \;\;\;\;x + 1 \cdot t\\
                                                                      
                                                                      \mathbf{else}:\\
                                                                      \;\;\;\;\frac{y}{-a} \cdot x\\
                                                                      
                                                                      
                                                                      \end{array}
                                                                      \end{array}
                                                                      
                                                                      Derivation
                                                                      1. Split input into 3 regimes
                                                                      2. if y < -5.40000000000000036e140

                                                                        1. Initial program 93.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--.f6464.8

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

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

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

                                                                            \[\leadsto \frac{t - x}{a} \cdot \color{blue}{y} \]
                                                                          2. Taylor expanded in x around 0

                                                                            \[\leadsto \frac{t}{a} \cdot y \]
                                                                          3. Step-by-step derivation
                                                                            1. Applied rewrites40.8%

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

                                                                            if -5.40000000000000036e140 < y < 9.49999999999999976e164

                                                                            1. Initial program 75.4%

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

                                                                              \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                            4. Step-by-step derivation
                                                                              1. lower--.f6426.3

                                                                                \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                            5. Applied rewrites26.3%

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

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

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

                                                                                \[\leadsto x + 1 \cdot t \]
                                                                              3. Step-by-step derivation
                                                                                1. Applied rewrites45.4%

                                                                                  \[\leadsto x + 1 \cdot t \]

                                                                                if 9.49999999999999976e164 < y

                                                                                1. Initial program 89.1%

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

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

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

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

                                                                                    \[\leadsto \frac{t - x}{a} \cdot \color{blue}{y} \]
                                                                                  2. Taylor expanded in x around inf

                                                                                    \[\leadsto -1 \cdot \frac{x \cdot y}{\color{blue}{a}} \]
                                                                                  3. Step-by-step derivation
                                                                                    1. Applied rewrites46.0%

                                                                                      \[\leadsto \frac{y}{a} \cdot \left(-x\right) \]
                                                                                  4. Recombined 3 regimes into one program.
                                                                                  5. Final simplification44.9%

                                                                                    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5.4 \cdot 10^{+140}:\\ \;\;\;\;\frac{t}{a} \cdot y\\ \mathbf{elif}\;y \leq 9.5 \cdot 10^{+164}:\\ \;\;\;\;x + 1 \cdot t\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{-a} \cdot x\\ \end{array} \]
                                                                                  6. Add Preprocessing

                                                                                  Alternative 16: 39.1% accurate, 1.0× speedup?

                                                                                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -5.4 \cdot 10^{+140} \lor \neg \left(y \leq 1.5 \cdot 10^{+132}\right):\\ \;\;\;\;\frac{t}{a} \cdot y\\ \mathbf{else}:\\ \;\;\;\;x + 1 \cdot t\\ \end{array} \end{array} \]
                                                                                  (FPCore (x y z t a)
                                                                                   :precision binary64
                                                                                   (if (or (<= y -5.4e+140) (not (<= y 1.5e+132)))
                                                                                     (* (/ t a) y)
                                                                                     (+ x (* 1.0 t))))
                                                                                  double code(double x, double y, double z, double t, double a) {
                                                                                  	double tmp;
                                                                                  	if ((y <= -5.4e+140) || !(y <= 1.5e+132)) {
                                                                                  		tmp = (t / a) * y;
                                                                                  	} else {
                                                                                  		tmp = x + (1.0 * t);
                                                                                  	}
                                                                                  	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) :: tmp
                                                                                      if ((y <= (-5.4d+140)) .or. (.not. (y <= 1.5d+132))) then
                                                                                          tmp = (t / a) * y
                                                                                      else
                                                                                          tmp = x + (1.0d0 * t)
                                                                                      end if
                                                                                      code = tmp
                                                                                  end function
                                                                                  
                                                                                  public static double code(double x, double y, double z, double t, double a) {
                                                                                  	double tmp;
                                                                                  	if ((y <= -5.4e+140) || !(y <= 1.5e+132)) {
                                                                                  		tmp = (t / a) * y;
                                                                                  	} else {
                                                                                  		tmp = x + (1.0 * t);
                                                                                  	}
                                                                                  	return tmp;
                                                                                  }
                                                                                  
                                                                                  def code(x, y, z, t, a):
                                                                                  	tmp = 0
                                                                                  	if (y <= -5.4e+140) or not (y <= 1.5e+132):
                                                                                  		tmp = (t / a) * y
                                                                                  	else:
                                                                                  		tmp = x + (1.0 * t)
                                                                                  	return tmp
                                                                                  
                                                                                  function code(x, y, z, t, a)
                                                                                  	tmp = 0.0
                                                                                  	if ((y <= -5.4e+140) || !(y <= 1.5e+132))
                                                                                  		tmp = Float64(Float64(t / a) * y);
                                                                                  	else
                                                                                  		tmp = Float64(x + Float64(1.0 * t));
                                                                                  	end
                                                                                  	return tmp
                                                                                  end
                                                                                  
                                                                                  function tmp_2 = code(x, y, z, t, a)
                                                                                  	tmp = 0.0;
                                                                                  	if ((y <= -5.4e+140) || ~((y <= 1.5e+132)))
                                                                                  		tmp = (t / a) * y;
                                                                                  	else
                                                                                  		tmp = x + (1.0 * t);
                                                                                  	end
                                                                                  	tmp_2 = tmp;
                                                                                  end
                                                                                  
                                                                                  code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -5.4e+140], N[Not[LessEqual[y, 1.5e+132]], $MachinePrecision]], N[(N[(t / a), $MachinePrecision] * y), $MachinePrecision], N[(x + N[(1.0 * t), $MachinePrecision]), $MachinePrecision]]
                                                                                  
                                                                                  \begin{array}{l}
                                                                                  
                                                                                  \\
                                                                                  \begin{array}{l}
                                                                                  \mathbf{if}\;y \leq -5.4 \cdot 10^{+140} \lor \neg \left(y \leq 1.5 \cdot 10^{+132}\right):\\
                                                                                  \;\;\;\;\frac{t}{a} \cdot y\\
                                                                                  
                                                                                  \mathbf{else}:\\
                                                                                  \;\;\;\;x + 1 \cdot t\\
                                                                                  
                                                                                  
                                                                                  \end{array}
                                                                                  \end{array}
                                                                                  
                                                                                  Derivation
                                                                                  1. Split input into 2 regimes
                                                                                  2. if y < -5.40000000000000036e140 or 1.4999999999999999e132 < y

                                                                                    1. Initial program 93.0%

                                                                                      \[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--.f6469.2

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

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

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

                                                                                        \[\leadsto \frac{t - x}{a} \cdot \color{blue}{y} \]
                                                                                      2. Taylor expanded in x around 0

                                                                                        \[\leadsto \frac{t}{a} \cdot y \]
                                                                                      3. Step-by-step derivation
                                                                                        1. Applied rewrites40.7%

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

                                                                                        if -5.40000000000000036e140 < y < 1.4999999999999999e132

                                                                                        1. Initial program 73.8%

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

                                                                                          \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                        4. Step-by-step derivation
                                                                                          1. lower--.f6427.3

                                                                                            \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                        5. Applied rewrites27.3%

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

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

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

                                                                                            \[\leadsto x + 1 \cdot t \]
                                                                                          3. Step-by-step derivation
                                                                                            1. Applied rewrites46.0%

                                                                                              \[\leadsto x + 1 \cdot t \]
                                                                                          4. Recombined 2 regimes into one program.
                                                                                          5. Final simplification44.5%

                                                                                            \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -5.4 \cdot 10^{+140} \lor \neg \left(y \leq 1.5 \cdot 10^{+132}\right):\\ \;\;\;\;\frac{t}{a} \cdot y\\ \mathbf{else}:\\ \;\;\;\;x + 1 \cdot t\\ \end{array} \]
                                                                                          6. Add Preprocessing

                                                                                          Alternative 17: 33.4% accurate, 3.2× speedup?

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

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

                                                                                            \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                          4. Step-by-step derivation
                                                                                            1. lower--.f6422.2

                                                                                              \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                          5. Applied rewrites22.2%

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

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

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

                                                                                              \[\leadsto x + 1 \cdot t \]
                                                                                            3. Step-by-step derivation
                                                                                              1. Applied rewrites38.2%

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

                                                                                              Alternative 18: 18.5% accurate, 4.1× speedup?

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

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

                                                                                                \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                              4. Step-by-step derivation
                                                                                                1. lower--.f6422.2

                                                                                                  \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                              5. Applied rewrites22.2%

                                                                                                \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                              6. Add Preprocessing

                                                                                              Alternative 19: 2.8% accurate, 4.8× speedup?

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

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

                                                                                                \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                              4. Step-by-step derivation
                                                                                                1. lower--.f6422.2

                                                                                                  \[\leadsto x + \color{blue}{\left(t - x\right)} \]
                                                                                              5. Applied rewrites22.2%

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

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

                                                                                                  \[\leadsto x + \left(-x\right) \]
                                                                                                2. Add Preprocessing

                                                                                                Reproduce

                                                                                                ?
                                                                                                herbie shell --seed 2024329 
                                                                                                (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)))))