Numeric.SpecFunctions:logBeta from math-functions-0.1.5.2, A

Percentage Accurate: 99.9% → 99.9%
Time: 4.8s
Alternatives: 19
Speedup: 1.0×

Specification

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

\\
\left(\left(\left(x + y\right) + z\right) - z \cdot \log t\right) + \left(a - 0.5\right) \cdot b
\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 19 alternatives:

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

Initial Program: 99.9% accurate, 1.0× speedup?

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

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

Alternative 1: 99.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (+ (+ (fma (- 1.0 (log t)) z (* (- a 0.5) b)) y) x))
double code(double x, double y, double z, double t, double a, double b) {
	return (fma((1.0 - log(t)), z, ((a - 0.5) * b)) + y) + x;
}
function code(x, y, z, t, a, b)
	return Float64(Float64(fma(Float64(1.0 - log(t)), z, Float64(Float64(a - 0.5) * b)) + y) + x)
end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(N[(1.0 - N[Log[t], $MachinePrecision]), $MachinePrecision] * z + N[(N[(a - 0.5), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision] + y), $MachinePrecision] + x), $MachinePrecision]
\begin{array}{l}

\\
\left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x
\end{array}
Derivation
  1. Initial program 99.9%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
    12. lift--.f6499.9

      \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
  4. Applied rewrites99.9%

    \[\leadsto \color{blue}{\left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x} \]
  5. Add Preprocessing

Alternative 2: 57.7% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\left(\left(x + y\right) + z\right) - z \cdot \log t \leq -5 \cdot 10^{-120}:\\ \;\;\;\;x + \left(a - 0.5\right) \cdot b\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(b, a - 0.5, y\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b)
 :precision binary64
 (if (<= (- (+ (+ x y) z) (* z (log t))) -5e-120)
   (+ x (* (- a 0.5) b))
   (fma b (- a 0.5) y)))
double code(double x, double y, double z, double t, double a, double b) {
	double tmp;
	if ((((x + y) + z) - (z * log(t))) <= -5e-120) {
		tmp = x + ((a - 0.5) * b);
	} else {
		tmp = fma(b, (a - 0.5), y);
	}
	return tmp;
}
function code(x, y, z, t, a, b)
	tmp = 0.0
	if (Float64(Float64(Float64(x + y) + z) - Float64(z * log(t))) <= -5e-120)
		tmp = Float64(x + Float64(Float64(a - 0.5) * b));
	else
		tmp = fma(b, Float64(a - 0.5), y);
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(N[(N[(x + y), $MachinePrecision] + z), $MachinePrecision] - N[(z * N[Log[t], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], -5e-120], N[(x + N[(N[(a - 0.5), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision], N[(b * N[(a - 0.5), $MachinePrecision] + y), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;\left(\left(x + y\right) + z\right) - z \cdot \log t \leq -5 \cdot 10^{-120}:\\
\;\;\;\;x + \left(a - 0.5\right) \cdot b\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(b, a - 0.5, y\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (+.f64 (+.f64 x y) z) (*.f64 z (log.f64 t))) < -5.00000000000000007e-120

    1. Initial program 99.9%

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

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

        \[\leadsto \color{blue}{x} + \left(a - 0.5\right) \cdot b \]

      if -5.00000000000000007e-120 < (-.f64 (+.f64 (+.f64 x y) z) (*.f64 z (log.f64 t)))

      1. Initial program 99.8%

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

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

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

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

          \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
        4. *-commutativeN/A

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

          \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
        6. lift--.f6477.9

          \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
      4. Applied rewrites77.9%

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

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

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

          \[\leadsto \mathsf{fma}\left(b, a - \color{blue}{\frac{1}{2}}, y\right) \]
        3. lift--.f6458.1

          \[\leadsto \mathsf{fma}\left(b, a - 0.5, y\right) \]
      7. Applied rewrites58.1%

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

    Alternative 3: 21.9% accurate, 1.0× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\left(\left(\left(x + y\right) + z\right) - z \cdot \log t\right) + \left(a - 0.5\right) \cdot b \leq -4 \cdot 10^{-125}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \end{array} \]
    (FPCore (x y z t a b)
     :precision binary64
     (if (<= (+ (- (+ (+ x y) z) (* z (log t))) (* (- a 0.5) b)) -4e-125) x y))
    double code(double x, double y, double z, double t, double a, double b) {
    	double tmp;
    	if (((((x + y) + z) - (z * log(t))) + ((a - 0.5) * b)) <= -4e-125) {
    		tmp = x;
    	} else {
    		tmp = 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 (((((x + y) + z) - (z * log(t))) + ((a - 0.5d0) * b)) <= (-4d-125)) then
            tmp = x
        else
            tmp = 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 (((((x + y) + z) - (z * Math.log(t))) + ((a - 0.5) * b)) <= -4e-125) {
    		tmp = x;
    	} else {
    		tmp = y;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t, a, b):
    	tmp = 0
    	if ((((x + y) + z) - (z * math.log(t))) + ((a - 0.5) * b)) <= -4e-125:
    		tmp = x
    	else:
    		tmp = y
    	return tmp
    
    function code(x, y, z, t, a, b)
    	tmp = 0.0
    	if (Float64(Float64(Float64(Float64(x + y) + z) - Float64(z * log(t))) + Float64(Float64(a - 0.5) * b)) <= -4e-125)
    		tmp = x;
    	else
    		tmp = y;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t, a, b)
    	tmp = 0.0;
    	if (((((x + y) + z) - (z * log(t))) + ((a - 0.5) * b)) <= -4e-125)
    		tmp = x;
    	else
    		tmp = y;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(N[(N[(N[(x + y), $MachinePrecision] + z), $MachinePrecision] - N[(z * N[Log[t], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(a - 0.5), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision], -4e-125], x, y]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    \mathbf{if}\;\left(\left(\left(x + y\right) + z\right) - z \cdot \log t\right) + \left(a - 0.5\right) \cdot b \leq -4 \cdot 10^{-125}:\\
    \;\;\;\;x\\
    
    \mathbf{else}:\\
    \;\;\;\;y\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if (+.f64 (-.f64 (+.f64 (+.f64 x y) z) (*.f64 z (log.f64 t))) (*.f64 (-.f64 a #s(literal 1/2 binary64)) b)) < -4.00000000000000005e-125

      1. Initial program 99.9%

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

        \[\leadsto \color{blue}{x} \]
      3. Step-by-step derivation
        1. Applied rewrites21.5%

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

        if -4.00000000000000005e-125 < (+.f64 (-.f64 (+.f64 (+.f64 x y) z) (*.f64 z (log.f64 t))) (*.f64 (-.f64 a #s(literal 1/2 binary64)) b))

        1. Initial program 99.8%

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

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

            \[\leadsto \color{blue}{y} \]
        4. Recombined 2 regimes into one program.
        5. Add Preprocessing

        Alternative 4: 90.9% accurate, 1.0× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right)\\ \mathbf{if}\;z \leq -1.35 \cdot 10^{+39}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 7.5 \cdot 10^{+176}:\\ \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
        (FPCore (x y z t a b)
         :precision binary64
         (let* ((t_1 (fma (- 1.0 (log t)) z (fma b (- a 0.5) y))))
           (if (<= z -1.35e+39)
             t_1
             (if (<= z 7.5e+176) (+ (fma (- a 0.5) b y) x) t_1))))
        double code(double x, double y, double z, double t, double a, double b) {
        	double t_1 = fma((1.0 - log(t)), z, fma(b, (a - 0.5), y));
        	double tmp;
        	if (z <= -1.35e+39) {
        		tmp = t_1;
        	} else if (z <= 7.5e+176) {
        		tmp = fma((a - 0.5), b, y) + x;
        	} else {
        		tmp = t_1;
        	}
        	return tmp;
        }
        
        function code(x, y, z, t, a, b)
        	t_1 = fma(Float64(1.0 - log(t)), z, fma(b, Float64(a - 0.5), y))
        	tmp = 0.0
        	if (z <= -1.35e+39)
        		tmp = t_1;
        	elseif (z <= 7.5e+176)
        		tmp = Float64(fma(Float64(a - 0.5), b, y) + x);
        	else
        		tmp = t_1;
        	end
        	return tmp
        end
        
        code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(1.0 - N[Log[t], $MachinePrecision]), $MachinePrecision] * z + N[(b * N[(a - 0.5), $MachinePrecision] + y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.35e+39], t$95$1, If[LessEqual[z, 7.5e+176], N[(N[(N[(a - 0.5), $MachinePrecision] * b + y), $MachinePrecision] + x), $MachinePrecision], t$95$1]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right)\\
        \mathbf{if}\;z \leq -1.35 \cdot 10^{+39}:\\
        \;\;\;\;t\_1\\
        
        \mathbf{elif}\;z \leq 7.5 \cdot 10^{+176}:\\
        \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\
        
        \mathbf{else}:\\
        \;\;\;\;t\_1\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if z < -1.35000000000000002e39 or 7.499999999999999e176 < z

          1. Initial program 99.6%

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
            12. lift--.f6499.8

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
          4. Applied rewrites99.8%

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

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

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

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

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

              \[\leadsto \left(\left(1 - \log t\right) \cdot z + \left(a - \frac{1}{2}\right) \cdot b\right) + y \]
            5. associate-+l+N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            7. lift-log.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            8. lift--.f64N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot \left(a - \frac{1}{2}\right) + y\right) \]
            10. lower-fma.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - \frac{1}{2}, y\right)\right) \]
            11. lift--.f6487.3

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right) \]
          7. Applied rewrites87.3%

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

          if -1.35000000000000002e39 < z < 7.499999999999999e176

          1. Initial program 100.0%

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

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

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

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

              \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
            4. *-commutativeN/A

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

              \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
            6. lift--.f6492.7

              \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
          4. Applied rewrites92.7%

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

        Alternative 5: 87.2% accurate, 1.0× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := 1 - \log t\\ \mathbf{if}\;z \leq -1.52 \cdot 10^{+174}:\\ \;\;\;\;\mathsf{fma}\left(t\_1, z, b \cdot a\right)\\ \mathbf{elif}\;z \leq 8.6 \cdot 10^{+192}:\\ \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(t\_1, z, \mathsf{fma}\left(-0.5, b, y\right)\right)\\ \end{array} \end{array} \]
        (FPCore (x y z t a b)
         :precision binary64
         (let* ((t_1 (- 1.0 (log t))))
           (if (<= z -1.52e+174)
             (fma t_1 z (* b a))
             (if (<= z 8.6e+192)
               (+ (fma (- a 0.5) b y) x)
               (fma t_1 z (fma -0.5 b y))))))
        double code(double x, double y, double z, double t, double a, double b) {
        	double t_1 = 1.0 - log(t);
        	double tmp;
        	if (z <= -1.52e+174) {
        		tmp = fma(t_1, z, (b * a));
        	} else if (z <= 8.6e+192) {
        		tmp = fma((a - 0.5), b, y) + x;
        	} else {
        		tmp = fma(t_1, z, fma(-0.5, b, y));
        	}
        	return tmp;
        }
        
        function code(x, y, z, t, a, b)
        	t_1 = Float64(1.0 - log(t))
        	tmp = 0.0
        	if (z <= -1.52e+174)
        		tmp = fma(t_1, z, Float64(b * a));
        	elseif (z <= 8.6e+192)
        		tmp = Float64(fma(Float64(a - 0.5), b, y) + x);
        	else
        		tmp = fma(t_1, z, fma(-0.5, b, y));
        	end
        	return tmp
        end
        
        code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(1.0 - N[Log[t], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.52e+174], N[(t$95$1 * z + N[(b * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 8.6e+192], N[(N[(N[(a - 0.5), $MachinePrecision] * b + y), $MachinePrecision] + x), $MachinePrecision], N[(t$95$1 * z + N[(-0.5 * b + y), $MachinePrecision]), $MachinePrecision]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := 1 - \log t\\
        \mathbf{if}\;z \leq -1.52 \cdot 10^{+174}:\\
        \;\;\;\;\mathsf{fma}\left(t\_1, z, b \cdot a\right)\\
        
        \mathbf{elif}\;z \leq 8.6 \cdot 10^{+192}:\\
        \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\
        
        \mathbf{else}:\\
        \;\;\;\;\mathsf{fma}\left(t\_1, z, \mathsf{fma}\left(-0.5, b, y\right)\right)\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if z < -1.52000000000000004e174

          1. Initial program 99.7%

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
            12. lift--.f6499.8

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
          4. Applied rewrites99.8%

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

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

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

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

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

              \[\leadsto \left(\left(1 - \log t\right) \cdot z + \left(a - \frac{1}{2}\right) \cdot b\right) + y \]
            5. associate-+l+N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            7. lift-log.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            8. lift--.f64N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot \left(a - \frac{1}{2}\right) + y\right) \]
            10. lower-fma.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - \frac{1}{2}, y\right)\right) \]
            11. lift--.f6491.4

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right) \]
          7. Applied rewrites91.4%

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

            \[\leadsto \mathsf{fma}\left(1 - \log t, z, a \cdot b\right) \]
          9. Step-by-step derivation
            1. *-commutativeN/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot a\right) \]
            2. lower-*.f6478.5

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot a\right) \]
          10. Applied rewrites78.5%

            \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot a\right) \]

          if -1.52000000000000004e174 < z < 8.59999999999999952e192

          1. Initial program 99.9%

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

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

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

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

              \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
            4. *-commutativeN/A

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

              \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
            6. lift--.f6489.6

              \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
          4. Applied rewrites89.6%

            \[\leadsto \color{blue}{\mathsf{fma}\left(a - 0.5, b, y\right) + x} \]

          if 8.59999999999999952e192 < z

          1. Initial program 99.3%

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
            12. lift--.f6499.7

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
          4. Applied rewrites99.7%

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

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

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

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

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

              \[\leadsto \left(\left(1 - \log t\right) \cdot z + \left(a - \frac{1}{2}\right) \cdot b\right) + y \]
            5. associate-+l+N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            7. lift-log.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            8. lift--.f64N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot \left(a - \frac{1}{2}\right) + y\right) \]
            10. lower-fma.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - \frac{1}{2}, y\right)\right) \]
            11. lift--.f6492.4

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right) \]
          7. Applied rewrites92.4%

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

            \[\leadsto \mathsf{fma}\left(1 - \log t, z, y + \frac{-1}{2} \cdot b\right) \]
          9. Step-by-step derivation
            1. +-commutativeN/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \frac{-1}{2} \cdot b + y\right) \]
            2. lower-fma.f6477.6

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(-0.5, b, y\right)\right) \]
          10. Applied rewrites77.6%

            \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(-0.5, b, y\right)\right) \]
        3. Recombined 3 regimes into one program.
        4. Add Preprocessing

        Alternative 6: 86.8% accurate, 1.0× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := 1 - \log t\\ \mathbf{if}\;z \leq -1.52 \cdot 10^{+174}:\\ \;\;\;\;\mathsf{fma}\left(t\_1, z, b \cdot a\right)\\ \mathbf{elif}\;z \leq 1.35 \cdot 10^{+193}:\\ \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(t\_1, z, y\right)\\ \end{array} \end{array} \]
        (FPCore (x y z t a b)
         :precision binary64
         (let* ((t_1 (- 1.0 (log t))))
           (if (<= z -1.52e+174)
             (fma t_1 z (* b a))
             (if (<= z 1.35e+193) (+ (fma (- a 0.5) b y) x) (fma t_1 z y)))))
        double code(double x, double y, double z, double t, double a, double b) {
        	double t_1 = 1.0 - log(t);
        	double tmp;
        	if (z <= -1.52e+174) {
        		tmp = fma(t_1, z, (b * a));
        	} else if (z <= 1.35e+193) {
        		tmp = fma((a - 0.5), b, y) + x;
        	} else {
        		tmp = fma(t_1, z, y);
        	}
        	return tmp;
        }
        
        function code(x, y, z, t, a, b)
        	t_1 = Float64(1.0 - log(t))
        	tmp = 0.0
        	if (z <= -1.52e+174)
        		tmp = fma(t_1, z, Float64(b * a));
        	elseif (z <= 1.35e+193)
        		tmp = Float64(fma(Float64(a - 0.5), b, y) + x);
        	else
        		tmp = fma(t_1, z, y);
        	end
        	return tmp
        end
        
        code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(1.0 - N[Log[t], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.52e+174], N[(t$95$1 * z + N[(b * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.35e+193], N[(N[(N[(a - 0.5), $MachinePrecision] * b + y), $MachinePrecision] + x), $MachinePrecision], N[(t$95$1 * z + y), $MachinePrecision]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := 1 - \log t\\
        \mathbf{if}\;z \leq -1.52 \cdot 10^{+174}:\\
        \;\;\;\;\mathsf{fma}\left(t\_1, z, b \cdot a\right)\\
        
        \mathbf{elif}\;z \leq 1.35 \cdot 10^{+193}:\\
        \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\
        
        \mathbf{else}:\\
        \;\;\;\;\mathsf{fma}\left(t\_1, z, y\right)\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if z < -1.52000000000000004e174

          1. Initial program 99.7%

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
            12. lift--.f6499.8

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
          4. Applied rewrites99.8%

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

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

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

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

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

              \[\leadsto \left(\left(1 - \log t\right) \cdot z + \left(a - \frac{1}{2}\right) \cdot b\right) + y \]
            5. associate-+l+N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            7. lift-log.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            8. lift--.f64N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot \left(a - \frac{1}{2}\right) + y\right) \]
            10. lower-fma.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - \frac{1}{2}, y\right)\right) \]
            11. lift--.f6491.4

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right) \]
          7. Applied rewrites91.4%

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

            \[\leadsto \mathsf{fma}\left(1 - \log t, z, a \cdot b\right) \]
          9. Step-by-step derivation
            1. *-commutativeN/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot a\right) \]
            2. lower-*.f6478.5

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot a\right) \]
          10. Applied rewrites78.5%

            \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot a\right) \]

          if -1.52000000000000004e174 < z < 1.35e193

          1. Initial program 99.9%

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

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

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

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

              \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
            4. *-commutativeN/A

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

              \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
            6. lift--.f6489.6

              \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
          4. Applied rewrites89.6%

            \[\leadsto \color{blue}{\mathsf{fma}\left(a - 0.5, b, y\right) + x} \]

          if 1.35e193 < z

          1. Initial program 99.3%

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

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

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

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

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

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

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

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

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

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

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

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

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
            12. lift--.f6499.7

              \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
          4. Applied rewrites99.7%

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

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

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

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

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

              \[\leadsto \left(\left(1 - \log t\right) \cdot z + \left(a - \frac{1}{2}\right) \cdot b\right) + y \]
            5. associate-+l+N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            7. lift-log.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
            8. lift--.f64N/A

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot \left(a - \frac{1}{2}\right) + y\right) \]
            10. lower-fma.f64N/A

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - \frac{1}{2}, y\right)\right) \]
            11. lift--.f6492.4

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right) \]
          7. Applied rewrites92.4%

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

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

              \[\leadsto \mathsf{fma}\left(1 - \log t, z, y\right) \]
          10. Recombined 3 regimes into one program.
          11. Add Preprocessing

          Alternative 7: 86.8% accurate, 1.0× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(1 - \log t, z, y\right)\\ \mathbf{if}\;z \leq -2.25 \cdot 10^{+196}:\\ \;\;\;\;t\_1 + x\\ \mathbf{elif}\;z \leq 1.35 \cdot 10^{+193}:\\ \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
          (FPCore (x y z t a b)
           :precision binary64
           (let* ((t_1 (fma (- 1.0 (log t)) z y)))
             (if (<= z -2.25e+196)
               (+ t_1 x)
               (if (<= z 1.35e+193) (+ (fma (- a 0.5) b y) x) t_1))))
          double code(double x, double y, double z, double t, double a, double b) {
          	double t_1 = fma((1.0 - log(t)), z, y);
          	double tmp;
          	if (z <= -2.25e+196) {
          		tmp = t_1 + x;
          	} else if (z <= 1.35e+193) {
          		tmp = fma((a - 0.5), b, y) + x;
          	} else {
          		tmp = t_1;
          	}
          	return tmp;
          }
          
          function code(x, y, z, t, a, b)
          	t_1 = fma(Float64(1.0 - log(t)), z, y)
          	tmp = 0.0
          	if (z <= -2.25e+196)
          		tmp = Float64(t_1 + x);
          	elseif (z <= 1.35e+193)
          		tmp = Float64(fma(Float64(a - 0.5), b, y) + x);
          	else
          		tmp = t_1;
          	end
          	return tmp
          end
          
          code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(1.0 - N[Log[t], $MachinePrecision]), $MachinePrecision] * z + y), $MachinePrecision]}, If[LessEqual[z, -2.25e+196], N[(t$95$1 + x), $MachinePrecision], If[LessEqual[z, 1.35e+193], N[(N[(N[(a - 0.5), $MachinePrecision] * b + y), $MachinePrecision] + x), $MachinePrecision], t$95$1]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          t_1 := \mathsf{fma}\left(1 - \log t, z, y\right)\\
          \mathbf{if}\;z \leq -2.25 \cdot 10^{+196}:\\
          \;\;\;\;t\_1 + x\\
          
          \mathbf{elif}\;z \leq 1.35 \cdot 10^{+193}:\\
          \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\
          
          \mathbf{else}:\\
          \;\;\;\;t\_1\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if z < -2.24999999999999989e196

            1. Initial program 99.7%

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
              12. lift--.f6499.7

                \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
            4. Applied rewrites99.7%

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

              \[\leadsto \left(y + z \cdot \left(1 - \log t\right)\right) + x \]
            6. Step-by-step derivation
              1. +-commutativeN/A

                \[\leadsto \left(z \cdot \left(1 - \log t\right) + y\right) + x \]
              2. *-commutativeN/A

                \[\leadsto \left(\left(1 - \log t\right) \cdot z + y\right) + x \]
              3. lower-fma.f64N/A

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, y\right) + x \]
              4. lift-log.f64N/A

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, y\right) + x \]
              5. lift--.f6481.4

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, y\right) + x \]
            7. Applied rewrites81.4%

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

            if -2.24999999999999989e196 < z < 1.35e193

            1. Initial program 99.9%

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

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

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

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

                \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
              4. *-commutativeN/A

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

                \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
              6. lift--.f6488.9

                \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
            4. Applied rewrites88.9%

              \[\leadsto \color{blue}{\mathsf{fma}\left(a - 0.5, b, y\right) + x} \]

            if 1.35e193 < z

            1. Initial program 99.3%

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

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

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

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

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

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

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

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

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

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

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

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

                \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
              12. lift--.f6499.7

                \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
            4. Applied rewrites99.7%

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

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

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

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

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

                \[\leadsto \left(\left(1 - \log t\right) \cdot z + \left(a - \frac{1}{2}\right) \cdot b\right) + y \]
              5. associate-+l+N/A

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

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
              7. lift-log.f64N/A

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
              8. lift--.f64N/A

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

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot \left(a - \frac{1}{2}\right) + y\right) \]
              10. lower-fma.f64N/A

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - \frac{1}{2}, y\right)\right) \]
              11. lift--.f6492.4

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right) \]
            7. Applied rewrites92.4%

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

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

                \[\leadsto \mathsf{fma}\left(1 - \log t, z, y\right) \]
            10. Recombined 3 regimes into one program.
            11. Add Preprocessing

            Alternative 8: 86.0% accurate, 1.0× speedup?

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

              1. Initial program 99.5%

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

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

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

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

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

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

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

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

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

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

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

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

                  \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                12. lift--.f6499.7

                  \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
              4. Applied rewrites99.7%

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

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

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

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

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

                  \[\leadsto \left(\left(1 - \log t\right) \cdot z + \left(a - \frac{1}{2}\right) \cdot b\right) + y \]
                5. associate-+l+N/A

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

                  \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
                7. lift-log.f64N/A

                  \[\leadsto \mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b + y\right) \]
                8. lift--.f64N/A

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

                  \[\leadsto \mathsf{fma}\left(1 - \log t, z, b \cdot \left(a - \frac{1}{2}\right) + y\right) \]
                10. lower-fma.f64N/A

                  \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - \frac{1}{2}, y\right)\right) \]
                11. lift--.f6492.4

                  \[\leadsto \mathsf{fma}\left(1 - \log t, z, \mathsf{fma}\left(b, a - 0.5, y\right)\right) \]
              7. Applied rewrites92.4%

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

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

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

                if -1.7e199 < z < 1.35e193

                1. Initial program 99.9%

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

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

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

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

                    \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                  4. *-commutativeN/A

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

                    \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                  6. lift--.f6488.8

                    \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                4. Applied rewrites88.8%

                  \[\leadsto \color{blue}{\mathsf{fma}\left(a - 0.5, b, y\right) + x} \]
              10. Recombined 2 regimes into one program.
              11. Add Preprocessing

              Alternative 9: 84.7% accurate, 1.0× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(1 - \log t\right) \cdot z\\ \mathbf{if}\;z \leq -3 \cdot 10^{+218}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 1.5 \cdot 10^{+216}:\\ \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
              (FPCore (x y z t a b)
               :precision binary64
               (let* ((t_1 (* (- 1.0 (log t)) z)))
                 (if (<= z -3e+218) t_1 (if (<= z 1.5e+216) (+ (fma (- a 0.5) b y) x) t_1))))
              double code(double x, double y, double z, double t, double a, double b) {
              	double t_1 = (1.0 - log(t)) * z;
              	double tmp;
              	if (z <= -3e+218) {
              		tmp = t_1;
              	} else if (z <= 1.5e+216) {
              		tmp = fma((a - 0.5), b, y) + x;
              	} else {
              		tmp = t_1;
              	}
              	return tmp;
              }
              
              function code(x, y, z, t, a, b)
              	t_1 = Float64(Float64(1.0 - log(t)) * z)
              	tmp = 0.0
              	if (z <= -3e+218)
              		tmp = t_1;
              	elseif (z <= 1.5e+216)
              		tmp = Float64(fma(Float64(a - 0.5), b, y) + x);
              	else
              		tmp = t_1;
              	end
              	return tmp
              end
              
              code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(1.0 - N[Log[t], $MachinePrecision]), $MachinePrecision] * z), $MachinePrecision]}, If[LessEqual[z, -3e+218], t$95$1, If[LessEqual[z, 1.5e+216], N[(N[(N[(a - 0.5), $MachinePrecision] * b + y), $MachinePrecision] + x), $MachinePrecision], t$95$1]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_1 := \left(1 - \log t\right) \cdot z\\
              \mathbf{if}\;z \leq -3 \cdot 10^{+218}:\\
              \;\;\;\;t\_1\\
              
              \mathbf{elif}\;z \leq 1.5 \cdot 10^{+216}:\\
              \;\;\;\;\mathsf{fma}\left(a - 0.5, b, y\right) + x\\
              
              \mathbf{else}:\\
              \;\;\;\;t\_1\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if z < -3.0000000000000001e218 or 1.4999999999999999e216 < z

                1. Initial program 99.4%

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

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

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

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

                    \[\leadsto \left(1 - \log t\right) \cdot z \]
                  4. lift-log.f6470.6

                    \[\leadsto \left(1 - \log t\right) \cdot z \]
                4. Applied rewrites70.6%

                  \[\leadsto \color{blue}{\left(1 - \log t\right) \cdot z} \]

                if -3.0000000000000001e218 < z < 1.4999999999999999e216

                1. Initial program 99.9%

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

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

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

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

                    \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                  4. *-commutativeN/A

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

                    \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                  6. lift--.f6487.2

                    \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                4. Applied rewrites87.2%

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

              Alternative 10: 63.5% accurate, 1.9× speedup?

              \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(a - 0.5\right) \cdot b\\ \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+145}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_1 \leq 10^{+35}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;t\_1 \leq 5 \cdot 10^{+88}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+199}:\\ \;\;\;\;\mathsf{fma}\left(b, a, y\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
              (FPCore (x y z t a b)
               :precision binary64
               (let* ((t_1 (* (- a 0.5) b)))
                 (if (<= t_1 -1e+145)
                   t_1
                   (if (<= t_1 1e+35)
                     (+ y x)
                     (if (<= t_1 5e+88) t_1 (if (<= t_1 2e+199) (fma b a y) t_1))))))
              double code(double x, double y, double z, double t, double a, double b) {
              	double t_1 = (a - 0.5) * b;
              	double tmp;
              	if (t_1 <= -1e+145) {
              		tmp = t_1;
              	} else if (t_1 <= 1e+35) {
              		tmp = y + x;
              	} else if (t_1 <= 5e+88) {
              		tmp = t_1;
              	} else if (t_1 <= 2e+199) {
              		tmp = fma(b, a, y);
              	} else {
              		tmp = t_1;
              	}
              	return tmp;
              }
              
              function code(x, y, z, t, a, b)
              	t_1 = Float64(Float64(a - 0.5) * b)
              	tmp = 0.0
              	if (t_1 <= -1e+145)
              		tmp = t_1;
              	elseif (t_1 <= 1e+35)
              		tmp = Float64(y + x);
              	elseif (t_1 <= 5e+88)
              		tmp = t_1;
              	elseif (t_1 <= 2e+199)
              		tmp = fma(b, a, y);
              	else
              		tmp = t_1;
              	end
              	return tmp
              end
              
              code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(a - 0.5), $MachinePrecision] * b), $MachinePrecision]}, If[LessEqual[t$95$1, -1e+145], t$95$1, If[LessEqual[t$95$1, 1e+35], N[(y + x), $MachinePrecision], If[LessEqual[t$95$1, 5e+88], t$95$1, If[LessEqual[t$95$1, 2e+199], N[(b * a + y), $MachinePrecision], t$95$1]]]]]
              
              \begin{array}{l}
              
              \\
              \begin{array}{l}
              t_1 := \left(a - 0.5\right) \cdot b\\
              \mathbf{if}\;t\_1 \leq -1 \cdot 10^{+145}:\\
              \;\;\;\;t\_1\\
              
              \mathbf{elif}\;t\_1 \leq 10^{+35}:\\
              \;\;\;\;y + x\\
              
              \mathbf{elif}\;t\_1 \leq 5 \cdot 10^{+88}:\\
              \;\;\;\;t\_1\\
              
              \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+199}:\\
              \;\;\;\;\mathsf{fma}\left(b, a, y\right)\\
              
              \mathbf{else}:\\
              \;\;\;\;t\_1\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 3 regimes
              2. if (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < -9.9999999999999999e144 or 9.9999999999999997e34 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < 4.99999999999999997e88 or 2.00000000000000019e199 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b)

                1. Initial program 99.9%

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

                  \[\leadsto \color{blue}{b \cdot \left(a - \frac{1}{2}\right)} \]
                3. Step-by-step derivation
                  1. *-commutativeN/A

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

                    \[\leadsto \left(a - \frac{1}{2}\right) \cdot \color{blue}{b} \]
                  3. lift--.f6472.4

                    \[\leadsto \left(a - 0.5\right) \cdot b \]
                4. Applied rewrites72.4%

                  \[\leadsto \color{blue}{\left(a - 0.5\right) \cdot b} \]

                if -9.9999999999999999e144 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < 9.9999999999999997e34

                1. Initial program 99.8%

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

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

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

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

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

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

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

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

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

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

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

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

                    \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                  12. lift--.f6499.9

                    \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
                4. Applied rewrites99.9%

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

                  \[\leadsto y + x \]
                6. Step-by-step derivation
                  1. Applied rewrites60.8%

                    \[\leadsto y + x \]

                  if 4.99999999999999997e88 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < 2.00000000000000019e199

                  1. Initial program 99.9%

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

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

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

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

                      \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                    4. *-commutativeN/A

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

                      \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                    6. lift--.f6477.5

                      \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                  4. Applied rewrites77.5%

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

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

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

                      \[\leadsto \mathsf{fma}\left(b, a - \color{blue}{\frac{1}{2}}, y\right) \]
                    3. lift--.f6458.4

                      \[\leadsto \mathsf{fma}\left(b, a - 0.5, y\right) \]
                  7. Applied rewrites58.4%

                    \[\leadsto \mathsf{fma}\left(b, \color{blue}{a - 0.5}, y\right) \]
                  8. Taylor expanded in a around inf

                    \[\leadsto \mathsf{fma}\left(b, a, y\right) \]
                  9. Step-by-step derivation
                    1. Applied rewrites39.0%

                      \[\leadsto \mathsf{fma}\left(b, a, y\right) \]
                  10. Recombined 3 regimes into one program.
                  11. Add Preprocessing

                  Alternative 11: 58.2% accurate, 2.0× speedup?

                  \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(a - 0.5\right) \cdot b\\ \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+274}:\\ \;\;\;\;b \cdot a\\ \mathbf{elif}\;t\_1 \leq -5 \cdot 10^{+38}:\\ \;\;\;\;\mathsf{fma}\left(b, -0.5, y\right)\\ \mathbf{elif}\;t\_1 \leq 10^{+35}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+261}:\\ \;\;\;\;\mathsf{fma}\left(b, -0.5, y\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot a\\ \end{array} \end{array} \]
                  (FPCore (x y z t a b)
                   :precision binary64
                   (let* ((t_1 (* (- a 0.5) b)))
                     (if (<= t_1 -4e+274)
                       (* b a)
                       (if (<= t_1 -5e+38)
                         (fma b -0.5 y)
                         (if (<= t_1 1e+35)
                           (+ y x)
                           (if (<= t_1 4e+261) (fma b -0.5 y) (* b a)))))))
                  double code(double x, double y, double z, double t, double a, double b) {
                  	double t_1 = (a - 0.5) * b;
                  	double tmp;
                  	if (t_1 <= -4e+274) {
                  		tmp = b * a;
                  	} else if (t_1 <= -5e+38) {
                  		tmp = fma(b, -0.5, y);
                  	} else if (t_1 <= 1e+35) {
                  		tmp = y + x;
                  	} else if (t_1 <= 4e+261) {
                  		tmp = fma(b, -0.5, y);
                  	} else {
                  		tmp = b * a;
                  	}
                  	return tmp;
                  }
                  
                  function code(x, y, z, t, a, b)
                  	t_1 = Float64(Float64(a - 0.5) * b)
                  	tmp = 0.0
                  	if (t_1 <= -4e+274)
                  		tmp = Float64(b * a);
                  	elseif (t_1 <= -5e+38)
                  		tmp = fma(b, -0.5, y);
                  	elseif (t_1 <= 1e+35)
                  		tmp = Float64(y + x);
                  	elseif (t_1 <= 4e+261)
                  		tmp = fma(b, -0.5, y);
                  	else
                  		tmp = Float64(b * a);
                  	end
                  	return tmp
                  end
                  
                  code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(a - 0.5), $MachinePrecision] * b), $MachinePrecision]}, If[LessEqual[t$95$1, -4e+274], N[(b * a), $MachinePrecision], If[LessEqual[t$95$1, -5e+38], N[(b * -0.5 + y), $MachinePrecision], If[LessEqual[t$95$1, 1e+35], N[(y + x), $MachinePrecision], If[LessEqual[t$95$1, 4e+261], N[(b * -0.5 + y), $MachinePrecision], N[(b * a), $MachinePrecision]]]]]]
                  
                  \begin{array}{l}
                  
                  \\
                  \begin{array}{l}
                  t_1 := \left(a - 0.5\right) \cdot b\\
                  \mathbf{if}\;t\_1 \leq -4 \cdot 10^{+274}:\\
                  \;\;\;\;b \cdot a\\
                  
                  \mathbf{elif}\;t\_1 \leq -5 \cdot 10^{+38}:\\
                  \;\;\;\;\mathsf{fma}\left(b, -0.5, y\right)\\
                  
                  \mathbf{elif}\;t\_1 \leq 10^{+35}:\\
                  \;\;\;\;y + x\\
                  
                  \mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+261}:\\
                  \;\;\;\;\mathsf{fma}\left(b, -0.5, y\right)\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;b \cdot a\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 3 regimes
                  2. if (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < -3.99999999999999969e274 or 3.9999999999999997e261 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b)

                    1. Initial program 99.9%

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

                      \[\leadsto \color{blue}{a \cdot b} \]
                    3. Step-by-step derivation
                      1. *-commutativeN/A

                        \[\leadsto b \cdot \color{blue}{a} \]
                      2. lower-*.f6480.8

                        \[\leadsto b \cdot \color{blue}{a} \]
                    4. Applied rewrites80.8%

                      \[\leadsto \color{blue}{b \cdot a} \]

                    if -3.99999999999999969e274 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < -4.9999999999999997e38 or 9.9999999999999997e34 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < 3.9999999999999997e261

                    1. Initial program 99.9%

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

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

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

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

                        \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                      4. *-commutativeN/A

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

                        \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                      6. lift--.f6479.9

                        \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                    4. Applied rewrites79.9%

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

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

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

                        \[\leadsto \mathsf{fma}\left(b, a - \color{blue}{\frac{1}{2}}, y\right) \]
                      3. lift--.f6462.1

                        \[\leadsto \mathsf{fma}\left(b, a - 0.5, y\right) \]
                    7. Applied rewrites62.1%

                      \[\leadsto \mathsf{fma}\left(b, \color{blue}{a - 0.5}, y\right) \]
                    8. Taylor expanded in a around 0

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

                        \[\leadsto \mathsf{fma}\left(b, -0.5, y\right) \]

                      if -4.9999999999999997e38 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < 9.9999999999999997e34

                      1. Initial program 99.8%

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

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

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

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

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

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

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

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

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

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

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

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

                          \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                        12. lift--.f6499.9

                          \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
                      4. Applied rewrites99.9%

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

                        \[\leadsto y + x \]
                      6. Step-by-step derivation
                        1. Applied rewrites63.2%

                          \[\leadsto y + x \]
                      7. Recombined 3 regimes into one program.
                      8. Add Preprocessing

                      Alternative 12: 57.9% accurate, 2.6× speedup?

                      \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(a - 0.5\right) \cdot b\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+250}:\\ \;\;\;\;b \cdot a\\ \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+199}:\\ \;\;\;\;y + x\\ \mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+261}:\\ \;\;\;\;-0.5 \cdot b\\ \mathbf{else}:\\ \;\;\;\;b \cdot a\\ \end{array} \end{array} \]
                      (FPCore (x y z t a b)
                       :precision binary64
                       (let* ((t_1 (* (- a 0.5) b)))
                         (if (<= t_1 -2e+250)
                           (* b a)
                           (if (<= t_1 2e+199) (+ y x) (if (<= t_1 4e+261) (* -0.5 b) (* b a))))))
                      double code(double x, double y, double z, double t, double a, double b) {
                      	double t_1 = (a - 0.5) * b;
                      	double tmp;
                      	if (t_1 <= -2e+250) {
                      		tmp = b * a;
                      	} else if (t_1 <= 2e+199) {
                      		tmp = y + x;
                      	} else if (t_1 <= 4e+261) {
                      		tmp = -0.5 * b;
                      	} else {
                      		tmp = b * a;
                      	}
                      	return tmp;
                      }
                      
                      module fmin_fmax_functions
                          implicit none
                          private
                          public fmax
                          public fmin
                      
                          interface fmax
                              module procedure fmax88
                              module procedure fmax44
                              module procedure fmax84
                              module procedure fmax48
                          end interface
                          interface fmin
                              module procedure fmin88
                              module procedure fmin44
                              module procedure fmin84
                              module procedure fmin48
                          end interface
                      contains
                          real(8) function fmax88(x, y) result (res)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                          end function
                          real(4) function fmax44(x, y) result (res)
                              real(4), intent (in) :: x
                              real(4), intent (in) :: y
                              res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                          end function
                          real(8) function fmax84(x, y) result(res)
                              real(8), intent (in) :: x
                              real(4), intent (in) :: y
                              res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                          end function
                          real(8) function fmax48(x, y) result(res)
                              real(4), intent (in) :: x
                              real(8), intent (in) :: y
                              res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                          end function
                          real(8) function fmin88(x, y) result (res)
                              real(8), intent (in) :: x
                              real(8), intent (in) :: y
                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                          end function
                          real(4) function fmin44(x, y) result (res)
                              real(4), intent (in) :: x
                              real(4), intent (in) :: y
                              res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                          end function
                          real(8) function fmin84(x, y) result(res)
                              real(8), intent (in) :: x
                              real(4), intent (in) :: y
                              res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                          end function
                          real(8) function fmin48(x, y) result(res)
                              real(4), intent (in) :: x
                              real(8), intent (in) :: y
                              res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                          end function
                      end module
                      
                      real(8) function code(x, y, z, t, a, 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 = (a - 0.5d0) * b
                          if (t_1 <= (-2d+250)) then
                              tmp = b * a
                          else if (t_1 <= 2d+199) then
                              tmp = y + x
                          else if (t_1 <= 4d+261) then
                              tmp = (-0.5d0) * b
                          else
                              tmp = b * a
                          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 = (a - 0.5) * b;
                      	double tmp;
                      	if (t_1 <= -2e+250) {
                      		tmp = b * a;
                      	} else if (t_1 <= 2e+199) {
                      		tmp = y + x;
                      	} else if (t_1 <= 4e+261) {
                      		tmp = -0.5 * b;
                      	} else {
                      		tmp = b * a;
                      	}
                      	return tmp;
                      }
                      
                      def code(x, y, z, t, a, b):
                      	t_1 = (a - 0.5) * b
                      	tmp = 0
                      	if t_1 <= -2e+250:
                      		tmp = b * a
                      	elif t_1 <= 2e+199:
                      		tmp = y + x
                      	elif t_1 <= 4e+261:
                      		tmp = -0.5 * b
                      	else:
                      		tmp = b * a
                      	return tmp
                      
                      function code(x, y, z, t, a, b)
                      	t_1 = Float64(Float64(a - 0.5) * b)
                      	tmp = 0.0
                      	if (t_1 <= -2e+250)
                      		tmp = Float64(b * a);
                      	elseif (t_1 <= 2e+199)
                      		tmp = Float64(y + x);
                      	elseif (t_1 <= 4e+261)
                      		tmp = Float64(-0.5 * b);
                      	else
                      		tmp = Float64(b * a);
                      	end
                      	return tmp
                      end
                      
                      function tmp_2 = code(x, y, z, t, a, b)
                      	t_1 = (a - 0.5) * b;
                      	tmp = 0.0;
                      	if (t_1 <= -2e+250)
                      		tmp = b * a;
                      	elseif (t_1 <= 2e+199)
                      		tmp = y + x;
                      	elseif (t_1 <= 4e+261)
                      		tmp = -0.5 * b;
                      	else
                      		tmp = b * a;
                      	end
                      	tmp_2 = tmp;
                      end
                      
                      code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(a - 0.5), $MachinePrecision] * b), $MachinePrecision]}, If[LessEqual[t$95$1, -2e+250], N[(b * a), $MachinePrecision], If[LessEqual[t$95$1, 2e+199], N[(y + x), $MachinePrecision], If[LessEqual[t$95$1, 4e+261], N[(-0.5 * b), $MachinePrecision], N[(b * a), $MachinePrecision]]]]]
                      
                      \begin{array}{l}
                      
                      \\
                      \begin{array}{l}
                      t_1 := \left(a - 0.5\right) \cdot b\\
                      \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+250}:\\
                      \;\;\;\;b \cdot a\\
                      
                      \mathbf{elif}\;t\_1 \leq 2 \cdot 10^{+199}:\\
                      \;\;\;\;y + x\\
                      
                      \mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+261}:\\
                      \;\;\;\;-0.5 \cdot b\\
                      
                      \mathbf{else}:\\
                      \;\;\;\;b \cdot a\\
                      
                      
                      \end{array}
                      \end{array}
                      
                      Derivation
                      1. Split input into 3 regimes
                      2. if (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < -1.9999999999999998e250 or 3.9999999999999997e261 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b)

                        1. Initial program 99.9%

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

                          \[\leadsto \color{blue}{a \cdot b} \]
                        3. Step-by-step derivation
                          1. *-commutativeN/A

                            \[\leadsto b \cdot \color{blue}{a} \]
                          2. lower-*.f6476.6

                            \[\leadsto b \cdot \color{blue}{a} \]
                        4. Applied rewrites76.6%

                          \[\leadsto \color{blue}{b \cdot a} \]

                        if -1.9999999999999998e250 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < 2.00000000000000019e199

                        1. Initial program 99.8%

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

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

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

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

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

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

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

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

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

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

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

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

                            \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                          12. lift--.f6499.9

                            \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
                        4. Applied rewrites99.9%

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

                          \[\leadsto y + x \]
                        6. Step-by-step derivation
                          1. Applied rewrites54.3%

                            \[\leadsto y + x \]

                          if 2.00000000000000019e199 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < 3.9999999999999997e261

                          1. Initial program 99.9%

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

                            \[\leadsto \color{blue}{b \cdot \left(a - \frac{1}{2}\right)} \]
                          3. Step-by-step derivation
                            1. *-commutativeN/A

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

                              \[\leadsto \left(a - \frac{1}{2}\right) \cdot \color{blue}{b} \]
                            3. lift--.f6464.2

                              \[\leadsto \left(a - 0.5\right) \cdot b \]
                          4. Applied rewrites64.2%

                            \[\leadsto \color{blue}{\left(a - 0.5\right) \cdot b} \]
                          5. Taylor expanded in a around 0

                            \[\leadsto \frac{-1}{2} \cdot b \]
                          6. Step-by-step derivation
                            1. Applied rewrites35.3%

                              \[\leadsto -0.5 \cdot b \]
                          7. Recombined 3 regimes into one program.
                          8. Add Preprocessing

                          Alternative 13: 57.6% accurate, 3.7× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(a - 0.5\right) \cdot b\\ \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+250}:\\ \;\;\;\;b \cdot a\\ \mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+212}:\\ \;\;\;\;y + x\\ \mathbf{else}:\\ \;\;\;\;b \cdot a\\ \end{array} \end{array} \]
                          (FPCore (x y z t a b)
                           :precision binary64
                           (let* ((t_1 (* (- a 0.5) b)))
                             (if (<= t_1 -2e+250) (* b a) (if (<= t_1 4e+212) (+ y x) (* b a)))))
                          double code(double x, double y, double z, double t, double a, double b) {
                          	double t_1 = (a - 0.5) * b;
                          	double tmp;
                          	if (t_1 <= -2e+250) {
                          		tmp = b * a;
                          	} else if (t_1 <= 4e+212) {
                          		tmp = y + x;
                          	} else {
                          		tmp = b * a;
                          	}
                          	return tmp;
                          }
                          
                          module fmin_fmax_functions
                              implicit none
                              private
                              public fmax
                              public fmin
                          
                              interface fmax
                                  module procedure fmax88
                                  module procedure fmax44
                                  module procedure fmax84
                                  module procedure fmax48
                              end interface
                              interface fmin
                                  module procedure fmin88
                                  module procedure fmin44
                                  module procedure fmin84
                                  module procedure fmin48
                              end interface
                          contains
                              real(8) function fmax88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmax44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, max(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmax84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmax48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
                              end function
                              real(8) function fmin88(x, y) result (res)
                                  real(8), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(4) function fmin44(x, y) result (res)
                                  real(4), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(y, merge(x, min(x, y), y /= y), x /= x)
                              end function
                              real(8) function fmin84(x, y) result(res)
                                  real(8), intent (in) :: x
                                  real(4), intent (in) :: y
                                  res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
                              end function
                              real(8) function fmin48(x, y) result(res)
                                  real(4), intent (in) :: x
                                  real(8), intent (in) :: y
                                  res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
                              end function
                          end module
                          
                          real(8) function code(x, y, z, t, a, 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 = (a - 0.5d0) * b
                              if (t_1 <= (-2d+250)) then
                                  tmp = b * a
                              else if (t_1 <= 4d+212) then
                                  tmp = y + x
                              else
                                  tmp = b * a
                              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 = (a - 0.5) * b;
                          	double tmp;
                          	if (t_1 <= -2e+250) {
                          		tmp = b * a;
                          	} else if (t_1 <= 4e+212) {
                          		tmp = y + x;
                          	} else {
                          		tmp = b * a;
                          	}
                          	return tmp;
                          }
                          
                          def code(x, y, z, t, a, b):
                          	t_1 = (a - 0.5) * b
                          	tmp = 0
                          	if t_1 <= -2e+250:
                          		tmp = b * a
                          	elif t_1 <= 4e+212:
                          		tmp = y + x
                          	else:
                          		tmp = b * a
                          	return tmp
                          
                          function code(x, y, z, t, a, b)
                          	t_1 = Float64(Float64(a - 0.5) * b)
                          	tmp = 0.0
                          	if (t_1 <= -2e+250)
                          		tmp = Float64(b * a);
                          	elseif (t_1 <= 4e+212)
                          		tmp = Float64(y + x);
                          	else
                          		tmp = Float64(b * a);
                          	end
                          	return tmp
                          end
                          
                          function tmp_2 = code(x, y, z, t, a, b)
                          	t_1 = (a - 0.5) * b;
                          	tmp = 0.0;
                          	if (t_1 <= -2e+250)
                          		tmp = b * a;
                          	elseif (t_1 <= 4e+212)
                          		tmp = y + x;
                          	else
                          		tmp = b * a;
                          	end
                          	tmp_2 = tmp;
                          end
                          
                          code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(a - 0.5), $MachinePrecision] * b), $MachinePrecision]}, If[LessEqual[t$95$1, -2e+250], N[(b * a), $MachinePrecision], If[LessEqual[t$95$1, 4e+212], N[(y + x), $MachinePrecision], N[(b * a), $MachinePrecision]]]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          t_1 := \left(a - 0.5\right) \cdot b\\
                          \mathbf{if}\;t\_1 \leq -2 \cdot 10^{+250}:\\
                          \;\;\;\;b \cdot a\\
                          
                          \mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+212}:\\
                          \;\;\;\;y + x\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;b \cdot a\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 2 regimes
                          2. if (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < -1.9999999999999998e250 or 3.9999999999999996e212 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b)

                            1. Initial program 99.9%

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

                              \[\leadsto \color{blue}{a \cdot b} \]
                            3. Step-by-step derivation
                              1. *-commutativeN/A

                                \[\leadsto b \cdot \color{blue}{a} \]
                              2. lower-*.f6469.1

                                \[\leadsto b \cdot \color{blue}{a} \]
                            4. Applied rewrites69.1%

                              \[\leadsto \color{blue}{b \cdot a} \]

                            if -1.9999999999999998e250 < (*.f64 (-.f64 a #s(literal 1/2 binary64)) b) < 3.9999999999999996e212

                            1. Initial program 99.8%

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

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

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

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

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

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

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

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

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

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

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

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

                                \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                              12. lift--.f6499.9

                                \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
                            4. Applied rewrites99.9%

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

                              \[\leadsto y + x \]
                            6. Step-by-step derivation
                              1. Applied rewrites53.7%

                                \[\leadsto y + x \]
                            7. Recombined 2 regimes into one program.
                            8. Add Preprocessing

                            Alternative 14: 49.8% accurate, 4.7× speedup?

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

                              1. Initial program 99.9%

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

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

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

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

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

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

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

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

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

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

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

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

                                  \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                                12. lift--.f6499.9

                                  \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
                              4. Applied rewrites99.9%

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

                                \[\leadsto a \cdot b + x \]
                              6. Step-by-step derivation
                                1. *-commutativeN/A

                                  \[\leadsto b \cdot a + x \]
                                2. lower-*.f6448.8

                                  \[\leadsto b \cdot a + x \]
                              7. Applied rewrites48.8%

                                \[\leadsto b \cdot a + x \]

                              if -4.99999999999999972e71 < (+.f64 x y) < 2.0000000000000001e-22

                              1. Initial program 99.8%

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

                                \[\leadsto \color{blue}{b \cdot \left(a - \frac{1}{2}\right)} \]
                              3. Step-by-step derivation
                                1. *-commutativeN/A

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

                                  \[\leadsto \left(a - \frac{1}{2}\right) \cdot \color{blue}{b} \]
                                3. lift--.f6453.6

                                  \[\leadsto \left(a - 0.5\right) \cdot b \]
                              4. Applied rewrites53.6%

                                \[\leadsto \color{blue}{\left(a - 0.5\right) \cdot b} \]

                              if 2.0000000000000001e-22 < (+.f64 x y)

                              1. Initial program 99.9%

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

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

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

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

                                  \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                                4. *-commutativeN/A

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

                                  \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                                6. lift--.f6483.3

                                  \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                              4. Applied rewrites83.3%

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

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

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

                                  \[\leadsto \mathsf{fma}\left(b, a - \color{blue}{\frac{1}{2}}, y\right) \]
                                3. lift--.f6458.1

                                  \[\leadsto \mathsf{fma}\left(b, a - 0.5, y\right) \]
                              7. Applied rewrites58.1%

                                \[\leadsto \mathsf{fma}\left(b, \color{blue}{a - 0.5}, y\right) \]
                              8. Taylor expanded in a around inf

                                \[\leadsto \mathsf{fma}\left(b, a, y\right) \]
                              9. Step-by-step derivation
                                1. Applied rewrites47.8%

                                  \[\leadsto \mathsf{fma}\left(b, a, y\right) \]
                              10. Recombined 3 regimes into one program.
                              11. Add Preprocessing

                              Alternative 15: 57.1% accurate, 5.0× speedup?

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

                                1. Initial program 99.8%

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

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

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

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

                                    \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                                  4. *-commutativeN/A

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

                                    \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                                  6. lift--.f6482.5

                                    \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                                4. Applied rewrites82.5%

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

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

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

                                    \[\leadsto \mathsf{fma}\left(b, a - \color{blue}{\frac{1}{2}}, y\right) \]
                                  3. lift--.f6466.2

                                    \[\leadsto \mathsf{fma}\left(b, a - 0.5, y\right) \]
                                7. Applied rewrites66.2%

                                  \[\leadsto \mathsf{fma}\left(b, \color{blue}{a - 0.5}, y\right) \]
                                8. Taylor expanded in a around inf

                                  \[\leadsto \mathsf{fma}\left(b, a, y\right) \]
                                9. Step-by-step derivation
                                  1. Applied rewrites65.3%

                                    \[\leadsto \mathsf{fma}\left(b, a, y\right) \]

                                  if -0.5 < a < -2.3e-111

                                  1. Initial program 99.8%

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

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

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

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

                                      \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                                    4. *-commutativeN/A

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

                                      \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                                    6. lift--.f6473.7

                                      \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                                  4. Applied rewrites73.7%

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

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

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

                                      \[\leadsto \mathsf{fma}\left(b, a - \color{blue}{\frac{1}{2}}, y\right) \]
                                    3. lift--.f6450.4

                                      \[\leadsto \mathsf{fma}\left(b, a - 0.5, y\right) \]
                                  7. Applied rewrites50.4%

                                    \[\leadsto \mathsf{fma}\left(b, \color{blue}{a - 0.5}, y\right) \]
                                  8. Taylor expanded in a around 0

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

                                      \[\leadsto \mathsf{fma}\left(b, -0.5, y\right) \]

                                    if -2.3e-111 < a < 1.25000000000000006e-5

                                    1. Initial program 99.9%

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

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

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

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

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

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

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

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

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

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

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

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

                                        \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                                      12. lift--.f6499.9

                                        \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
                                    4. Applied rewrites99.9%

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

                                      \[\leadsto y + x \]
                                    6. Step-by-step derivation
                                      1. Applied rewrites49.3%

                                        \[\leadsto y + x \]
                                    7. Recombined 3 regimes into one program.
                                    8. Add Preprocessing

                                    Alternative 16: 55.5% accurate, 6.6× speedup?

                                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x + y \leq -5 \cdot 10^{+71}:\\ \;\;\;\;b \cdot a + x\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(b, a - 0.5, y\right)\\ \end{array} \end{array} \]
                                    (FPCore (x y z t a b)
                                     :precision binary64
                                     (if (<= (+ x y) -5e+71) (+ (* b a) x) (fma b (- a 0.5) y)))
                                    double code(double x, double y, double z, double t, double a, double b) {
                                    	double tmp;
                                    	if ((x + y) <= -5e+71) {
                                    		tmp = (b * a) + x;
                                    	} else {
                                    		tmp = fma(b, (a - 0.5), y);
                                    	}
                                    	return tmp;
                                    }
                                    
                                    function code(x, y, z, t, a, b)
                                    	tmp = 0.0
                                    	if (Float64(x + y) <= -5e+71)
                                    		tmp = Float64(Float64(b * a) + x);
                                    	else
                                    		tmp = fma(b, Float64(a - 0.5), y);
                                    	end
                                    	return tmp
                                    end
                                    
                                    code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(x + y), $MachinePrecision], -5e+71], N[(N[(b * a), $MachinePrecision] + x), $MachinePrecision], N[(b * N[(a - 0.5), $MachinePrecision] + y), $MachinePrecision]]
                                    
                                    \begin{array}{l}
                                    
                                    \\
                                    \begin{array}{l}
                                    \mathbf{if}\;x + y \leq -5 \cdot 10^{+71}:\\
                                    \;\;\;\;b \cdot a + x\\
                                    
                                    \mathbf{else}:\\
                                    \;\;\;\;\mathsf{fma}\left(b, a - 0.5, y\right)\\
                                    
                                    
                                    \end{array}
                                    \end{array}
                                    
                                    Derivation
                                    1. Split input into 2 regimes
                                    2. if (+.f64 x y) < -4.99999999999999972e71

                                      1. Initial program 99.9%

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

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

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

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

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

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

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

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

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

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

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

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

                                          \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                                        12. lift--.f6499.9

                                          \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
                                      4. Applied rewrites99.9%

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

                                        \[\leadsto a \cdot b + x \]
                                      6. Step-by-step derivation
                                        1. *-commutativeN/A

                                          \[\leadsto b \cdot a + x \]
                                        2. lower-*.f6448.8

                                          \[\leadsto b \cdot a + x \]
                                      7. Applied rewrites48.8%

                                        \[\leadsto b \cdot a + x \]

                                      if -4.99999999999999972e71 < (+.f64 x y)

                                      1. Initial program 99.8%

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

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

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

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

                                          \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                                        4. *-commutativeN/A

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

                                          \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                                        6. lift--.f6474.9

                                          \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                                      4. Applied rewrites74.9%

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

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

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

                                          \[\leadsto \mathsf{fma}\left(b, a - \color{blue}{\frac{1}{2}}, y\right) \]
                                        3. lift--.f6458.6

                                          \[\leadsto \mathsf{fma}\left(b, a - 0.5, y\right) \]
                                      7. Applied rewrites58.6%

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

                                    Alternative 17: 78.2% accurate, 9.7× speedup?

                                    \[\begin{array}{l} \\ \mathsf{fma}\left(a - 0.5, b, y\right) + x \end{array} \]
                                    (FPCore (x y z t a b) :precision binary64 (+ (fma (- a 0.5) b y) x))
                                    double code(double x, double y, double z, double t, double a, double b) {
                                    	return fma((a - 0.5), b, y) + x;
                                    }
                                    
                                    function code(x, y, z, t, a, b)
                                    	return Float64(fma(Float64(a - 0.5), b, y) + x)
                                    end
                                    
                                    code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(a - 0.5), $MachinePrecision] * b + y), $MachinePrecision] + x), $MachinePrecision]
                                    
                                    \begin{array}{l}
                                    
                                    \\
                                    \mathsf{fma}\left(a - 0.5, b, y\right) + x
                                    \end{array}
                                    
                                    Derivation
                                    1. Initial program 99.9%

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

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

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

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

                                        \[\leadsto \left(b \cdot \left(a - \frac{1}{2}\right) + y\right) + x \]
                                      4. *-commutativeN/A

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

                                        \[\leadsto \mathsf{fma}\left(a - \frac{1}{2}, b, y\right) + x \]
                                      6. lift--.f6478.2

                                        \[\leadsto \mathsf{fma}\left(a - 0.5, b, y\right) + x \]
                                    4. Applied rewrites78.2%

                                      \[\leadsto \color{blue}{\mathsf{fma}\left(a - 0.5, b, y\right) + x} \]
                                    5. Add Preprocessing

                                    Alternative 18: 42.3% accurate, 31.5× speedup?

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

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

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

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

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

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

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

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

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

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

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

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

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

                                        \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - \frac{1}{2}\right) \cdot b\right) + y\right) + x \]
                                      12. lift--.f6499.9

                                        \[\leadsto \left(\mathsf{fma}\left(1 - \log t, z, \left(a - 0.5\right) \cdot b\right) + y\right) + x \]
                                    4. Applied rewrites99.9%

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

                                      \[\leadsto y + x \]
                                    6. Step-by-step derivation
                                      1. Applied rewrites42.3%

                                        \[\leadsto y + x \]
                                      2. Add Preprocessing

                                      Alternative 19: 21.7% accurate, 126.0× speedup?

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

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

                                        \[\leadsto \color{blue}{x} \]
                                      3. Step-by-step derivation
                                        1. Applied rewrites21.7%

                                          \[\leadsto \color{blue}{x} \]
                                        2. Add Preprocessing

                                        Developer Target 1: 99.5% accurate, 0.4× speedup?

                                        \[\begin{array}{l} \\ \left(\left(x + y\right) + \frac{\left(1 - {\log t}^{2}\right) \cdot z}{1 + \log t}\right) + \left(a - 0.5\right) \cdot b \end{array} \]
                                        (FPCore (x y z t a b)
                                         :precision binary64
                                         (+
                                          (+ (+ x y) (/ (* (- 1.0 (pow (log t) 2.0)) z) (+ 1.0 (log t))))
                                          (* (- a 0.5) b)))
                                        double code(double x, double y, double z, double t, double a, double b) {
                                        	return ((x + y) + (((1.0 - pow(log(t), 2.0)) * z) / (1.0 + log(t)))) + ((a - 0.5) * b);
                                        }
                                        
                                        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) + (((1.0d0 - (log(t) ** 2.0d0)) * z) / (1.0d0 + log(t)))) + ((a - 0.5d0) * b)
                                        end function
                                        
                                        public static double code(double x, double y, double z, double t, double a, double b) {
                                        	return ((x + y) + (((1.0 - Math.pow(Math.log(t), 2.0)) * z) / (1.0 + Math.log(t)))) + ((a - 0.5) * b);
                                        }
                                        
                                        def code(x, y, z, t, a, b):
                                        	return ((x + y) + (((1.0 - math.pow(math.log(t), 2.0)) * z) / (1.0 + math.log(t)))) + ((a - 0.5) * b)
                                        
                                        function code(x, y, z, t, a, b)
                                        	return Float64(Float64(Float64(x + y) + Float64(Float64(Float64(1.0 - (log(t) ^ 2.0)) * z) / Float64(1.0 + log(t)))) + Float64(Float64(a - 0.5) * b))
                                        end
                                        
                                        function tmp = code(x, y, z, t, a, b)
                                        	tmp = ((x + y) + (((1.0 - (log(t) ^ 2.0)) * z) / (1.0 + log(t)))) + ((a - 0.5) * b);
                                        end
                                        
                                        code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x + y), $MachinePrecision] + N[(N[(N[(1.0 - N[Power[N[Log[t], $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * z), $MachinePrecision] / N[(1.0 + N[Log[t], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(a - 0.5), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
                                        
                                        \begin{array}{l}
                                        
                                        \\
                                        \left(\left(x + y\right) + \frac{\left(1 - {\log t}^{2}\right) \cdot z}{1 + \log t}\right) + \left(a - 0.5\right) \cdot b
                                        \end{array}
                                        

                                        Reproduce

                                        ?
                                        herbie shell --seed 2025103 
                                        (FPCore (x y z t a b)
                                          :name "Numeric.SpecFunctions:logBeta from math-functions-0.1.5.2, A"
                                          :precision binary64
                                        
                                          :alt
                                          (! :herbie-platform default (+ (+ (+ x y) (/ (* (- 1 (pow (log t) 2)) z) (+ 1 (log t)))) (* (- a 1/2) b)))
                                        
                                          (+ (- (+ (+ x y) z) (* z (log t))) (* (- a 0.5) b)))