Numeric.Signal:interpolate from hsignal-0.2.7.1

Percentage Accurate: 79.4% → 90.2%
Time: 9.1s
Alternatives: 21
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)));
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a)
use fmin_fmax_functions
    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 21 alternatives:

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

Initial Program: 79.4% 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)));
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a)
use fmin_fmax_functions
    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: 90.2% accurate, 0.3× speedup?

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

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

\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{-202}:\\
\;\;\;\;\mathsf{fma}\left(-\left(t - x\right), \frac{y - a}{z}, t\right)\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(t\_1, y - z, x\right)\\


\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)))) < -3.99999999999999982e-212

    1. Initial program 92.1%

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

    if -3.99999999999999982e-212 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 4.99999999999999973e-202

    1. Initial program 12.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--.f6488.2

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

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

    if 4.99999999999999973e-202 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z))))

    1. Initial program 91.1%

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

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

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

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

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

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

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

Alternative 2: 90.2% accurate, 0.3× speedup?

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

\\
\begin{array}{l}
t_1 := \frac{t - x}{a - z}\\
t_2 := x + \left(y - z\right) \cdot t\_1\\
\mathbf{if}\;t\_2 \leq -4 \cdot 10^{-212} \lor \neg \left(t\_2 \leq 5 \cdot 10^{-202}\right):\\
\;\;\;\;\mathsf{fma}\left(t\_1, y - z, 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 (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < -3.99999999999999982e-212 or 4.99999999999999973e-202 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z))))

    1. Initial program 91.6%

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

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

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

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

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

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

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

    if -3.99999999999999982e-212 < (+.f64 x (*.f64 (-.f64 y z) (/.f64 (-.f64 t x) (-.f64 a z)))) < 4.99999999999999973e-202

    1. Initial program 12.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--.f6488.2

        \[\leadsto \mathsf{fma}\left(-\left(t - x\right), \frac{\color{blue}{y - a}}{z}, t\right) \]
    5. Applied rewrites88.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 simplification91.1%

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

Alternative 3: 66.4% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{y - a}{z} \cdot x + t\\ \mathbf{if}\;z \leq -1.7 \cdot 10^{+32}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -2.3 \cdot 10^{-134}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 7.2 \cdot 10^{-93}:\\ \;\;\;\;x + \frac{\left(t - x\right) \cdot y}{a}\\ \mathbf{elif}\;z \leq 4.3 \cdot 10^{+166}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{t}{a - z}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ (* (/ (- y a) z) x) t)))
   (if (<= z -1.7e+32)
     t_1
     (if (<= z -2.3e-134)
       (* (- t x) (/ y (- a z)))
       (if (<= z 7.2e-93)
         (+ x (/ (* (- t x) y) a))
         (if (<= z 4.3e+166) (* (- y z) (/ t (- a z))) t_1))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = (((y - a) / z) * x) + t;
	double tmp;
	if (z <= -1.7e+32) {
		tmp = t_1;
	} else if (z <= -2.3e-134) {
		tmp = (t - x) * (y / (a - z));
	} else if (z <= 7.2e-93) {
		tmp = x + (((t - x) * y) / a);
	} else if (z <= 4.3e+166) {
		tmp = (y - z) * (t / (a - z));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a)
use fmin_fmax_functions
    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 = (((y - a) / z) * x) + t
    if (z <= (-1.7d+32)) then
        tmp = t_1
    else if (z <= (-2.3d-134)) then
        tmp = (t - x) * (y / (a - z))
    else if (z <= 7.2d-93) then
        tmp = x + (((t - x) * y) / a)
    else if (z <= 4.3d+166) then
        tmp = (y - z) * (t / (a - z))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = (((y - a) / z) * x) + t;
	double tmp;
	if (z <= -1.7e+32) {
		tmp = t_1;
	} else if (z <= -2.3e-134) {
		tmp = (t - x) * (y / (a - z));
	} else if (z <= 7.2e-93) {
		tmp = x + (((t - x) * y) / a);
	} else if (z <= 4.3e+166) {
		tmp = (y - z) * (t / (a - z));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = (((y - a) / z) * x) + t
	tmp = 0
	if z <= -1.7e+32:
		tmp = t_1
	elif z <= -2.3e-134:
		tmp = (t - x) * (y / (a - z))
	elif z <= 7.2e-93:
		tmp = x + (((t - x) * y) / a)
	elif z <= 4.3e+166:
		tmp = (y - z) * (t / (a - z))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(Float64(Float64(Float64(y - a) / z) * x) + t)
	tmp = 0.0
	if (z <= -1.7e+32)
		tmp = t_1;
	elseif (z <= -2.3e-134)
		tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z)));
	elseif (z <= 7.2e-93)
		tmp = Float64(x + Float64(Float64(Float64(t - x) * y) / a));
	elseif (z <= 4.3e+166)
		tmp = Float64(Float64(y - z) * Float64(t / Float64(a - z)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = (((y - a) / z) * x) + t;
	tmp = 0.0;
	if (z <= -1.7e+32)
		tmp = t_1;
	elseif (z <= -2.3e-134)
		tmp = (t - x) * (y / (a - z));
	elseif (z <= 7.2e-93)
		tmp = x + (((t - x) * y) / a);
	elseif (z <= 4.3e+166)
		tmp = (y - z) * (t / (a - z));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision] * x), $MachinePrecision] + t), $MachinePrecision]}, If[LessEqual[z, -1.7e+32], t$95$1, If[LessEqual[z, -2.3e-134], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7.2e-93], N[(x + N[(N[(N[(t - x), $MachinePrecision] * y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.3e+166], N[(N[(y - z), $MachinePrecision] * N[(t / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \frac{y - a}{z} \cdot x + t\\
\mathbf{if}\;z \leq -1.7 \cdot 10^{+32}:\\
\;\;\;\;t\_1\\

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

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -1.69999999999999989e32 or 4.3e166 < z

    1. Initial program 61.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -1.69999999999999989e32 < z < -2.3e-134

      1. Initial program 93.4%

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

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

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

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

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

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

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

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

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

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

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

      if -2.3e-134 < z < 7.2000000000000003e-93

      1. Initial program 88.4%

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

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

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

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

          \[\leadsto x + \frac{\color{blue}{\left(t - x\right) \cdot y}}{a} \]
        4. lower--.f6484.8

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

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

      if 7.2000000000000003e-93 < z < 4.3e166

      1. Initial program 80.1%

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

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

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

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

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

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

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

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

        \[\leadsto \color{blue}{\left(y - z\right) \cdot \frac{t}{a - z}} \]
    10. Recombined 4 regimes into one program.
    11. Final simplification74.6%

      \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.7 \cdot 10^{+32}:\\ \;\;\;\;\frac{y - a}{z} \cdot x + t\\ \mathbf{elif}\;z \leq -2.3 \cdot 10^{-134}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 7.2 \cdot 10^{-93}:\\ \;\;\;\;x + \frac{\left(t - x\right) \cdot y}{a}\\ \mathbf{elif}\;z \leq 4.3 \cdot 10^{+166}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{t}{a - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{y - a}{z} \cdot x + t\\ \end{array} \]
    12. Add Preprocessing

    Alternative 4: 67.5% accurate, 0.6× speedup?

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

      1. Initial program 61.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        if -1.69999999999999989e32 < z < -7.5e-69

        1. Initial program 95.3%

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

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

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

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

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

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

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

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

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

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

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

        if -7.5e-69 < z < 2.6e-43

        1. Initial program 87.7%

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

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

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

        if 2.6e-43 < z < 4.3e166

        1. Initial program 80.3%

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

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

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

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

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

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

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

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

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

        \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.7 \cdot 10^{+32}:\\ \;\;\;\;\frac{y - a}{z} \cdot x + t\\ \mathbf{elif}\;z \leq -7.5 \cdot 10^{-69}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 2.6 \cdot 10^{-43}:\\ \;\;\;\;\mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\ \mathbf{elif}\;z \leq 4.3 \cdot 10^{+166}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{t}{a - z}\\ \mathbf{else}:\\ \;\;\;\;\frac{y - a}{z} \cdot x + t\\ \end{array} \]
      12. Add Preprocessing

      Alternative 5: 61.5% accurate, 0.6× speedup?

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

        1. Initial program 34.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

          if -2.0999999999999999e218 < z < -5.50000000000000007e79 or 2.6e-43 < z

          1. Initial program 74.0%

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

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

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

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

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

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

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

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

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

          if -5.50000000000000007e79 < z < -7.5e-69

          1. Initial program 88.6%

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

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

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

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

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

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

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

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

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

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

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

          if -7.5e-69 < z < 2.6e-43

          1. Initial program 87.7%

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

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

            \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{t - x}{a}, y, x\right)} \]
        10. Recombined 4 regimes into one program.
        11. Final simplification71.1%

          \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.1 \cdot 10^{+218}:\\ \;\;\;\;\mathsf{fma}\left(\frac{t - x}{z}, a, t\right)\\ \mathbf{elif}\;z \leq -5.5 \cdot 10^{+79}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{t}{a - z}\\ \mathbf{elif}\;z \leq -7.5 \cdot 10^{-69}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 2.6 \cdot 10^{-43}:\\ \;\;\;\;\mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\ \mathbf{else}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{t}{a - z}\\ \end{array} \]
        12. Add Preprocessing

        Alternative 6: 61.5% accurate, 0.6× speedup?

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

          1. Initial program 57.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

            if -6.5999999999999998e112 < z < -7.5e-69 or 9.6000000000000002e-58 < z < 2.6000000000000001e74

            1. Initial program 89.5%

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

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

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

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

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

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

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

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

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

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

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

            if -7.5e-69 < z < 9.6000000000000002e-58

            1. Initial program 87.5%

              \[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--.f6478.0

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

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

            if 2.6000000000000001e74 < z

            1. Initial program 62.5%

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

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

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

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

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

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

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

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

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

              \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
            7. Step-by-step derivation
              1. Applied rewrites67.3%

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

              \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -6.6 \cdot 10^{+112}:\\ \;\;\;\;\mathsf{fma}\left(\frac{t - x}{z}, a, t\right)\\ \mathbf{elif}\;z \leq -7.5 \cdot 10^{-69}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 9.6 \cdot 10^{-58}:\\ \;\;\;\;\mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\ \mathbf{elif}\;z \leq 2.6 \cdot 10^{+74}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{else}:\\ \;\;\;\;\left(-t\right) \cdot \frac{z}{a - z}\\ \end{array} \]
            10. Add Preprocessing

            Alternative 7: 37.9% accurate, 0.7× speedup?

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

              1. Initial program 63.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

                  if -2.25e43 < z < -1.29999999999999993e-45 or 8.49999999999999959e-160 < z < 3.00000000000000003e-28

                  1. Initial program 87.2%

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

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

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

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

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

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

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

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

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

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

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

                    if -1.29999999999999993e-45 < z < 8.49999999999999959e-160

                    1. Initial program 89.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \mathsf{fma}\left(x, \frac{z}{a}, x\right) \]
                      3. Step-by-step derivation
                        1. Applied rewrites40.6%

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

                        if 3.00000000000000003e-28 < z

                        1. Initial program 71.4%

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

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

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

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

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

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

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

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

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

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

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

                            \[\leadsto t + \frac{a \cdot t}{\color{blue}{z}} \]
                          3. Step-by-step derivation
                            1. Applied rewrites42.2%

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

                          Alternative 8: 70.0% accurate, 0.7× speedup?

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

                            1. Initial program 62.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                if -1.69999999999999989e32 < z < -1.01999999999999996e-66

                                1. Initial program 95.3%

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

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

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

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

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

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

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

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

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

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

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

                                if -1.01999999999999996e-66 < z < 9.1999999999999999e52

                                1. Initial program 88.6%

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

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

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

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

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

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

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

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

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

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

                                if 9.1999999999999999e52 < z

                                1. Initial program 64.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                  \[\leadsto \frac{x \cdot \left(y - a\right)}{z} + t \]
                                9. Step-by-step derivation
                                  1. Applied rewrites71.3%

                                    \[\leadsto \frac{y - a}{z} \cdot x + t \]
                                10. Recombined 4 regimes into one program.
                                11. Final simplification73.4%

                                  \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.7 \cdot 10^{+32}:\\ \;\;\;\;\mathsf{fma}\left(y - a, \frac{-x}{-z}, t\right)\\ \mathbf{elif}\;z \leq -1.02 \cdot 10^{-66}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{+52}:\\ \;\;\;\;\mathsf{fma}\left(y - z, \frac{t - x}{a}, x\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{y - a}{z} \cdot x + t\\ \end{array} \]
                                12. Add Preprocessing

                                Alternative 9: 70.1% accurate, 0.7× speedup?

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

                                  1. Initial program 63.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                    if -1.69999999999999989e32 < z < -1.01999999999999996e-66

                                    1. Initial program 95.3%

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

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

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

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

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

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

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

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

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

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

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

                                    if -1.01999999999999996e-66 < z < 9.1999999999999999e52

                                    1. Initial program 88.6%

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

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

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

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

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

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

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

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

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

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

                                    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.7 \cdot 10^{+32}:\\ \;\;\;\;\frac{y - a}{z} \cdot x + t\\ \mathbf{elif}\;z \leq -1.02 \cdot 10^{-66}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{+52}:\\ \;\;\;\;\mathsf{fma}\left(y - z, \frac{t - x}{a}, x\right)\\ \mathbf{else}:\\ \;\;\;\;\frac{y - a}{z} \cdot x + t\\ \end{array} \]
                                  12. Add Preprocessing

                                  Alternative 10: 75.5% accurate, 0.8× speedup?

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

                                    1. Initial program 70.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--.f6477.2

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

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

                                    if -0.00679999999999999962 < z < 2.3499999999999999e-57

                                    1. Initial program 88.4%

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

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

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

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

                                  Alternative 11: 74.5% accurate, 0.8× speedup?

                                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -0.0068 \lor \neg \left(z \leq 2.35 \cdot 10^{-57}\right):\\ \;\;\;\;\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 (or (<= z -0.0068) (not (<= z 2.35e-57)))
                                     (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 ((z <= -0.0068) || !(z <= 2.35e-57)) {
                                  		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 ((z <= -0.0068) || !(z <= 2.35e-57))
                                  		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[Or[LessEqual[z, -0.0068], N[Not[LessEqual[z, 2.35e-57]], $MachinePrecision]], 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}\;z \leq -0.0068 \lor \neg \left(z \leq 2.35 \cdot 10^{-57}\right):\\
                                  \;\;\;\;\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 2 regimes
                                  2. if z < -0.00679999999999999962 or 2.3499999999999999e-57 < z

                                    1. Initial program 70.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--.f6477.2

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

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

                                    if -0.00679999999999999962 < z < 2.3499999999999999e-57

                                    1. Initial program 88.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--.f6478.3

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

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

                                    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -0.0068 \lor \neg \left(z \leq 2.35 \cdot 10^{-57}\right):\\ \;\;\;\;\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} \]
                                  5. Add Preprocessing

                                  Alternative 12: 61.3% accurate, 0.9× speedup?

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

                                    1. Initial program 62.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                      if -3.1999999999999999e32 < z < 2.30000000000000002e58

                                      1. Initial program 89.6%

                                        \[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--.f6470.8

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

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

                                      if 2.30000000000000002e58 < z

                                      1. Initial program 64.0%

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

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

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

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

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

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

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

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

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

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

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

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

                                      Alternative 13: 61.9% accurate, 0.9× speedup?

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

                                        1. Initial program 63.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                          if -3.1999999999999999e32 < z < 2.14999999999999996e58

                                          1. Initial program 89.6%

                                            \[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--.f6470.8

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

                                            \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{t - x}{a}, y, x\right)} \]
                                        10. Recombined 2 regimes into one program.
                                        11. Final simplification63.7%

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

                                        Alternative 14: 58.3% accurate, 0.9× speedup?

                                        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -4.8 \cdot 10^{+38} \lor \neg \left(z \leq 2.8 \cdot 10^{+58}\right):\\ \;\;\;\;\left(-t\right) \cdot -1\\ \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 (or (<= z -4.8e+38) (not (<= z 2.8e+58)))
                                           (* (- t) -1.0)
                                           (fma (/ (- t x) a) y x)))
                                        double code(double x, double y, double z, double t, double a) {
                                        	double tmp;
                                        	if ((z <= -4.8e+38) || !(z <= 2.8e+58)) {
                                        		tmp = -t * -1.0;
                                        	} else {
                                        		tmp = fma(((t - x) / a), y, x);
                                        	}
                                        	return tmp;
                                        }
                                        
                                        function code(x, y, z, t, a)
                                        	tmp = 0.0
                                        	if ((z <= -4.8e+38) || !(z <= 2.8e+58))
                                        		tmp = Float64(Float64(-t) * -1.0);
                                        	else
                                        		tmp = fma(Float64(Float64(t - x) / a), y, x);
                                        	end
                                        	return tmp
                                        end
                                        
                                        code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -4.8e+38], N[Not[LessEqual[z, 2.8e+58]], $MachinePrecision]], N[((-t) * -1.0), $MachinePrecision], N[(N[(N[(t - x), $MachinePrecision] / a), $MachinePrecision] * y + x), $MachinePrecision]]
                                        
                                        \begin{array}{l}
                                        
                                        \\
                                        \begin{array}{l}
                                        \mathbf{if}\;z \leq -4.8 \cdot 10^{+38} \lor \neg \left(z \leq 2.8 \cdot 10^{+58}\right):\\
                                        \;\;\;\;\left(-t\right) \cdot -1\\
                                        
                                        \mathbf{else}:\\
                                        \;\;\;\;\mathsf{fma}\left(\frac{t - x}{a}, y, x\right)\\
                                        
                                        
                                        \end{array}
                                        \end{array}
                                        
                                        Derivation
                                        1. Split input into 2 regimes
                                        2. if z < -4.80000000000000035e38 or 2.7999999999999998e58 < z

                                          1. Initial program 63.9%

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

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

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

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

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

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

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

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

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

                                            \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                                          7. Step-by-step derivation
                                            1. Applied rewrites57.3%

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

                                              \[\leadsto \left(-t\right) \cdot -1 \]
                                            3. Step-by-step derivation
                                              1. Applied rewrites47.4%

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

                                              if -4.80000000000000035e38 < z < 2.7999999999999998e58

                                              1. Initial program 89.0%

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

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

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

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

                                            Alternative 15: 48.2% accurate, 0.9× speedup?

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

                                              1. Initial program 63.9%

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

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

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

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

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

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

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

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

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

                                                \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                                              7. Step-by-step derivation
                                                1. Applied rewrites57.3%

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

                                                  \[\leadsto \left(-t\right) \cdot -1 \]
                                                3. Step-by-step derivation
                                                  1. Applied rewrites47.4%

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

                                                  if -4.80000000000000035e38 < z < 9.0000000000000006e56

                                                  1. Initial program 89.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                  Alternative 16: 37.6% accurate, 1.0× speedup?

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

                                                    1. Initial program 62.7%

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

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

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

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

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

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

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

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

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

                                                      \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                                                    7. Step-by-step derivation
                                                      1. Applied rewrites52.4%

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

                                                        \[\leadsto \left(-t\right) \cdot -1 \]
                                                      3. Step-by-step derivation
                                                        1. Applied rewrites44.8%

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

                                                        if -3.5e31 < z < 2.6999999999999997e-91

                                                        1. Initial program 89.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                            \[\leadsto \mathsf{fma}\left(x, \frac{z}{a}, x\right) \]
                                                          3. Step-by-step derivation
                                                            1. Applied rewrites36.9%

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

                                                            if 2.6999999999999997e-91 < z

                                                            1. Initial program 73.7%

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

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

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

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

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

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

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

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

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

                                                              \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                                                            7. Step-by-step derivation
                                                              1. Applied rewrites47.4%

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

                                                                \[\leadsto t + \frac{a \cdot t}{\color{blue}{z}} \]
                                                              3. Step-by-step derivation
                                                                1. Applied rewrites39.5%

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

                                                              Alternative 17: 35.5% accurate, 1.0× speedup?

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

                                                                1. Initial program 63.3%

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

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

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

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

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

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

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

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

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

                                                                  \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                                                                7. Step-by-step derivation
                                                                  1. Applied rewrites51.5%

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

                                                                    \[\leadsto \left(-t\right) \cdot -1 \]
                                                                  3. Step-by-step derivation
                                                                    1. Applied rewrites44.1%

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

                                                                    if -5.2e21 < z < 3.00000000000000003e-28

                                                                    1. Initial program 89.3%

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

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

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

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

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

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

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

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

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

                                                                      \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                                                                    7. Step-by-step derivation
                                                                      1. Applied rewrites7.2%

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

                                                                        \[\leadsto \frac{t \cdot y}{\color{blue}{a}} \]
                                                                      3. Step-by-step derivation
                                                                        1. Applied rewrites28.4%

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

                                                                        if 3.00000000000000003e-28 < z

                                                                        1. Initial program 71.4%

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

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

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

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

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

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

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

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

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

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

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

                                                                            \[\leadsto t + \frac{a \cdot t}{\color{blue}{z}} \]
                                                                          3. Step-by-step derivation
                                                                            1. Applied rewrites42.2%

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

                                                                          Alternative 18: 35.4% accurate, 1.0× speedup?

                                                                          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -5.2 \cdot 10^{+21} \lor \neg \left(z \leq 3 \cdot 10^{-28}\right):\\ \;\;\;\;\left(-t\right) \cdot -1\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{y}{a}\\ \end{array} \end{array} \]
                                                                          (FPCore (x y z t a)
                                                                           :precision binary64
                                                                           (if (or (<= z -5.2e+21) (not (<= z 3e-28))) (* (- t) -1.0) (* t (/ y a))))
                                                                          double code(double x, double y, double z, double t, double a) {
                                                                          	double tmp;
                                                                          	if ((z <= -5.2e+21) || !(z <= 3e-28)) {
                                                                          		tmp = -t * -1.0;
                                                                          	} else {
                                                                          		tmp = t * (y / a);
                                                                          	}
                                                                          	return tmp;
                                                                          }
                                                                          
                                                                          module fmin_fmax_functions
                                                                              implicit none
                                                                              private
                                                                              public fmax
                                                                              public fmin
                                                                          
                                                                              interface fmax
                                                                                  module procedure fmax88
                                                                                  module procedure fmax44
                                                                                  module procedure fmax84
                                                                                  module procedure fmax48
                                                                              end interface
                                                                              interface fmin
                                                                                  module procedure fmin88
                                                                                  module procedure fmin44
                                                                                  module procedure fmin84
                                                                                  module procedure fmin48
                                                                              end interface
                                                                          contains
                                                                              real(8) function fmax88(x, y) result (res)
                                                                                  real(8), intent (in) :: x
                                                                                  real(8), intent (in) :: y
                                                                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                              end function
                                                                              real(4) function fmax44(x, y) result (res)
                                                                                  real(4), intent (in) :: x
                                                                                  real(4), intent (in) :: y
                                                                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                              end function
                                                                              real(8) function fmax84(x, y) result(res)
                                                                                  real(8), intent (in) :: x
                                                                                  real(4), intent (in) :: y
                                                                                  res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                              end function
                                                                              real(8) function fmax48(x, y) result(res)
                                                                                  real(4), intent (in) :: x
                                                                                  real(8), intent (in) :: y
                                                                                  res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                              end function
                                                                              real(8) function fmin88(x, y) result (res)
                                                                                  real(8), intent (in) :: x
                                                                                  real(8), intent (in) :: y
                                                                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                              end function
                                                                              real(4) function fmin44(x, y) result (res)
                                                                                  real(4), intent (in) :: x
                                                                                  real(4), intent (in) :: y
                                                                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                              end function
                                                                              real(8) function fmin84(x, y) result(res)
                                                                                  real(8), intent (in) :: x
                                                                                  real(4), intent (in) :: y
                                                                                  res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                              end function
                                                                              real(8) function fmin48(x, y) result(res)
                                                                                  real(4), intent (in) :: x
                                                                                  real(8), intent (in) :: y
                                                                                  res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                              end function
                                                                          end module
                                                                          
                                                                          real(8) function code(x, y, z, t, a)
                                                                          use fmin_fmax_functions
                                                                              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 ((z <= (-5.2d+21)) .or. (.not. (z <= 3d-28))) then
                                                                                  tmp = -t * (-1.0d0)
                                                                              else
                                                                                  tmp = t * (y / a)
                                                                              end if
                                                                              code = tmp
                                                                          end function
                                                                          
                                                                          public static double code(double x, double y, double z, double t, double a) {
                                                                          	double tmp;
                                                                          	if ((z <= -5.2e+21) || !(z <= 3e-28)) {
                                                                          		tmp = -t * -1.0;
                                                                          	} else {
                                                                          		tmp = t * (y / a);
                                                                          	}
                                                                          	return tmp;
                                                                          }
                                                                          
                                                                          def code(x, y, z, t, a):
                                                                          	tmp = 0
                                                                          	if (z <= -5.2e+21) or not (z <= 3e-28):
                                                                          		tmp = -t * -1.0
                                                                          	else:
                                                                          		tmp = t * (y / a)
                                                                          	return tmp
                                                                          
                                                                          function code(x, y, z, t, a)
                                                                          	tmp = 0.0
                                                                          	if ((z <= -5.2e+21) || !(z <= 3e-28))
                                                                          		tmp = Float64(Float64(-t) * -1.0);
                                                                          	else
                                                                          		tmp = Float64(t * Float64(y / a));
                                                                          	end
                                                                          	return tmp
                                                                          end
                                                                          
                                                                          function tmp_2 = code(x, y, z, t, a)
                                                                          	tmp = 0.0;
                                                                          	if ((z <= -5.2e+21) || ~((z <= 3e-28)))
                                                                          		tmp = -t * -1.0;
                                                                          	else
                                                                          		tmp = t * (y / a);
                                                                          	end
                                                                          	tmp_2 = tmp;
                                                                          end
                                                                          
                                                                          code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -5.2e+21], N[Not[LessEqual[z, 3e-28]], $MachinePrecision]], N[((-t) * -1.0), $MachinePrecision], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]]
                                                                          
                                                                          \begin{array}{l}
                                                                          
                                                                          \\
                                                                          \begin{array}{l}
                                                                          \mathbf{if}\;z \leq -5.2 \cdot 10^{+21} \lor \neg \left(z \leq 3 \cdot 10^{-28}\right):\\
                                                                          \;\;\;\;\left(-t\right) \cdot -1\\
                                                                          
                                                                          \mathbf{else}:\\
                                                                          \;\;\;\;t \cdot \frac{y}{a}\\
                                                                          
                                                                          
                                                                          \end{array}
                                                                          \end{array}
                                                                          
                                                                          Derivation
                                                                          1. Split input into 2 regimes
                                                                          2. if z < -5.2e21 or 3.00000000000000003e-28 < z

                                                                            1. Initial program 67.6%

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

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

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

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

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

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

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

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

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

                                                                              \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                                                                            7. Step-by-step derivation
                                                                              1. Applied rewrites52.5%

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

                                                                                \[\leadsto \left(-t\right) \cdot -1 \]
                                                                              3. Step-by-step derivation
                                                                                1. Applied rewrites43.0%

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

                                                                                if -5.2e21 < z < 3.00000000000000003e-28

                                                                                1. Initial program 89.3%

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

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

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

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

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

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

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

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

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

                                                                                  \[\leadsto -1 \cdot \color{blue}{\frac{t \cdot z}{a - z}} \]
                                                                                7. Step-by-step derivation
                                                                                  1. Applied rewrites7.2%

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

                                                                                    \[\leadsto \frac{t \cdot y}{\color{blue}{a}} \]
                                                                                  3. Step-by-step derivation
                                                                                    1. Applied rewrites28.4%

                                                                                      \[\leadsto t \cdot \color{blue}{\frac{y}{a}} \]
                                                                                  4. Recombined 2 regimes into one program.
                                                                                  5. Final simplification35.6%

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

                                                                                  Alternative 19: 24.8% accurate, 3.6× speedup?

                                                                                  \[\begin{array}{l} \\ \left(-t\right) \cdot -1 \end{array} \]
                                                                                  (FPCore (x y z t a) :precision binary64 (* (- t) -1.0))
                                                                                  double code(double x, double y, double z, double t, double a) {
                                                                                  	return -t * -1.0;
                                                                                  }
                                                                                  
                                                                                  module fmin_fmax_functions
                                                                                      implicit none
                                                                                      private
                                                                                      public fmax
                                                                                      public fmin
                                                                                  
                                                                                      interface fmax
                                                                                          module procedure fmax88
                                                                                          module procedure fmax44
                                                                                          module procedure fmax84
                                                                                          module procedure fmax48
                                                                                      end interface
                                                                                      interface fmin
                                                                                          module procedure fmin88
                                                                                          module procedure fmin44
                                                                                          module procedure fmin84
                                                                                          module procedure fmin48
                                                                                      end interface
                                                                                  contains
                                                                                      real(8) function fmax88(x, y) result (res)
                                                                                          real(8), intent (in) :: x
                                                                                          real(8), intent (in) :: y
                                                                                          res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(4) function fmax44(x, y) result (res)
                                                                                          real(4), intent (in) :: x
                                                                                          real(4), intent (in) :: y
                                                                                          res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmax84(x, y) result(res)
                                                                                          real(8), intent (in) :: x
                                                                                          real(4), intent (in) :: y
                                                                                          res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmax48(x, y) result(res)
                                                                                          real(4), intent (in) :: x
                                                                                          real(8), intent (in) :: y
                                                                                          res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmin88(x, y) result (res)
                                                                                          real(8), intent (in) :: x
                                                                                          real(8), intent (in) :: y
                                                                                          res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(4) function fmin44(x, y) result (res)
                                                                                          real(4), intent (in) :: x
                                                                                          real(4), intent (in) :: y
                                                                                          res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmin84(x, y) result(res)
                                                                                          real(8), intent (in) :: x
                                                                                          real(4), intent (in) :: y
                                                                                          res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                                      end function
                                                                                      real(8) function fmin48(x, y) result(res)
                                                                                          real(4), intent (in) :: x
                                                                                          real(8), intent (in) :: y
                                                                                          res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                                      end function
                                                                                  end module
                                                                                  
                                                                                  real(8) function code(x, y, z, t, a)
                                                                                  use fmin_fmax_functions
                                                                                      real(8), intent (in) :: x
                                                                                      real(8), intent (in) :: y
                                                                                      real(8), intent (in) :: z
                                                                                      real(8), intent (in) :: t
                                                                                      real(8), intent (in) :: a
                                                                                      code = -t * (-1.0d0)
                                                                                  end function
                                                                                  
                                                                                  public static double code(double x, double y, double z, double t, double a) {
                                                                                  	return -t * -1.0;
                                                                                  }
                                                                                  
                                                                                  def code(x, y, z, t, a):
                                                                                  	return -t * -1.0
                                                                                  
                                                                                  function code(x, y, z, t, a)
                                                                                  	return Float64(Float64(-t) * -1.0)
                                                                                  end
                                                                                  
                                                                                  function tmp = code(x, y, z, t, a)
                                                                                  	tmp = -t * -1.0;
                                                                                  end
                                                                                  
                                                                                  code[x_, y_, z_, t_, a_] := N[((-t) * -1.0), $MachinePrecision]
                                                                                  
                                                                                  \begin{array}{l}
                                                                                  
                                                                                  \\
                                                                                  \left(-t\right) \cdot -1
                                                                                  \end{array}
                                                                                  
                                                                                  Derivation
                                                                                  1. Initial program 78.7%

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

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

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

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

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

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

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

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

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

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

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

                                                                                      \[\leadsto \left(-t\right) \cdot -1 \]
                                                                                    3. Step-by-step derivation
                                                                                      1. Applied rewrites23.9%

                                                                                        \[\leadsto \left(-t\right) \cdot -1 \]
                                                                                      2. Add Preprocessing

                                                                                      Alternative 20: 19.1% 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);
                                                                                      }
                                                                                      
                                                                                      module fmin_fmax_functions
                                                                                          implicit none
                                                                                          private
                                                                                          public fmax
                                                                                          public fmin
                                                                                      
                                                                                          interface fmax
                                                                                              module procedure fmax88
                                                                                              module procedure fmax44
                                                                                              module procedure fmax84
                                                                                              module procedure fmax48
                                                                                          end interface
                                                                                          interface fmin
                                                                                              module procedure fmin88
                                                                                              module procedure fmin44
                                                                                              module procedure fmin84
                                                                                              module procedure fmin48
                                                                                          end interface
                                                                                      contains
                                                                                          real(8) function fmax88(x, y) result (res)
                                                                                              real(8), intent (in) :: x
                                                                                              real(8), intent (in) :: y
                                                                                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(4) function fmax44(x, y) result (res)
                                                                                              real(4), intent (in) :: x
                                                                                              real(4), intent (in) :: y
                                                                                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmax84(x, y) result(res)
                                                                                              real(8), intent (in) :: x
                                                                                              real(4), intent (in) :: y
                                                                                              res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmax48(x, y) result(res)
                                                                                              real(4), intent (in) :: x
                                                                                              real(8), intent (in) :: y
                                                                                              res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmin88(x, y) result (res)
                                                                                              real(8), intent (in) :: x
                                                                                              real(8), intent (in) :: y
                                                                                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(4) function fmin44(x, y) result (res)
                                                                                              real(4), intent (in) :: x
                                                                                              real(4), intent (in) :: y
                                                                                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmin84(x, y) result(res)
                                                                                              real(8), intent (in) :: x
                                                                                              real(4), intent (in) :: y
                                                                                              res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmin48(x, y) result(res)
                                                                                              real(4), intent (in) :: x
                                                                                              real(8), intent (in) :: y
                                                                                              res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                                          end function
                                                                                      end module
                                                                                      
                                                                                      real(8) function code(x, y, z, t, a)
                                                                                      use fmin_fmax_functions
                                                                                          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 78.7%

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

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

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

                                                                                      Alternative 21: 2.8% accurate, 29.0× speedup?

                                                                                      \[\begin{array}{l} \\ 0 \end{array} \]
                                                                                      (FPCore (x y z t a) :precision binary64 0.0)
                                                                                      double code(double x, double y, double z, double t, double a) {
                                                                                      	return 0.0;
                                                                                      }
                                                                                      
                                                                                      module fmin_fmax_functions
                                                                                          implicit none
                                                                                          private
                                                                                          public fmax
                                                                                          public fmin
                                                                                      
                                                                                          interface fmax
                                                                                              module procedure fmax88
                                                                                              module procedure fmax44
                                                                                              module procedure fmax84
                                                                                              module procedure fmax48
                                                                                          end interface
                                                                                          interface fmin
                                                                                              module procedure fmin88
                                                                                              module procedure fmin44
                                                                                              module procedure fmin84
                                                                                              module procedure fmin48
                                                                                          end interface
                                                                                      contains
                                                                                          real(8) function fmax88(x, y) result (res)
                                                                                              real(8), intent (in) :: x
                                                                                              real(8), intent (in) :: y
                                                                                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(4) function fmax44(x, y) result (res)
                                                                                              real(4), intent (in) :: x
                                                                                              real(4), intent (in) :: y
                                                                                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmax84(x, y) result(res)
                                                                                              real(8), intent (in) :: x
                                                                                              real(4), intent (in) :: y
                                                                                              res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmax48(x, y) result(res)
                                                                                              real(4), intent (in) :: x
                                                                                              real(8), intent (in) :: y
                                                                                              res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmin88(x, y) result (res)
                                                                                              real(8), intent (in) :: x
                                                                                              real(8), intent (in) :: y
                                                                                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(4) function fmin44(x, y) result (res)
                                                                                              real(4), intent (in) :: x
                                                                                              real(4), intent (in) :: y
                                                                                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmin84(x, y) result(res)
                                                                                              real(8), intent (in) :: x
                                                                                              real(4), intent (in) :: y
                                                                                              res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                                                                                          end function
                                                                                          real(8) function fmin48(x, y) result(res)
                                                                                              real(4), intent (in) :: x
                                                                                              real(8), intent (in) :: y
                                                                                              res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                                                                                          end function
                                                                                      end module
                                                                                      
                                                                                      real(8) function code(x, y, z, t, a)
                                                                                      use fmin_fmax_functions
                                                                                          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 = 0.0d0
                                                                                      end function
                                                                                      
                                                                                      public static double code(double x, double y, double z, double t, double a) {
                                                                                      	return 0.0;
                                                                                      }
                                                                                      
                                                                                      def code(x, y, z, t, a):
                                                                                      	return 0.0
                                                                                      
                                                                                      function code(x, y, z, t, a)
                                                                                      	return 0.0
                                                                                      end
                                                                                      
                                                                                      function tmp = code(x, y, z, t, a)
                                                                                      	tmp = 0.0;
                                                                                      end
                                                                                      
                                                                                      code[x_, y_, z_, t_, a_] := 0.0
                                                                                      
                                                                                      \begin{array}{l}
                                                                                      
                                                                                      \\
                                                                                      0
                                                                                      \end{array}
                                                                                      
                                                                                      Derivation
                                                                                      1. Initial program 78.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                                                                                          \[\leadsto 0 \]
                                                                                        3. Step-by-step derivation
                                                                                          1. Applied rewrites2.8%

                                                                                            \[\leadsto 0 \]
                                                                                          2. Add Preprocessing

                                                                                          Reproduce

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