Development.Shake.Progress:decay from shake-0.15.5

Percentage Accurate: 67.5% → 90.0%
Time: 5.4s
Alternatives: 16
Speedup: 1.2×

Specification

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

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

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 16 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: 67.5% accurate, 1.0× speedup?

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

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

Alternative 1: 90.0% accurate, 0.2× speedup?

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

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

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

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

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

\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;t\_3\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -inf.0 or 1.0000000000000001e230 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < +inf.0

    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      if -inf.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < -5.00000000000000027e-250 or 0.0 < (/.f64 (+.f64 (*.f64 x y) (*.f64 z (-.f64 t a))) (+.f64 y (*.f64 z (-.f64 b y)))) < 1.0000000000000001e230

      1. Initial program 67.5%

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

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

      1. Initial program 67.5%

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

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

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

          \[\leadsto \frac{t - a}{\color{blue}{b} - y} \]
        3. lift--.f6451.5

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

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

    Alternative 2: 87.2% accurate, 0.6× speedup?

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

      1. Initial program 67.5%

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

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

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

          \[\leadsto \frac{t - a}{\color{blue}{b} - y} \]
        3. lift--.f6451.5

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

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

      if -1.84999999999999992e64 < z < 3.4e60

      1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    Alternative 3: 82.4% accurate, 0.7× speedup?

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

      1. Initial program 67.5%

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

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

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

          \[\leadsto \frac{t - a}{\color{blue}{b} - y} \]
        3. lift--.f6451.5

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

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

      if -5.3e13 < z < 8.1999999999999995e-166

      1. Initial program 67.5%

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

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

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

        if 8.1999999999999995e-166 < z < 2.5e6

        1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        Alternative 4: 82.2% accurate, 0.8× speedup?

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

          1. Initial program 67.5%

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

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

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

              \[\leadsto \frac{t - a}{\color{blue}{b} - y} \]
            3. lift--.f6451.5

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

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

          if -5.3e13 < z < 8.1999999999999995e-166

          1. Initial program 67.5%

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

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

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

            if 8.1999999999999995e-166 < z < 200

            1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

              Alternative 5: 76.9% accurate, 0.9× speedup?

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

                1. Initial program 67.5%

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

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

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

                    \[\leadsto \frac{t - a}{\color{blue}{b} - y} \]
                  3. lift--.f6451.5

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

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

                if -1.9000000000000001e-4 < z < 200

                1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                  Alternative 6: 71.9% accurate, 1.0× speedup?

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

                    1. Initial program 67.5%

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

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

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

                        \[\leadsto \frac{t - a}{\color{blue}{b} - y} \]
                      3. lift--.f6451.5

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

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

                    if -1.5999999999999999e-6 < z < 200

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto x + z \cdot \left(\frac{t}{y} - \mathsf{fma}\left(-1, x, \frac{a}{y}\right)\right) \]
                      6. lower-/.f6434.7

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

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

                      \[\leadsto x + z \cdot \left(\frac{t}{y} - \frac{a}{y}\right) \]
                    9. Step-by-step derivation
                      1. lift-/.f6434.8

                        \[\leadsto x + z \cdot \left(\frac{t}{y} - \frac{a}{y}\right) \]
                    10. Applied rewrites34.8%

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

                  Alternative 7: 71.7% accurate, 1.2× speedup?

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

                    1. Initial program 67.5%

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

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

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

                        \[\leadsto \frac{t - a}{\color{blue}{b} - y} \]
                      3. lift--.f6451.5

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

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

                    if -1.5999999999999999e-6 < z < 200

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto x + z \cdot \left(\frac{t}{y} - \mathsf{fma}\left(-1, x, \frac{a}{y}\right)\right) \]
                      6. lower-/.f6434.7

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

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

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

                        \[\leadsto x + z \cdot \frac{t - a}{y} \]
                      2. lower-/.f64N/A

                        \[\leadsto x + z \cdot \frac{t - a}{y} \]
                      3. lift--.f6435.3

                        \[\leadsto x + z \cdot \frac{t - a}{y} \]
                    10. Applied rewrites35.3%

                      \[\leadsto x + z \cdot \frac{t - a}{y} \]
                  3. Recombined 2 regimes into one program.
                  4. Add Preprocessing

                  Alternative 8: 63.7% accurate, 1.4× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t - a}{b - y}\\ \mathbf{if}\;z \leq -9.8 \cdot 10^{-117}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 1.2 \cdot 10^{-12}:\\ \;\;\;\;x + x \cdot z\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                  (FPCore (x y z t a b)
                   :precision binary64
                   (let* ((t_1 (/ (- t a) (- b y))))
                     (if (<= z -9.8e-117) t_1 (if (<= z 1.2e-12) (+ x (* x z)) t_1))))
                  double code(double x, double y, double z, double t, double a, double b) {
                  	double t_1 = (t - a) / (b - y);
                  	double tmp;
                  	if (z <= -9.8e-117) {
                  		tmp = t_1;
                  	} else if (z <= 1.2e-12) {
                  		tmp = x + (x * 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, b)
                  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), intent (in) :: b
                      real(8) :: t_1
                      real(8) :: tmp
                      t_1 = (t - a) / (b - y)
                      if (z <= (-9.8d-117)) then
                          tmp = t_1
                      else if (z <= 1.2d-12) then
                          tmp = x + (x * 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 b) {
                  	double t_1 = (t - a) / (b - y);
                  	double tmp;
                  	if (z <= -9.8e-117) {
                  		tmp = t_1;
                  	} else if (z <= 1.2e-12) {
                  		tmp = x + (x * z);
                  	} else {
                  		tmp = t_1;
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y, z, t, a, b):
                  	t_1 = (t - a) / (b - y)
                  	tmp = 0
                  	if z <= -9.8e-117:
                  		tmp = t_1
                  	elif z <= 1.2e-12:
                  		tmp = x + (x * z)
                  	else:
                  		tmp = t_1
                  	return tmp
                  
                  function code(x, y, z, t, a, b)
                  	t_1 = Float64(Float64(t - a) / Float64(b - y))
                  	tmp = 0.0
                  	if (z <= -9.8e-117)
                  		tmp = t_1;
                  	elseif (z <= 1.2e-12)
                  		tmp = Float64(x + Float64(x * z));
                  	else
                  		tmp = t_1;
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y, z, t, a, b)
                  	t_1 = (t - a) / (b - y);
                  	tmp = 0.0;
                  	if (z <= -9.8e-117)
                  		tmp = t_1;
                  	elseif (z <= 1.2e-12)
                  		tmp = x + (x * z);
                  	else
                  		tmp = t_1;
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(t - a), $MachinePrecision] / N[(b - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -9.8e-117], t$95$1, If[LessEqual[z, 1.2e-12], N[(x + N[(x * z), $MachinePrecision]), $MachinePrecision], t$95$1]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_1 := \frac{t - a}{b - y}\\
                  \mathbf{if}\;z \leq -9.8 \cdot 10^{-117}:\\
                  \;\;\;\;t\_1\\
                  
                  \mathbf{elif}\;z \leq 1.2 \cdot 10^{-12}:\\
                  \;\;\;\;x + x \cdot z\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;t\_1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if z < -9.7999999999999995e-117 or 1.19999999999999994e-12 < z

                    1. Initial program 67.5%

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

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

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

                        \[\leadsto \frac{t - a}{\color{blue}{b} - y} \]
                      3. lift--.f6451.5

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

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

                    if -9.7999999999999995e-117 < z < 1.19999999999999994e-12

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto x + z \cdot \left(\frac{t}{y} - \mathsf{fma}\left(-1, x, \frac{a}{y}\right)\right) \]
                      6. lower-/.f6434.7

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

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

                      \[\leadsto x + x \cdot z \]
                    9. Step-by-step derivation
                      1. lower-*.f6425.4

                        \[\leadsto x + x \cdot z \]
                    10. Applied rewrites25.4%

                      \[\leadsto x + x \cdot z \]
                  3. Recombined 2 regimes into one program.
                  4. Add Preprocessing

                  Alternative 9: 53.4% accurate, 1.5× speedup?

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

                    1. Initial program 67.5%

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

                      \[\leadsto \color{blue}{-1 \cdot \frac{x}{z - 1}} \]
                    3. Step-by-step derivation
                      1. associate-*r/N/A

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

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

                        \[\leadsto \frac{\mathsf{neg}\left(x\right)}{\color{blue}{z} - 1} \]
                      4. lower-neg.f64N/A

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

                        \[\leadsto \frac{-x}{z - \color{blue}{1}} \]
                    4. Applied rewrites32.8%

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

                    if -5.20000000000000016e60 < y < 3.8000000000000004e-37

                    1. Initial program 67.5%

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

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

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

                        \[\leadsto \frac{t - a}{b} \]
                    4. Applied rewrites35.3%

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

                  Alternative 10: 47.4% accurate, 1.6× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t - a}{b}\\ \mathbf{if}\;z \leq -9.8 \cdot 10^{-117}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 1.12 \cdot 10^{-12}:\\ \;\;\;\;x + x \cdot z\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
                  (FPCore (x y z t a b)
                   :precision binary64
                   (let* ((t_1 (/ (- t a) b)))
                     (if (<= z -9.8e-117) t_1 (if (<= z 1.12e-12) (+ x (* x z)) t_1))))
                  double code(double x, double y, double z, double t, double a, double b) {
                  	double t_1 = (t - a) / b;
                  	double tmp;
                  	if (z <= -9.8e-117) {
                  		tmp = t_1;
                  	} else if (z <= 1.12e-12) {
                  		tmp = x + (x * 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, b)
                  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), intent (in) :: b
                      real(8) :: t_1
                      real(8) :: tmp
                      t_1 = (t - a) / b
                      if (z <= (-9.8d-117)) then
                          tmp = t_1
                      else if (z <= 1.12d-12) then
                          tmp = x + (x * 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 b) {
                  	double t_1 = (t - a) / b;
                  	double tmp;
                  	if (z <= -9.8e-117) {
                  		tmp = t_1;
                  	} else if (z <= 1.12e-12) {
                  		tmp = x + (x * z);
                  	} else {
                  		tmp = t_1;
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y, z, t, a, b):
                  	t_1 = (t - a) / b
                  	tmp = 0
                  	if z <= -9.8e-117:
                  		tmp = t_1
                  	elif z <= 1.12e-12:
                  		tmp = x + (x * z)
                  	else:
                  		tmp = t_1
                  	return tmp
                  
                  function code(x, y, z, t, a, b)
                  	t_1 = Float64(Float64(t - a) / b)
                  	tmp = 0.0
                  	if (z <= -9.8e-117)
                  		tmp = t_1;
                  	elseif (z <= 1.12e-12)
                  		tmp = Float64(x + Float64(x * z));
                  	else
                  		tmp = t_1;
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y, z, t, a, b)
                  	t_1 = (t - a) / b;
                  	tmp = 0.0;
                  	if (z <= -9.8e-117)
                  		tmp = t_1;
                  	elseif (z <= 1.12e-12)
                  		tmp = x + (x * z);
                  	else
                  		tmp = t_1;
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(t - a), $MachinePrecision] / b), $MachinePrecision]}, If[LessEqual[z, -9.8e-117], t$95$1, If[LessEqual[z, 1.12e-12], N[(x + N[(x * z), $MachinePrecision]), $MachinePrecision], t$95$1]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_1 := \frac{t - a}{b}\\
                  \mathbf{if}\;z \leq -9.8 \cdot 10^{-117}:\\
                  \;\;\;\;t\_1\\
                  
                  \mathbf{elif}\;z \leq 1.12 \cdot 10^{-12}:\\
                  \;\;\;\;x + x \cdot z\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;t\_1\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if z < -9.7999999999999995e-117 or 1.1200000000000001e-12 < z

                    1. Initial program 67.5%

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

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

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

                        \[\leadsto \frac{t - a}{b} \]
                    4. Applied rewrites35.3%

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

                    if -9.7999999999999995e-117 < z < 1.1200000000000001e-12

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto x + z \cdot \left(\frac{t}{y} - \mathsf{fma}\left(-1, x, \frac{a}{y}\right)\right) \]
                      6. lower-/.f6434.7

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

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

                      \[\leadsto x + x \cdot z \]
                    9. Step-by-step derivation
                      1. lower-*.f6425.4

                        \[\leadsto x + x \cdot z \]
                    10. Applied rewrites25.4%

                      \[\leadsto x + x \cdot z \]
                  3. Recombined 2 regimes into one program.
                  4. Add Preprocessing

                  Alternative 11: 43.9% accurate, 1.3× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{t}{b - y}\\ \mathbf{if}\;z \leq -0.00088:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 8.2 \cdot 10^{-10}:\\ \;\;\;\;x + x \cdot z\\ \mathbf{elif}\;z \leq 3.1 \cdot 10^{+227}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\frac{a}{y}\\ \end{array} \end{array} \]
                  (FPCore (x y z t a b)
                   :precision binary64
                   (let* ((t_1 (/ t (- b y))))
                     (if (<= z -0.00088)
                       t_1
                       (if (<= z 8.2e-10) (+ x (* x z)) (if (<= z 3.1e+227) t_1 (/ a y))))))
                  double code(double x, double y, double z, double t, double a, double b) {
                  	double t_1 = t / (b - y);
                  	double tmp;
                  	if (z <= -0.00088) {
                  		tmp = t_1;
                  	} else if (z <= 8.2e-10) {
                  		tmp = x + (x * z);
                  	} else if (z <= 3.1e+227) {
                  		tmp = t_1;
                  	} else {
                  		tmp = a / y;
                  	}
                  	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, b)
                  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), intent (in) :: b
                      real(8) :: t_1
                      real(8) :: tmp
                      t_1 = t / (b - y)
                      if (z <= (-0.00088d0)) then
                          tmp = t_1
                      else if (z <= 8.2d-10) then
                          tmp = x + (x * z)
                      else if (z <= 3.1d+227) then
                          tmp = t_1
                      else
                          tmp = a / y
                      end if
                      code = tmp
                  end function
                  
                  public static double code(double x, double y, double z, double t, double a, double b) {
                  	double t_1 = t / (b - y);
                  	double tmp;
                  	if (z <= -0.00088) {
                  		tmp = t_1;
                  	} else if (z <= 8.2e-10) {
                  		tmp = x + (x * z);
                  	} else if (z <= 3.1e+227) {
                  		tmp = t_1;
                  	} else {
                  		tmp = a / y;
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y, z, t, a, b):
                  	t_1 = t / (b - y)
                  	tmp = 0
                  	if z <= -0.00088:
                  		tmp = t_1
                  	elif z <= 8.2e-10:
                  		tmp = x + (x * z)
                  	elif z <= 3.1e+227:
                  		tmp = t_1
                  	else:
                  		tmp = a / y
                  	return tmp
                  
                  function code(x, y, z, t, a, b)
                  	t_1 = Float64(t / Float64(b - y))
                  	tmp = 0.0
                  	if (z <= -0.00088)
                  		tmp = t_1;
                  	elseif (z <= 8.2e-10)
                  		tmp = Float64(x + Float64(x * z));
                  	elseif (z <= 3.1e+227)
                  		tmp = t_1;
                  	else
                  		tmp = Float64(a / y);
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y, z, t, a, b)
                  	t_1 = t / (b - y);
                  	tmp = 0.0;
                  	if (z <= -0.00088)
                  		tmp = t_1;
                  	elseif (z <= 8.2e-10)
                  		tmp = x + (x * z);
                  	elseif (z <= 3.1e+227)
                  		tmp = t_1;
                  	else
                  		tmp = a / y;
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(t / N[(b - y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -0.00088], t$95$1, If[LessEqual[z, 8.2e-10], N[(x + N[(x * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.1e+227], t$95$1, N[(a / y), $MachinePrecision]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_1 := \frac{t}{b - y}\\
                  \mathbf{if}\;z \leq -0.00088:\\
                  \;\;\;\;t\_1\\
                  
                  \mathbf{elif}\;z \leq 8.2 \cdot 10^{-10}:\\
                  \;\;\;\;x + x \cdot z\\
                  
                  \mathbf{elif}\;z \leq 3.1 \cdot 10^{+227}:\\
                  \;\;\;\;t\_1\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\frac{a}{y}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 3 regimes
                  2. if z < -8.80000000000000031e-4 or 8.1999999999999996e-10 < z < 3.0999999999999999e227

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto \frac{t}{b - \color{blue}{y}} \]
                      2. lift--.f6428.5

                        \[\leadsto \frac{t}{b - y} \]
                    7. Applied rewrites28.5%

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

                    if -8.80000000000000031e-4 < z < 8.1999999999999996e-10

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto x + z \cdot \left(\frac{t}{y} - \mathsf{fma}\left(-1, x, \frac{a}{y}\right)\right) \]
                      6. lower-/.f6434.7

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

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

                      \[\leadsto x + x \cdot z \]
                    9. Step-by-step derivation
                      1. lower-*.f6425.4

                        \[\leadsto x + x \cdot z \]
                    10. Applied rewrites25.4%

                      \[\leadsto x + x \cdot z \]

                    if 3.0999999999999999e227 < z

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot \color{blue}{z}\right)} \]
                      6. lower-*.f6414.2

                        \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot z\right)} \]
                    7. Applied rewrites14.2%

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

                      \[\leadsto \frac{a}{y} \]
                    9. Step-by-step derivation
                      1. lower-/.f6412.9

                        \[\leadsto \frac{a}{y} \]
                    10. Applied rewrites12.9%

                      \[\leadsto \frac{a}{y} \]
                  3. Recombined 3 regimes into one program.
                  4. Add Preprocessing

                  Alternative 12: 37.0% accurate, 1.5× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -0.00088:\\ \;\;\;\;\frac{t}{b}\\ \mathbf{elif}\;z \leq 6.6 \cdot 10^{-10}:\\ \;\;\;\;x + x \cdot z\\ \mathbf{elif}\;z \leq 1.45 \cdot 10^{+227}:\\ \;\;\;\;\frac{t}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{a}{y}\\ \end{array} \end{array} \]
                  (FPCore (x y z t a b)
                   :precision binary64
                   (if (<= z -0.00088)
                     (/ t b)
                     (if (<= z 6.6e-10) (+ x (* x z)) (if (<= z 1.45e+227) (/ t b) (/ a y)))))
                  double code(double x, double y, double z, double t, double a, double b) {
                  	double tmp;
                  	if (z <= -0.00088) {
                  		tmp = t / b;
                  	} else if (z <= 6.6e-10) {
                  		tmp = x + (x * z);
                  	} else if (z <= 1.45e+227) {
                  		tmp = t / b;
                  	} else {
                  		tmp = a / y;
                  	}
                  	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, b)
                  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), intent (in) :: b
                      real(8) :: tmp
                      if (z <= (-0.00088d0)) then
                          tmp = t / b
                      else if (z <= 6.6d-10) then
                          tmp = x + (x * z)
                      else if (z <= 1.45d+227) then
                          tmp = t / b
                      else
                          tmp = a / y
                      end if
                      code = tmp
                  end function
                  
                  public static double code(double x, double y, double z, double t, double a, double b) {
                  	double tmp;
                  	if (z <= -0.00088) {
                  		tmp = t / b;
                  	} else if (z <= 6.6e-10) {
                  		tmp = x + (x * z);
                  	} else if (z <= 1.45e+227) {
                  		tmp = t / b;
                  	} else {
                  		tmp = a / y;
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y, z, t, a, b):
                  	tmp = 0
                  	if z <= -0.00088:
                  		tmp = t / b
                  	elif z <= 6.6e-10:
                  		tmp = x + (x * z)
                  	elif z <= 1.45e+227:
                  		tmp = t / b
                  	else:
                  		tmp = a / y
                  	return tmp
                  
                  function code(x, y, z, t, a, b)
                  	tmp = 0.0
                  	if (z <= -0.00088)
                  		tmp = Float64(t / b);
                  	elseif (z <= 6.6e-10)
                  		tmp = Float64(x + Float64(x * z));
                  	elseif (z <= 1.45e+227)
                  		tmp = Float64(t / b);
                  	else
                  		tmp = Float64(a / y);
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y, z, t, a, b)
                  	tmp = 0.0;
                  	if (z <= -0.00088)
                  		tmp = t / b;
                  	elseif (z <= 6.6e-10)
                  		tmp = x + (x * z);
                  	elseif (z <= 1.45e+227)
                  		tmp = t / b;
                  	else
                  		tmp = a / y;
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -0.00088], N[(t / b), $MachinePrecision], If[LessEqual[z, 6.6e-10], N[(x + N[(x * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.45e+227], N[(t / b), $MachinePrecision], N[(a / y), $MachinePrecision]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  \mathbf{if}\;z \leq -0.00088:\\
                  \;\;\;\;\frac{t}{b}\\
                  
                  \mathbf{elif}\;z \leq 6.6 \cdot 10^{-10}:\\
                  \;\;\;\;x + x \cdot z\\
                  
                  \mathbf{elif}\;z \leq 1.45 \cdot 10^{+227}:\\
                  \;\;\;\;\frac{t}{b}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\frac{a}{y}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 3 regimes
                  2. if z < -8.80000000000000031e-4 or 6.6e-10 < z < 1.4499999999999999e227

                    1. Initial program 67.5%

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

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

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

                        \[\leadsto \frac{t - a}{b} \]
                    4. Applied rewrites35.3%

                      \[\leadsto \color{blue}{\frac{t - a}{b}} \]
                    5. Taylor expanded in t around inf

                      \[\leadsto \frac{t}{\color{blue}{b}} \]
                    6. Step-by-step derivation
                      1. lower-/.f6420.3

                        \[\leadsto \frac{t}{b} \]
                    7. Applied rewrites20.3%

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

                    if -8.80000000000000031e-4 < z < 6.6e-10

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto x + z \cdot \left(\frac{t}{y} - \mathsf{fma}\left(-1, x, \frac{a}{y}\right)\right) \]
                      6. lower-/.f6434.7

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

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

                      \[\leadsto x + x \cdot z \]
                    9. Step-by-step derivation
                      1. lower-*.f6425.4

                        \[\leadsto x + x \cdot z \]
                    10. Applied rewrites25.4%

                      \[\leadsto x + x \cdot z \]

                    if 1.4499999999999999e227 < z

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot \color{blue}{z}\right)} \]
                      6. lower-*.f6414.2

                        \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot z\right)} \]
                    7. Applied rewrites14.2%

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

                      \[\leadsto \frac{a}{y} \]
                    9. Step-by-step derivation
                      1. lower-/.f6412.9

                        \[\leadsto \frac{a}{y} \]
                    10. Applied rewrites12.9%

                      \[\leadsto \frac{a}{y} \]
                  3. Recombined 3 regimes into one program.
                  4. Add Preprocessing

                  Alternative 13: 37.0% accurate, 1.5× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -0.00088:\\ \;\;\;\;\frac{t}{b}\\ \mathbf{elif}\;z \leq 6.6 \cdot 10^{-10}:\\ \;\;\;\;x \cdot \left(1 + z\right)\\ \mathbf{elif}\;z \leq 1.45 \cdot 10^{+227}:\\ \;\;\;\;\frac{t}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{a}{y}\\ \end{array} \end{array} \]
                  (FPCore (x y z t a b)
                   :precision binary64
                   (if (<= z -0.00088)
                     (/ t b)
                     (if (<= z 6.6e-10) (* x (+ 1.0 z)) (if (<= z 1.45e+227) (/ t b) (/ a y)))))
                  double code(double x, double y, double z, double t, double a, double b) {
                  	double tmp;
                  	if (z <= -0.00088) {
                  		tmp = t / b;
                  	} else if (z <= 6.6e-10) {
                  		tmp = x * (1.0 + z);
                  	} else if (z <= 1.45e+227) {
                  		tmp = t / b;
                  	} else {
                  		tmp = a / y;
                  	}
                  	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, b)
                  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), intent (in) :: b
                      real(8) :: tmp
                      if (z <= (-0.00088d0)) then
                          tmp = t / b
                      else if (z <= 6.6d-10) then
                          tmp = x * (1.0d0 + z)
                      else if (z <= 1.45d+227) then
                          tmp = t / b
                      else
                          tmp = a / y
                      end if
                      code = tmp
                  end function
                  
                  public static double code(double x, double y, double z, double t, double a, double b) {
                  	double tmp;
                  	if (z <= -0.00088) {
                  		tmp = t / b;
                  	} else if (z <= 6.6e-10) {
                  		tmp = x * (1.0 + z);
                  	} else if (z <= 1.45e+227) {
                  		tmp = t / b;
                  	} else {
                  		tmp = a / y;
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y, z, t, a, b):
                  	tmp = 0
                  	if z <= -0.00088:
                  		tmp = t / b
                  	elif z <= 6.6e-10:
                  		tmp = x * (1.0 + z)
                  	elif z <= 1.45e+227:
                  		tmp = t / b
                  	else:
                  		tmp = a / y
                  	return tmp
                  
                  function code(x, y, z, t, a, b)
                  	tmp = 0.0
                  	if (z <= -0.00088)
                  		tmp = Float64(t / b);
                  	elseif (z <= 6.6e-10)
                  		tmp = Float64(x * Float64(1.0 + z));
                  	elseif (z <= 1.45e+227)
                  		tmp = Float64(t / b);
                  	else
                  		tmp = Float64(a / y);
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y, z, t, a, b)
                  	tmp = 0.0;
                  	if (z <= -0.00088)
                  		tmp = t / b;
                  	elseif (z <= 6.6e-10)
                  		tmp = x * (1.0 + z);
                  	elseif (z <= 1.45e+227)
                  		tmp = t / b;
                  	else
                  		tmp = a / y;
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -0.00088], N[(t / b), $MachinePrecision], If[LessEqual[z, 6.6e-10], N[(x * N[(1.0 + z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.45e+227], N[(t / b), $MachinePrecision], N[(a / y), $MachinePrecision]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  \mathbf{if}\;z \leq -0.00088:\\
                  \;\;\;\;\frac{t}{b}\\
                  
                  \mathbf{elif}\;z \leq 6.6 \cdot 10^{-10}:\\
                  \;\;\;\;x \cdot \left(1 + z\right)\\
                  
                  \mathbf{elif}\;z \leq 1.45 \cdot 10^{+227}:\\
                  \;\;\;\;\frac{t}{b}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\frac{a}{y}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 3 regimes
                  2. if z < -8.80000000000000031e-4 or 6.6e-10 < z < 1.4499999999999999e227

                    1. Initial program 67.5%

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

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

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

                        \[\leadsto \frac{t - a}{b} \]
                    4. Applied rewrites35.3%

                      \[\leadsto \color{blue}{\frac{t - a}{b}} \]
                    5. Taylor expanded in t around inf

                      \[\leadsto \frac{t}{\color{blue}{b}} \]
                    6. Step-by-step derivation
                      1. lower-/.f6420.3

                        \[\leadsto \frac{t}{b} \]
                    7. Applied rewrites20.3%

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

                    if -8.80000000000000031e-4 < z < 6.6e-10

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto x + z \cdot \left(\frac{t}{y} - \mathsf{fma}\left(-1, x, \frac{a}{y}\right)\right) \]
                      6. lower-/.f6434.7

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

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

                      \[\leadsto x \cdot \left(1 + \color{blue}{z}\right) \]
                    9. Step-by-step derivation
                      1. lower-*.f64N/A

                        \[\leadsto x \cdot \left(1 + z\right) \]
                      2. lower-+.f6425.4

                        \[\leadsto x \cdot \left(1 + z\right) \]
                    10. Applied rewrites25.4%

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

                    if 1.4499999999999999e227 < z

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot \color{blue}{z}\right)} \]
                      6. lower-*.f6414.2

                        \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot z\right)} \]
                    7. Applied rewrites14.2%

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

                      \[\leadsto \frac{a}{y} \]
                    9. Step-by-step derivation
                      1. lower-/.f6412.9

                        \[\leadsto \frac{a}{y} \]
                    10. Applied rewrites12.9%

                      \[\leadsto \frac{a}{y} \]
                  3. Recombined 3 regimes into one program.
                  4. Add Preprocessing

                  Alternative 14: 23.4% accurate, 2.0× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1.6 \cdot 10^{+65}:\\ \;\;\;\;\frac{a}{y}\\ \mathbf{elif}\;y \leq 10^{+40}:\\ \;\;\;\;\frac{t}{b}\\ \mathbf{else}:\\ \;\;\;\;\frac{a}{y}\\ \end{array} \end{array} \]
                  (FPCore (x y z t a b)
                   :precision binary64
                   (if (<= y -1.6e+65) (/ a y) (if (<= y 1e+40) (/ t b) (/ a y))))
                  double code(double x, double y, double z, double t, double a, double b) {
                  	double tmp;
                  	if (y <= -1.6e+65) {
                  		tmp = a / y;
                  	} else if (y <= 1e+40) {
                  		tmp = t / b;
                  	} else {
                  		tmp = a / y;
                  	}
                  	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, b)
                  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), intent (in) :: b
                      real(8) :: tmp
                      if (y <= (-1.6d+65)) then
                          tmp = a / y
                      else if (y <= 1d+40) then
                          tmp = t / b
                      else
                          tmp = a / y
                      end if
                      code = tmp
                  end function
                  
                  public static double code(double x, double y, double z, double t, double a, double b) {
                  	double tmp;
                  	if (y <= -1.6e+65) {
                  		tmp = a / y;
                  	} else if (y <= 1e+40) {
                  		tmp = t / b;
                  	} else {
                  		tmp = a / y;
                  	}
                  	return tmp;
                  }
                  
                  def code(x, y, z, t, a, b):
                  	tmp = 0
                  	if y <= -1.6e+65:
                  		tmp = a / y
                  	elif y <= 1e+40:
                  		tmp = t / b
                  	else:
                  		tmp = a / y
                  	return tmp
                  
                  function code(x, y, z, t, a, b)
                  	tmp = 0.0
                  	if (y <= -1.6e+65)
                  		tmp = Float64(a / y);
                  	elseif (y <= 1e+40)
                  		tmp = Float64(t / b);
                  	else
                  		tmp = Float64(a / y);
                  	end
                  	return tmp
                  end
                  
                  function tmp_2 = code(x, y, z, t, a, b)
                  	tmp = 0.0;
                  	if (y <= -1.6e+65)
                  		tmp = a / y;
                  	elseif (y <= 1e+40)
                  		tmp = t / b;
                  	else
                  		tmp = a / y;
                  	end
                  	tmp_2 = tmp;
                  end
                  
                  code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -1.6e+65], N[(a / y), $MachinePrecision], If[LessEqual[y, 1e+40], N[(t / b), $MachinePrecision], N[(a / y), $MachinePrecision]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  \mathbf{if}\;y \leq -1.6 \cdot 10^{+65}:\\
                  \;\;\;\;\frac{a}{y}\\
                  
                  \mathbf{elif}\;y \leq 10^{+40}:\\
                  \;\;\;\;\frac{t}{b}\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;\frac{a}{y}\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if y < -1.60000000000000003e65 or 1.00000000000000003e40 < y

                    1. Initial program 67.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                        \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot \color{blue}{z}\right)} \]
                      6. lower-*.f6414.2

                        \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot z\right)} \]
                    7. Applied rewrites14.2%

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

                      \[\leadsto \frac{a}{y} \]
                    9. Step-by-step derivation
                      1. lower-/.f6412.9

                        \[\leadsto \frac{a}{y} \]
                    10. Applied rewrites12.9%

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

                    if -1.60000000000000003e65 < y < 1.00000000000000003e40

                    1. Initial program 67.5%

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

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

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

                        \[\leadsto \frac{t - a}{b} \]
                    4. Applied rewrites35.3%

                      \[\leadsto \color{blue}{\frac{t - a}{b}} \]
                    5. Taylor expanded in t around inf

                      \[\leadsto \frac{t}{\color{blue}{b}} \]
                    6. Step-by-step derivation
                      1. lower-/.f6420.3

                        \[\leadsto \frac{t}{b} \]
                    7. Applied rewrites20.3%

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

                  Alternative 15: 12.9% accurate, 5.5× speedup?

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot \color{blue}{z}\right)} \]
                    6. lower-*.f6414.2

                      \[\leadsto -1 \cdot \frac{a \cdot z}{y + -1 \cdot \left(y \cdot z\right)} \]
                  7. Applied rewrites14.2%

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

                    \[\leadsto \frac{a}{y} \]
                  9. Step-by-step derivation
                    1. lower-/.f6412.9

                      \[\leadsto \frac{a}{y} \]
                  10. Applied rewrites12.9%

                    \[\leadsto \frac{a}{y} \]
                  11. Add Preprocessing

                  Alternative 16: 3.9% accurate, 6.1× speedup?

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

                      \[\leadsto x + z \cdot \left(\frac{t}{y} - \mathsf{fma}\left(-1, x, \frac{a}{y}\right)\right) \]
                    6. lower-/.f6434.7

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

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

                    \[\leadsto x \cdot \left(1 + \color{blue}{z}\right) \]
                  9. Step-by-step derivation
                    1. lower-*.f64N/A

                      \[\leadsto x \cdot \left(1 + z\right) \]
                    2. lower-+.f6425.4

                      \[\leadsto x \cdot \left(1 + z\right) \]
                  10. Applied rewrites25.4%

                    \[\leadsto x \cdot \left(1 + \color{blue}{z}\right) \]
                  11. Taylor expanded in z around inf

                    \[\leadsto x \cdot z \]
                  12. Step-by-step derivation
                    1. lower-*.f643.9

                      \[\leadsto x \cdot z \]
                  13. Applied rewrites3.9%

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

                  Reproduce

                  ?
                  herbie shell --seed 2025139 
                  (FPCore (x y z t a b)
                    :name "Development.Shake.Progress:decay from shake-0.15.5"
                    :precision binary64
                    (/ (+ (* x y) (* z (- t a))) (+ y (* z (- b y)))))